Examples of Variable


Examples of com.creativewidgetworks.goldparser.parser.Variable

        String str = parser.getCurrentReduction() == null ? "\"\"" : parser.getCurrentReduction().get(0).asString();
       
        StringBuilder sb = new StringBuilder(str);
        sb.deleteCharAt(sb.length() - 1);
        sb.deleteCharAt(0);
        setValue(new Variable(sb.toString()));
    }
View Full Code Here

Examples of com.dubture.twig.core.parser.ast.node.Variable

                @Override
                public boolean visit(BlockStatement block) throws Exception
                {
                    if (TwigCoreConstants.START_BLOCK.equals(block.getName().getValue())) {

                        Variable name = block.getBlockName();

                        if (name == null) {
                            return false;
                        }

                        List<?> statements = block.getChilds();

                        MethodInfo info = new MethodInfo();
                        info.nameSourceStart = name.sourceStart();
                        info.nameSourceEnd = name.sourceEnd() - 1;
                        info.declarationStart = block.sourceStart();

                        info.name = name.getValue();
                        fRequestor.enterMethod(info);

                        if (statements.size() > 1) {
                            fRequestor.exitMethod(block.sourceEnd());
                        }
View Full Code Here

Examples of com.facebook.presto.byteCode.Variable

            LabelNode matchLabel,
            LabelNode noMatchLabel,
            Collection<ByteCodeNode> testValues,
            boolean checkForNulls)
    {
        Variable caseWasNull = null;
        if (checkForNulls) {
            caseWasNull = context.createTempVariable(boolean.class);
        }

        Block caseBlock = new Block(context)
                .visitLabel(caseLabel);

        if (checkForNulls) {
            caseBlock.putVariable(caseWasNull.getLocalVariableDefinition(), false);
        }

        LabelNode elseLabel = new LabelNode("else");
        Block elseBlock = new Block(context)
                .visitLabel(elseLabel);

        if (checkForNulls) {
            elseBlock.getVariable(caseWasNull.getLocalVariableDefinition())
                    .putVariable("wasNull");
        }

        elseBlock.gotoLabel(noMatchLabel);

        FunctionBinding equalsFunction = generatorContext.getBootstrapBinder().bindOperator(
                OperatorType.EQUAL,
                generatorContext.generateGetSession(),
                ImmutableList.<ByteCodeNode>of(NOP, NOP),
                ImmutableList.of(type, type));

        ByteCodeNode elseNode = elseBlock;
        for (ByteCodeNode testNode : testValues) {
            LabelNode testLabel = new LabelNode("test");
            IfStatement.IfStatementBuilder test = ifStatementBuilder(context);

            Block condition = new Block(context)
                    .visitLabel(testLabel)
                    .dup(type.getJavaType())
                    .append(testNode);

            if (checkForNulls) {
                condition.getVariable("wasNull")
                        .putVariable(caseWasNull.getLocalVariableDefinition())
                        .append(ifWasNullPopAndGoto(context, elseLabel, void.class, type.getJavaType(), type.getJavaType()));
            }
            condition.invokeDynamic(equalsFunction.getName(), equalsFunction.getCallSite().type(), equalsFunction.getBindingId());
            test.condition(condition);
View Full Code Here

Examples of com.github.sommeri.less4j.core.ast.Variable

  }

  private Variable buildFromVariable(HiddenTokenAwareTree realOwner, HiddenTokenAwareTree variableToken) {
    if (realOwner != null) {
      realOwner.addFollowing(variableToken.getFollowing());
      return new Variable(realOwner, variableToken.getText());
    }
    return new Variable(variableToken, variableToken.getText());
  }
View Full Code Here

Examples of com.google.test.metric.Variable

    @Override
    public void visit(AssignmentExpression assignmentExpression) {
      Node leftSide = assignmentExpression.getExpression(0);
      Node rightSide = assignmentExpression.getExpression(1);
      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;
        VariableDeclaration declaration = rightName.lookupVariable(
            rightName.getIdentifier());
        rightVar = new Variable(declaration.getName(),
            CppType.fromName(declaration.getType()), false, false);
      }
      if (leftVar != null && rightVar != null) {
        Node leftParent = leftDeclaration.getParent();
        if (leftParent instanceof ClassDeclaration) {
View Full Code Here

Examples of com.googlecode.aviator.lexer.token.Variable

            }
            // binary operation as variable for seq functions
            if (lookhead.getType() == TokenType.Char) {
                CharToken charToken = (CharToken) lookhead;
                // make it as variable
                lookhead = new Variable(charToken.getLexeme(), charToken.getStartIndex());
            }
            move(true);
            // function
            if (prevToken.getType() == TokenType.Variable && expectLexeme("(")) {
                method();
View Full Code Here

Examples of com.grits.objects.Variable

                return vars.get(i);
            }
            else
            {
                this.isVariable = false;
                return new Variable(1);
            }
        }
        return new Variable(1);
    }
View Full Code Here

Examples of com.javaforge.bobber.archetype.model.Variable

                        }
                    }
                    getLogger().debug("Not Expr: " + not);
                    getLogger().debug("Condition Value: '" + condition + "'");
                    getLogger().debug("Required Value: '" + requiredValue + "'");
                    final Variable var = (Variable) findVariable(condition, variables);
                    if (var != null)
                    {
                        final String strValue = (String) context.get(var.getName());
                        getLogger().debug("Variable Value is: '" + strValue + "'");
                        if (requiredValue == null)
                        {
                            if (!Boolean.valueOf(strValue).booleanValue())
                            {
View Full Code Here

Examples of com.litecoding.smali2java.entity.java.Variable

        for(SmaliCodeEntity regEntity : regGroup.getArguments()) {
          if(skipElement) {
            skipElement = false;
            continue;
          }
          Variable var = new Variable();
          var.setName(((Register)regEntity).getName());
          methodCall.getParams().add(var);
        }
       
        if(smaliClass.getSuperClassName().equals("Ljava/lang/Object;"))
          entity = new Comment(methodCall.render());
View Full Code Here

Examples of com.opera.core.systems.scope.protos.EcmascriptProtos.EvalArg.Variable

    String toSend = buildEvalString(elements, script, params);
    EvalArg.Builder evalBuilder = buildEval(toSend, getRuntimeId());

    for (WebElement webElement : elements) {
      Variable variable =
          buildVariable(webElement.toString(), ((OperaWebElement) webElement).getObjectId());
      evalBuilder.addVariableList(variable);
    }

    Response response = executeMessage(EcmascriptMessage.EVAL, evalBuilder);
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.