|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.eclipse.emf.query.conditions.Condition org.eclipse.emf.query.conditions.eobjects.EObjectCondition org.eclipse.emf.query.ocl.conditions.OCLCondition org.eclipse.emf.query.ocl.conditions.OCLConstraintCondition
BooleanOCLCondition
class, which supports
customization of the OCL parsing environment as well as other metamodels
than Ecore
@Deprecated public class OCLConstraintCondition
A specialized OCL condition class that is used to apply boolean-valued OCL
expressions to EObject
s. These are commonly used to express
invariant constraints; they are not typically
evaluated but are usually checked
for isSatisfied(EObject)
.
Field Summary | |
---|---|
static OCLConstraintCondition |
NULL_CONDITION
Deprecated. A simple condition constant that represents an OCLConstraintCondition that is always
satisfied. |
Fields inherited from class org.eclipse.emf.query.conditions.eobjects.EObjectCondition |
---|
E_FALSE, E_TRUE |
Fields inherited from class org.eclipse.emf.query.conditions.Condition |
---|
FALSE, TRUE |
Constructor Summary | |
---|---|
OCLConstraintCondition(Query oclQuery,
EClass contextEObjectType,
IEStructuralFeatureValueGetter eStructuralFeatureValueGetter,
PruneHandler pruneHandler)
Deprecated. Initializes a constraint condition with a compiled OCL query, an EClass representing the EObject type which the OCL
expression uses as a context, an IEStructuralFeatureValueGetter
to use to get values of StructuralFeature s
referenced by the OCL expression, and a PruneHandler to consult
for pruning the content tree. |
|
OCLConstraintCondition(Query oclQuery,
EClass contextEObjectType,
PruneHandler pruneHandler)
Deprecated. Initializes a constraint condition with a compiled OCL query, an EClass representing the EObject type which the OCL
expression uses as a context, an IEStructuralFeatureValueGetter
to use to get values of StructuralFeature s
referenced by the OCL expression, and a PruneHandler to consult
for pruning the content tree. |
|
OCLConstraintCondition(String oclExpressionString,
EClass contextEObjectType)
Deprecated. Initializes a constraint condition with an OCL expression string, an EClass representing the EObject type which the OCL
expression uses as a context, and an
IEStructuralFeatureValueGetter to use to get values of
StructuralFeature s referenced by the OCL
expression. |
|
OCLConstraintCondition(String oclExpressionString,
EClass contextEObjectType,
IEStructuralFeatureValueGetter eStructuralFeatureValueGetter)
Deprecated. Initializes a constraint condition with an OCL expression string, an EClass representing the EObject type which the OCL
expression uses as a context, and an
IEStructuralFeatureValueGetter to use to get values of
StructuralFeature s referenced by the OCL
expression. |
|
OCLConstraintCondition(String oclExpressionString,
EClass contextEObjectType,
IEStructuralFeatureValueGetter eStructuralFeatureValueGetter,
PruneHandler pruneHandler)
Deprecated. Initializes a constraint condition with an OCL expression string, an EClass representing the EObject type which the OCL
expression uses as a context, an IEStructuralFeatureValueGetter
to use to get values of StructuralFeature s
referenced by the OCL expression, and a PruneHandler to consult
for pruning the content tree. |
Method Summary | |
---|---|
boolean |
isSatisfied(EObject eObject)
Deprecated. Computes the boolean value resulting from evaluating the constraint condition on the specified eObject . |
Methods inherited from class org.eclipse.emf.query.ocl.conditions.OCLCondition |
---|
evaluate, getContextEObjectType, getEStructuralFeatureValueGetter, getOclQuery, getResultType, isContextFree, setEStructuralFeatureValueGetter |
Methods inherited from class org.eclipse.emf.query.conditions.eobjects.EObjectCondition |
---|
AND, EQUIVALENT, getPruneHandler, IMPLIES, isSatisfied, OR, shouldPrune, XOR |
Methods inherited from class org.eclipse.emf.query.conditions.Condition |
---|
AND, EQUIVALENT, IMPLIES, OR, XOR |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final OCLConstraintCondition NULL_CONDITION
OCLConstraintCondition
that is always
satisfied. Functions as a literal "true".
Constructor Detail |
---|
public OCLConstraintCondition(String oclExpressionString, EClass contextEObjectType, IEStructuralFeatureValueGetter eStructuralFeatureValueGetter)
EClass
representing the EObject
type which the OCL
expression uses as a context, and an
IEStructuralFeatureValueGetter
to use to get values of
StructuralFeature
s referenced by the OCL
expression. It defaults to using PruneHandler.NEVER
to consult
for pruning.
NOTE: if contextEObjectType
is null
,
then this becomes a context-free OCL constraint condition.
oclExpressionString
- The OCL expression to apply when evaluating this
OCLCondition
contextEObjectType
- The EClass
representing the OCL context classifier.
Use null
to create a context-free
OCLCondition
.eStructuralFeatureValueGetter
- The strategy for accessing structural feature values. It
serves as a layer of indirection to allow clients to intervene
between this condition object and the way it extracts the
StructuralFeature
s' values so
as to allow for manipulation of such values before subjecting
them to evaluation by the OCL interpreter.public OCLConstraintCondition(String oclExpressionString, EClass contextEObjectType)
EClass
representing the EObject
type which the OCL
expression uses as a context, and an
IEStructuralFeatureValueGetter
to use to get values of
StructuralFeature
s referenced by the OCL
expression. It defaults to using PruneHandler.NEVER
to consult
for pruning.
NOTE: if contextEObjectType
is null
,
then this becomes a context-free OCL constraint condition.
This constructor implicitly uses the default EStructuralFeatureValueGetter
to access any EAttributes or EReferences of EObjects.
oclExpressionString
- The OCL expression to apply when evaluating this
OCLCondition
contextEObjectType
- The EClass
representing the OCL context classifier.
Use null
to create a context-free
OCLCondition
.public OCLConstraintCondition(String oclExpressionString, EClass contextEObjectType, IEStructuralFeatureValueGetter eStructuralFeatureValueGetter, PruneHandler pruneHandler)
EClass
representing the EObject
type which the OCL
expression uses as a context, an IEStructuralFeatureValueGetter
to use to get values of StructuralFeature
s
referenced by the OCL expression, and a PruneHandler
to consult
for pruning the content tree.
NOTE: if contextEObjectType
is null
,
then this becomes a context-free OCL constraint condition.
oclExpressionString
- The OCL expression to apply when evaluating this
OCLCondition
contextEObjectType
- The EClass
representing the OCL context classifier.
Use null
to create a context-free
OCLCondition
.eStructuralFeatureValueGetter
- The strategy for accessing structural feature values. It
serves as a layer of indirection to allow clients to intervene
between this condition object and the way it extracts the
StructuralFeature
s' values so
as to allow for manipulation of such values before subjecting
them to evaluation by the OCL interpreter.pruneHandler
- The PruneHandler
to consult when pruningpublic OCLConstraintCondition(Query oclQuery, EClass contextEObjectType, IEStructuralFeatureValueGetter eStructuralFeatureValueGetter, PruneHandler pruneHandler)
EClass
representing the EObject
type which the OCL
expression uses as a context, an IEStructuralFeatureValueGetter
to use to get values of StructuralFeature
s
referenced by the OCL expression, and a PruneHandler
to consult
for pruning the content tree.
oclQuery
- The OCL query to apply when evaluating this
OCLCondition
contextEObjectType
- The EClass
representing the OCL context classifier.
Must not be null
.eStructuralFeatureValueGetter
- The strategy for accessing structural feature values. It
serves as a layer of indirection to allow clients to intervene
between this condition object and the way it extracts the
StructuralFeature
s' values so
as to allow for manipulation of such values before subjecting
them to evaluation by the OCL interpreter.pruneHandler
- The PruneHandler
to consult when pruningpublic OCLConstraintCondition(Query oclQuery, EClass contextEObjectType, PruneHandler pruneHandler)
Initializes a constraint condition with a compiled OCL query, an
EClass
representing the EObject
type which the OCL
expression uses as a context, an IEStructuralFeatureValueGetter
to use to get values of StructuralFeature
s
referenced by the OCL expression, and a PruneHandler
to consult
for pruning the content tree.
This constructor implicitly uses the default EStructuralFeatureValueGetter
to retrieve the values of an EObject's structural feature values.
oclQuery
- The OCL query to apply when evaluating this
OCLCondition
contextEObjectType
- The EClass
representing the OCL context classifier.
Must not be null
.pruneHandler
- The PruneHandler
to consult when pruningMethod Detail |
---|
public boolean isSatisfied(EObject eObject)
eObject
.
isSatisfied
in class OCLCondition
eObject
- the EObject
to check
true
if the argument eObject satisfies
this EObjectCondition
OCLCondition.getContextEObjectType()
,
OCLCondition.isContextFree()
|
Copyright 2002, 2007 IBM Corporation and others. All Rights Reserved. |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |