org.enhydra.apache.xerces.readers
Class CharReader

java.lang.Object
  |
  +--org.enhydra.apache.xerces.readers.XMLEntityReader
        |
        +--org.enhydra.apache.xerces.readers.AbstractCharReader
              |
              +--org.enhydra.apache.xerces.readers.CharReader
All Implemented Interfaces:
XMLEntityHandler.EntityReader

final class CharReader
extends AbstractCharReader

General purpose character stream reader. This class is used when the input source for the document entity is specified using a character stream, when the input source is specified using a byte stream with an explicit encoding, or when a recognizer scans the encoding decl from the byte stream and chooses to use this reader class for that encoding. For the latter two cases, the byte stream is wrapped in the appropriate InputStreamReader using the desired encoding.

Version:
 

Fields inherited from class org.enhydra.apache.xerces.readers.AbstractCharReader
fCurrentChunk, fCurrentIndex, fLength, fMostRecentChar, fMostRecentData
 
Fields inherited from class org.enhydra.apache.xerces.readers.XMLEntityReader
fCarriageReturnCounter, fCharacterCounter, fCharDataHandler, fCurrentOffset, fEntityHandler, fErrorReporter, fInCDSect, fLinefeedCounter, fSendCharDataAsCharArray
 
Constructor Summary
(package private) CharReader(XMLEntityHandler entityHandler, XMLErrorReporter errorReporter, boolean sendCharDataAsCharArray, Reader reader, StringPool stringPool)
           
 
Method Summary
protected  int fillCurrentChunk()
          Fill the current chunk the next buffer worth of data.
 
Methods inherited from class org.enhydra.apache.xerces.readers.AbstractCharReader
addString, addSymbol, append, changeReaders, deferException, lookingAtChar, lookingAtSpace, lookingAtValidChar, scanAttValue, scanCharRef, scanContent, scanEntityValue, scanExpectedName, scanInvalidChar, scanName, scanQName, scanStringLiteral, skipPastName, skipPastNmtoken, skipPastSpaces, skippedString, skipToChar
 
Methods inherited from class org.enhydra.apache.xerces.readers.XMLEntityReader
currentOffset, getColumnNumber, getInCDSect, getLineNumber, init, setInCDSect
 
Methods inherited from class java.lang.Object
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CharReader

CharReader(XMLEntityHandler entityHandler,
           XMLErrorReporter errorReporter,
           boolean sendCharDataAsCharArray,
           Reader reader,
           StringPool stringPool)
     throws Exception
Method Detail

fillCurrentChunk

protected int fillCurrentChunk()
                        throws Exception
Description copied from class: AbstractCharReader
Fill the current chunk the next buffer worth of data. This method should replace any 0xD,0xA sequence with a single 0xA character, and replace single 0xD characters with a 0xA character. This is described in the spec under section 2.11, "End-of-Line Handling".
Overrides:
fillCurrentChunk in class AbstractCharReader
Following copied from class: org.enhydra.apache.xerces.readers.AbstractCharReader
Returns:
The value of the first character available for processing.
Throws:
Exception -  


Copyright © 1999 The Apache Software Foundation. All Rights reserved.