Uses of Class
com.github.javaparser.ast.comments.Comment
-
-
Uses of Comment in com.github.javaparser
Methods in com.github.javaparser that return Comment Modifier and Type Method Description (package private) static Comment
GeneratedJavaParserTokenManagerBase. createCommentFromToken(Token token)
Since comments are completely captured in a single token, including their delimiters, deconstruct them here so we can turn them into nodes later on.Method parameters in com.github.javaparser with type arguments of type Comment Modifier and Type Method Description private void
CommentsInserter. attributeLineCommentsOnSameLine(java.util.TreeSet<Comment> commentsToAttribute, java.util.List<Node> children)
private void
CommentsInserter. insertComments(CompilationUnit cu, java.util.TreeSet<Comment> comments)
Comments are attributed to the thing they comment and are removed from the comments.(package private) void
CommentsInserter. insertComments(Node node, java.util.TreeSet<Comment> commentsToAttribute)
This method try to attributes the nodes received to child of the node. -
Uses of Comment in com.github.javaparser.ast
Fields in com.github.javaparser.ast declared as Comment Modifier and Type Field Description private Comment
Node. comment
Fields in com.github.javaparser.ast with type parameters of type Comment Modifier and Type Field Description private java.util.List<Comment>
Node. orphanComments
Methods in com.github.javaparser.ast that return types with arguments of type Comment Modifier and Type Method Description java.util.List<Comment>
Node. getAllContainedComments()
This is the list of Comment which are contained in the Node either because they are properly associated to one of its children or because they are floating around inside the Nodejava.util.Optional<Comment>
Node. getComment()
This is a comment associated with this node.java.util.List<Comment>
CompilationUnit. getComments()
Return a list containing all comments declared in this compilation unit.java.util.List<Comment>
Node. getOrphanComments()
This is a list of Comment which are inside the node and are not associated with any meaningful AST Node.Methods in com.github.javaparser.ast with parameters of type Comment Modifier and Type Method Description void
Node. addOrphanComment(Comment comment)
boolean
Node. removeOrphanComment(Comment comment)
Node
Node. setComment(Comment comment)
Use this to store additional information to this node. -
Uses of Comment in com.github.javaparser.ast.comments
Subclasses of Comment in com.github.javaparser.ast.comments Modifier and Type Class Description class
BlockComment
AST node that represent block comments.class
JavadocComment
A Javadoc comment.class
LineComment
AST node that represent line comments.Fields in com.github.javaparser.ast.comments with type parameters of type Comment Modifier and Type Field Description private java.util.TreeSet<Comment>
CommentsCollection. comments
Methods in com.github.javaparser.ast.comments that return Comment Modifier and Type Method Description Comment
Comment. clone()
Comment
Comment. setCommentedNode(Node commentedNode)
Sets the commentedNodeComment
Comment. setContent(java.lang.String content)
Sets the text of the comment.Methods in com.github.javaparser.ast.comments that return types with arguments of type Comment Modifier and Type Method Description java.util.TreeSet<Comment>
CommentsCollection. getComments()
Methods in com.github.javaparser.ast.comments with parameters of type Comment Modifier and Type Method Description void
CommentsCollection. addComment(Comment comment)
boolean
CommentsCollection. contains(Comment comment)
Node
Comment. setComment(Comment comment)
Constructor parameters in com.github.javaparser.ast.comments with type arguments of type Comment Constructor Description CommentsCollection(java.util.Collection<Comment> commentsToCopy)
-
Uses of Comment in com.github.javaparser.ast.nodeTypes
Methods in com.github.javaparser.ast.nodeTypes that return types with arguments of type Comment Modifier and Type Method Description java.util.Optional<Comment>
NodeWithJavadoc. getComment()
java.util.Optional<Comment>
SwitchNode. getComment()
Methods in com.github.javaparser.ast.nodeTypes with parameters of type Comment Modifier and Type Method Description Node
NodeWithJavadoc. setComment(Comment comment)
-
Uses of Comment in com.github.javaparser.printer
Method parameters in com.github.javaparser.printer with type arguments of type Comment Modifier and Type Method Description private void
PrettyPrintVisitor. printComment(java.util.Optional<Comment> comment, java.lang.Void arg)
-
Uses of Comment in com.github.javaparser.printer.concretesyntaxmodel
Methods in com.github.javaparser.printer.concretesyntaxmodel with parameters of type Comment Modifier and Type Method Description (package private) static void
CsmComment. process(Comment comment, SourcePrinter printer)
-
Uses of Comment in com.github.javaparser.printer.lexicalpreservation
Methods in com.github.javaparser.printer.lexicalpreservation that return types with arguments of type Comment Modifier and Type Method Description static java.util.Optional<Comment>
LexicalPreservingPrinter. getComment(Node node)
Returns the comment or an Optional.empty if there is no comment on this method call.Methods in com.github.javaparser.printer.lexicalpreservation with parameters of type Comment Modifier and Type Method Description private java.util.List<ChildTextElement>
LexicalPreservingPrinter.Observer. findChildTextElementForComment(Comment oldValue, NodeText nodeText)
private java.util.List<TokenTextElement>
LexicalPreservingPrinter.Observer. findTokenTextElementForComment(Comment oldValue, NodeText nodeText)
private int
LexicalPreservingPrinter.Observer. getIndexOfComment(Comment oldValue, NodeText nodeText)
private static int
LexicalPreservingPrinter. getTokenKind(Comment comment)
-