All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class vnet.yawb.YAWBParser

java.lang.Object
   |
   +----vnet.yawb.YAWBParser

public class YAWBParser
extends Object
implements DocumentHandler
Parses a YAWB XML document. Not thread safe. Use an instance per thread.


Variable Index

 o base
 o elements
 o ROOT

Constructor Index

 o YAWBParser()

Method Index

 o characters(char[], int, int)
 o endDocument()
 o endElement(String)
 o ignorableWhitespace(char[], int, int)
 o main(String[])
Simple test.
 o parse(InputSource)
 o parse(InputStream)
Parses data from the given InputStream and returns a vnet.markup.Document.
 o parse(Reader)
Parses data from the given Reader and returns a vnet.markup.Document.
 o processingInstruction(String, String)
 o setDocumentLocator(Locator)
 o startDocument()
 o startElement(String, AttributeList)

Variables

 o base
 protected Document base
 o elements
 protected Stack elements
 o ROOT
 public static final String ROOT

Constructors

 o YAWBParser
 public YAWBParser()

Methods

 o parse
 public Document parse(Reader reader) throws IOException, YAWBException
Parses data from the given Reader and returns a vnet.markup.Document. The stream must contain well-formed XML, and valid according to the current YAWB DTD.

Parameters:
reader - source Reader
Returns:
Returns the base Document
Throws: IOException
if an IO error occurs
Throws: YAWBException
if the XML document contained errors (validity or well-formedness)
 o parse
 public Document parse(InputStream input) throws IOException, YAWBException
Parses data from the given InputStream and returns a vnet.markup.Document. The stream must contain well-formed XML, and valid according to the current YAWB DTD.

Parameters:
input - source InputStream
Returns:
Returns the base Document.
Throws: IOException
if an IO error occurs
Throws: YAWBException
if the XML document contained errors (validity or well-formedness)
 o parse
 protected Document parse(InputSource source) throws IOException, YAWBException
 o characters
 public void characters(char arg1[],
                        int arg2,
                        int arg3) throws SAXException
 o endDocument
 public void endDocument() throws SAXException
 o endElement
 public void endElement(String arg1) throws SAXException
 o ignorableWhitespace
 public void ignorableWhitespace(char arg1[],
                                 int arg2,
                                 int arg3) throws SAXException
 o processingInstruction
 public void processingInstruction(String arg1,
                                   String arg2) throws SAXException
 o setDocumentLocator
 public void setDocumentLocator(Locator arg1)
 o startDocument
 public void startDocument() throws SAXException
 o startElement
 public void startElement(String arg1,
                          AttributeList arg2) throws SAXException
 o main
 public static void main(String args[])
Simple test. Looks for the file file etc/test.xml and parses it. Outputs to System.out.


All Packages  Class Hierarchy  This Package  Previous  Next  Index