Interface IResolutionScope
- All Known Implementing Classes:
Compound,ContainableModelElementList,Project,ProjectInterface
public interface IResolutionScope
Provides access to containable model elements.
- Author:
- Holger Eichelberger
-
Method Summary
Modifier and TypeMethodDescriptiongetElement(int index) Returns a contained model element specified byindex.getElement(String name) Returns a contained model element specified by itsname.intReturns the number of contained elements.getImport(int index) Returns the project import specified byindex.intReturns the number of imports.getName()Returns the (unqualified) name of the scope.Returns the parent model element.booleanReturns whether this scope has interfaces.booleanReturns whether this scope is an interfaces.
-
Method Details
-
getName
String getName()Returns the (unqualified) name of the scope.- Returns:
- the unqualified name of the scope
-
getParent
IModelElement getParent()Returns the parent model element.- Returns:
- the parent model element (may be null)
-
getElement
Returns a contained model element specified byindex.- Parameters:
index- a 0-based index specifying the operation to be returned- Returns:
- the contained element
- Throws:
IndexOutOfBoundsException- ifindex<0 || index>=getElementCount()
-
getElement
Returns a contained model element specified by itsname.- Parameters:
name- the qualified or unqualified name to search for- Returns:
- the related element or null if no such element is known
-
getElementCount
int getElementCount()Returns the number of contained elements.- Returns:
- the number of contained elements
-
getImportsCount
int getImportsCount()Returns the number of imports.- Returns:
- the number of imports
-
getImport
Returns the project import specified byindex.- Parameters:
index- a 0-based index specifying the import to be returned- Returns:
- the project import
- Throws:
IndexOutOfBoundsException- ifindex<0 || index>=getImportsCount()
-
hasInterfaces
boolean hasInterfaces()Returns whether this scope has interfaces.- Returns:
trueif it has interfaces,falseelse
-
isInterface
boolean isInterface()Returns whether this scope is an interfaces.- Returns:
trueif it is an interface,falseelse
-