public class Comment extends JavaSourceElement
Modifier and Type | Field and Description |
---|---|
private java.lang.String |
text |
Constructor and Description |
---|
Comment() |
Comment(java.lang.String text) |
Comment(java.lang.String text,
PositionInfo pInfo) |
Modifier and Type | Method and Description |
---|---|
boolean |
equals(java.lang.Object o) |
boolean |
equalsModRenaming(SourceElement se,
NameAbstractionTable nat)
comments can be ignored
|
java.lang.String |
getText() |
int |
hashCode() |
boolean |
isPrefixed() |
void |
prettyPrint(PrettyPrinter w)
Pretty printing the source element.
|
java.lang.String |
toString()
toString
|
void |
visit(Visitor v)
calls the corresponding method of a visitor in order to
perform some action/transformation on this element
|
getEndPosition, getFirstElement, getFirstElementIncludingBlocks, getLastElement, getParentClass, getPositionInfo, getRelativePosition, getStartPosition, setParentClass, toSource, toString
public Comment()
public Comment(java.lang.String text)
public Comment(java.lang.String text, PositionInfo pInfo)
public boolean isPrefixed()
public void prettyPrint(PrettyPrinter w)
JavaSourceElement
prettyPrint
in interface SourceElement
prettyPrint
in class JavaSourceElement
w
- a pretty printer.public void visit(Visitor v)
v
- the Visitorpublic java.lang.String getText()
public java.lang.String toString()
JavaSourceElement
toString
in class JavaSourceElement
public boolean equalsModRenaming(SourceElement se, NameAbstractionTable nat)
public int hashCode()
hashCode
in class java.lang.Object
public boolean equals(java.lang.Object o)
equals
in class java.lang.Object