EXIficient

com.siemens.ct.exi.io.channel
Interface DecoderChannel

All Known Implementing Classes:
AbstractDecoderChannel, BitDecoderChannel, ByteDecoderChannel, PreReadByteDecoderChannel

public interface DecoderChannel

TODO Description

Version:
0.3.20081117
Author:
Daniel.Peintner.EXT@siemens.com, Joerg.Heuer@siemens.com

Method Summary
 int decode()
          Decodes a single byte
 byte[] decodeBinary()
          Decode a binary value as a length-prefixed sequence of octets.
 java.lang.String decodeBinaryAsString()
           
 boolean decodeBoolean()
          Decode a single boolean value.
 java.lang.String decodeBooleanAsString()
           
 java.util.Calendar decodeDateTime(DatetimeType type)
          Decode Date-Time as sequence of values representing the individual components of the Date-Time.
 java.lang.String decodeDateTimeAsString(DatetimeType type)
           
 java.math.BigDecimal decodeDecimal()
          Decode a decimal represented as a Boolean sign followed by two Unsigned Integers.
 java.lang.String decodeDecimalAsString()
           
 float decodeFloat()
          Decode a Float represented as two consecutive Integers.
 java.lang.String decodeFloatAsString()
           
 int decodeInteger()
          Decode an arbitrary precision integer using a sign bit followed by a sequence of octets.
 java.lang.String decodeIntegerAsString()
           
 int decodeNBitUnsignedInteger(int n)
          Decodes and returns an n-bit unsigned integer.
 java.lang.String decodeNBitUnsignedIntegerAsString(int n)
           
 java.lang.String decodeString()
          Decode a string as a length-prefixed sequence of UCS codepoints, each of which is encoded as an integer.
 java.lang.String decodeStringOnly(int length)
          Decode the characters of a string whose length has already been read.
 int decodeUnsignedInteger()
          Decode an arbitrary precision non negative integer using a sequence of octets.
 long decodeUnsignedIntegerAsLong()
           
 java.lang.String decodeUnsignedIntegerAsString()
           
 

Method Detail

decode

int decode()
           throws java.io.IOException
Decodes a single byte

Returns:
a byte as int
Throws:
java.io.IOException

decodeNBitUnsignedInteger

int decodeNBitUnsignedInteger(int n)
                              throws java.io.IOException
Decodes and returns an n-bit unsigned integer.

Throws:
java.io.IOException

decodeNBitUnsignedIntegerAsString

java.lang.String decodeNBitUnsignedIntegerAsString(int n)
                                                   throws java.io.IOException
Throws:
java.io.IOException

decodeBoolean

boolean decodeBoolean()
                      throws java.io.IOException
Decode a single boolean value. The value false is represented by the bit (byte) 0, and the value true is represented by the bit (byte) 1.

Throws:
java.io.IOException

decodeBooleanAsString

java.lang.String decodeBooleanAsString()
                                       throws java.io.IOException
Throws:
java.io.IOException

decodeBinary

byte[] decodeBinary()
                    throws java.io.IOException
Decode a binary value as a length-prefixed sequence of octets.

Throws:
java.io.IOException

decodeBinaryAsString

java.lang.String decodeBinaryAsString()
                                      throws java.io.IOException
Throws:
java.io.IOException

decodeString

java.lang.String decodeString()
                              throws java.io.IOException
Decode a string as a length-prefixed sequence of UCS codepoints, each of which is encoded as an integer. Look for codepoints of more than 16 bits that are represented as UTF-16 surrogate pairs in Java.

Throws:
java.io.IOException

decodeStringOnly

java.lang.String decodeStringOnly(int length)
                                  throws java.io.IOException
Decode the characters of a string whose length has already been read. Look for codepoints of more than 16 bits that are represented as UTF-16 surrogate pairs in Java.

Parameters:
length - Length of the character sequence to read.
Returns:
The character sequence as a string.
Throws:
java.io.IOException

decodeUnsignedInteger

int decodeUnsignedInteger()
                          throws java.io.IOException
Decode an arbitrary precision non negative integer using a sequence of octets. The most significant bit of the last octet is set to zero to indicate sequence termination. Only seven bits per octet are used to store the integer's value.

Throws:
java.io.IOException

decodeUnsignedIntegerAsLong

long decodeUnsignedIntegerAsLong()
                                 throws java.io.IOException
Throws:
java.io.IOException

decodeUnsignedIntegerAsString

java.lang.String decodeUnsignedIntegerAsString()
                                               throws java.io.IOException
Throws:
java.io.IOException

decodeInteger

int decodeInteger()
                  throws java.io.IOException
Decode an arbitrary precision integer using a sign bit followed by a sequence of octets. The most significant bit of the last octet is set to zero to indicate sequence termination. Only seven bits per octet are used to store the integer's value.

Throws:
java.io.IOException

decodeIntegerAsString

java.lang.String decodeIntegerAsString()
                                       throws java.io.IOException
Throws:
java.io.IOException

decodeDecimal

java.math.BigDecimal decodeDecimal()
                                   throws java.io.IOException
Decode a decimal represented as a Boolean sign followed by two Unsigned Integers. A sign value of zero (0) is used to represent positive Decimal values and a sign value of one (1) is used to represent negative Decimal values The first Integer represents the integral portion of the Decimal value. The second positive integer represents the fractional portion of the decimal with the digits in reverse order to preserve leading zeros.

Throws:
java.io.IOException

decodeDecimalAsString

java.lang.String decodeDecimalAsString()
                                       throws java.io.IOException
Throws:
java.io.IOException

decodeFloat

float decodeFloat()
                  throws java.io.IOException
Decode a Float represented as two consecutive Integers. The first Integer represents the mantissa of the floating point number and the second Integer represents the 10-based exponent of the floating point number

Throws:
java.io.IOException

decodeFloatAsString

java.lang.String decodeFloatAsString()
                                     throws java.io.IOException
Throws:
java.io.IOException

decodeDateTime

java.util.Calendar decodeDateTime(DatetimeType type)
                                  throws java.io.IOException
Decode Date-Time as sequence of values representing the individual components of the Date-Time.

Throws:
java.io.IOException

decodeDateTimeAsString

java.lang.String decodeDateTimeAsString(DatetimeType type)
                                        throws java.io.IOException
Throws:
java.io.IOException

EXIficient