Class Decoder
- java.lang.Object
-
- com.sun.xml.fastinfoset.Decoder
-
- All Implemented Interfaces:
FastInfosetParser
- Direct Known Subclasses:
DOMDocumentParser,SAXDocumentParser,StAXDocumentParser
public abstract class Decoder extends java.lang.Object implements FastInfosetParser
Abstract decoder for developing concrete encoders. Concrete implementations extending Decoder will utilize methods on Decoder to decode XML infoset according to the Fast Infoset standard. It is the responsibility of the concrete implementation to ensure that methods are invoked in the correct order to correctly decode a valid fast infoset document.This class extends org.sax.xml.DefaultHandler so that concrete SAX implementations can be used with javax.xml.parsers.SAXParser and the parse methods that take org.sax.xml.DefaultHandler as a parameter.
Buffering of octets that are read from an
InputStreamis supported in a similar manner to aBufferedInputStream. Combining buffering with decoding enables better performance.More than one fast infoset document may be decoded from the
InputStream.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description protected classDecoder.EncodingAlgorithmInputStream
-
Field Summary
Fields Modifier and Type Field Description protected boolean_addToTableTrue if an entry is required to be added to a tableprotected QualifiedNameArray_attributeNameTableThe attribute name table of the vocabulary.protected StringArray_attributeValueTableThe attribute value table of the vocabulary.protected int_bThe current octet that is being readprivate int_bitsLeftInOctetprotected int_bufferSizeThe size of the internal buffer.private static int_bufferSizeSystemDefaultprotected ContiguousCharArrayArray_characterContentChunkTableThe character content chunk table of the vocabulary.protected char[]_charBufferThe internal buffer of characters.protected int_charBufferLengthThe length of characters in the buffer of characters.protected boolean_doubleTerminateTrue if two information item are terminated in direct sequence.protected DuplicateAttributeVerifier_duplicateAttributeVerifierHelper class that checks for duplicate attribute information items.protected QualifiedNameArray_elementNameTableThe element name table of the vocabulary.private java.util.Map_externalVocabulariesThe map of URIs to referenced vocabularies.protected int_identifierThe vocabulary table index of identifying string or the identifier of an encoding algorithm or restricted alphabet.protected int_integerThe vocabulary table index to an indexed non identifying string.protected int_namespaceNameIndexprotected boolean_needForceStreamCloseTrue if needs to close underlying input stream.protected java.util.List_notationsThe list of Notation Information Items that are part of the Document Information Item.protected byte[]_octetBufferThe internal buffer used for decoding.protected int_octetBufferEndThe end of the buffer.protected int_octetBufferLengthThe length of some octets in the buffer that are to be read.protected int_octetBufferOffsetThe offset into the buffer to read the next byte.protected int_octetBufferStartA mark into the internal buffer used for decoding encoded algorithm or restricted alphabet data.protected boolean_parseFragmentsTrue if can parse fragments.protected int_prefixIndexprotected PrefixArray_prefixTableThe prefix table of the vocabulary.protected java.util.Map_registeredEncodingAlgorithmsThe map of URIs to registered encoding algorithms.private java.io.InputStream_sThe input stream from which the fast infoset document is being read.private boolean_stringInterningTrue if string interning is performed by the decoder.private static boolean_stringInterningSystemDefaultprotected boolean_terminateTrue if an information item is terminated.protected java.util.List_unparsedEntitiesThe list of Unparsed Entity Information Items that are part of the Document Information Item.private char_utf8_highSurrogateprivate char_utf8_lowSurrogateprotected ParserVocabulary_vThe vocabulary used for decoding.private boolean_vIsInternalTrue if the vocabulary is internally created by decoder.static java.lang.StringBUFFER_SIZE_SYSTEM_PROPERTYInternal buffer size interning system property.protected static intNISTRING_EMPTY_STRINGprotected static intNISTRING_ENCODING_ALGORITHMprotected static intNISTRING_INDEXprotected static intNISTRING_STRINGstatic java.lang.StringSTRING_INTERNING_SYSTEM_PROPERTYString interning system property.private static char[]XML_NAMESPACE_NAME_CHARSprivate static char[]XMLNS_NAMESPACE_NAME_CHARSprivate static char[]XMLNS_NAMESPACE_PREFIX_CHARS-
Fields inherited from interface org.jvnet.fastinfoset.FastInfosetParser
BUFFER_SIZE_PROPERTY, EXTERNAL_VOCABULARIES_PROPERTY, FORCE_STREAM_CLOSE_PROPERTY, REGISTERED_ENCODING_ALGORITHMS_PROPERTY, STRING_INTERNING_PROPERTY
-
-
Constructor Summary
Constructors Modifier Constructor Description protectedDecoder()Default constructor for the Decoder.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description protected boolean_isFastInfosetDocument()private booleanarrayEquals(byte[] b1, int offset, byte[] b2, int length)protected voidcloseIfRequired()private booleancompareCharsWithCharBufferFromEndToStart(char[] c)protected java.lang.StringcreateQualifiedNameString(char[] first, java.lang.String second)protected java.lang.StringcreateQualifiedNameString(java.lang.String second)protected voiddecodeAdditionalData()protected voiddecodeAlphabetOctetsAsCharBuffer(char[] restrictedAlphabet)protected java.lang.StringdecodeCharacterEncodingScheme()protected voiddecodeDII()protected QualifiedNamedecodeEIIIndexLarge()protected QualifiedNamedecodeEIIIndexMedium()private voiddecodeExternalVocabularyURI()protected voiddecodeFourBitAlphabetOctetsAsCharBuffer(char[] restrictedAlphabet)protected voiddecodeHeader()protected java.lang.StringdecodeIdentifyingNonEmptyStringIndexOnFirstBitAsNamespaceName(boolean prefixPresent)protected java.lang.StringdecodeIdentifyingNonEmptyStringIndexOnFirstBitAsPrefix(boolean namespaceNamePresent)protected java.lang.StringdecodeIdentifyingNonEmptyStringOnFirstBit(StringArray table)protected java.lang.StringdecodeIdentifyingNonEmptyStringOnFirstBitAsNamespaceName(boolean prefixPresent)protected java.lang.StringdecodeIdentifyingNonEmptyStringOnFirstBitAsPrefix(boolean namespaceNamePresent)protected voiddecodeInitialVocabulary()protected intdecodeIntegerIndexOnSecondBit()protected QualifiedNamedecodeLiteralQualifiedName(int state, QualifiedName q)protected voiddecodeNonEmptyOctetStringLengthOnSecondBit()protected voiddecodeNonEmptyOctetStringOnSecondBitAsUtf8CharArray()protected java.lang.StringdecodeNonEmptyOctetStringOnSecondBitAsUtf8String()protected intdecodeNonIdentifyingStringOnFirstBit()protected voiddecodeNotations()private intdecodeNumberOfItemsOfSequence()protected voiddecodeOctetsOnFifthBitOfNonIdentifyingStringOnFirstBit(int b)protected voiddecodeOctetsOnSeventhBitOfNonIdentifyingStringOnThirdBit(int b)protected java.lang.StringdecodeRAOctetsAsString(char[] restrictedAlphabet)protected voiddecodeRestrictedAlphabetAsCharBuffer()protected java.lang.StringdecodeRestrictedAlphabetAsString()private voiddecodeTableItems(CharArrayArray array)private voiddecodeTableItems(ContiguousCharArrayArray array)private voiddecodeTableItems(PrefixArray array)private voiddecodeTableItems(QualifiedNameArray array, boolean isAttribute)private voiddecodeTableItems(StringArray array)private voiddecodeTwoToFourByteUtf8Character(char[] ch, int b1, int end)private voiddecodeTwoToFourByteUtf8Character(int b1, int end)protected voiddecodeUnparsedEntities()protected voiddecodeUtf16StringAsCharBuffer()protected java.lang.StringdecodeUtf16StringAsString()private voiddecodeUtf16StringIntoCharBuffer()private intdecodeUtf8FourByteChar(int end, int b1)private voiddecodeUtf8NCNameIllegalState()protected voiddecodeUtf8NCNameIntoCharBuffer()private voiddecodeUtf8NCNameStartTwoToFourByteCharacters(int b1, int end)private voiddecodeUtf8NCNameTwoToFourByteCharacters(int b1, int end)protected voiddecodeUtf8StringAsCharBuffer()protected voiddecodeUtf8StringAsCharBuffer(char[] ch, int offset)protected java.lang.StringdecodeUtf8StringAsString()private voiddecodeUtf8StringIllegalState()protected voiddecodeUtf8StringIntoCharBuffer()protected voiddecodeUtf8StringIntoCharBuffer(char[] ch, int offset)private voiddecodeUtf8StringLengthTooSmall()private chardecodeUtf8ThreeByteChar(int end, int b1)protected java.lang.StringdecodeVersion()private voidensureOctetBufferSize()intgetBufferSize()Get the buffer size.java.util.MapgetExternalVocabularies()Get the map of referenced external vocabularies.booleangetForceStreamClose()Return the force stream close property.booleangetParseFragments()Return the parse fragments property.java.util.MapgetRegisteredEncodingAlgorithms()Gets the set of registered encoding algorithms.booleangetStringInterning()Return the string interning property.static booleanisFastInfosetDocument(java.io.InputStream s)protected intpeek()protected intpeek(OctetBufferListener octetBufferListener)protected intpeek2(OctetBufferListener octetBufferListener)protected intread()private intreadBits(int bits)private voidrepeatedRead()voidreset()Reset the decoder for reuse decoding another XML infoset.private voidresetBits()voidsetBufferSize(int bufferSize)Set the buffer size.voidsetExternalVocabularies(java.util.Map referencedVocabualries)Set the map of referenced external vocabularies.voidsetForceStreamClose(boolean needForceStreamClose)Set the force stream close property.voidsetInputStream(java.io.InputStream s)Set the InputStream to decode the fast infoset document.voidsetParseFragments(boolean parseFragments)Set the parse fragments property.voidsetRegisteredEncodingAlgorithms(java.util.Map algorithms)Sets the set of registered encoding algorithms.voidsetStringInterning(boolean stringInterning)Set the string interning property.voidsetVocabulary(ParserVocabulary v)Set the ParserVocabulary to be used for decoding.
-
-
-
Field Detail
-
XML_NAMESPACE_NAME_CHARS
private static final char[] XML_NAMESPACE_NAME_CHARS
-
XMLNS_NAMESPACE_PREFIX_CHARS
private static final char[] XMLNS_NAMESPACE_PREFIX_CHARS
-
XMLNS_NAMESPACE_NAME_CHARS
private static final char[] XMLNS_NAMESPACE_NAME_CHARS
-
STRING_INTERNING_SYSTEM_PROPERTY
public static final java.lang.String STRING_INTERNING_SYSTEM_PROPERTY
String interning system property.- See Also:
- Constant Field Values
-
BUFFER_SIZE_SYSTEM_PROPERTY
public static final java.lang.String BUFFER_SIZE_SYSTEM_PROPERTY
Internal buffer size interning system property.- See Also:
- Constant Field Values
-
_stringInterningSystemDefault
private static boolean _stringInterningSystemDefault
-
_bufferSizeSystemDefault
private static int _bufferSizeSystemDefault
-
_stringInterning
private boolean _stringInterning
True if string interning is performed by the decoder.
-
_s
private java.io.InputStream _s
The input stream from which the fast infoset document is being read.
-
_externalVocabularies
private java.util.Map _externalVocabularies
The map of URIs to referenced vocabularies.
-
_parseFragments
protected boolean _parseFragments
True if can parse fragments.
-
_needForceStreamClose
protected boolean _needForceStreamClose
True if needs to close underlying input stream.
-
_vIsInternal
private boolean _vIsInternal
True if the vocabulary is internally created by decoder.
-
_notations
protected java.util.List _notations
The list of Notation Information Items that are part of the Document Information Item.
-
_unparsedEntities
protected java.util.List _unparsedEntities
The list of Unparsed Entity Information Items that are part of the Document Information Item.
-
_registeredEncodingAlgorithms
protected java.util.Map _registeredEncodingAlgorithms
The map of URIs to registered encoding algorithms.
-
_v
protected ParserVocabulary _v
The vocabulary used for decoding.
-
_prefixTable
protected PrefixArray _prefixTable
The prefix table of the vocabulary.
-
_elementNameTable
protected QualifiedNameArray _elementNameTable
The element name table of the vocabulary.
-
_attributeNameTable
protected QualifiedNameArray _attributeNameTable
The attribute name table of the vocabulary.
-
_characterContentChunkTable
protected ContiguousCharArrayArray _characterContentChunkTable
The character content chunk table of the vocabulary.
-
_attributeValueTable
protected StringArray _attributeValueTable
The attribute value table of the vocabulary.
-
_b
protected int _b
The current octet that is being read
-
_terminate
protected boolean _terminate
True if an information item is terminated.
-
_doubleTerminate
protected boolean _doubleTerminate
True if two information item are terminated in direct sequence.
-
_addToTable
protected boolean _addToTable
True if an entry is required to be added to a table
-
_integer
protected int _integer
The vocabulary table index to an indexed non identifying string.
-
_identifier
protected int _identifier
The vocabulary table index of identifying string or the identifier of an encoding algorithm or restricted alphabet.
-
_bufferSize
protected int _bufferSize
The size of the internal buffer.
-
_octetBuffer
protected byte[] _octetBuffer
The internal buffer used for decoding.
-
_octetBufferStart
protected int _octetBufferStart
A mark into the internal buffer used for decoding encoded algorithm or restricted alphabet data.
-
_octetBufferOffset
protected int _octetBufferOffset
The offset into the buffer to read the next byte.
-
_octetBufferEnd
protected int _octetBufferEnd
The end of the buffer.
-
_octetBufferLength
protected int _octetBufferLength
The length of some octets in the buffer that are to be read.
-
_charBuffer
protected char[] _charBuffer
The internal buffer of characters.
-
_charBufferLength
protected int _charBufferLength
The length of characters in the buffer of characters.
-
_duplicateAttributeVerifier
protected DuplicateAttributeVerifier _duplicateAttributeVerifier
Helper class that checks for duplicate attribute information items.
-
NISTRING_STRING
protected static final int NISTRING_STRING
- See Also:
- Constant Field Values
-
NISTRING_INDEX
protected static final int NISTRING_INDEX
- See Also:
- Constant Field Values
-
NISTRING_ENCODING_ALGORITHM
protected static final int NISTRING_ENCODING_ALGORITHM
- See Also:
- Constant Field Values
-
NISTRING_EMPTY_STRING
protected static final int NISTRING_EMPTY_STRING
- See Also:
- Constant Field Values
-
_prefixIndex
protected int _prefixIndex
-
_namespaceNameIndex
protected int _namespaceNameIndex
-
_bitsLeftInOctet
private int _bitsLeftInOctet
-
_utf8_highSurrogate
private char _utf8_highSurrogate
-
_utf8_lowSurrogate
private char _utf8_lowSurrogate
-
-
Method Detail
-
setStringInterning
public void setStringInterning(boolean stringInterning)
Set the string interning property.If the string interning property is set to true then
Stringobjects instantiated for [namespace name], [prefix] and [local name] infoset properties will be interned using the methodString.intern().- Specified by:
setStringInterningin interfaceFastInfosetParser- Parameters:
stringInterning- The string interning property.
-
getStringInterning
public boolean getStringInterning()
Return the string interning property.- Specified by:
getStringInterningin interfaceFastInfosetParser- Returns:
- The string interning property.
-
setBufferSize
public void setBufferSize(int bufferSize)
Set the buffer size.The size of the buffer for parsing is set using this method. Requests for sizes smaller then the current size will be ignored. Otherwise the buffer will be resized when the next parse is performed.
- Specified by:
setBufferSizein interfaceFastInfosetParser- Parameters:
bufferSize- The requested buffer size.
-
getBufferSize
public int getBufferSize()
Get the buffer size.- Specified by:
getBufferSizein interfaceFastInfosetParser- Returns:
- The buffer size.
-
setRegisteredEncodingAlgorithms
public void setRegisteredEncodingAlgorithms(java.util.Map algorithms)
Sets the set of registered encoding algorithms.- Specified by:
setRegisteredEncodingAlgorithmsin interfaceFastInfosetParser- Parameters:
algorithms- The set of registered algorithms.
-
getRegisteredEncodingAlgorithms
public java.util.Map getRegisteredEncodingAlgorithms()
Gets the set of registered encoding algorithms.- Specified by:
getRegisteredEncodingAlgorithmsin interfaceFastInfosetParser- Returns:
- The set of registered algorithms.
-
setExternalVocabularies
public void setExternalVocabularies(java.util.Map referencedVocabualries)
Set the map of referenced external vocabularies.The map (but not the keys and values) be cloned.
- Specified by:
setExternalVocabulariesin interfaceFastInfosetParser- Parameters:
referencedVocabualries- the map of URI to vocabulary.
-
getExternalVocabularies
public java.util.Map getExternalVocabularies()
Get the map of referenced external vocabularies.- Specified by:
getExternalVocabulariesin interfaceFastInfosetParser- Returns:
- the map of URI to vocabulary.
-
setParseFragments
public void setParseFragments(boolean parseFragments)
Set the parse fragments property.If the parse fragments property is set to true then fragments of an XML infoset may be parsed.
- Specified by:
setParseFragmentsin interfaceFastInfosetParser- Parameters:
parseFragments- The parse fragments property.
-
getParseFragments
public boolean getParseFragments()
Return the parse fragments property.- Specified by:
getParseFragmentsin interfaceFastInfosetParser- Returns:
- The parse fragments property.
-
setForceStreamClose
public void setForceStreamClose(boolean needForceStreamClose)
Set the force stream close property.If the force stream property is set to true then Parser's underlying InputStream will be closed.
- Specified by:
setForceStreamClosein interfaceFastInfosetParser- Parameters:
needForceStreamClose- The force stream close property.
-
getForceStreamClose
public boolean getForceStreamClose()
Return the force stream close property.- Specified by:
getForceStreamClosein interfaceFastInfosetParser- Returns:
- The force stream close property.
-
reset
public void reset()
Reset the decoder for reuse decoding another XML infoset.
-
setVocabulary
public void setVocabulary(ParserVocabulary v)
Set the ParserVocabulary to be used for decoding.- Parameters:
v- the vocabulary to be used for decoding.
-
setInputStream
public void setInputStream(java.io.InputStream s)
Set the InputStream to decode the fast infoset document.- Parameters:
s- the InputStream where the fast infoset document is decoded from.
-
decodeDII
protected final void decodeDII() throws FastInfosetException, java.io.IOException- Throws:
FastInfosetExceptionjava.io.IOException
-
decodeAdditionalData
protected final void decodeAdditionalData() throws FastInfosetException, java.io.IOException- Throws:
FastInfosetExceptionjava.io.IOException
-
decodeInitialVocabulary
protected final void decodeInitialVocabulary() throws FastInfosetException, java.io.IOException- Throws:
FastInfosetExceptionjava.io.IOException
-
decodeExternalVocabularyURI
private void decodeExternalVocabularyURI() throws FastInfosetException, java.io.IOException- Throws:
FastInfosetExceptionjava.io.IOException
-
decodeTableItems
private void decodeTableItems(StringArray array) throws FastInfosetException, java.io.IOException
- Throws:
FastInfosetExceptionjava.io.IOException
-
decodeTableItems
private void decodeTableItems(PrefixArray array) throws FastInfosetException, java.io.IOException
- Throws:
FastInfosetExceptionjava.io.IOException
-
decodeTableItems
private void decodeTableItems(ContiguousCharArrayArray array) throws FastInfosetException, java.io.IOException
- Throws:
FastInfosetExceptionjava.io.IOException
-
decodeTableItems
private void decodeTableItems(CharArrayArray array) throws FastInfosetException, java.io.IOException
- Throws:
FastInfosetExceptionjava.io.IOException
-
decodeTableItems
private void decodeTableItems(QualifiedNameArray array, boolean isAttribute) throws FastInfosetException, java.io.IOException
- Throws:
FastInfosetExceptionjava.io.IOException
-
decodeNumberOfItemsOfSequence
private int decodeNumberOfItemsOfSequence() throws java.io.IOException- Throws:
java.io.IOException
-
decodeNotations
protected final void decodeNotations() throws FastInfosetException, java.io.IOException- Throws:
FastInfosetExceptionjava.io.IOException
-
decodeUnparsedEntities
protected final void decodeUnparsedEntities() throws FastInfosetException, java.io.IOException- Throws:
FastInfosetExceptionjava.io.IOException
-
decodeCharacterEncodingScheme
protected final java.lang.String decodeCharacterEncodingScheme() throws FastInfosetException, java.io.IOException- Throws:
FastInfosetExceptionjava.io.IOException
-
decodeVersion
protected final java.lang.String decodeVersion() throws FastInfosetException, java.io.IOException- Throws:
FastInfosetExceptionjava.io.IOException
-
decodeEIIIndexMedium
protected final QualifiedName decodeEIIIndexMedium() throws FastInfosetException, java.io.IOException
- Throws:
FastInfosetExceptionjava.io.IOException
-
decodeEIIIndexLarge
protected final QualifiedName decodeEIIIndexLarge() throws FastInfosetException, java.io.IOException
- Throws:
FastInfosetExceptionjava.io.IOException
-
decodeLiteralQualifiedName
protected final QualifiedName decodeLiteralQualifiedName(int state, QualifiedName q) throws FastInfosetException, java.io.IOException
- Throws:
FastInfosetExceptionjava.io.IOException
-
decodeNonIdentifyingStringOnFirstBit
protected final int decodeNonIdentifyingStringOnFirstBit() throws FastInfosetException, java.io.IOException- Throws:
FastInfosetExceptionjava.io.IOException
-
decodeOctetsOnFifthBitOfNonIdentifyingStringOnFirstBit
protected final void decodeOctetsOnFifthBitOfNonIdentifyingStringOnFirstBit(int b) throws FastInfosetException, java.io.IOException- Throws:
FastInfosetExceptionjava.io.IOException
-
decodeOctetsOnSeventhBitOfNonIdentifyingStringOnThirdBit
protected final void decodeOctetsOnSeventhBitOfNonIdentifyingStringOnThirdBit(int b) throws FastInfosetException, java.io.IOException- Throws:
FastInfosetExceptionjava.io.IOException
-
decodeIdentifyingNonEmptyStringOnFirstBit
protected final java.lang.String decodeIdentifyingNonEmptyStringOnFirstBit(StringArray table) throws FastInfosetException, java.io.IOException
- Throws:
FastInfosetExceptionjava.io.IOException
-
decodeIdentifyingNonEmptyStringOnFirstBitAsPrefix
protected final java.lang.String decodeIdentifyingNonEmptyStringOnFirstBitAsPrefix(boolean namespaceNamePresent) throws FastInfosetException, java.io.IOException- Throws:
FastInfosetExceptionjava.io.IOException
-
decodeIdentifyingNonEmptyStringIndexOnFirstBitAsPrefix
protected final java.lang.String decodeIdentifyingNonEmptyStringIndexOnFirstBitAsPrefix(boolean namespaceNamePresent) throws FastInfosetException, java.io.IOException- Throws:
FastInfosetExceptionjava.io.IOException
-
decodeIdentifyingNonEmptyStringOnFirstBitAsNamespaceName
protected final java.lang.String decodeIdentifyingNonEmptyStringOnFirstBitAsNamespaceName(boolean prefixPresent) throws FastInfosetException, java.io.IOException- Throws:
FastInfosetExceptionjava.io.IOException
-
decodeIdentifyingNonEmptyStringIndexOnFirstBitAsNamespaceName
protected final java.lang.String decodeIdentifyingNonEmptyStringIndexOnFirstBitAsNamespaceName(boolean prefixPresent) throws FastInfosetException, java.io.IOException- Throws:
FastInfosetExceptionjava.io.IOException
-
compareCharsWithCharBufferFromEndToStart
private boolean compareCharsWithCharBufferFromEndToStart(char[] c)
-
decodeNonEmptyOctetStringOnSecondBitAsUtf8String
protected final java.lang.String decodeNonEmptyOctetStringOnSecondBitAsUtf8String() throws FastInfosetException, java.io.IOException- Throws:
FastInfosetExceptionjava.io.IOException
-
decodeNonEmptyOctetStringOnSecondBitAsUtf8CharArray
protected final void decodeNonEmptyOctetStringOnSecondBitAsUtf8CharArray() throws FastInfosetException, java.io.IOException- Throws:
FastInfosetExceptionjava.io.IOException
-
decodeNonEmptyOctetStringLengthOnSecondBit
protected final void decodeNonEmptyOctetStringLengthOnSecondBit() throws FastInfosetException, java.io.IOException- Throws:
FastInfosetExceptionjava.io.IOException
-
decodeIntegerIndexOnSecondBit
protected final int decodeIntegerIndexOnSecondBit() throws FastInfosetException, java.io.IOException- Throws:
FastInfosetExceptionjava.io.IOException
-
decodeHeader
protected final void decodeHeader() throws FastInfosetException, java.io.IOException- Throws:
FastInfosetExceptionjava.io.IOException
-
decodeRestrictedAlphabetAsCharBuffer
protected final void decodeRestrictedAlphabetAsCharBuffer() throws FastInfosetException, java.io.IOException- Throws:
FastInfosetExceptionjava.io.IOException
-
decodeRestrictedAlphabetAsString
protected final java.lang.String decodeRestrictedAlphabetAsString() throws FastInfosetException, java.io.IOException- Throws:
FastInfosetExceptionjava.io.IOException
-
decodeRAOctetsAsString
protected final java.lang.String decodeRAOctetsAsString(char[] restrictedAlphabet) throws FastInfosetException, java.io.IOException- Throws:
FastInfosetExceptionjava.io.IOException
-
decodeFourBitAlphabetOctetsAsCharBuffer
protected final void decodeFourBitAlphabetOctetsAsCharBuffer(char[] restrictedAlphabet) throws FastInfosetException, java.io.IOException- Throws:
FastInfosetExceptionjava.io.IOException
-
decodeAlphabetOctetsAsCharBuffer
protected final void decodeAlphabetOctetsAsCharBuffer(char[] restrictedAlphabet) throws FastInfosetException, java.io.IOException- Throws:
FastInfosetExceptionjava.io.IOException
-
resetBits
private void resetBits()
-
readBits
private int readBits(int bits) throws java.io.IOException- Throws:
java.io.IOException
-
decodeUtf8StringAsCharBuffer
protected final void decodeUtf8StringAsCharBuffer() throws java.io.IOException- Throws:
java.io.IOException
-
decodeUtf8StringAsCharBuffer
protected final void decodeUtf8StringAsCharBuffer(char[] ch, int offset) throws java.io.IOException- Throws:
java.io.IOException
-
decodeUtf8StringAsString
protected final java.lang.String decodeUtf8StringAsString() throws java.io.IOException- Throws:
java.io.IOException
-
decodeUtf16StringAsCharBuffer
protected final void decodeUtf16StringAsCharBuffer() throws java.io.IOException- Throws:
java.io.IOException
-
decodeUtf16StringAsString
protected final java.lang.String decodeUtf16StringAsString() throws java.io.IOException- Throws:
java.io.IOException
-
ensureOctetBufferSize
private void ensureOctetBufferSize() throws java.io.IOException- Throws:
java.io.IOException
-
repeatedRead
private void repeatedRead() throws java.io.IOException- Throws:
java.io.IOException
-
decodeUtf8StringIntoCharBuffer
protected final void decodeUtf8StringIntoCharBuffer() throws java.io.IOException- Throws:
java.io.IOException
-
decodeUtf8StringIntoCharBuffer
protected final void decodeUtf8StringIntoCharBuffer(char[] ch, int offset) throws java.io.IOException- Throws:
java.io.IOException
-
decodeTwoToFourByteUtf8Character
private void decodeTwoToFourByteUtf8Character(int b1, int end) throws java.io.IOException- Throws:
java.io.IOException
-
decodeTwoToFourByteUtf8Character
private void decodeTwoToFourByteUtf8Character(char[] ch, int b1, int end) throws java.io.IOException- Throws:
java.io.IOException
-
decodeUtf8NCNameIntoCharBuffer
protected final void decodeUtf8NCNameIntoCharBuffer() throws java.io.IOException- Throws:
java.io.IOException
-
decodeUtf8NCNameStartTwoToFourByteCharacters
private void decodeUtf8NCNameStartTwoToFourByteCharacters(int b1, int end) throws java.io.IOException- Throws:
java.io.IOException
-
decodeUtf8NCNameTwoToFourByteCharacters
private void decodeUtf8NCNameTwoToFourByteCharacters(int b1, int end) throws java.io.IOException- Throws:
java.io.IOException
-
decodeUtf8ThreeByteChar
private char decodeUtf8ThreeByteChar(int end, int b1) throws java.io.IOException- Throws:
java.io.IOException
-
decodeUtf8FourByteChar
private int decodeUtf8FourByteChar(int end, int b1) throws java.io.IOException- Throws:
java.io.IOException
-
decodeUtf8StringLengthTooSmall
private void decodeUtf8StringLengthTooSmall() throws java.io.IOException- Throws:
java.io.IOException
-
decodeUtf8StringIllegalState
private void decodeUtf8StringIllegalState() throws java.io.IOException- Throws:
java.io.IOException
-
decodeUtf8NCNameIllegalState
private void decodeUtf8NCNameIllegalState() throws java.io.IOException- Throws:
java.io.IOException
-
decodeUtf16StringIntoCharBuffer
private void decodeUtf16StringIntoCharBuffer() throws java.io.IOException- Throws:
java.io.IOException
-
createQualifiedNameString
protected java.lang.String createQualifiedNameString(java.lang.String second)
-
createQualifiedNameString
protected java.lang.String createQualifiedNameString(char[] first, java.lang.String second)
-
read
protected final int read() throws java.io.IOException- Throws:
java.io.IOException
-
closeIfRequired
protected final void closeIfRequired() throws java.io.IOException- Throws:
java.io.IOException
-
peek
protected final int peek() throws java.io.IOException- Throws:
java.io.IOException
-
peek
protected final int peek(OctetBufferListener octetBufferListener) throws java.io.IOException
- Throws:
java.io.IOException
-
peek2
protected final int peek2(OctetBufferListener octetBufferListener) throws java.io.IOException
- Throws:
java.io.IOException
-
_isFastInfosetDocument
protected final boolean _isFastInfosetDocument() throws java.io.IOException- Throws:
java.io.IOException
-
arrayEquals
private boolean arrayEquals(byte[] b1, int offset, byte[] b2, int length)
-
isFastInfosetDocument
public static boolean isFastInfosetDocument(java.io.InputStream s) throws java.io.IOException- Throws:
java.io.IOException
-
-