Class JavaDocGenerator

java.lang.Object
io.vertx.docgen.JavaDocGenerator
All Implemented Interfaces:
DocGenerator

public class JavaDocGenerator extends Object implements DocGenerator
Author:
Julien Viet
  • Field Details

    • docTrees

      protected com.sun.source.util.DocTrees docTrees
    • processingEnv

      protected ProcessingEnvironment processingEnv
  • Constructor Details

    • JavaDocGenerator

      public JavaDocGenerator()
  • Method Details

    • init

      public void init(ProcessingEnvironment env)
      Description copied from interface: DocGenerator
      Init the generator.
      Specified by:
      init in interface DocGenerator
      Parameters:
      env - the processor environment
    • getName

      public String getName()
      Specified by:
      getName in interface DocGenerator
      Returns:
      the generator name
    • resolveTypeLink

      public String resolveTypeLink(TypeElement elt)
      Description copied from interface: DocGenerator
      Resolve a constructor link.
      Specified by:
      resolveTypeLink in interface DocGenerator
      Parameters:
      elt - the element linked to
      Returns:
      the resolved http link or null if the link cannot be resolved
    • resolveConstructorLink

      public String resolveConstructorLink(ExecutableElement elt)
      Description copied from interface: DocGenerator
      Resolve a constructor link.
      Specified by:
      resolveConstructorLink in interface DocGenerator
      Parameters:
      elt - the element linked to
      Returns:
      the resolved http link or null if the link cannot be resolved
    • resolveMethodLink

      public String resolveMethodLink(ExecutableElement elt)
      Description copied from interface: DocGenerator
      Resolve a method link.
      Specified by:
      resolveMethodLink in interface DocGenerator
      Parameters:
      elt - the element linked to
      Returns:
      the resolved http link or null if the link cannot be resolved
    • resolveLabel

      public String resolveLabel(Element elt, String defaultLabel)
      Description copied from interface: DocGenerator
      Resolve a label.
      Specified by:
      resolveLabel in interface DocGenerator
      Parameters:
      elt - the labelled element
      defaultLabel - the default label
      Returns:
      the resolved label or null if a label cannot be resolved
    • resolveFieldLink

      public String resolveFieldLink(VariableElement elt)
      Description copied from interface: DocGenerator
      Resolve a field link.
      Specified by:
      resolveFieldLink in interface DocGenerator
      Parameters:
      elt - the element linked to
      Returns:
      the resolved http link or null if the link cannot be resolved
    • renderSource

      public String renderSource(ExecutableElement elt, String source)
      Render the source fragment for the Java language. Java being the pivot language, we consider this method as the _default_ behavior. This method is final as it must not be overridden by any extension.
      Specified by:
      renderSource in interface DocGenerator
      Parameters:
      elt - the element
      source - the source
      Returns:
      the fragment
    • renderSource

      public String renderSource(TypeElement elt, String source)
    • renderSource

      public String renderSource(com.sun.source.util.TreePath path, List<? extends com.sun.source.tree.Tree> trees, String source)