setPart method

void setPart(
  1. {required int index,
  2. required MutablePart mutablePart}
)

Replace a part in the mutable part collection at the specified part index.

Parameters:

  • index — Zero-based index of the part.
  • mutablePart — Collection of segments representing the part.

Implementation

void setPart({required int index, required MutablePart mutablePart}) {
  _withThrowingErrorHandler((errorHandler) {
    runtimecore.RT_MutablePartCollection_setPart(
        _handle, index, mutablePart._handle, errorHandler);
  });
}