|
||||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
The Factory for the model. It provides a create method for each non-abstract class of the model.
QueryPackage
Field Summary | |
---|---|
static java.lang.String |
copyright
|
static QueryFactory |
eINSTANCE
The singleton instance of the factory |
Method Summary | |
---|---|
Query |
createQuery()
Returns a new object of class 'Query' |
Query |
createQuery(OCLExpression expr)
Creates a query from an OCLExpression (constraint or query).
|
Query |
createQuery(java.lang.String expr,
org.eclipse.emf.ecore.EClassifier context)
Creates an OCL query from the specified OCL expression string, for the given OCL classifier context. |
QueryPackage |
getQueryPackage()
Returns the package supported by this factory |
Methods inherited from interface org.eclipse.emf.ecore.EFactory |
---|
convertToString, create, createFromString, getEPackage, setEPackage |
Methods inherited from interface org.eclipse.emf.ecore.EModelElement |
---|
getEAnnotation, getEAnnotations |
Methods inherited from interface org.eclipse.emf.ecore.EObject |
---|
eAllContents, eClass, eContainer, eContainingFeature, eContainmentFeature, eContents, eCrossReferences, eGet, eGet, eIsProxy, eIsSet, eResource, eSet, eUnset |
Methods inherited from interface org.eclipse.emf.common.notify.Notifier |
---|
eAdapters, eDeliver, eNotify, eSetDeliver |
Field Detail |
public static final java.lang.String copyright
public static final QueryFactory eINSTANCE
Method Detail |
public Query createQuery(java.lang.String expr, org.eclipse.emf.ecore.EClassifier 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::redinstead of:
package com::examples::fruit context Pomegranate inv: self.color <> Color::red endpackage
expr
- the bare OCL expression textcontext
- the OCL classifier context
java.lang.IllegalArgumentException
- if the OCL expression string
is malformed or the context
is null
public Query createQuery()
public Query createQuery(OCLExpression expr)
OCLExpression
(constraint or query).
The query is validated according to OCL well-formedness rules.
expr
- the ocl expression
java.lang.IllegalArgumentException
- in case of well-formedness problemspublic QueryPackage getQueryPackage()
|
Copyright 2002, 2006 IBM Corporation and others. All Rights Reserved. |
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |