Examples of lookupVariable()


Examples of com.google.test.metric.cpp.dom.Name.lookupVariable()

      Variable leftVar = null;
      Variable rightVar = null;
      VariableDeclaration leftDeclaration = null;
      if (leftSide instanceof Name) {
        Name leftName = (Name) leftSide;
        leftDeclaration = leftName.lookupVariable(leftName.getIdentifier());
        leftVar = new Variable(leftDeclaration.getName(),
            CppType.fromName(leftDeclaration.getType()), false, false);
      }
      if (rightSide instanceof Name) {
        Name rightName = (Name) rightSide;
View Full Code Here

Examples of com.google.test.metric.cpp.dom.Name.lookupVariable()

        leftVar = new Variable(leftDeclaration.getName(),
            CppType.fromName(leftDeclaration.getType()), false, false);
      }
      if (rightSide instanceof Name) {
        Name rightName = (Name) rightSide;
        VariableDeclaration declaration = rightName.lookupVariable(
            rightName.getIdentifier());
        rightVar = new Variable(declaration.getName(),
            CppType.fromName(declaration.getType()), false, false);
      }
      if (leftVar != null && rightVar != null) {
View Full Code Here

Examples of org.springframework.expression.spel.support.StandardEvaluationContext.lookupVariable()

    expectFailNotIncrementable(parser, ctx, "#wibble++");
    expectFailNotDecrementable(parser, ctx, "--#wibble");
    e = parser.parseExpression("#wibble=#wibble+#wibble");
    String s = e.getValue(ctx,String.class);
    assertEquals("hello worldhello world",s);
    assertEquals("hello worldhello world",ctx.lookupVariable("wibble"));

    ctx.setVariable("wobble", 3);
    e = parser.parseExpression("#wobble++");
    assertEquals(3,((Integer)ctx.lookupVariable("wobble")).intValue());
    int r = e.getValue(ctx,Integer.TYPE);
View Full Code Here

Examples of org.springframework.expression.spel.support.StandardEvaluationContext.lookupVariable()

    assertEquals("hello worldhello world",s);
    assertEquals("hello worldhello world",ctx.lookupVariable("wibble"));

    ctx.setVariable("wobble", 3);
    e = parser.parseExpression("#wobble++");
    assertEquals(3,((Integer)ctx.lookupVariable("wobble")).intValue());
    int r = e.getValue(ctx,Integer.TYPE);
    assertEquals(3,r);
    assertEquals(4,((Integer)ctx.lookupVariable("wobble")).intValue());

    e = parser.parseExpression("--#wobble");
View Full Code Here

Examples of org.springframework.expression.spel.support.StandardEvaluationContext.lookupVariable()

    ctx.setVariable("wobble", 3);
    e = parser.parseExpression("#wobble++");
    assertEquals(3,((Integer)ctx.lookupVariable("wobble")).intValue());
    int r = e.getValue(ctx,Integer.TYPE);
    assertEquals(3,r);
    assertEquals(4,((Integer)ctx.lookupVariable("wobble")).intValue());

    e = parser.parseExpression("--#wobble");
    assertEquals(4,((Integer)ctx.lookupVariable("wobble")).intValue());
    r = e.getValue(ctx,Integer.TYPE);
    assertEquals(3,r);
View Full Code Here

Examples of org.springframework.expression.spel.support.StandardEvaluationContext.lookupVariable()

    int r = e.getValue(ctx,Integer.TYPE);
    assertEquals(3,r);
    assertEquals(4,((Integer)ctx.lookupVariable("wobble")).intValue());

    e = parser.parseExpression("--#wobble");
    assertEquals(4,((Integer)ctx.lookupVariable("wobble")).intValue());
    r = e.getValue(ctx,Integer.TYPE);
    assertEquals(3,r);
    assertEquals(3,((Integer)ctx.lookupVariable("wobble")).intValue());

    e = parser.parseExpression("#wobble=34");
View Full Code Here

Examples of org.springframework.expression.spel.support.StandardEvaluationContext.lookupVariable()

    e = parser.parseExpression("--#wobble");
    assertEquals(4,((Integer)ctx.lookupVariable("wobble")).intValue());
    r = e.getValue(ctx,Integer.TYPE);
    assertEquals(3,r);
    assertEquals(3,((Integer)ctx.lookupVariable("wobble")).intValue());

    e = parser.parseExpression("#wobble=34");
    assertEquals(3,((Integer)ctx.lookupVariable("wobble")).intValue());
    r = e.getValue(ctx,Integer.TYPE);
    assertEquals(34,r);
View Full Code Here

Examples of org.springframework.expression.spel.support.StandardEvaluationContext.lookupVariable()

    r = e.getValue(ctx,Integer.TYPE);
    assertEquals(3,r);
    assertEquals(3,((Integer)ctx.lookupVariable("wobble")).intValue());

    e = parser.parseExpression("#wobble=34");
    assertEquals(3,((Integer)ctx.lookupVariable("wobble")).intValue());
    r = e.getValue(ctx,Integer.TYPE);
    assertEquals(34,r);
    assertEquals(34,((Integer)ctx.lookupVariable("wobble")).intValue());

    // Projection
View Full Code Here

Examples of org.springframework.expression.spel.support.StandardEvaluationContext.lookupVariable()

    e = parser.parseExpression("#wobble=34");
    assertEquals(3,((Integer)ctx.lookupVariable("wobble")).intValue());
    r = e.getValue(ctx,Integer.TYPE);
    assertEquals(34,r);
    assertEquals(34,((Integer)ctx.lookupVariable("wobble")).intValue());

    // Projection
    expectFailNotIncrementable(parser, ctx, "({1,2,3}.![#isEven(#this)])++"); // projection would be {false,true,false}
    expectFailNotDecrementable(parser, ctx, "--({1,2,3}.![#isEven(#this)])"); // projection would be {false,true,false}
    expectFailNotAssignable(parser, ctx, "({1,2,3}.![#isEven(#this)])=({1,2,3}.![#isEven(#this)])");
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.