public class JavaDocGenerator extends Object implements DocGenerator
Modifier and Type | Field and Description |
---|---|
protected com.sun.source.util.DocTrees |
docTrees |
protected ProcessingEnvironment |
processingEnv |
Constructor and Description |
---|
JavaDocGenerator() |
Modifier and Type | Method and Description |
---|---|
String |
getName() |
void |
init(ProcessingEnvironment env)
Init the generator.
|
String |
renderSource(ExecutableElement elt,
String source)
Render the source fragment for the Java language.
|
String |
renderSource(com.sun.source.util.TreePath path,
List<? extends com.sun.source.tree.Tree> trees,
String source) |
String |
renderSource(TypeElement elt,
String source) |
String |
resolveConstructorLink(ExecutableElement elt,
Coordinate coordinate)
Resolve a constructor link.
|
String |
resolveFieldLink(VariableElement elt,
Coordinate coordinate)
Resolve a field link.
|
String |
resolveLabel(Element elt,
String defaultLabel)
Resolve a label.
|
String |
resolveMethodLink(ExecutableElement elt,
Coordinate coordinate)
Resolve a method link.
|
String |
resolveTypeLink(TypeElement elt,
Coordinate coordinate)
Resolve a constructor link.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
resolveRelativeFileName
protected com.sun.source.util.DocTrees docTrees
protected ProcessingEnvironment processingEnv
public void init(ProcessingEnvironment env)
DocGenerator
init
in interface DocGenerator
env
- the processor environmentpublic String getName()
getName
in interface DocGenerator
public String resolveTypeLink(TypeElement elt, Coordinate coordinate)
DocGenerator
resolveTypeLink
in interface DocGenerator
elt
- the element linked tocoordinate
- the optional coordinate of the jar containing the elementpublic String resolveConstructorLink(ExecutableElement elt, Coordinate coordinate)
DocGenerator
resolveConstructorLink
in interface DocGenerator
elt
- the element linked tocoordinate
- the optional coordinate of the jar containing the elementpublic String resolveMethodLink(ExecutableElement elt, Coordinate coordinate)
DocGenerator
resolveMethodLink
in interface DocGenerator
elt
- the element linked tocoordinate
- the optional coordinate of the jar containing the elementpublic String resolveLabel(Element elt, String defaultLabel)
DocGenerator
resolveLabel
in interface DocGenerator
elt
- the labelled elementdefaultLabel
- the default labelpublic String resolveFieldLink(VariableElement elt, Coordinate coordinate)
DocGenerator
resolveFieldLink
in interface DocGenerator
elt
- the element linked tocoordinate
- the optional coordinate of the jar containing the elementpublic String renderSource(ExecutableElement elt, String source)
renderSource
in interface DocGenerator
elt
- the elementsource
- the sourcepublic String renderSource(TypeElement elt, String source)
Copyright © 2017. All rights reserved.