com.bea.xml.stream
Class EventScanner

java.lang.Object
  extended bycom.bea.xml.stream.EventScanner

public class EventScanner
extends Object

This class replays events from a simple non-xml file format


Field Summary
protected  char currentChar
           
protected  int currentLine
           
protected  Reader reader
           
 
Constructor Summary
EventScanner()
           
EventScanner(Reader reader)
           
 
Method Summary
 boolean endDocumentIsPresent()
           
protected  char getChar()
           
 String getName(String name)
           
 String getPrefix(String name)
           
 boolean hasNext()
           
static void main(String[] args)
           
protected  char read()
           
protected  char read(char c)
           
protected  void read(String s)
           
 Attribute readAttribute()
           
 List readAttributes()
           
 EventState readCDATA()
           
 EventState readCharacterData()
           
 EventState readComment()
           
 EventState readDTD()
           
 EventState readElement()
           
 EventState readEndDocument()
           
 EventState readEndElement()
           
 EventState readEntityReference()
           
 QName readName()
           
 QName readName(char delim)
           
 EventState readProcessingInstruction()
           
 EventState readSpace()
           
 EventState readStartDocument()
           
 EventState readStartElement()
           
protected  String readString(char delim)
           
protected  int readType()
           
 void setReader(Reader reader)
           
protected  void skipSpace()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

reader

protected Reader reader

currentChar

protected char currentChar

currentLine

protected int currentLine
Constructor Detail

EventScanner

public EventScanner()

EventScanner

public EventScanner(Reader reader)
             throws IOException
Method Detail

setReader

public void setReader(Reader reader)
               throws IOException
Throws:
IOException

readString

protected String readString(char delim)
                     throws IOException,
                            XMLStreamException
Throws:
IOException
XMLStreamException

getChar

protected char getChar()

skipSpace

protected void skipSpace()
                  throws IOException
Throws:
IOException

read

protected char read()
             throws IOException
Throws:
IOException

read

protected char read(char c)
             throws XMLStreamException,
                    IOException
Throws:
XMLStreamException
IOException

read

protected void read(String s)
             throws XMLStreamException,
                    IOException
Throws:
XMLStreamException
IOException

readType

protected int readType()
                throws XMLStreamException,
                       IOException
Throws:
XMLStreamException
IOException

readStartElement

public EventState readStartElement()
                            throws XMLStreamException,
                                   IOException
Throws:
XMLStreamException
IOException

readEndElement

public EventState readEndElement()
                          throws XMLStreamException,
                                 IOException
Throws:
XMLStreamException
IOException

readProcessingInstruction

public EventState readProcessingInstruction()
                                     throws XMLStreamException,
                                            IOException
Throws:
XMLStreamException
IOException

readCharacterData

public EventState readCharacterData()
                             throws XMLStreamException,
                                    IOException
Throws:
XMLStreamException
IOException

readCDATA

public EventState readCDATA()
                     throws XMLStreamException,
                            IOException
Throws:
XMLStreamException
IOException

readStartDocument

public EventState readStartDocument()
                             throws XMLStreamException,
                                    IOException
Throws:
XMLStreamException
IOException

readDTD

public EventState readDTD()
                   throws XMLStreamException,
                          IOException
Throws:
XMLStreamException
IOException

readEndDocument

public EventState readEndDocument()
                           throws XMLStreamException
Throws:
XMLStreamException

readComment

public EventState readComment()
                       throws XMLStreamException,
                              IOException
Throws:
XMLStreamException
IOException

getPrefix

public String getPrefix(String name)

getName

public String getName(String name)

readName

public QName readName()
               throws XMLStreamException,
                      IOException
Throws:
XMLStreamException
IOException

readName

public QName readName(char delim)
               throws XMLStreamException,
                      IOException
Throws:
XMLStreamException
IOException

readAttributes

public List readAttributes()
                    throws XMLStreamException,
                           IOException
Throws:
XMLStreamException
IOException

readAttribute

public Attribute readAttribute()
                        throws XMLStreamException,
                               IOException
Throws:
XMLStreamException
IOException

readEntityReference

public EventState readEntityReference()
                               throws XMLStreamException,
                                      IOException
Throws:
XMLStreamException
IOException

readSpace

public EventState readSpace()
                     throws XMLStreamException,
                            IOException
Throws:
XMLStreamException
IOException

readElement

public EventState readElement()
                       throws XMLStreamException,
                              IOException
Throws:
XMLStreamException
IOException

endDocumentIsPresent

public boolean endDocumentIsPresent()

hasNext

public boolean hasNext()
                throws IOException
Throws:
IOException

main

public static void main(String[] args)
                 throws Exception
Throws:
Exception


Copyright © 2004 . All Rights Reserved.