Class HTMLwriter

java.lang.Object
org.ampere.base.html.HTMLwriter

public class HTMLwriter extends Object
Writer for HTML files
Author:
hmorel
  • Field Details

  • Constructor Details

    • HTMLwriter

      public HTMLwriter(File file)
      Create a new HTML writer
      Parameters:
      file - the associated file.
  • Method Details

    • getFile

      public File getFile()
    • writeTag

      public void writeTag(String tag, boolean closing)
      Write a simple tag, i.e. <tag>
      Parameters:
      tag - value of the tag to be written
      closing -
    • openElement

      public void openElement(String name, boolean closed, boolean newline)
      Write a simple element
      Parameters:
      name - element name
      closed - flag specifying if the element tag has to be closed or not.
      newline - flag specifying if the writing is finished by a new line or not.
    • closeElement

      public void closeElement(String element, boolean newLine)
      Close an element, i.e. write in the XML document </element>
      Parameters:
      element - name of the element
      newLine - flag specifying is a new line is printed or not
    • writeTitle

      public void writeTitle(int level, String title)
    • openParagraph

      public void openParagraph()
    • closeParagraph

      public void closeParagraph()
    • addText

      public void addText(String... texts)
    • writeParagraph

      public void writeParagraph(String... texts)
    • closeHTML

      public void closeHTML()
    • openBody

      public void openBody()
    • closeBody

      public void closeBody()
    • openHead

      public void openHead(String title)
    • closeHead

      public void closeHead()
    • writeLink

      public void writeLink(String tag, String text2click, boolean newLine)
    • writeLocalLink

      public void writeLocalLink(String target, String text2click, boolean newLine)
    • createTarget

      public void createTarget(String targetName)
    • writeDataRow

      public void writeDataRow(HTMLelement... values)
    • writeDataRow

      public void writeDataRow(List<HTMLelement> values)
    • writeHeaderRow

      public void writeHeaderRow(HTMLelement... values)
    • openStyle

      public void openStyle()
    • closeStyle

      public void closeStyle()