addCustomModelChange Method

This method should only be called inside [IModelTransformer.addCustomChanges]. Adds the provided change to the model changes maintained by this instance of ChangedInstanceIds. If the same ECInstanceId is seen multiple times, the changedInstanceIds will be modified accordingly, i.e. if an id 'x' was updated but now we see 'x' was deleted, we will remove 'x' from the set of updatedIds and add it to the set of deletedIds for the appropriate class type. Will add same change to the model's modeledElement by calling addCustomElementChange which will register more needed changes. This is to ensure the changes from the model and its modeledElement get exported together.

addCustomModelChange(changeType: SqliteChangeOp, ids: Id64Arg): Promise<void>

@note It is the responsibility of the caller to ensure that the provided id is, in fact a model.

@note In most cases, this method does not need to be called. Its only for consumers to mimic changes as if they were found in a changeset, which should only be useful in certain cases such as the changing of filter criteria for a preexisting master branch relationship.

@note In data processing with filter criteria scenarios it is important to consistently filter out models and their modeled elements that were previously removed from target via addCustomModelChange or shouldExportElement apis.

Parameter Type Description
changeType SqliteChangeOp  
ids Id64Arg  

Returns - Promise

Defined in

Last Updated: 06 March, 2025