Class WorkModel
java.lang.Object
de.mid.innovator.m2msdk.model.workspace.WorkModel
- All Implemented Interfaces:
WorkModelInterface,Serializable,Remote
Work model of source model. The work model contains the source model for the
model transformation. It is separated in initial, active and passive
elements. If an element is in active selection, it will be removed from
passive selection.
- Version:
- 10.1.1
- Author:
- jmback
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidaddElements(ExtensionStore iStore, MappingElementList iList) Add uniquely the elements to this work model in the given store.voidclearElements(ExtensionStore iStore) Clear the elements in this work model in the given store.org.jdom2.DocumentgetDocument(ExtensionStore iStore, int iChunk) Get all model elements that are in this work model and in the specified store.getElements(ExtensionStore iStore) Get all model elements that are in this work model and in the specified store.getElementsAsUri(ExtensionStore iStore) Get all model elements that are in this work model and in the specified store.Get mapping model of this work model.Get meta model of work model.getRole()Get the role of the work model.getUnique(MappingElementIF iElement) Get the unique mapping element by checking its hash code.voidinitialize(MappingModel model) voidinitialize(org.jdom2.Document iDoc) Initialize the work model based on a given Document.voidinitialize(org.jdom2.Document iDoc, ExtensionStore store, String nameElement) Initialize the work model based on a given Document.booleanIs the element in the passive selection of this work model.voidremoveElements(ExtensionStore iStore, MappingElementList iList) Remove the elements from this work model in the given store.voidsetElements(ExtensionStore iStore, MappingElementList elements) voidsetElements(WorkModelInterface modelNew) voidsetMetaModel(String iMetaModel) Set meta model of work model.toString()
-
Constructor Details
-
WorkModel
-
WorkModel
-
-
Method Details
-
initialize
- Specified by:
initializein interfaceWorkModelInterface- Throws:
RemoteExceptionM2MException
-
initialize
Description copied from interface:WorkModelInterfaceInitialize the work model based on a given Document.- Specified by:
initializein interfaceWorkModelInterface- Parameters:
iDoc- containing the mapping elements- Throws:
RemoteExceptionM2MException
-
initialize
public void initialize(org.jdom2.Document iDoc, ExtensionStore store, String nameElement) throws RemoteException, M2MException Description copied from interface:WorkModelInterfaceInitialize the work model based on a given Document.- Specified by:
initializein interfaceWorkModelInterface- Parameters:
iDoc- containing the mapping elementsstore- store to read tonameElement- name of the element to read- Throws:
RemoteExceptionM2MException
-
addElements
Description copied from interface:WorkModelInterfaceAdd uniquely the elements to this work model in the given store.- Specified by:
addElementsin interfaceWorkModelInterface- Parameters:
iStore- specified storeiList- list of model elements- Throws:
M2MException
-
getElements
Description copied from interface:WorkModelInterfaceGet all model elements that are in this work model and in the specified store.- Specified by:
getElementsin interfaceWorkModelInterface- Parameters:
iStore- store within the work model.- Returns:
- list of model elements
-
setElements
- Specified by:
setElementsin interfaceWorkModelInterface
-
getDocument
Description copied from interface:WorkModelInterfaceGet all model elements that are in this work model and in the specified store.- Specified by:
getDocumentin interfaceWorkModelInterface- Parameters:
iStore- store within the work model. If no store is specified, all elements are returned.iChunk- chunk number to get a specific chunk. Use zero (0) to get all model elements in chunks and minus one (-1) to get all model elements not chunked.- Returns:
- XML with URI of all model elements. If the number of model elements is to large, you will get chunks instead.
- Throws:
RemoteException- error in communication with remote server
-
getElementsAsUri
Description copied from interface:WorkModelInterfaceGet all model elements that are in this work model and in the specified store.- Specified by:
getElementsAsUriin interfaceWorkModelInterface- Parameters:
iStore- store within the work model.- Returns:
- comma separated list of URIs of all model elements
-
getMappingModel
Description copied from interface:WorkModelInterfaceGet mapping model of this work model.- Specified by:
getMappingModelin interfaceWorkModelInterface- Returns:
- mapping model containing the elements of this work model
- Throws:
M2MExceptionRemoteExceptionRemoteException- error in communication with remote server
-
getMetaModel
Description copied from interface:WorkModelInterfaceGet meta model of work model.- Specified by:
getMetaModelin interfaceWorkModelInterface- Returns:
- meta model
-
setMetaModel
Description copied from interface:WorkModelInterfaceSet meta model of work model.- Specified by:
setMetaModelin interfaceWorkModelInterface- Parameters:
iMetaModel- name of meta model- Throws:
RemoteException- error in communication with remote serverM2MException
-
isPassiveSelectedElement
Description copied from interface:WorkModelInterfaceIs the element in the passive selection of this work model.- Specified by:
isPassiveSelectedElementin interfaceWorkModelInterface- Parameters:
el-- Returns:
- true, if the element is in passive, but not in active selection.
-
clearElements
Description copied from interface:WorkModelInterfaceClear the elements in this work model in the given store.- Specified by:
clearElementsin interfaceWorkModelInterface- Parameters:
iStore- specified store- Throws:
M2MException
-
getRole
Description copied from interface:WorkModelInterfaceGet the role of the work model.- Specified by:
getRolein interfaceWorkModelInterface- Returns:
- source or target
-
toString
-
getExtensionStore
- Specified by:
getExtensionStorein interfaceWorkModelInterface
-
getUnique
Description copied from interface:WorkModelInterfaceGet the unique mapping element by checking its hash code.- Specified by:
getUniquein interfaceWorkModelInterface- Parameters:
iElement- mapping element to check- Returns:
- same mapping element or one with same hash
- Throws:
RemoteExceptionM2MException
-
setElements
-
removeElements
public void removeElements(ExtensionStore iStore, MappingElementList iList) throws M2MException, RemoteException Description copied from interface:WorkModelInterfaceRemove the elements from this work model in the given store.- Specified by:
removeElementsin interfaceWorkModelInterface- Parameters:
iStore- specified storeiList- list of model elements- Throws:
M2MExceptionRemoteException- error in communication with remote server
-