Package org.eclipse.dltk.ast

Examples of org.eclipse.dltk.ast.ASTNode.sourceEnd()


          bounds[0] = Math.min(bounds[0], firstNode.sourceStart());
        }
       
        ASTNode lastNode = list.get(list.size() - 1);
        if (lastNode != null) {
          bounds[1] = Math.max(bounds[0], lastNode.sourceEnd());
        }
      }
    }
    return bounds;
  }
View Full Code Here


    ASTNode quantifierPart = null;
    if (q != null && !q.isEmpty()) {
      quantifierPart = q.get(q.size() - 1);
    }
    if (quantifierPart != null) {
      bounds[1] = Math.max(bounds[1], quantifierPart.sourceEnd());
    }
    if (c != null && !c.isEmpty()) {
      bounds[1] = Math.max(bounds[1], c.get(c.size() - 1).sourceEnd());
    }
    if (a != null && !a.isEmpty()) {
View Full Code Here

      if (s != null && s.getChilds() != null) {
        children = s.getChilds();
        Iterator it = children.iterator();
        while (it.hasNext()) {
          ASTNode n = (ASTNode) it.next();
          requestor.addPosition(n.sourceStart(), n.sourceEnd(), RutaPreferenceConstants.EDITOR_DECLARATION_DEFINITION_COLOR);
        }
      }

      requestor.addPosition(t.getNameStart(), t.getNameEnd(), RutaPreferenceConstants.EDITOR_VARIABLE_COLOR);
    }
View Full Code Here

        ASTNode previousStatement = null;
        for (Iterator iterator = statements.iterator(); iterator
            .hasNext();) {
          ASTNode statement = (ASTNode) iterator.next();
          if (statement.sourceStart() <= sourceRange.getOffset()
              && statement.sourceEnd() >= (sourceRange
                  .getOffset() + sourceRange.getLength())) {
            // define statement
            phpDocBlocks = getPHPDocBlockBetweenStatements(
                previousStatement, statement, phpDocBlocks);
            if (phpDocBlocks.isEmpty()) {
View Full Code Here

        if (argument instanceof Scalar) {
          String constant = ASTUtils.stripQuotes(((Scalar) argument)
              .getValue());
          FieldDeclaration fieldDeclaration = new FieldDeclaration(
              constant, argument.sourceStart(),
              argument.sourceEnd(), callExpression.sourceStart(),
              callExpression.sourceEnd());
          fieldDeclaration.setModifier(Modifiers.AccGlobal
              | Modifiers.AccConstant | Modifiers.AccFinal);
          return fieldDeclaration;
        }
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.