Interface IResolvableModel<V extends IMetaParameterDeclaration,M extends IModel>
-
- Type Parameters:
V- the actual type of variableM- the model type
- All Superinterfaces:
IMetaType,IModel,IModelData,IParameterizable<V>,ITypedModel
- All Known Implementing Classes:
AbstractResolvableModel,DummyModel,Script,Template
public interface IResolvableModel<V extends IMetaParameterDeclaration,M extends IModel> extends IParameterizable<V>, ITypedModel
Defines the interface for a resolvable model which may provide its parts as operations.- Author:
- Holger Eichelberger
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description voidaddRuntimeImport(ModelImport<M> imp)Adds a runtime model import.CompoundgetCompound(int index)Get the compound at the specified index.CompoundgetCompound(java.lang.String name)Returns the compound declaration with given name.intgetCompoundCount()Get the number of compounds defined in this model.IMetaTypegetExtensionType(int index)Returns the specified extension type.intgetExtensionTypesCount()Returns the number of extension types declared in/by this model.java.lang.ObjectgetIvmlElement(java.lang.String name)Returns whether the givennameresolves to an IVML element.IResolvableModel<V,M>getParent()Get the parent project which this project extends.TypedefgetTypedef(int index)Get the typedef at the specified index.TypedefgetTypedef(java.lang.String name)Returns the typedef with given name.intgetTypedefCount()Get the number of typedefs of this model.TypeRegistrygetTypeRegistry()Returns the responsible type registry.VgetVariableDeclaration(int index)Get the variable declaration of this model at the specified index.intgetVariableDeclarationCount()Get the number of variable declaration of this model.booleanisImplicit(V decl)Returns whether a variable declaration is implicit (predefined).-
Methods inherited from interface net.ssehub.easy.instantiation.core.model.vilTypes.IMetaType
addPlaceholderOperation, checkConversion, enableDynamicDispatch, findConversion, getBaseType, getCandidates, getField, getFieldCount, getGenericParameterCount, getGenericParameterType, getName, getOperation, getOperationsCount, getQualifiedName, getSuperType, isActualTypeOf, isAssignableFrom, isBasicType, isInternal, isPlaceholder
-
Methods inherited from interface net.ssehub.easy.basics.modelManagement.IModel
dispose, getImport, getImportsCount, getIndentationConfiguration, getName, getRestrictionEvaluationContext, getSuper, getVersion, setVersion
-
Methods inherited from interface net.ssehub.easy.instantiation.core.model.common.IParameterizable
getParameter, getParameter, getParameterCount, getRequiredParameterCount
-
-
-
-
Method Detail
-
getIvmlElement
java.lang.Object getIvmlElement(java.lang.String name)
Returns whether the givennameresolves to an IVML element.- Parameters:
name- the name to be resolved- Returns:
- the IVML element (value, containable model element), null else
-
getParent
IResolvableModel<V,M> getParent()
Get the parent project which this project extends.- Returns:
- The parent project of this project or
nullif no parent is defined for this project.
-
getExtensionTypesCount
int getExtensionTypesCount()
Returns the number of extension types declared in/by this model.- Returns:
- the number of extension types
-
getExtensionType
IMetaType getExtensionType(int index)
Returns the specified extension type.- Parameters:
index- the 0-based index of the extension type to be returned- Returns:
- the specified extension type
- Throws:
java.lang.IndexOutOfBoundsException- in case thatindex < 0 || index >=getExtensionTypesCount()
-
getVariableDeclarationCount
int getVariableDeclarationCount()
Get the number of variable declaration of this model.- Returns:
- The number of variable declaration of this model.
-
getVariableDeclaration
V getVariableDeclaration(int index)
Get the variable declaration of this model at the specified index.- Parameters:
index- The 0-based index of the variable declaration to be returned.- Returns:
- The variable declaration at the given index.
- Throws:
java.lang.IndexOutOfBoundsException- ifindex < 0 || index >=getVariableDeclarationCount()
-
isImplicit
boolean isImplicit(V decl)
Returns whether a variable declaration is implicit (predefined).- Parameters:
decl- the declaration to be tested- Returns:
trueif it is implicit,falseelse
-
getTypeRegistry
TypeRegistry getTypeRegistry()
Returns the responsible type registry.- Specified by:
getTypeRegistryin interfaceIMetaType- Returns:
- the type registry
-
getTypedefCount
int getTypedefCount()
Get the number of typedefs of this model.- Returns:
- The number of typedefs of this model.
-
getTypedef
Typedef getTypedef(int index)
Get the typedef at the specified index.- Parameters:
index- The 0-based index of the typedef to be returned.- Returns:
- The typedef parameter at the given index.
- Throws:
java.lang.IndexOutOfBoundsException- ifindex < 0 || index >=getTypedefCount()
-
getTypedef
Typedef getTypedef(java.lang.String name)
Returns the typedef with given name.- Parameters:
name- the name- Returns:
- the typedef (may be null for none)
-
addRuntimeImport
void addRuntimeImport(ModelImport<M> imp)
Adds a runtime model import.- Parameters:
imp- the import
-
getCompoundCount
int getCompoundCount()
Get the number of compounds defined in this model.- Returns:
- The number of compounds of this model.
-
getCompound
Compound getCompound(int index)
Get the compound at the specified index.- Parameters:
index- The 0-based index of the compound to be returned.- Returns:
- The compound at the given index.
- Throws:
java.lang.IndexOutOfBoundsException- ifindex < 0 || index >=getCompoundCount()
-
getCompound
Compound getCompound(java.lang.String name)
Returns the compound declaration with given name.- Parameters:
name- the name- Returns:
- the compound (may be null for none)
-
-