Class BooleanEncodingAlgorithm
- java.lang.Object
-
- com.sun.xml.fastinfoset.algorithm.BuiltInEncodingAlgorithm
-
- com.sun.xml.fastinfoset.algorithm.BooleanEncodingAlgorithm
-
- All Implemented Interfaces:
EncodingAlgorithm
public class BooleanEncodingAlgorithm extends BuiltInEncodingAlgorithm
An encoder for handling boolean values. Suppports the builtin BOOLEAN encoder.- Author:
- Alan Hudson, Paul Sandoz
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class com.sun.xml.fastinfoset.algorithm.BuiltInEncodingAlgorithm
BuiltInEncodingAlgorithm.WordListener
-
-
Field Summary
-
Fields inherited from class com.sun.xml.fastinfoset.algorithm.BuiltInEncodingAlgorithm
SPACE_PATTERN
-
-
Constructor Summary
Constructors Constructor Description BooleanEncodingAlgorithm()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ObjectconvertFromCharacters(char[] ch, int start, int length)voidconvertToCharacters(Object data, StringBuffer s)ObjectdecodeFromBytes(byte[] b, int start, int length)voiddecodeFromBytesToBooleanArray(boolean[] bdata, int bstart, int blength, byte[] b, int start, int length)ObjectdecodeFromInputStream(InputStream s)voidencodeToBytes(Object array, int astart, int alength, byte[] b, int start)voidencodeToBytesFromBooleanArray(boolean[] array, int astart, int alength, byte[] b, int start)voidencodeToOutputStream(Object data, OutputStream s)intgetOctetLengthFromPrimitiveLength(int primitiveLength)intgetPrimtiveLengthFromOctetLength(int octetLength)intgetPrimtiveLengthFromOctetLength(int octetLength, int firstOctet)-
Methods inherited from class com.sun.xml.fastinfoset.algorithm.BuiltInEncodingAlgorithm
matchWhiteSpaceDelimnatedWords, removeWhitespace
-
-
-
-
Method Detail
-
getPrimtiveLengthFromOctetLength
public int getPrimtiveLengthFromOctetLength(int octetLength) throws EncodingAlgorithmException- Specified by:
getPrimtiveLengthFromOctetLengthin classBuiltInEncodingAlgorithm- Throws:
EncodingAlgorithmException
-
getOctetLengthFromPrimitiveLength
public int getOctetLengthFromPrimitiveLength(int primitiveLength)
- Specified by:
getOctetLengthFromPrimitiveLengthin classBuiltInEncodingAlgorithm
-
decodeFromBytes
public final Object decodeFromBytes(byte[] b, int start, int length) throws EncodingAlgorithmException
- Throws:
EncodingAlgorithmException
-
decodeFromInputStream
public final Object decodeFromInputStream(InputStream s) throws IOException
- Throws:
IOException
-
encodeToOutputStream
public void encodeToOutputStream(Object data, OutputStream s) throws IOException
- Throws:
IOException
-
convertFromCharacters
public final Object convertFromCharacters(char[] ch, int start, int length)
-
convertToCharacters
public final void convertToCharacters(Object data, StringBuffer s)
-
getPrimtiveLengthFromOctetLength
public int getPrimtiveLengthFromOctetLength(int octetLength, int firstOctet) throws EncodingAlgorithmException- Throws:
EncodingAlgorithmException
-
decodeFromBytesToBooleanArray
public final void decodeFromBytesToBooleanArray(boolean[] bdata, int bstart, int blength, byte[] b, int start, int length)
-
encodeToBytes
public void encodeToBytes(Object array, int astart, int alength, byte[] b, int start)
- Specified by:
encodeToBytesin classBuiltInEncodingAlgorithm
-
encodeToBytesFromBooleanArray
public void encodeToBytesFromBooleanArray(boolean[] array, int astart, int alength, byte[] b, int start)
-
-