public C getContextClassifier() { return env.getContextClassifier(); }
public C getContextClassifier() { return env.getContextClassifier(); }
protected Environment<PK, C, O, P, EL, PM, S, COA, SSA, CT, CLS, E> createClassifierContext( Environment<PK, C, O, P, EL, PM, S, COA, SSA, CT, CLS, E> env, ClassifierContextDeclCS classifierContextDeclCS, C classifier) { // create the classifier context as parent for the property context Environment<PK, C, O, P, EL, PM, S, COA, SSA, CT, CLS, E> result = environmentFactory .createClassifierContext(env, classifier); // ensure that the classifier context has a 'self' variable if (result.lookupLocal(SELF_VARIABLE_NAME) == null) { genVariableDeclaration(classifierContextDeclCS, "propertyContextCS", result, //$NON-NLS-1$ SELF_VARIABLE_NAME, env.getContextClassifier(), null, true, true, true); } return result; }
protected Environment<PK, C, O, P, EL, PM, S, COA, SSA, CT, CLS, E> createClassifierContext( Environment<PK, C, O, P, EL, PM, S, COA, SSA, CT, CLS, E> env, ClassifierContextDeclCS classifierContextDeclCS, C classifier) { // create the classifier context as parent for the property context Environment<PK, C, O, P, EL, PM, S, COA, SSA, CT, CLS, E> result = environmentFactory .createClassifierContext(env, classifier); // ensure that the classifier context has a 'self' variable if (result.lookupLocal(SELF_VARIABLE_NAME) == null) { genVariableDeclaration(classifierContextDeclCS, "propertyContextCS", result, //$NON-NLS-1$ SELF_VARIABLE_NAME, env.getContextClassifier(), null, true, true, true); } return result; }
protected Environment<PK, C, O, P, EL, PM, S, COA, SSA, CT, CLS, E> createPropertyContext( Environment<PK, C, O, P, EL, PM, S, COA, SSA, CT, CLS, E> env, PropertyContextCS propertyContextCS, P property) { // create the classifier context as parent for the property context Environment<PK, C, O, P, EL, PM, S, COA, SSA, CT, CLS, E> result = environmentFactory .createAttributeContext(env, property); // ensure that the classifier context has a 'self' variable if (result.lookupLocal(SELF_VARIABLE_NAME) == null) { genVariableDeclaration( propertyContextCS, "propertyContextCS", result, //$NON-NLS-1$ SELF_VARIABLE_NAME, env.getContextClassifier(), null, true, true, true); } return result; }
protected Environment<PK, C, O, P, EL, PM, S, COA, SSA, CT, CLS, E> createPropertyContext( Environment<PK, C, O, P, EL, PM, S, COA, SSA, CT, CLS, E> env, PropertyContextCS propertyContextCS, P property) { // create the classifier context as parent for the property context Environment<PK, C, O, P, EL, PM, S, COA, SSA, CT, CLS, E> result = environmentFactory .createAttributeContext(env, property); // ensure that the classifier context has a 'self' variable if (result.lookupLocal(SELF_VARIABLE_NAME) == null) { genVariableDeclaration( propertyContextCS, "propertyContextCS", result, //$NON-NLS-1$ SELF_VARIABLE_NAME, env.getContextClassifier(), null, true, true, true); } return result; }
/** * InvOrDefCS * * @param invOrDefCS * the <code>InvOrDefCS</code> <code>CSTNode</code> * @param env * the OCL environment * @return the parsed <code>Constraint</code> */ protected CT invOrDefCS(InvOrDefCS invOrDefCS, Environment<PK, C, O, P, EL, PM, S, COA, SSA, CT, CLS, E> env) { C classifier = env.getContextClassifier(); // create a disposable classifier context for this environment env = createClassifierContext(env, (ClassifierContextDeclCS) invOrDefCS .eContainer(), classifier); CT astNode = null; if (invOrDefCS instanceof InvCS) { astNode = invCS((InvCS) invOrDefCS, env); } else if (invOrDefCS instanceof DefCS) { astNode = defCS((DefCS) invOrDefCS, env); } return astNode; }
/** * InvOrDefCS * * @param invOrDefCS * the <code>InvOrDefCS</code> <code>CSTNode</code> * @param env * the OCL environment * @return the parsed <code>Constraint</code> */ protected CT invOrDefCS(InvOrDefCS invOrDefCS, Environment<PK, C, O, P, EL, PM, S, COA, SSA, CT, CLS, E> env) { C classifier = env.getContextClassifier(); // create a disposable classifier context for this environment env = createClassifierContext(env, (ClassifierContextDeclCS) invOrDefCS .eContainer(), classifier); CT astNode = null; if (invOrDefCS instanceof InvCS) { astNode = invCS((InvCS) invOrDefCS, env); } else if (invOrDefCS instanceof DefCS) { astNode = defCS((DefCS) invOrDefCS, env); } return astNode; }
genVariableDeclaration(operationContextCS, "operationContextDeclCS", result, //$NON-NLS-1$ SELF_VARIABLE_NAME, env.getContextClassifier(), null, true, true, true);
genVariableDeclaration(operationContextCS, "operationContextDeclCS", result, //$NON-NLS-1$ SELF_VARIABLE_NAME, env.getContextClassifier(), null, true, true, true);
C type = env.getContextClassifier(); uml.addConstrainedElement(astNode, (EObject) type);
C type = env.getContextClassifier(); uml.addConstrainedElement(astNode, (EObject) type);
C contextClassifier = env.getContextClassifier(); OCLMessages.DuplicateProperty_ERROR_, variable .getName(), uml.getName(contextEnv .getContextClassifier()))); operationString(env, operName, params), uml .getName(contextEnv .getContextClassifier())));
C contextClassifier = env.getContextClassifier(); OCLMessages.DuplicateProperty_ERROR_, variable .getName(), uml.getName(contextEnv .getContextClassifier()))); operationString(env, operName, params), uml .getName(contextEnv .getContextClassifier())));