Top Description Fields Constructors Methods
com.sun.xml.fastinfoset.algorithm

public Class BooleanEncodingAlgorithm

extends BuiltInEncodingAlgorithm
Class Inheritance
Imports
java.io.EOFException, .IOException, .InputStream, .OutputStream, java.nio.CharBuffer, java.util.ArrayList, .List, org.jvnet.fastinfoset.EncodingAlgorithmException, com.sun.xml.fastinfoset.CommonResourceBundle

An encoder for handling boolean values. Supports the builtin BOOLEAN encoder.
Authors
Alan Hudson, Paul Sandoz

Field Summary

Modifier and TypeField and Description
private static final int[]
BIT_TABLE

Table for setting a particular bit of a byte

Inherited from com.sun.xml.fastinfoset.algorithm.BuiltInEncodingAlgorithm:
SPACE_PATTERN

Constructor Summary

AccessConstructor and Description
public

Method Summary

Modifier and TypeMethod and Description
public final Object
public final void
public final Object
public final void
decodeFromBytesToBooleanArray(boolean[] bdata, int bstart, int blength, byte[] b, int start, int length)

public final Object
public void
encodeToBytes(Object array, int astart, int alength, byte[] b, int start)

Implements abstract com.sun.xml.fastinfoset.algorithm.BuiltInEncodingAlgorithm.encodeToBytes.

public void
encodeToBytesFromBooleanArray(boolean[] array, int astart, int alength, byte[] b, int start)

public void
private boolean[]
generateArrayFromList(List<Boolean>
The array
array
)

Generate a boolean array from a list of Booleans.

public int
public int
public int
getPrimtiveLengthFromOctetLength(int octetLength, int firstOctet)

Inherited from com.sun.xml.fastinfoset.algorithm.BuiltInEncodingAlgorithm:
matchWhiteSpaceDelimnatedWordsremoveWhitespace

Field Detail

BIT_TABLEback to summary
private static final int[] BIT_TABLE

Table for setting a particular bit of a byte

Constructor Detail

BooleanEncodingAlgorithmback to summary
public BooleanEncodingAlgorithm()

Method Detail

convertFromCharactersback to summary
public final Object convertFromCharacters(char[] ch, int start, int length)

Implements org.jvnet.fastinfoset.EncodingAlgorithm.convertFromCharacters.

Annotations
@Override
convertToCharactersback to summary
public final void convertToCharacters(Object data, StringBuilder s)

Implements org.jvnet.fastinfoset.EncodingAlgorithm.convertToCharacters.

Annotations
@Override
decodeFromBytesback to summary
public final Object decodeFromBytes(byte[] b, int start, int length) throws EncodingAlgorithmException

Implements org.jvnet.fastinfoset.EncodingAlgorithm.decodeFromBytes.

Annotations
@Override
decodeFromBytesToBooleanArrayback to summary
public final void decodeFromBytesToBooleanArray(boolean[] bdata, int bstart, int blength, byte[] b, int start, int length)
decodeFromInputStreamback to summary
public final Object decodeFromInputStream(InputStream s) throws IOException

Implements org.jvnet.fastinfoset.EncodingAlgorithm.decodeFromInputStream.

Annotations
@Override
encodeToBytesback to summary
public void encodeToBytes(Object array, int astart, int alength, byte[] b, int start)

Implements abstract com.sun.xml.fastinfoset.algorithm.BuiltInEncodingAlgorithm.encodeToBytes.

Annotations
@Override
encodeToBytesFromBooleanArrayback to summary
public void encodeToBytesFromBooleanArray(boolean[] array, int astart, int alength, byte[] b, int start)
encodeToOutputStreamback to summary
public void encodeToOutputStream(Object data, OutputStream s) throws IOException

Implements org.jvnet.fastinfoset.EncodingAlgorithm.encodeToOutputStream.

Annotations
@Override
generateArrayFromListback to summary
private boolean[] generateArrayFromList(List<Boolean> array)

Generate a boolean array from a list of Booleans.

Parameters
array:List<Boolean>

The array

getOctetLengthFromPrimitiveLengthback to summary
public int getOctetLengthFromPrimitiveLength(int primitiveLength)

Implements abstract com.sun.xml.fastinfoset.algorithm.BuiltInEncodingAlgorithm.getOctetLengthFromPrimitiveLength.

Annotations
@Override
getPrimtiveLengthFromOctetLengthback to summary
public int getPrimtiveLengthFromOctetLength(int octetLength) throws EncodingAlgorithmException

Implements abstract com.sun.xml.fastinfoset.algorithm.BuiltInEncodingAlgorithm.getPrimtiveLengthFromOctetLength.

Annotations
@Override
getPrimtiveLengthFromOctetLengthback to summary
public int getPrimtiveLengthFromOctetLength(int octetLength, int firstOctet) throws EncodingAlgorithmException