Transformation scripts are written in VBScript using a certain number of special methods. Transformation scripts do not require as many checks as standard scripts, because they are always implemented in a new, empty, temporary model, which is merged with the generation target model.
CopyObject(source [,tag])Duplicates an existing object, sets a source for the duplicated object, and returns a copy of the new object.
SetSource(source, target [,tag])Sets the source object of a generated object. It is recommended to always set the source object to keep track of the origin of a generated object.
GetSource(target [,tag])Retrieves the source object of a generated object.
GetTarget(source [,tag])Retrieves the target object of a source object.
Internal transformation objects are preserved when the transformations are used via the Apply Transformations or a custom menu command, so that they can be re-executed if you subsequently update (regenerate) the model. For example, you generate a CDM entity A to an OOM class B and then apply a transformation to class B in order to create class C. If you make changes to entity A and repeat the generation to update the OOM, class B is updated and the transformation is automatically reapplied to update class C.