org.xerial.util.xml.pullparser
Class ProgressiveSAXParser

java.lang.Object
  extended by org.xerial.util.xml.pullparser.ProgressiveSAXParser

public class ProgressiveSAXParser
extends Object

SAXParsingの進み具合を自分でコントロールするためのクラス

 XMLInputSource xmlSource = new XMLInputSource("booklist.xml");
 ProgressiveSAXParser parser = new ProgressiveSAXParser(handler, xmlSource);
 
 int state;
 while((state = parser.parseStep()) != XmlPullParser.END_DOCUMENT)
 {}
 
 

Author:
leo

Constructor Summary
ProgressiveSAXParser(List<SAXEventHandler> handlerList, XMLInputSource inputSource)
           
ProgressiveSAXParser(SAXEventHandler handler, XMLInputSource inputSource)
           
 
Method Summary
 int parseStep()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ProgressiveSAXParser

public ProgressiveSAXParser(SAXEventHandler handler,
                            XMLInputSource inputSource)
                     throws XMLException
Throws:
XMLParserException
XMLException

ProgressiveSAXParser

public ProgressiveSAXParser(List<SAXEventHandler> handlerList,
                            XMLInputSource inputSource)
                     throws XMLException
Throws:
XMLException
Method Detail

parseStep

public int parseStep()
              throws Exception,
                     IOException
Throws:
Exception
IOException


Creative Commons License
This work is licensed under a Creative Commons Attribution-ShareAlike 2.1 Japan License.