org.apache.mina.filter.codec.serialization

Class ObjectSerializationInputStream

Implemented Interfaces:
ObjectInput

public class ObjectSerializationInputStream
extends InputStream
implements ObjectInput

An ObjectInput and InputStream that can read the objects encoded by ObjectSerializationEncoder.

Constructor Summary

ObjectSerializationInputStream(InputStream in)
ObjectSerializationInputStream(InputStream in, ClassLoader classLoader)

Method Summary

int
getMaxObjectSize()
Returns the allowed maximum size of the object to be decoded.
int
read()
boolean
readBoolean()
byte
readByte()
char
readChar()
double
readDouble()
float
readFloat()
void
readFully(byte[] b)
void
readFully(byte[] b, int off, int len)
int
readInt()
String
readLine()
Deprecated.
long
readLong()
Object
readObject()
short
readShort()
String
readUTF()
int
readUnsignedByte()
int
readUnsignedShort()
void
setMaxObjectSize(int maxObjectSize)
Sets the allowed maximum size of the object to be decoded.
int
skipBytes(int n)

Constructor Details

ObjectSerializationInputStream

public ObjectSerializationInputStream(InputStream in)

ObjectSerializationInputStream

public ObjectSerializationInputStream(InputStream in,
                                      ClassLoader classLoader)

Method Details

getMaxObjectSize

public int getMaxObjectSize()

read

public int read()
            throws IOException

readBoolean

public boolean readBoolean()
            throws IOException

readByte

public byte readByte()
            throws IOException

readChar

public char readChar()
            throws IOException

readDouble

public double readDouble()
            throws IOException

readFloat

public float readFloat()
            throws IOException

readFully

public void readFully(byte[] b)
            throws IOException

readFully

public void readFully(byte[] b,
                      int off,
                      int len)
            throws IOException

readInt

public int readInt()
            throws IOException

readLine

public String readLine()
            throws IOException

Deprecated.

See Also:
DataInput.readLine()

readLong

public long readLong()
            throws IOException

readObject

public Object readObject()
            throws ClassNotFoundException,
                   IOException

readShort

public short readShort()
            throws IOException

readUTF

public String readUTF()
            throws IOException

readUnsignedByte

public int readUnsignedByte()
            throws IOException

readUnsignedShort

public int readUnsignedShort()
            throws IOException

setMaxObjectSize

public void setMaxObjectSize(int maxObjectSize)

skipBytes

public int skipBytes(int n)
            throws IOException