public class JavadocComment extends AbstractComment
CommentStructure
This class is responsible of adding the right JavaDoc syntax in its proper
place inside the structure. Having this in mind, adding manually any syntax
*is discouraged*.
Please, avoid using specific system line separators. Use
`org.apache.commons.io.IOUtils.LINE_SEPARATOR` to specify line breaks.| Constructor and Description |
|---|
JavadocComment()
Default empty constructor.
|
JavadocComment(String comment)
Used to add the full JavaDoc comment during the instantiation.
|
JavadocComment(String description,
List<String> paramsInfo,
String returnInfo,
List<String> throwsTypes)
Constructor used to generate a full Javadoc with description, params,
return and throws.
|
| Modifier and Type | Method and Description |
|---|---|
String |
getDescription() |
List<String> |
getParamsInfo() |
String |
getReturnInfo() |
List<String> |
getThrowsInfo() |
void |
setComment(String comment) |
void |
setDescription(String description) |
void |
setParamsInfo(List<String> paramsInfo) |
void |
setReturnInfo(String returnInfo) |
void |
setThrowsInfo(List<String> throwsInfo) |
getCommentpublic JavadocComment()
public JavadocComment(String comment)
comment - the String with the comment to add as JavaDoc syntax.public JavadocComment(String description, List<String> paramsInfo, String returnInfo, List<String> throwsTypes)
description - the `String` with the block description to add. Please, use
`org.apache.commons.io.IOUtils.LINE_SEPARATOR` for line breaks.paramsInfo - the `ListreturnInfo - the `String` with the return info. JavaDoc ` * @return`
syntax will be automatically added.throwsInfo - the `Listpublic void setComment(String comment)
setComment in class AbstractCommentpublic String getDescription()
public void setDescription(String description)
public String getReturnInfo()
public void setReturnInfo(String returnInfo)
Copyright © 2009–2017. All rights reserved.