Class DocumentParser

java.lang.Object
com.nomagic.reportwizard.tools.doc.javadoc.DocumentParser

@OpenApiAll public class DocumentParser extends Object
Parse the comment string into Document.
Since:
Sep 3, 2008
  • Constructor Details

    • DocumentParser

      public DocumentParser(ITool tool)
      Create the parser.
      Parameters:
      tool - Document Tool
  • Method Details

    • getDocument

      public Document getDocument()
      Return a Document from comment string.
      Returns:
      a Document
    • parse

      public void parse(String commentText) throws DocumentException
      Parse the comment string. The JavaDoc comment must be started with /** and end with */.
      Parameters:
      commentText - input string with /** and end with invalid input: '&#42'
      Throws:
      DocumentException - when error while parsing document.
    • parseText

      public void parseText(String commentText) throws DocumentException
      Parse the comment string in plain text format.
      Parameters:
      commentText - input string
      Throws:
      DocumentException - when error while parsing document.
    • handleTag

      public void handleTag(String tagName, String text)
      Called when a JavaDoc block tag is encountered.
      Parameters:
      tagName - tag name
      text - text comment
    • handleInlineTag

      public void handleInlineTag(String blockTag, String inlineTag, String text)
      Called when a JavaDoc inline tag is encountered.
      Parameters:
      blockTag - block tag name
      inlineTag - inline tag name
      text - text comment
    • handleComment

      public void handleComment(String text)
      Called when a JavaDoc comment is encountered.
      Parameters:
      text - text comment