Package org.eclipse.epsilon.eol.models
Class ModelRepository
java.lang.Object
org.eclipse.epsilon.eol.models.ModelRepository
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classSpecial return value that can be used bygetEnumerationValue(String)to signal that a certain enumeration reference is ambiguous.static class -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidvoidaddModels(Collection<? extends IModel> models) voidcheckAmbiguity(String typeName) Returns a result that indicates (1) whether the specified type is ambiguous (i.e.voiddispose()protected StringgetEnumeration(String enumerationAndLabel) getEnumerationValue(String modelAndEnumerationAndLabel) Resolves the enumeration literal corresponding to a given label of the form(MODEL '!')? TYPE? '#' LABEL.protected Stringprotected StringgetMetaClassName(String modelAndMetaClass) getModelByName(String modelName) getModelByNameSafe(String modelName) protected StringgetModelName(String modelAndMetaClass) getOwningModel(Object instance) voidremoveModel(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 oneIModelin 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.AmbiguousEnumerationValueif it is ambiguous. - Throws:
EolModelNotFoundExceptionEolEnumerationValueNotFoundException
-
getOwningModel
-
getMetaClassName
-
getModelName
-
getEnumeration
-
getLabel
-
dispose
public void dispose() -
getModels
-
toString
-