Package org.apache.maven.doxia.index
Class IndexingSink
- java.lang.Object
-
- org.apache.maven.doxia.sink.impl.AbstractSink
-
- org.apache.maven.doxia.sink.impl.SinkAdapter
-
- org.apache.maven.doxia.index.IndexingSink
-
- All Implemented Interfaces:
org.apache.maven.doxia.logging.LogEnabled
,Markup
,org.apache.maven.doxia.sink.Sink
public class IndexingSink extends SinkAdapter
A sink implementation for index.- Author:
- Trygve Laugstøl, Vincent Siveton
-
-
Field Summary
-
Fields inherited from interface org.apache.maven.doxia.markup.Markup
COLON, EOL, EQUAL, GREATER_THAN, LEFT_CURLY_BRACKET, LEFT_SQUARE_BRACKET, LESS_THAN, MINUS, PLUS, QUOTE, RIGHT_CURLY_BRACKET, RIGHT_SQUARE_BRACKET, SEMICOLON, SLASH, SPACE, STAR
-
Fields inherited from interface org.apache.maven.doxia.sink.Sink
JUSTIFY_CENTER, JUSTIFY_LEFT, JUSTIFY_RIGHT, NUMBERING_DECIMAL, NUMBERING_LOWER_ALPHA, NUMBERING_LOWER_ROMAN, NUMBERING_UPPER_ALPHA, NUMBERING_UPPER_ROMAN, ROLE, SECTION_LEVEL_1, SECTION_LEVEL_2, SECTION_LEVEL_3, SECTION_LEVEL_4, SECTION_LEVEL_5, SECTION_LEVEL_6
-
-
Constructor Summary
Constructors Constructor Description IndexingSink(IndexEntry sectionEntry)
Default constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
close()
java.lang.String
getTitle()
Getter for the fieldtitle
.protected void
init()
This is called inSink.head()
or inSink.close()
, and can be used to set the sink into a clear state so it can be re-used.IndexEntry
peek()
peek.void
pop()
Removes the IndexEntry at the top of this stack.void
push(IndexEntry entry)
Pushes an IndexEntry onto the top of this stack.void
pushNewEntry()
Creates and pushes a new IndexEntry onto the top of this stack.void
section1()
void
section1_()
void
section2()
void
section2_()
void
section3()
void
section3_()
void
section4()
void
section4_()
void
section5()
void
section5_()
void
sectionTitle1()
void
sectionTitle1_()
sectionTitle1_.void
sectionTitle2()
void
sectionTitle2_()
sectionTitle2_.void
sectionTitle3()
void
sectionTitle3_()
sectionTitle3_.void
sectionTitle4()
void
sectionTitle4_()
sectionTitle4_.void
sectionTitle5()
void
sectionTitle5_()
sectionTitle5_.void
text(java.lang.String text)
void
title()
void
title_()
-
Methods inherited from class org.apache.maven.doxia.sink.impl.SinkAdapter
address, address, address_, anchor, anchor, anchor_, article, article, article_, author, author, author_, blockquote, blockquote, blockquote_, body, body, body_, bold, bold_, comment, content, content, content_, data, data, data_, date, date, date_, definedTerm, definedTerm, definedTerm_, definition, definition, definition_, definitionList, definitionList, definitionList_, definitionListItem, definitionListItem, definitionListItem_, division, division, division_, figure, figure, figure_, figureCaption, figureCaption, figureCaption_, figureGraphics, figureGraphics, flush, footer, footer, footer_, head, head, head_, header, header, header_, horizontalRule, horizontalRule, inline, inline, inline_, italic, italic_, lineBreak, lineBreak, lineBreakOpportunity, lineBreakOpportunity, link, link, link_, list, list, list_, listItem, listItem, listItem_, monospaced, monospaced_, navigation, navigation, navigation_, nonBreakingSpace, numberedList, numberedList, numberedList_, numberedListItem, numberedListItem, numberedListItem_, pageBreak, paragraph, paragraph, paragraph_, rawText, section, section_, section6, section6_, sectionTitle, sectionTitle, sectionTitle_, sectionTitle_, sectionTitle6, sectionTitle6_, sidebar, sidebar, sidebar_, table, table, table_, tableCaption, tableCaption, tableCaption_, tableCell, tableCell, tableCell, tableCell_, tableHeaderCell, tableHeaderCell, tableHeaderCell, tableHeaderCell_, tableRow, tableRow, tableRow_, tableRows, tableRows_, text, time, time, time_, title, unknown, verbatim, verbatim, verbatim_
-
Methods inherited from class org.apache.maven.doxia.sink.impl.AbstractSink
enableLogging, getLog, unifyEOLs
-
-
-
-
Constructor Detail
-
IndexingSink
public IndexingSink(IndexEntry sectionEntry)
Default constructor.- Parameters:
sectionEntry
- The first index entry.
-
-
Method Detail
-
getTitle
public java.lang.String getTitle()
Getter for the field
title
.- Returns:
- the title
-
title
public void title()
- Specified by:
title
in interfaceorg.apache.maven.doxia.sink.Sink
- Overrides:
title
in classSinkAdapter
-
section1
public void section1()
- Specified by:
section1
in interfaceorg.apache.maven.doxia.sink.Sink
- Overrides:
section1
in classSinkAdapter
-
sectionTitle1
public void sectionTitle1()
- Specified by:
sectionTitle1
in interfaceorg.apache.maven.doxia.sink.Sink
- Overrides:
sectionTitle1
in classSinkAdapter
-
title_
public void title_()
- Specified by:
title_
in interfaceorg.apache.maven.doxia.sink.Sink
- Overrides:
title_
in classSinkAdapter
-
sectionTitle1_
public void sectionTitle1_()
sectionTitle1_.
- Specified by:
sectionTitle1_
in interfaceorg.apache.maven.doxia.sink.Sink
- Overrides:
sectionTitle1_
in classSinkAdapter
-
section1_
public void section1_()
- Specified by:
section1_
in interfaceorg.apache.maven.doxia.sink.Sink
- Overrides:
section1_
in classSinkAdapter
-
section2
public void section2()
- Specified by:
section2
in interfaceorg.apache.maven.doxia.sink.Sink
- Overrides:
section2
in classSinkAdapter
-
sectionTitle2
public void sectionTitle2()
- Specified by:
sectionTitle2
in interfaceorg.apache.maven.doxia.sink.Sink
- Overrides:
sectionTitle2
in classSinkAdapter
-
sectionTitle2_
public void sectionTitle2_()
sectionTitle2_.
- Specified by:
sectionTitle2_
in interfaceorg.apache.maven.doxia.sink.Sink
- Overrides:
sectionTitle2_
in classSinkAdapter
-
section2_
public void section2_()
- Specified by:
section2_
in interfaceorg.apache.maven.doxia.sink.Sink
- Overrides:
section2_
in classSinkAdapter
-
section3
public void section3()
- Specified by:
section3
in interfaceorg.apache.maven.doxia.sink.Sink
- Overrides:
section3
in classSinkAdapter
-
sectionTitle3
public void sectionTitle3()
- Specified by:
sectionTitle3
in interfaceorg.apache.maven.doxia.sink.Sink
- Overrides:
sectionTitle3
in classSinkAdapter
-
sectionTitle3_
public void sectionTitle3_()
sectionTitle3_.
- Specified by:
sectionTitle3_
in interfaceorg.apache.maven.doxia.sink.Sink
- Overrides:
sectionTitle3_
in classSinkAdapter
-
section3_
public void section3_()
- Specified by:
section3_
in interfaceorg.apache.maven.doxia.sink.Sink
- Overrides:
section3_
in classSinkAdapter
-
section4
public void section4()
- Specified by:
section4
in interfaceorg.apache.maven.doxia.sink.Sink
- Overrides:
section4
in classSinkAdapter
-
sectionTitle4
public void sectionTitle4()
- Specified by:
sectionTitle4
in interfaceorg.apache.maven.doxia.sink.Sink
- Overrides:
sectionTitle4
in classSinkAdapter
-
sectionTitle4_
public void sectionTitle4_()
sectionTitle4_.
- Specified by:
sectionTitle4_
in interfaceorg.apache.maven.doxia.sink.Sink
- Overrides:
sectionTitle4_
in classSinkAdapter
-
section4_
public void section4_()
- Specified by:
section4_
in interfaceorg.apache.maven.doxia.sink.Sink
- Overrides:
section4_
in classSinkAdapter
-
section5
public void section5()
- Specified by:
section5
in interfaceorg.apache.maven.doxia.sink.Sink
- Overrides:
section5
in classSinkAdapter
-
sectionTitle5
public void sectionTitle5()
- Specified by:
sectionTitle5
in interfaceorg.apache.maven.doxia.sink.Sink
- Overrides:
sectionTitle5
in classSinkAdapter
-
sectionTitle5_
public void sectionTitle5_()
sectionTitle5_.
- Specified by:
sectionTitle5_
in interfaceorg.apache.maven.doxia.sink.Sink
- Overrides:
sectionTitle5_
in classSinkAdapter
-
section5_
public void section5_()
- Specified by:
section5_
in interfaceorg.apache.maven.doxia.sink.Sink
- Overrides:
section5_
in classSinkAdapter
-
text
public void text(java.lang.String text)
- Specified by:
text
in interfaceorg.apache.maven.doxia.sink.Sink
- Overrides:
text
in classSinkAdapter
-
pushNewEntry
public void pushNewEntry()
Creates and pushes a new IndexEntry onto the top of this stack.
-
push
public void push(IndexEntry entry)
Pushes an IndexEntry onto the top of this stack.- Parameters:
entry
- to put.
-
pop
public void pop()
Removes the IndexEntry at the top of this stack.
-
peek
public IndexEntry peek()
peek.
- Returns:
- Looks at the IndexEntry at the top of this stack.
-
close
public void close()
- Specified by:
close
in interfaceorg.apache.maven.doxia.sink.Sink
- Overrides:
close
in classSinkAdapter
-
init
protected void init()
This is called inSink.head()
or inSink.close()
, and can be used to set the sink into a clear state so it can be re-used.- Overrides:
init
in classAbstractSink
-
-