Class AbstractSink

java.lang.Object
org.apache.maven.doxia.sink.impl.AbstractSink
All Implemented Interfaces:
AutoCloseable, Markup, org.apache.maven.doxia.sink.Sink
Direct Known Subclasses:
SinkAdapter, SinkWrapper

public abstract class AbstractSink extends Object implements org.apache.maven.doxia.sink.Sink, Markup
An abstract base class that defines some convenience methods for sinks. Also acts as compatibility bridge for Doxia 1.0 methods which have overloaded variants in Doxia > 1.0 (taking an additional argument SinkEventAttributes). This implementation just delegates the former to the latter with argument SinkEventAttributes being null.
Since:
1.1
Author:
ltheussl, Vincent Siveton
  • Constructor Details

    • AbstractSink

      public AbstractSink()
  • Method Details

    • head

      public final void head()
      Specified by:
      head in interface org.apache.maven.doxia.sink.Sink
    • title

      public final void title()
      Specified by:
      title in interface org.apache.maven.doxia.sink.Sink
    • author

      public final void author()
      Specified by:
      author in interface org.apache.maven.doxia.sink.Sink
    • date

      public final void date()
      Specified by:
      date in interface org.apache.maven.doxia.sink.Sink
    • body

      public final void body()
      Specified by:
      body in interface org.apache.maven.doxia.sink.Sink
    • article

      public final void article()
      Specified by:
      article in interface org.apache.maven.doxia.sink.Sink
    • sidebar

      public final void sidebar()
      Specified by:
      sidebar in interface org.apache.maven.doxia.sink.Sink
    • sectionTitle

      public final void sectionTitle()
      Specified by:
      sectionTitle in interface org.apache.maven.doxia.sink.Sink
    • section1

      public final void section1()
      Specified by:
      section1 in interface org.apache.maven.doxia.sink.Sink
    • sectionTitle_

      public final void sectionTitle_()
      Specified by:
      sectionTitle_ in interface org.apache.maven.doxia.sink.Sink
    • section1_

      public final void section1_()
      Specified by:
      section1_ in interface org.apache.maven.doxia.sink.Sink
    • sectionTitle1

      public final void sectionTitle1()
      Specified by:
      sectionTitle1 in interface org.apache.maven.doxia.sink.Sink
    • sectionTitle1_

      public final void sectionTitle1_()
      Specified by:
      sectionTitle1_ in interface org.apache.maven.doxia.sink.Sink
    • section2

      public final void section2()
      Specified by:
      section2 in interface org.apache.maven.doxia.sink.Sink
    • section2_

      public final void section2_()
      Specified by:
      section2_ in interface org.apache.maven.doxia.sink.Sink
    • sectionTitle2

      public final void sectionTitle2()
      Specified by:
      sectionTitle2 in interface org.apache.maven.doxia.sink.Sink
    • sectionTitle2_

      public final void sectionTitle2_()
      Specified by:
      sectionTitle2_ in interface org.apache.maven.doxia.sink.Sink
    • section3

      public final void section3()
      Specified by:
      section3 in interface org.apache.maven.doxia.sink.Sink
    • section3_

      public final void section3_()
      Specified by:
      section3_ in interface org.apache.maven.doxia.sink.Sink
    • sectionTitle3

      public final void sectionTitle3()
      Specified by:
      sectionTitle3 in interface org.apache.maven.doxia.sink.Sink
    • sectionTitle3_

      public final void sectionTitle3_()
      Specified by:
      sectionTitle3_ in interface org.apache.maven.doxia.sink.Sink
    • section4

      public final void section4()
      Specified by:
      section4 in interface org.apache.maven.doxia.sink.Sink
    • section4_

      public final void section4_()
      Specified by:
      section4_ in interface org.apache.maven.doxia.sink.Sink
    • sectionTitle4

      public final void sectionTitle4()
      Specified by:
      sectionTitle4 in interface org.apache.maven.doxia.sink.Sink
    • sectionTitle4_

      public final void sectionTitle4_()
      Specified by:
      sectionTitle4_ in interface org.apache.maven.doxia.sink.Sink
    • section5

      public final void section5()
      Specified by:
      section5 in interface org.apache.maven.doxia.sink.Sink
    • section5_

      public final void section5_()
      Specified by:
      section5_ in interface org.apache.maven.doxia.sink.Sink
    • sectionTitle5

      public final void sectionTitle5()
      Specified by:
      sectionTitle5 in interface org.apache.maven.doxia.sink.Sink
    • sectionTitle5_

      public final void sectionTitle5_()
      Specified by:
      sectionTitle5_ in interface org.apache.maven.doxia.sink.Sink
    • section6

      public final void section6()
      Specified by:
      section6 in interface org.apache.maven.doxia.sink.Sink
    • section6_

      public final void section6_()
      Specified by:
      section6_ in interface org.apache.maven.doxia.sink.Sink
    • sectionTitle6

      public final void sectionTitle6()
      Specified by:
      sectionTitle6 in interface org.apache.maven.doxia.sink.Sink
    • sectionTitle6_

      public final void sectionTitle6_()
      Specified by:
      sectionTitle6_ in interface org.apache.maven.doxia.sink.Sink
    • header

      public final void header()
      Specified by:
      header in interface org.apache.maven.doxia.sink.Sink
    • content

      public final void content()
      Specified by:
      content in interface org.apache.maven.doxia.sink.Sink
    • footer

      public final void footer()
      Specified by:
      footer in interface org.apache.maven.doxia.sink.Sink
    • list

      public final void list()
      Specified by:
      list in interface org.apache.maven.doxia.sink.Sink
    • listItem

      public final void listItem()
      Specified by:
      listItem in interface org.apache.maven.doxia.sink.Sink
    • numberedList

      public final void numberedList(int numbering)
      Specified by:
      numberedList in interface org.apache.maven.doxia.sink.Sink
    • numberedListItem

      public final void numberedListItem()
      Specified by:
      numberedListItem in interface org.apache.maven.doxia.sink.Sink
    • definitionList

      public final void definitionList()
      Specified by:
      definitionList in interface org.apache.maven.doxia.sink.Sink
    • definitionListItem

      public final void definitionListItem()
      Specified by:
      definitionListItem in interface org.apache.maven.doxia.sink.Sink
    • definition

      public final void definition()
      Specified by:
      definition in interface org.apache.maven.doxia.sink.Sink
    • definedTerm

      public final void definedTerm()
      Specified by:
      definedTerm in interface org.apache.maven.doxia.sink.Sink
    • figure

      public final void figure()
      Specified by:
      figure in interface org.apache.maven.doxia.sink.Sink
    • figureCaption

      public final void figureCaption()
      Specified by:
      figureCaption in interface org.apache.maven.doxia.sink.Sink
    • figureGraphics

      public final void figureGraphics(String name)
      Specified by:
      figureGraphics in interface org.apache.maven.doxia.sink.Sink
    • table

      public final void table()
      Specified by:
      table in interface org.apache.maven.doxia.sink.Sink
    • tableRows

      public final void tableRows()
      Specified by:
      tableRows in interface org.apache.maven.doxia.sink.Sink
    • tableRow

      public final void tableRow()
      Specified by:
      tableRow in interface org.apache.maven.doxia.sink.Sink
    • tableCell

      public final void tableCell()
      Specified by:
      tableCell in interface org.apache.maven.doxia.sink.Sink
    • tableHeaderCell

      public final void tableHeaderCell()
      Specified by:
      tableHeaderCell in interface org.apache.maven.doxia.sink.Sink
    • tableCaption

      public final void tableCaption()
      Specified by:
      tableCaption in interface org.apache.maven.doxia.sink.Sink
    • paragraph

      public final void paragraph()
      Specified by:
      paragraph in interface org.apache.maven.doxia.sink.Sink
    • data

      public final void data(String value)
      Specified by:
      data in interface org.apache.maven.doxia.sink.Sink
    • time

      public final void time(String datetime)
      Specified by:
      time in interface org.apache.maven.doxia.sink.Sink
    • address

      public final void address()
      Specified by:
      address in interface org.apache.maven.doxia.sink.Sink
    • blockquote

      public final void blockquote()
      Specified by:
      blockquote in interface org.apache.maven.doxia.sink.Sink
    • division

      public final void division()
      Specified by:
      division in interface org.apache.maven.doxia.sink.Sink
    • verbatim

      public final void verbatim()
      Specified by:
      verbatim in interface org.apache.maven.doxia.sink.Sink
    • horizontalRule

      public final void horizontalRule()
      Specified by:
      horizontalRule in interface org.apache.maven.doxia.sink.Sink
    • anchor

      public final void anchor(String name)
      Specified by:
      anchor in interface org.apache.maven.doxia.sink.Sink
    • link

      public final void link(String name)
      Specified by:
      link in interface org.apache.maven.doxia.sink.Sink
    • inline

      public final void inline()
      Specified by:
      inline in interface org.apache.maven.doxia.sink.Sink
    • lineBreak

      public final void lineBreak()
      Specified by:
      lineBreak in interface org.apache.maven.doxia.sink.Sink
    • lineBreakOpportunity

      public final void lineBreakOpportunity()
      Specified by:
      lineBreakOpportunity in interface org.apache.maven.doxia.sink.Sink
    • text

      public final void text(String text)
      Specified by:
      text in interface org.apache.maven.doxia.sink.Sink
    • unifyEOLs

      protected static String unifyEOLs(String text)
      Parses the given String and replaces all occurrences of '\n', '\r' and '\r\n' with the system EOL. All Sinks should make sure that text output is filtered through this method.
      Parameters:
      text - the text to scan. May be null in which case null is returned.
      Returns:
      a String that contains only System EOLs.
    • init

      protected void init()
      This is called in head() or in Sink.close(), and can be used to set the sink into a clear state so it can be re-used.
      Since:
      1.1.2
    • setDocumentLocator

      public void setDocumentLocator(org.apache.maven.doxia.sink.Locator locator)
      Specified by:
      setDocumentLocator in interface org.apache.maven.doxia.sink.Sink
    • getDocumentLocator

      public org.apache.maven.doxia.sink.Locator getDocumentLocator()
      Specified by:
      getDocumentLocator in interface org.apache.maven.doxia.sink.Sink
    • getLocationLogPrefix

      protected String getLocationLogPrefix()
    • formatLocation

      public static String formatLocation(org.apache.maven.doxia.sink.Locator locator)
      Creates a string with line/column information. Inspired by o.a.m.model.building.ModelProblemUtils.formatLocation(...).
      Parameters:
      locator - The locator must not be null.
      Returns:
      The formatted location or an empty string if unknown, never null.