Class ConfluenceParser
- java.lang.Object
-
- org.apache.maven.doxia.parser.AbstractParser
-
- org.apache.maven.doxia.parser.AbstractTextParser
-
- org.apache.maven.doxia.module.confluence.ConfluenceParser
-
- All Implemented Interfaces:
LogEnabled,Markup,TextMarkup,Parser
@Component(role=Parser.class, hint="confluence") public class ConfluenceParser extends AbstractTextParser
Parse the Confluence. See Confluence Notation Guide Overview- Since:
- 1.0
-
-
Field Summary
Fields Modifier and Type Field Description private BlockParser[]parsers-
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.parser.Parser
ROLE, TXT_TYPE, UNKNOWN_TYPE, XML_TYPE
-
Fields inherited from interface org.apache.maven.doxia.markup.TextMarkup
PIPE
-
-
Constructor Summary
Constructors Constructor Description ConfluenceParser()Constructor for ConfluenceParser.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected voidinit()Initialize the parser.voidparse(java.io.Reader source, Sink sink)Parses the given source model and emits Doxia events into the given sink.voidparse(java.io.Reader source, Sink sink, java.lang.String reference)Parses the given source model and emits Doxia events into the given sink.private java.util.List<Block>parse(ByLineSource source)-
Methods inherited from class org.apache.maven.doxia.parser.AbstractTextParser
getType
-
Methods inherited from class org.apache.maven.doxia.parser.AbstractParser
doxiaVersion, enableLogging, executeMacro, getBasedir, getLog, getMacroManager, isEmitComments, isSecondParsing, parse, setEmitComments, setSecondParsing
-
-
-
-
Field Detail
-
parsers
private BlockParser[] parsers
-
-
Method Detail
-
parse
private java.util.List<Block> parse(ByLineSource source) throws ParseException
- Throws:
ParseException
-
parse
public void parse(java.io.Reader source, Sink sink) throws ParseExceptionParses the given source model and emits Doxia events into the given sink.- Parameters:
source- not null reader that provides the source document. You could usenewReadermethods fromReaderFactory.sink- A sink that consumes the Doxia events.- Throws:
ParseException- if the model could not be parsed.
-
parse
public void parse(java.io.Reader source, Sink sink, java.lang.String reference) throws ParseExceptionParses the given source model and emits Doxia events into the given sink.- Specified by:
parsein interfaceParser- Overrides:
parsein classAbstractParser- Parameters:
source- not null reader that provides the source document. You could usenewReadermethods fromReaderFactory.sink- A sink that consumes the Doxia events.reference- the reference- Throws:
ParseException- if the model could not be parsed.
-
init
protected void init()
Initialize the parser. This is called first byParser.parse(java.io.Reader, org.apache.maven.doxia.sink.Sink)and can be used to set the parser into a clear state so it can be re-used.- Overrides:
initin classAbstractParser
-
-