org.eclipse.epsilon.eol.models
Interface IAdaptableModel

All Superinterfaces:
IModel
All Known Implementing Classes:
HutnModel, ModelReference, ReflectiveModelReference

public interface IAdaptableModel
extends IModel

Interface for models which can be adapted to a different model type, if required. Mostly useful for adapting model types which do not implement comparison to those who do.


Method Summary
<T> T
adaptTo(java.lang.Class<T> modelType)
          Tries to adapt the model to a different type.
 
Methods inherited from interface org.eclipse.epsilon.eol.models.IModel
allContents, createInstance, createInstance, deleteElement, dispose, getAliases, getAllOfKind, getAllOfType, getElementById, getElementId, getEnumerationValue, getFullyQualifiedTypeNameOf, getName, getPropertyGetter, getPropertySetter, getTransactionSupport, getTypeNameOf, getTypeOf, hasType, isInstantiable, isModelElement, isOfKind, isOfType, isReadOnLoad, isStoredOnDisposal, knowsAboutProperty, load, load, owns, setElementId, setName, setReadOnLoad, setStoredOnDisposal, store, store
 

Method Detail

adaptTo

<T> T adaptTo(java.lang.Class<T> modelType)
Tries to adapt the model to a different type. If it is not possible, this method should return null.

Parameters:
modelType - Type to which this model should be adapted.
Returns:
Non-null value if the model could be adapted, null otherwise.