Structural Primitives
Structural primitives create or delete metamodel elements.
Copy Feature
In the metamodel, a feature is copied, giving it a new name. In the model, the values are copied, accordingly.
Parameters:
- feature: The feature to be copied
- name: The name of the copy
Create Attribute
In the metamodel, a new attribute is created. Nothing is changed in the model.
Parameters:
- eClass: The class in which the attribute is created
- name: The name of the new attribute
- type: The type of the new attribute
- lowerBound: The lower bound of the new attribute
- upperBound: The upper bound of the new reference
- defaultValue: The default value literal
Create Class
In the metamodel, a new class is created. Nothing is changed in the model.
Parameters:
- ePackage: The package in which the class is created
- name: The name of the new class
- superClasses: The super classes of the new class
- abstr: Whether the class is abstract
Create Enumeration
In the metamodel, an enumeration is created. In the model, nothing needs to be changed.
Parameters:
- ePackage: The package in which the enumeration is created
- name: The name of the new enumeration
- literals: The names of the literals of the new enumeration
Create GMF Constraint
In the metamodel, a new constraint is introduced. Nothing is changed in the model.
Parameters:
- element: The metamodel element to be annotated
- ocl: The OCL expression of the constraint
- description: The description of the constraint
Constraints:
- The element must not be an annotation.
Create Opposite Reference
In the metamodel, an opposite is created for a reference. In the model, the opposite direction needs to be set.
Parameters:
- reference: The reference for which the opposite is created
- name: The name of the opposite reference
- lowerBound: The lower bound of the opposite reference
- upperBound: The upper bound of the opposite reference
- changeable: Whether the opposite reference is changeable
Constraints:
- In case of a cross reference, the upper bound of the opposite reference must be -1.
- The reference must not already have an opposite
- In case of a containment reference, the upper bound of the opposite reference must be 1.
Create Reference
In the metamodel, a new reference is created. Nothing is changed in the model.
Parameters:
- eClass: The class in which the reference is created
- name: The name of the new reference
- type: The type of the new reference
- lowerBound: The lower bound of the new reference
- upperBound: The upper bound of the new reference
- containment: Whether the new reference is a containment reference
- opposite: The opposite reference of the new reference
Delete Class
In the metamodel, a class that is no longer used is deleted. In the model, nothing is changed.
Parameters:
- eClass: The class to be deleted
Constraints:
- The class must not be the target of a reference
- The class must not have sub classes
- The class must not have super classes
Delete Feature
In the metamodel, a feature is deleted. In the model, its values are deleted, too.
Parameters:
- feature: The feature to be deleted
Delete Opposite Reference
In the metamodel, the opposite of a reference is deleted. In the model, its values are deleted, too.
Parameters:
- reference: The reference whose opposite should be deleted
Constraints:
- The reference needs to define an opposite
Delete Package
In the metamodel, an empty package is deleted.
Parameters:
- ePackage: The package to be deleted
Constraints:
- The package must not contain classifiers
- The package must not contain subpackages
Contents
- Structural Primitives
- Copy Feature
- Create Attribute
- Create Class
- Create Enumeration
- Create GMF Constraint
- Create Opposite Reference
- Create Reference
- Delete Class
- Delete Feature
- Delete Opposite Reference
- Delete Package
- Non-structural Primitives
- Generalization / Specialization Operations
- Inheritance Operations
- Delegation Operations
- Replacement Operations
- Merge Operations