org.apache.avalon.excalibur.xml
Interface Parser

All Superinterfaces:
org.apache.avalon.framework.component.Component
All Known Implementing Classes:
JaxpParser, XercesParser

public interface Parser
extends org.apache.avalon.framework.component.Component

The parser can be used to parse any XML document given by a InputSource object. It can either send XML events or create a DOM from the parsed document.

Version:
CVS $Revision: 1.5 $ $Date: 2001/12/11 09:53:38 $
Author:
Carsten Ziegeler

Field Summary
static java.lang.String ROLE
           
 
Method Summary
 void parse(org.xml.sax.InputSource in, org.xml.sax.ContentHandler consumer)
          Parse the InputSource and send SAX events to the consumer.
 org.w3c.dom.Document parseDocument(org.xml.sax.InputSource in)
          Parse the InputSource and create a DOM out of it.
 

Field Detail

ROLE

public static final java.lang.String ROLE
Method Detail

parse

public void parse(org.xml.sax.InputSource in,
                  org.xml.sax.ContentHandler consumer)
           throws org.xml.sax.SAXException,
                  java.io.IOException
Parse the InputSource and send SAX events to the consumer. Attention: the consumer can either be an XMLConsumer or implement the LexicalHandler as well. The parse should take care of this.

parseDocument

public org.w3c.dom.Document parseDocument(org.xml.sax.InputSource in)
                                   throws org.xml.sax.SAXException,
                                          java.io.IOException
Parse the InputSource and create a DOM out of it.


Copyright © 2001 Apache Jakarta Project. All Rights Reserved.