|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.camunda.bpm.model.xml.impl.ModelImpl
public class ModelImpl
A model contains all defined types and the relationship between them.
| Field Summary | |
|---|---|
protected Map<String,String> |
actualNsToAlternative
|
protected Map<String,String> |
alternativeNsToActual
|
| Constructor Summary | |
|---|---|
ModelImpl(String modelName)
Create a new Model with a model name. |
|
| Method Summary | |
|---|---|
void |
declareAlternativeNamespace(String alternativeNs,
String actualNs)
Declares an alternative namespace for an actual so that during lookup of elements/attributes both will be considered. |
boolean |
equals(Object obj)
|
String |
getActualNamespace(String alternativeNs)
Returns the actual namespace URI for an alternative namespace URI |
String |
getAlternativeNamespace(String actualNs)
Returns the alternative namespace URI for a namespace URI |
String |
getModelName()
Returns the model name, which is the identifier of this model. |
ModelElementType |
getType(Class<? extends ModelElementInstance> instanceClass)
Gets the defined ModelElementType of a ModelElementInstance. |
ModelElementType |
getTypeForName(String typeName)
Gets the defined ModelElementType for a type by its name. |
ModelElementType |
getTypeForName(String namespaceUri,
String typeName)
Gets the defined ModelElementType for a type by its name and namespace URI. |
Collection<ModelElementType> |
getTypes()
Gets the collection of all ModelElementType defined in the model. |
int |
hashCode()
|
void |
registerType(ModelElementType modelElementType,
Class<? extends ModelElementInstance> instanceType)
Registers a ModelElementType in this Model. |
void |
undeclareAlternativeNamespace(String alternativeNs)
|
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected final Map<String,String> actualNsToAlternative
protected final Map<String,String> alternativeNsToActual
| Constructor Detail |
|---|
public ModelImpl(String modelName)
Model with a model name.
modelName - the model name to identify the model| Method Detail |
|---|
public void declareAlternativeNamespace(String alternativeNs,
String actualNs)
alternativeNs - actualNs -
IllegalArgumentException - if the alternative is already used or if the actual namespace has an alternativepublic void undeclareAlternativeNamespace(String alternativeNs)
public String getAlternativeNamespace(String actualNs)
Model
getAlternativeNamespace in interface ModelactualNs - the actual namespace URI
public String getActualNamespace(String alternativeNs)
Model
getActualNamespace in interface ModelalternativeNs - the alternative namespace URI
public Collection<ModelElementType> getTypes()
ModelModelElementType defined in the model.
getTypes in interface Modelpublic ModelElementType getType(Class<? extends ModelElementInstance> instanceClass)
ModelModelElementType of a ModelElementInstance.
getType in interface ModelinstanceClass - the instance class to find the type for
public ModelElementType getTypeForName(String typeName)
ModelModelElementType for a type by its name.
getTypeForName in interface ModeltypeName - the name of the type
public ModelElementType getTypeForName(String namespaceUri,
String typeName)
ModelModelElementType for a type by its name and namespace URI.
getTypeForName in interface ModelnamespaceUri - the namespace URI for the typetypeName - the name of the type
public void registerType(ModelElementType modelElementType,
Class<? extends ModelElementInstance> instanceType)
ModelElementType in this Model.
modelElementType - the element type to registerinstanceType - the instance class of the type to registerpublic String getModelName()
Model
getModelName in interface Modelpublic int hashCode()
hashCode in class Objectpublic boolean equals(Object obj)
equals in class Object
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||