Package net.sf.parteg.base.testcasetree.generated

Examples of net.sf.parteg.base.testcasetree.generated.TCGOCLIfThenElse


        if (result == null) result = caseTCGOCLExpression(tcgoclAtom);
        if (result == null) result = defaultCase(theEObject);
        return result;
      }
      case GeneratedPackage.TCGOCL_IF_THEN_ELSE: {
        TCGOCLIfThenElse tcgoclIfThenElse = (TCGOCLIfThenElse)theEObject;
        T result = caseTCGOCLIfThenElse(tcgoclIfThenElse);
        if (result == null) result = caseTCGOCLExpression(tcgoclIfThenElse);
        if (result == null) result = defaultCase(theEObject);
        return result;
      }
View Full Code Here


      return conditionContainsReferenceToObject(oOpExp.getLeft(), in_oReferencedObject) ||
        conditionContainsReferenceToObject(oOpExp.getRight(), in_oReferencedObject);
    }
    else if(in_oOCLExpression instanceof TCGOCLIfThenElse)
    {
      TCGOCLIfThenElse oIfThenElseExp = (TCGOCLIfThenElse)in_oOCLExpression;
      return conditionContainsReferenceToObject(oIfThenElseExp.getCondition(), in_oReferencedObject) ||
        conditionContainsReferenceToObject(oIfThenElseExp.getThenExpression(), in_oReferencedObject) ||
        conditionContainsReferenceToObject(oIfThenElseExp.getElseExpression(), in_oReferencedObject);
    }
    return false;
  }
View Full Code Here

        }
      }  */   
    }
    else if(in_oExpression instanceof TCGOCLIfThenElse)
    {
      TCGOCLIfThenElse oTCGIfThenElse = (TCGOCLIfThenElse)in_oExpression;
     
      // condition satisfied
      TCGDisjunctiveNormalForm oConditionDNF = createDisjunctiveNormalForm(oTCGIfThenElse.getCondition());
      TCGDisjunctiveNormalForm oThenDNF = createDisjunctiveNormalForm(oTCGIfThenElse.getThenExpression());
      TCGDisjunctiveNormalForm oSatisfiedDNF = connectTwoDNFWithAnd(oConditionDNF, oThenDNF);
     
      // condition violated
      negateTCGOCLExpression(oTCGIfThenElse.getCondition());
      TCGDisjunctiveNormalForm oNotConditionDNF = createDisjunctiveNormalForm(oTCGIfThenElse.getCondition());
      TCGDisjunctiveNormalForm oElseDNF = createDisjunctiveNormalForm(oTCGIfThenElse.getElseExpression());
      TCGDisjunctiveNormalForm oViolatedDNF = connectTwoDNFWithAnd(oNotConditionDNF, oElseDNF);
     
      return connectTwoDNFWithOr(oSatisfiedDNF, oViolatedDNF);
    }

View Full Code Here

        oOperation.setOperationName(oOpExp.getReferredOperation().getName());
        oTCGOCLExpression = oOperation;
      }
      else if(in_oExpression instanceof IfExp)
      {
        TCGOCLIfThenElse oTCGIfExp = GeneratedFactory.eINSTANCE.createTCGOCLIfThenElse();
        IfExp oIfExp = (IfExp)in_oExpression;
        oTCGIfExp.setCondition(transformExpression((OCLExpression)oIfExp.getCondition(), in_sOCLTypeId, oContextClass));
        oTCGIfExp.setThenExpression(transformExpression((OCLExpression)oIfExp.getThenExpression(), in_sOCLTypeId, oContextClass));
        oTCGIfExp.setElseExpression(transformExpression((OCLExpression)oIfExp.getElseExpression(), in_sOCLTypeId, oContextClass));
        oTCGOCLExpression = oTCGIfExp;
      }

      // Reference to original OCL expression
      oTCGOCLExpression.setOclReference(in_oExpression);
View Full Code Here

TOP

Related Classes of net.sf.parteg.base.testcasetree.generated.TCGOCLIfThenElse

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.