public class EcoreEnvironmentFactoryWithHiddenOpposites extends EcoreEnvironmentFactory
null
OppositeEndFinder
to the OCL environment. This enables lookup and
evaluation of so-called "hidden opposites" which are represented by
annotations with key "Property#oppositeRoleName" on the forward reference
and which allow for querying the opposite direction by simple dotted syntax
and by cleanly providing a scope for the opposite lookup.
If no OppositeEndFinder
is provided to a constructor, a
DefaultOppositeEndFinder
is used that is either specific to the
registry
provided or that is aligned with the
default package registry
.
Modifier and Type | Field and Description |
---|---|
static EcoreEnvironmentFactoryWithHiddenOpposites |
INSTANCE
A default instance that works with the default
package registry . |
Constructor and Description |
---|
EcoreEnvironmentFactoryWithHiddenOpposites()
Initializes me.
|
EcoreEnvironmentFactoryWithHiddenOpposites(EPackage.Registry reg)
Initializes me with an
EPackage.Registry that the environments I create will use to look up
packages. |
EcoreEnvironmentFactoryWithHiddenOpposites(EPackage.Registry reg,
OppositeEndFinder oppositeEndFinder)
Configures both, a specific package registry as well as a dedicated opposite end finder to be used
by the OCL environment created by this factory.
|
createEnvironment, createEnvironment, createEvaluationEnvironment, createEvaluationEnvironment, createEvaluationVisitor, createOCLAnalyzer, createOCLAnalyzer, createOCLFactoryWithHistory, createOCLSyntaxHelper, createValidationVisitor, getEPackageRegistry, getOppositeEndFinder, loadEnvironment
createAttributeContext, createClassifierContext, createInstanceContext, createOperationContext, createPackageContext, getAdapter
public static final EcoreEnvironmentFactoryWithHiddenOpposites INSTANCE
package registry
.public EcoreEnvironmentFactoryWithHiddenOpposites()
DefaultOppositeEndFinder.getInstance()
as opposite end finder.public EcoreEnvironmentFactoryWithHiddenOpposites(EPackage.Registry reg)
EPackage.Registry
that the environments I create will use to look up
packages. A new DefaultOppositeEndFinder
object is created for the specific package registry
provided as reg
.reg
- my package registry (must not be null
)public EcoreEnvironmentFactoryWithHiddenOpposites(EPackage.Registry reg, OppositeEndFinder oppositeEndFinder)
Copyright © 2005, 2018 IBM Corporation and others. All Rights Reserved.