org.eclipse.emf.ocl.query.impl
Class QueryFactoryImpl
java.lang.Object
org.eclipse.emf.common.notify.impl.BasicNotifierImpl
org.eclipse.emf.ecore.impl.BasicEObjectImpl
org.eclipse.emf.ecore.impl.EObjectImpl
org.eclipse.emf.ecore.impl.FlatEObjectImpl
org.eclipse.emf.ecore.impl.EModelElementImpl
org.eclipse.emf.ecore.impl.EFactoryImpl
org.eclipse.emf.ocl.query.impl.QueryFactoryImpl
- All Implemented Interfaces:
- Notifier, EFactory, EModelElement, EObject, InternalEObject, QueryFactory
public class QueryFactoryImpl
- extends EFactoryImpl
- implements QueryFactory
An implementation of the model Factory.
Methods inherited from class org.eclipse.emf.ecore.impl.EFactoryImpl |
basicCreate, basicSetEPackage, collapseWhiteSpace, convertToString, createFromString, eGet, eInverseAdd, eInverseRemove, eIsSet, eSet, eStaticClass, eUnset, getEPackage, replaceWhiteSpace, setEPackage |
Methods inherited from class org.eclipse.emf.ecore.impl.BasicEObjectImpl |
eAddVirtualValue, eAllContents, eBaseStructuralFeatureID, eBasicRemoveFromContainer, eBasicRemoveFromContainerFeature, eBasicSetContainer, eComputeVirtualValuesCapacity, eContainer, eContainingFeature, eContainmentFeature, eContainmentFeature, eContains, eDerivedStructuralFeatureID, eDerivedStructuralFeatureID, eDirectResource, eDynamicBasicRemoveFromContainer, eDynamicClass, eDynamicFeature, eDynamicFeatureID, eDynamicGet, eDynamicGet, eDynamicGet, eDynamicInverseAdd, eDynamicInverseAdd, eDynamicInverseRemove, eDynamicInverseRemove, eDynamicIsSet, eDynamicIsSet, eDynamicIsSet, eDynamicSet, eDynamicSet, eDynamicSet, eDynamicUnset, eDynamicUnset, eDynamicUnset, eGet, eGet, eGet, eHasSettings, eInternalResource, eInverseAdd, eInverseRemove, eIsSet, eOpenGet, eOpenIsSet, eOpenSet, eOpenUnset, eRemoveVirtualValue, eResolveProxy, eResource, eSet, eSetDirectResource, eSetResource, eSetStore, eSetting, eSettingDelegate, eSettings, eSetVirtualIndexBits, eSetVirtualValue, eSetVirtualValues, eStaticFeatureCount, eStore, eUnset, eVirtualBitCount, eVirtualGet, eVirtualGet, eVirtualIndex, eVirtualIndexBits, eVirtualIsSet, eVirtualSet, eVirtualUnset, eVirtualValue, eVirtualValues, toString |
Methods inherited from interface org.eclipse.emf.ecore.EObject |
eAllContents, eClass, eContainer, eContainingFeature, eContainmentFeature, eContents, eCrossReferences, eGet, eGet, eIsProxy, eIsSet, eResource, eSet, eUnset |
copyright
public static final String copyright
-
- See Also:
- Constant Field Values
QueryFactoryImpl
public QueryFactoryImpl()
- Creates an instance of the factory.
init
public static QueryFactory init()
- Creates the default factory implementation.
create
public EObject create(EClass eClass)
-
- Specified by:
create
in interface EFactory
- Overrides:
create
in class EFactoryImpl
createFromString
public Object createFromString(EDataType eDataType,
String initialValue)
-
- Specified by:
createFromString
in interface EFactory
- Overrides:
createFromString
in class EFactoryImpl
convertToString
public String convertToString(EDataType eDataType,
Object instanceValue)
-
- Specified by:
convertToString
in interface EFactory
- Overrides:
convertToString
in class EFactoryImpl
createQuery
public Query createQuery()
-
- Specified by:
createQuery
in interface QueryFactory
- Returns:
- a new object of class 'Query'.
createQuery
public Query createQuery(String expr,
EClassifier context)
- Description copied from interface:
QueryFactory
- Creates an OCL query from the specified OCL expression string, for the
given OCL classifier context.
This method offers the convenience of creating the package and context
declaration and other boilerplate components of the query on the caller's
behalf; the specified expression must be only the bare expression without
even the inv: keyword. e.g.,
self.color <> Color::red
instead of:
package com::examples::fruit
context Pomegranate
inv: self.color <> Color::red
endpackage
- Specified by:
createQuery
in interface QueryFactory
- Parameters:
expr
- the bare OCL expression textcontext
- the OCL classifier context
- Returns:
- the compiled OCL query object
createQuery
public Query createQuery(OCLExpression expr)
- Description copied from interface:
QueryFactory
- Creates a query from an
OCLExpression
(constraint or query).
The query is validated according to OCL well-formedness rules.
- Specified by:
createQuery
in interface QueryFactory
- Parameters:
expr
- the ocl expression
- Returns:
- the new query instance, if the OCL expression is valid
getQueryPackage
public QueryPackage getQueryPackage()
-
- Specified by:
getQueryPackage
in interface QueryFactory
- Returns:
- the package supported by this factory.
getPackage
@Deprecated
public static QueryPackage getPackage()
- Deprecated.
-