Examples of Variable


Examples of com.opera.core.systems.scope.protos.EsdbgProtos.EvalData.Variable

    }

    EvalData.Builder evalBuilder = buildEval(toSend, getRuntimeId());

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

    Response response = executeMessage(EcmascriptDebuggerMessage.EVAL, evalBuilder);
View Full Code Here

Examples of com.sk89q.worldedit.internal.expression.runtime.Variable

        for (String variableName : variableNames) {
            if (variables.containsKey(variableName)) {
                throw new ExpressionException(-1, "Tried to overwrite identifier '" + variableName + "'");
            }
            variables.put(variableName, new Variable(0));
        }

        root = Parser.parse(tokens, this);
    }
View Full Code Here

Examples of com.strobel.decompiler.ast.Variable

            _result.remove();
        }

        @Override
        public Void visitIdentifierExpression(final IdentifierExpression node, final Void _) {
            final Variable variable = node.getUserData(Keys.VARIABLE);

            if (variable != null && variable.isParameter()) {
                final ParameterDefinition parameter = variable.getOriginalParameter();

                if (areMethodsEquivalent((MethodReference) parameter.getMethod(), context.getCurrentMethod())) {
                    final AstNode replacement = _argumentMappings.get(parameter);

                    if (replacement != null) {
View Full Code Here

Examples of com.sun.jdo.spi.persistence.support.sqlstore.query.util.scope.Variable

    _t = __t18;
    _t = _t.getNextSibling();
   
    String name = i_AST.getText();
    Type type = t_AST.getJQLType();
    Definition old = symtab.declare(name, new Variable(type));
    if (old != null)
    {
    errorMsg.error(i_AST.getLine(), i_AST.getColumn(),
    I18NHelper.getMessage(messages, "jqlc.semantic.generic.alreadydeclared", //NOI18N
    name, old.getName()));
View Full Code Here

Examples of com.sun.org.apache.xpath.internal.operations.Variable

   * @throws TransformerException if a error occurs creating the Expression.
   */
  protected Expression variable(int opPos) throws TransformerException
  {

    Variable var = new Variable();

    opPos = getFirstChildPos(opPos);

    int nsPos = getOp(opPos);
    java.lang.String namespace
      = (OpCodes.EMPTY == nsPos) ? null
                                   : (java.lang.String) getTokenQueue().elementAt(nsPos);
    java.lang.String localname
      = (java.lang.String) getTokenQueue().elementAt(getOp(opPos+1));
    QName qname = new QName(namespace, localname);

    var.setQName(qname);

    return var;
  }
View Full Code Here

Examples of com.volantis.xml.expression.Variable

    }

    // javadoc inherited
    public Variable declareVariable(ExpandedName name,
                                    Value initialValue) {
        Variable variable = null;

        if (variables.containsKey(name)) {
            throw new IllegalArgumentException(
                    "Variable " + name.getLocalName() + " in namespace \"" +
                    name.getNamespaceURI() + "\" already exists in this scope");
View Full Code Here

Examples of common.model.Variable

    }
    // Range Check
    for (int i = 0; i < total; i++) {
      String var = MessageFormat.format(varPattern, i);
      result.add(new Assert(new Predicate(Operator.AND, new Predicate(
          Operator.GE, new Variable(var), new Constant(1)),
          new Predicate(Operator.LE, new Variable(var), new Constant(
              size * size)))));
    }
    // Assigned values
    for (int[] assign : assigned) {
      String var = MessageFormat.format(varPattern,
          translate(assign[0], assign[1]));
      result.add(new Assert(new Predicate(Operator.EQUAL, new Variable(
          var), new Constant(assign[2]))));
    }
    // Limitations
    // Columns and rows
    for (int i = 0; i < size * size; i++) {
      for (int j = 0; j < size * size; j++) {
        for (int k = j + 1; k < size * size; k++) {
          result.add(new Assert(new Predicate(Operator.NOT,
              new Predicate(Operator.EQUAL, new Variable(
                  MessageFormat.format(varPattern,
                      translate(i, j))), new Variable(
                  MessageFormat.format(varPattern,
                      translate(i, k)))))));
          result.add(new Assert(new Predicate(Operator.NOT,
              new Predicate(Operator.EQUAL, new Variable(
                  MessageFormat.format(varPattern,
                      translate(j, i))), new Variable(
                  MessageFormat.format(varPattern,
                      translate(k, i)))))));
          result.add(new Assert(new Predicate(Operator.NOT,
              new Predicate(Operator.EQUAL, new Variable(
                  MessageFormat.format(varPattern,
                      sqrtranslate(i, j))), new Variable(
                  MessageFormat.format(varPattern,
                      sqrtranslate(i, k)))))));
        }
      }
    }
View Full Code Here

Examples of cs227b.teamIago.resolver.Variable

public static Expression parseExpression(Object _s){
  if (_s instanceof ArrayList)
    _s = ((ArrayList)_s).get(0);
  if (_s instanceof String){
    if (((String)_s).startsWith("?"))
      return new Variable(new Atom((String)_s));
    return new Atom((String)_s);
  }
  Statement s = (Statement) _s;
  String opt = s.operator.toUpperCase();
  Expression res=null;
View Full Code Here

Examples of de.maramuse.soundcomp.math.Variable

  if(variables!=null)
  for(ParserVal val:variables.inner){
    if(usedNames.contains(val.getText()))
    throw new IllegalArgumentException("Process "+name+" contains repeated variable name "
      +val.getText());
    Variable v=new Variable();
    v.setAbstractName(val.getText());
    containedVariables.put(val.getText(), v);
    subs.put(val.getText(), v);
    usedNames.add(val.getText());
    SourceStore sst=getAsSource(val.inner.get(0));
    v.setSource(0, sst.source, sst.sourceIndex);
  }
  /*
   * make all internal elements known to the internal accounting these may be process references and in the future
   * also inner process definitions
   */
  if(subprocesses!=null)
  for(ParserVal val:subprocesses.inner){
    NamedSource el;
    if(usedNames.contains(val.getText()))
    throw new IllegalArgumentException("Process "+name+" contains repeated element name "
      +val.getText());
    if(val instanceof ProcessRef){
    ProcessRef r=((ProcessRef)val);
    // TODO find the corresponding process, if it is not a primitive. Should be done during parsing?
    if(r.process==null){
      if(r.localName==null)
        throw new IllegalStateException("no process set for anonymous reference");
      throw new IllegalStateException("no process set for reference "+r.localName);
    }
    el=r.process.createTemplate();
    usedNames.add(r.localName);
    subprocessMap.put(val.getText(), (Process)el);
    subrefMap.put(val.getText(), r);
    subs.put(val.getText(), el);
    break; // do not insert it into subprocess map
    }
    // TODO: allow inner process definitions
    throw new IllegalArgumentException("Element "+val.getText()+" contained in element "
      +getText()
      +" is not of suitable type (must be process reference) in "+filename+", line "+line);
  }
  // TODO: now that we know all sub elements, iterate once again over them, and connect
  // their inputs. All connection counterparts, except for formulas, must be available now.
  // For formulas, anonymous subprocesses must be created on the fly and
  // get their inputs directly fed.
  for(String ename:subs.keySet()){
    // iterate over all subprocesses and subprocess references and connect their inputs
    NamedSource val=subs.get(ename);
    if(val instanceof ProcessRef){
     ProcessRef r=(ProcessRef)val;
     Process p=subprocessMap.get(r.localName);
     if(r.getInputAssignments()!=null)
        for(InputAssignment i:r.getInputAssignments().getAssignments()){
      // now for each input of the subprocess, check if there is an assignment
        if(i.getInputName()==null||i.getInputName().length()==0)
        continue;
      // first, get the destination index to which to connect to
      Parameter dest=p.namedInputs.get(i.getInputName());
      // then for each assignment, check if there is an input, and set the connection
      if(i.getFormula()==null){
        // this input of the sub element stays open, so ignore it
      }else{
        SourceStore sst=getAsSource(i.getFormula());
        p.setSource(dest.i, sst.source, sst.sourceIndex);
      }
        }
     }else if(val instanceof Process){
     throw new IllegalArgumentException("Found process "+val.getAbstractName()+" where a processreference was expected - nested process definitions not yet implemented");
     }else
    // don't expect that here.
     throw new IllegalArgumentException("Found symbol "+val.getAbstractName()+" where a processreference was expected");
   }
  // connect all variables to their value sources
  if(variables!=null)
  for(ParserVal val:variables.inner){
    Variable v=containedVariables.get(val.getText());
    SourceStore sst=getAsSource(val.inner.get(0));
    v.setSource(0, sst.source, sst.sourceIndex);
  }
  // after all internal elements are connected, fix the connections of the outputs.
  // here also, create anonymous subprocesses if applicable.
  for(ParserVal val:outputs.inner){
    if(usedNames.contains(val.getText()))
View Full Code Here

Examples of dk.brics.string.intermediate.Variable

                for (Call c : s.getMethod().getCallSites()) {
                    link(((AssignmentNode) n).getArg(), c, c.args[i]);
                }
            }
            if (v == pa[i]) { // link formal to param alias
                Variable p = s.params[i];
                AssignmentNode an = (AssignmentNode) map.get(s).get(p);
                ((AssignmentNode) n).getArg().addDefUse(an);
            }
        }
    }
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.