org.apache.maven.doxia.parser

Interface Parser

public interface Parser

A Parser is responsible for parsing any document in a supported front-end format, and emitting the standard Doxia events, which can then be consumed by any Doxia Sink.

Since: 1.0

Version: $Id: Parser.java 564180 2007-08-09 12:15:44Z vsiveton $

Author: Jason van Zyl

Field Summary
intJUSTIFY_CENTER
Used for table cells: justify center.
intJUSTIFY_LEFT
Used for table cells: justify left.
intJUSTIFY_RIGHT
Used for table cells: justify right.
StringROLE
The Plexus lookup role.
intTXT_TYPE
Text parser type
intUNKNOWN_TYPE
Unknown parser type
intXML_TYPE
XML parser type
Method Summary
intgetType()
The parser type value could be UNKNOWN_TYPE, TXT_TYPE or XML_TYPE.
voidparse(Reader source, Sink sink)
Parses the given source model and emits Doxia events into the given sink.

Field Detail

JUSTIFY_CENTER

public int JUSTIFY_CENTER
Used for table cells: justify center.

JUSTIFY_LEFT

public int JUSTIFY_LEFT
Used for table cells: justify left.

JUSTIFY_RIGHT

public int JUSTIFY_RIGHT
Used for table cells: justify right.

ROLE

public String ROLE
The Plexus lookup role.

TXT_TYPE

public int TXT_TYPE
Text parser type

UNKNOWN_TYPE

public int UNKNOWN_TYPE
Unknown parser type

XML_TYPE

public int XML_TYPE
XML parser type

Method Detail

getType

public int getType()
The parser type value could be UNKNOWN_TYPE, TXT_TYPE or XML_TYPE.

Returns: the type of Parser

parse

public void parse(Reader source, Sink sink)
Parses the given source model and emits Doxia events into the given sink.

Parameters: source A reader that provides the source document. sink A sink that consumes the Doxia events.

Throws: ParseException if the model could not be parsed.

Copyright © 2002-2011 Apache Software Foundation. All Rights Reserved.