public <C, O> org.eclipse.ocl.types.SequenceType<C, O> createSequenceType(C elementType) { SequenceType result = EcoreFactory.eINSTANCE.createSequenceType(); result.setElementType((EClassifier) elementType); return (org.eclipse.ocl.types.SequenceType<C, O>) result; }
public SendSignalAction createSendSignalAction(EClassifier signal) { SendSignalAction result = EcoreFactory.eINSTANCE.createSendSignalAction(); result.setSignal((EClass) signal); return result; }
public <C, O> org.eclipse.ocl.types.SetType<C, O> createSetType(C elementType) { SetType result = EcoreFactory.eINSTANCE.createSetType(); result.setElementType((EClassifier) elementType); return (org.eclipse.ocl.types.SetType<C, O>) result; }
public static Object query(EObject eObject, String body) throws Exception { OCL.Helper helper = ocl.createOCLHelper(); helper.setContext(eObject.eClass()); OCLExpression expression = helper.createQuery(body); OCL.Query query = ocl.createQuery(expression); return query.evaluate(eObject); }
public static boolean check(EObject eObject, String body) throws Exception { OCL.Helper helper = ocl.createOCLHelper(); helper.setContext(eObject.eClass()); Constraint constraint = helper.createInvariant(body); OCL.Query query = ocl.createQuery(constraint); return query.check(eObject); }
public <C, O, P> org.eclipse.ocl.types.MessageType<C, O, P> createOperationMessageType(O operation) { MessageType result = EcoreFactory.eINSTANCE.createMessageType(); result.setReferredOperation((EOperation) operation); result.oclProperties(); // ensure that the structural features are created return (org.eclipse.ocl.types.MessageType<C, O, P>) result; }
public <C, O, P> org.eclipse.ocl.types.MessageType<C, O, P> createSignalMessageType(C signal) { MessageType result = EcoreFactory.eINSTANCE.createMessageType(); result.setReferredSignal((EClassifier) signal); result.oclProperties(); // ensure that the structural features are created return (org.eclipse.ocl.types.MessageType<C, O, P>) result; }
public CallOperationAction createCallOperationAction(EOperation operation) { CallOperationAction result = EcoreFactory.eINSTANCE.createCallOperationAction(); result.setOperation(operation); return result; }
public <C, O> org.eclipse.ocl.types.OrderedSetType<C, O> createOrderedSetType(C elementType) { OrderedSetType result = EcoreFactory.eINSTANCE.createOrderedSetType(); result.setElementType((EClassifier) elementType); return (org.eclipse.ocl.types.OrderedSetType<C, O>) result; }
public <C, O> org.eclipse.ocl.types.BagType<C, O> createBagType(C elementType) { BagType result = EcoreFactory.eINSTANCE.createBagType(); result.setElementType((EClassifier) elementType); return (org.eclipse.ocl.types.BagType<C, O>) result; }
public <C, O> org.eclipse.ocl.types.CollectionType<C, O> createCollectionType(C elementType) { CollectionType result = EcoreFactory.eINSTANCE.createCollectionType(); result.setElementType((EClassifier) elementType); return (org.eclipse.ocl.types.CollectionType<C, O>) result; }
/** * Looks in the EMF registry for a package with the specified qualified * package name. Uses the global package registry. * * @param packageNames * the qualified package name * @return the matching EPackage, or <code>null</code> if not found */ static public EPackage findPackage(List<String> packageNames) { return findPackage(packageNames, EPackage.Registry.INSTANCE); }
public void dispose() { if (ocl != null) { ocl.dispose(); } }
public void setSpecification( Constraint constraint, ExpressionInOCL<EClassifier, EParameter> specification) { constraint.setSpecification(specification); }
public EvaluationEnvironment<EClassifier, EOperation, EStructuralFeature, EClass, EObject> createEvaluationEnvironment() { return new EcoreEvaluationEnvironment(this); }
public <C> IfExp<C> createIfExp() { return (IfExp<C>) EcoreFactory.eINSTANCE.createIfExp(); }
public <C> TypeExp<C> createTypeExp() { return (TypeExp<C>) EcoreFactory.eINSTANCE.createTypeExp(); }
public <C> CollectionLiteralExp<C> createCollectionLiteralExp() { return (CollectionLiteralExp<C>) EcoreFactory.eINSTANCE.createCollectionLiteralExp(); }
public <C, O> OperationCallExp<C, O> createOperationCallExp() { return (OperationCallExp<C, O>) EcoreFactory.eINSTANCE.createOperationCallExp(); }
@Override protected EPackage lookupPackage(List<String> pathname) { return EcoreEnvironment.findPackage(pathname, registry); }