Interface MappingElementIF
- All Superinterfaces:
Serializable
- All Known Implementing Classes:
MappingElementBaseImpl,MappingElementDummy,MappingElementInnovator,MappingElementInnovatorDTD,MappingElementJavaBeans,MappingElementRepresentant,MappingElementText,MappingElementVirtualIndexed
Mapping element is a model element which takes part in the mapping either in
source or on target model.
- Version:
- 10.1.1
- Author:
- jmback
-
Method Summary
Modifier and TypeMethodDescriptioncloneIndexed(int virtualIndex) Creates from the original Element an cloned indexed elementcreateElement(ModelTransformationStepIF step, CreateDescriptorIF createDescriptor, MappingAnchor anchor) Create a new element in the same model as this element.voiddelete()Delete the mapping element.booleanequals(MappingElementIF obj) Compare two mapping elements (by hash).Get the children of the element.Get the display name of element's type.getElementProperty(ExpressionContext expressionContext, PropertyDescriptorIF descriptor) Get the property value for a property descriptor.getHash()Get the hash value of the element inside the mapping model.getIcon()Get the icon of the element.getModel()Get the model of the element.getName()Get the name.getObject(ExpressionContext expressionContext, String descriptor, PropertyDescriptorList subDescriptors) Return the element associated.getObjects(ExpressionContext expressionContext, String descriptor, PropertyDescriptorList subDescriptors) Return the element associated.getOwner()Get the owner of the element.getOwnerTransitive(MappingElementIF sentinel) Get transitive owner up to a sentinel.getPath()Get the path of the element inside the model.getProperty(ExpressionContext expressionContext, String descriptor) Return the property's value.getProperty(ExpressionContext expressionContext, String descriptor, PropertyDescriptorList subDescriptors) Return the property.Get the targets of the element.getType()Get the name of element's type.getURI()Get the URI.setElementProperty(PropertyDescriptorIF descriptor, PropertyValue value) Set the property.
-
Method Details
-
getHash
Long getHash()Get the hash value of the element inside the mapping model. Equal elements have same hash. Different elements have different hash.- Returns:
- the elements hash value unique within one model.
-
equals
Compare two mapping elements (by hash).- Parameters:
obj- other mapping element- Returns:
- true, if same hash code.
-
getName
String getName()Get the name.- Returns:
- the elements name
-
getType
String getType()Get the name of element's type.- Returns:
- the name of elements type
-
getDisplayType
Get the display name of element's type.- Returns:
- the display name of elements type
- Throws:
RemoteException
-
getPath
String getPath()Get the path of the element inside the model.- Returns:
- the elements path
-
getIcon
String getIcon()Get the icon of the element. Either provide the fully qualified file name or the name in the classpath or the file name for Innovator bitmaps.- Returns:
- the name of the elements icon, if exists
-
getURI
URI getURI()Get the URI. The URI can be used to retrieve an element from the mapping meta model.- Returns:
- URI of the element
-
getOwner
MappingElementIF getOwner()Get the owner of the element.- Returns:
- the owning element
-
getOwnerTransitive
Get transitive owner up to a sentinel.- Parameters:
sentinel- maybe null- Returns:
- gets owner transitive
-
getChildren
MappingElementList getChildren()Get the children of the element.- Returns:
- the children elements
-
getTargets
MappingElementList getTargets()Get the targets of the element.- Returns:
- the target elements ( e.g. dependency or relationship target ) otherwise returns nothing
-
getObject
MappingElementIF getObject(ExpressionContext expressionContext, String descriptor, PropertyDescriptorList subDescriptors) throws M2MException, RemoteException Return the element associated.- Parameters:
expressionContext- the context in which the navigatable object should be calculated.descriptor- navigation directivesubDescriptors- sub descriptors or parameters of the navigation directive- Returns:
- Element, if found
- Throws:
SevereException- an error has occured during access of InnovatorM2MExceptionRemoteException
-
getObjects
MappingElementList getObjects(ExpressionContext expressionContext, String descriptor, PropertyDescriptorList subDescriptors) throws M2MException, RemoteException Return the element associated.- Parameters:
expressionContext- the context in which the related objects should be calculated.descriptor- navigation directivesubDescriptors- sub descriptors or parameters of the navigation directive- Returns:
- List of Elements
- Throws:
M2MExceptionRemoteException
-
getProperty
PropertyValue getProperty(ExpressionContext expressionContext, String descriptor) throws M2MException, RemoteException Return the property's value. Remark: This is the property of type "Property".- Parameters:
expressionContext- TODOdescriptor- property name- Returns:
- primitive, if found
- Throws:
SevereException- an error has occurred during accessM2MExceptionRemoteException
-
getProperty
PropertyValue getProperty(ExpressionContext expressionContext, String descriptor, PropertyDescriptorList subDescriptors) throws M2MException, RemoteException Return the property.- Parameters:
expressionContext- TODOdescriptor- property namesubDescriptors- optional list of subdescriptors- Returns:
- primitive, if found
- Throws:
SevereException- an error has occurred during accessM2MExceptionRemoteException
-
getElementProperty
PropertyValue getElementProperty(ExpressionContext expressionContext, PropertyDescriptorIF descriptor) throws M2MException, RemoteException Get the property value for a property descriptor.- Parameters:
expressionContext- TODOdescriptor-- Returns:
- the elements property described by the PropertyDescriptor
- Throws:
SevereException- non critical errorAbortException- critical errorM2MExceptionRemoteException
-
setElementProperty
OperationResult setElementProperty(PropertyDescriptorIF descriptor, PropertyValue value) throws M2MException, RemoteException Set the property.- Parameters:
descriptor- property namevalue-- Returns:
- false on error
- Throws:
M2MExceptionRemoteException
-
getModel
Get the model of the element.- Returns:
- the elements model
- Throws:
AbortExceptionM2MExceptionRemoteException
-
getMetaModel
- Throws:
M2MExceptionRemoteException
-
createElement
MappingElementIF createElement(ModelTransformationStepIF step, CreateDescriptorIF createDescriptor, MappingAnchor anchor) throws M2MException, RemoteException Create a new element in the same model as this element.- Parameters:
createDescriptor- description what to createanchor- additional anchor elements for the new element- Returns:
- a newly created element with the current element as owner spawned through the additional target elements
- Throws:
M2MExceptionRemoteException
-
delete
Delete the mapping element.- Throws:
M2MExceptionRemoteException
-
cloneIndexed
Creates from the original Element an cloned indexed element- Parameters:
virtualIndex-- Returns:
- a copy of the mapping element with an index
-
getBulkInfo
- Throws:
RemoteException
-
getBulkInfoSpecialist
- Throws:
RemoteException
-