Package org.eclipse.jdt.core.dom

Examples of org.eclipse.jdt.core.dom.Comment


      converter.set(cu);
      converter.set(loc);
      cu.accept(converter);
      for (Iterator it = cu.getCommentList().iterator(); it.hasNext();) {
        Comment comment = (Comment) it.next();
        if (comment.isDocComment())
          continue;
        comment.accept(converter);
      }
     
      return converter.getModel(true);
    } catch (IOException e) {
      throw RuntimeExceptionFactory.io(VF.string(e.getMessage()), null, null);
View Full Code Here


        converter.set(cu);
        converter.set(loc);
        cu.accept(converter);
        for (Iterator it = cu.getCommentList().iterator(); it.hasNext();) {
          Comment comment = (Comment) it.next();
          if (comment.isDocComment())
            continue;
          comment.accept(converter);
        }
       
        return converter.getModel(true);
      } catch (IOException e) {
        throw RuntimeExceptionFactory.io(VF.string(e.getMessage()), null, null);
View Full Code Here

      int nodeLine = resource.getResourceCompUnit().getLineNumber(
          parent.getStartPosition());
      int line = 0;
      for (Iterator it = comments.iterator(); it.hasNext() && !found
          && nodeLine > line;) {
        Comment c = (Comment) it.next();
        // $ANALYSIS-IGNORE,codereview.java.rules.loop.RuleLoopAssignLoopVariable
        line = resource.getResourceCompUnit().getLineNumber(
            c.getStartPosition());
        if (c.getNodeType() == ASTNode.LINE_COMMENT) {
          LineComment lc = (LineComment) c;

          try {
            String comment = resource.getICompilationUnit()
                .getBuffer().getText(lc.getStartPosition(),
View Full Code Here

            }
          });
          // index = -(insertion point) - 1.
          if (index < 0) {
            loop: for (int j = -(index + 1); j < numberOfComments; j++) {
              Comment currentComment = (Comment) commentList.get(j);
              int commentStartPosition = currentComment.getStartPosition();
              int commentLength = currentComment.getLength();
              if ((commentStartPosition > currentExtendedEnd)
                  && ((commentStartPosition + commentLength - 1) < extendedStart)) {
                if (regions == null) {
                  regions = new ArrayList();
                }
View Full Code Here

            }
          });
          // index = -(insertion point) - 1.
          if (index < 0) {
            loop: for (int j = -(index + 1); j < numberOfComments; j++) {
              Comment currentComment = (Comment) commentList.get(j);
              int commentStartPosition = currentComment.getStartPosition();
              int commentLength = currentComment.getLength();
              if ((commentStartPosition > currentExtendedEnd)
                  && ((commentStartPosition + commentLength - 1) < extendedStart)) {
                if (regions == null) {
                  regions = new ArrayList();
                }
View Full Code Here

TOP

Related Classes of org.eclipse.jdt.core.dom.Comment

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.