Package spoon.javadoc.internal
Class Javadoc
- java.lang.Object
-
- spoon.javadoc.internal.Javadoc
-
- All Implemented Interfaces:
Serializable
public class Javadoc extends Object implements Serializable
The structured content of a single Javadoc comment.It is composed by a description and a list of block tags.
An example would be the text contained in this very Javadoc comment. At the moment of this writing this comment does not contain any block tags (such as
@see AnotherClass
)- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description Javadoc()
Javadoc(JavadocDescription description)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description Javadoc
addBlockTag(String tagName)
Javadoc
addBlockTag(String tagName, String parameter, String content)
For tags like "@return good things" where tagName is "return", and the rest is content.Javadoc
addBlockTag(JavadocBlockTag blockTag)
boolean
equals(Object o)
List<JavadocBlockTag>
getBlockTags()
JavadocDescription
getDescription()
int
hashCode()
static Javadoc
parse(String commentContent)
parses the Javadoc content (description + tags)static JavadocDescription
parseText(String text)
parse the description part (before tags) of a JavadocString
toString()
String
toText()
Return the text content of the document.
-
-
-
Constructor Detail
-
Javadoc
public Javadoc()
-
Javadoc
public Javadoc(JavadocDescription description)
-
-
Method Detail
-
addBlockTag
public Javadoc addBlockTag(JavadocBlockTag blockTag)
-
addBlockTag
public Javadoc addBlockTag(String tagName, String parameter, String content)
For tags like "@return good things" where tagName is "return", and the rest is content.
-
toText
public String toText()
Return the text content of the document. It does not containing trailing spaces and asterisks at the start of the line.
-
getDescription
public JavadocDescription getDescription()
-
getBlockTags
public List<JavadocBlockTag> getBlockTags()
- Returns:
- the current List of associated JavadocBlockTags
-
parseText
public static JavadocDescription parseText(String text)
parse the description part (before tags) of a Javadoc
-
-