|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.eclipse.ocl.examples.pivot.context.AbstractParserContext
public abstract class AbstractParserContext
Field Summary | |
---|---|
protected MetaModelManager |
metaModelManager
|
protected org.eclipse.emf.common.util.URI |
uri
|
Constructor Summary | |
---|---|
protected |
AbstractParserContext(MetaModelManager metaModelManager,
org.eclipse.emf.common.util.URI uri)
|
Method Summary | |
---|---|
BaseResource |
createBaseResource(java.lang.String expression)
Create a Concrete Syntax resource containing the parsed expression. |
Type |
getClassContext()
Return the type of the self variable. |
ExpressionInOCL |
getExpression(BaseResource resource)
Extract an Abstract Syntax ExpressionInOCL fronm a Concrete Syntax resource. |
MetaModelManager |
getMetaModelManager()
Returbn the MetaModelManager in use. |
void |
initialize(Base2PivotConversion conversion,
ExpressionInOCL expression)
Callback to initialize the ExpressionInOCL with the derived context such as a contextvariable for the self type, parameter and result variables. |
ExpressionInOCL |
parse(org.eclipse.emf.ecore.EObject owner,
java.lang.String expression)
Create an Abstract Syntax ExpressionInOCL containing the parsed expression on behalf of a potential owner. |
ExpressionInOCL |
parse(java.lang.String expression)
Deprecated. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
@NonNull protected final MetaModelManager metaModelManager
@NonNull protected final org.eclipse.emf.common.util.URI uri
Constructor Detail |
---|
protected AbstractParserContext(@NonNull MetaModelManager metaModelManager, @Nullable org.eclipse.emf.common.util.URI uri)
Method Detail |
---|
@NonNull public BaseResource createBaseResource(@NonNull java.lang.String expression) throws java.io.IOException, ParserException
ParserContext
createBaseResource
in interface ParserContext
java.io.IOException
- if resource loading fails
ParserException
@Nullable public Type getClassContext()
ParserContext
getClassContext
in interface ParserContext
@NonNull public ExpressionInOCL getExpression(@NonNull BaseResource resource) throws ParserException
ParserContext
getExpression
in interface ParserContext
ParserException
- if parsing fails@NonNull public MetaModelManager getMetaModelManager()
ParserContext
getMetaModelManager
in interface ParserContext
public void initialize(@NonNull Base2PivotConversion conversion, @NonNull ExpressionInOCL expression)
ParserContext
initialize
in interface ParserContext
@Deprecated @NonNull public ExpressionInOCL parse(@NonNull java.lang.String expression) throws ParserException
ParserContext
parse
in interface ParserContext
ParserException
- if parsing fails@NonNull public ExpressionInOCL parse(@Nullable org.eclipse.emf.ecore.EObject owner, @NonNull java.lang.String expression) throws ParserException
ParserContext
This an invariant/precondition may specify its constraint as the owner
an operation body may specify the operation as the owner
The owner should be non-null but a null value is tolerated for deprecated compatibility.
parse
in interface ParserContext
ParserException
- if parsing fails
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |