Package org.eclipse.epsilon.eol.models
Class ModelRepository
java.lang.Object
org.eclipse.epsilon.eol.models.ModelRepository
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic class
Special return value that can be used bygetEnumerationValue(String)
to signal that a certain enumeration reference is ambiguous.static class
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
void
addModels
(Collection<? extends IModel> models) void
checkAmbiguity
(String typeName) Returns a result that indicates (1) whether the specified type is ambiguous (i.e.void
dispose()
protected String
getEnumeration
(String enumerationAndLabel) getEnumerationValue
(String modelAndEnumerationAndLabel) Resolves the enumeration literal corresponding to a given label of the form(MODEL '!')? TYPE? '#' LABEL
.protected String
protected String
getMetaClassName
(String modelAndMetaClass) getModelByName
(String modelName) getModelByNameSafe
(String modelName) protected String
getModelName
(String modelAndMetaClass) getOwningModel
(Object instance) void
removeModel
(IModel model) toString()
-
Constructor Details
-
ModelRepository
public ModelRepository()
-
-
Method Details
-
getTransactionSupport
-
addModels
-
addModels
- Parameters:
models
-- Since:
- 1.6
-
addModel
-
removeModel
-
getModelByNameSafe
-
getModelByName
- Throws:
EolModelNotFoundException
-
checkAmbiguity
Returns a result that indicates (1) whether the specified type is ambiguous (i.e. more than oneIModel
in this repository has the type), and (2) the set of models that do have this type. -
getEnumerationValue
public Object getEnumerationValue(String modelAndEnumerationAndLabel) throws EolModelNotFoundException, EolEnumerationValueNotFoundException Resolves the enumeration literal corresponding to a given label of the form(MODEL '!')? TYPE? '#' LABEL
.- Returns:
- The enumeration literal if unambiguous, or an
ModelRepository.AmbiguousEnumerationValue
if it is ambiguous. - Throws:
EolModelNotFoundException
EolEnumerationValueNotFoundException
-
getOwningModel
-
getMetaClassName
-
getModelName
-
getEnumeration
-
getLabel
-
dispose
public void dispose() -
getModels
-
toString
-