|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Describes a classifier of the model. All classifiers in the model are
types in the OCL-context. A type in OCL is defined via its
properties
and the state of its
instances
.
Note: "The evaluation of an OCL expression is instanceous. This means
that the states of objects in a model cannot change during evaluation."
[OCL1.5 6-3] That is the types cannot either.
Method Summary | |
boolean |
equals(java.lang.Object type)
Returns true if the specified Object is a
ClassifierDescriptor describing the same classifier
as this ClassifierDescriptor |
TypedAssociation |
getAssociation(java.lang.String roleName,
Type[] qualifiers)
Resolves and returns the specified association qualifiable by the specified qualifier parameters on this type. |
TypedProperty |
getAttribute(java.lang.String attrName,
boolean classScoped)
Resolves and returns the specified attribute on this type. |
java.lang.String |
getName()
Returns the name of the type. |
Classifier |
getOclSupertype()
Returns the predefined OCL 1.5 supertype of this type. |
TypedProperty |
getOperation(java.lang.String operationName,
ClassifierDescriptor[] params,
boolean classScoped)
Resolves and returns the specified operation on this type. |
boolean |
isStateDefined(java.lang.String state)
Returns true if the specified state is defined on
the statemachine attached to this type. |
boolean |
isSubtypeOf(ClassifierDescriptor type)
Returns true if this type is a subtype of the
specified type. |
Method Detail |
public boolean equals(java.lang.Object type)
true
if the specified Object is a
ClassifierDescriptor
describing the same classifier
as this ClassifierDescriptor.
- Overrides:
equals
in class java.lang.Object
- Returns:
true
if the specified Object is a
ClassifierDescriptor
describing the same classifier
as this ClassifierDescriptor, false
otherwise.
public java.lang.String getName()
public boolean isSubtypeOf(ClassifierDescriptor type)
true
if this type is a subtype of the
specified type. This relation will be used to build up a
type conformance hierarchy within OCL, which will be used in
either the type check (for example in oclAsType(OclType))
- and evaluation process (for example in oclIsKindOf(OclType)).
type
- a possible supertype of the model.
true
if this type is a suptype of
the specified type, otherwise false
.public TypedProperty getOperation(java.lang.String operationName, ClassifierDescriptor[] params, boolean classScoped) throws UndefinedFeatureException
operationName
- the name of the operation.params
- the parameters of the operation.classScoped
- true
if the operation is
called on the classifier itself.
UndefinedFeatureException
- if the operation could
not be resolved on this type.public TypedAssociation getAssociation(java.lang.String roleName, Type[] qualifiers) throws UndefinedFeatureException
roleName
- the role-name of the association/navigation.
UndefinedFeatureException
ModelType.isDescribedBy(ClassifierDescriptor)
public TypedProperty getAttribute(java.lang.String attrName, boolean classScoped) throws UndefinedFeatureException
attrName
- the name of the attributeclassScoped
- true
if the attribute is called
on the classifier itself.
UndefinedFeatureException
- if the attribute is not defined
on this type.public Classifier getOclSupertype()
public boolean isStateDefined(java.lang.String state)
true
if the specified state is defined on
the statemachine attached to this type. The state will be used
for the predefined Operation oclInState(OclState). The argument
state will be represented as a String
. The form
of the String is described in the Standard itself.
state
- a state of this type's statemachine.
true
if this type has at least one
statemachine attached to itself which defines the specified
state, false
otherwise.
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |