Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.jboss.netty.handler.codec.serialization
Class ObjectDecoderInputStream

    java.lang.Object
      java.io.InputStream
          org.jboss.netty.handler.codec.serialization.ObjectDecoderInputStream

All Implemented Interfaces:
  Closeable, DataInput, ObjectInput

    public class ObjectDecoderInputStream

extends InputStream
implements ObjectInput

An `ObjectInput` which is interoperable with `ObjectEncoder` and `ObjectEncoderOutputStream`.

Version:
  $Rev: 2080 $, $Date: 2010-01-26 18:04:19 +0900 (Tue, 26 Jan 2010) $
Author:
  The Netty Project, Trustin Lee

Constructor Summary
`ObjectDecoderInputStream(InputStream in)` Creates a new `ObjectInput`.
`ObjectDecoderInputStream(InputStream in, ClassLoader classLoader)` Creates a new `ObjectInput`.
`ObjectDecoderInputStream(InputStream in, ClassLoader classLoader, int maxObjectSize)` Creates a new `ObjectInput`.
`ObjectDecoderInputStream(InputStream in, int maxObjectSize)` Creates a new `ObjectInput`.

Method Summary
`int` | `available()`
`void` | `close()`
`void` | `mark(int readlimit)`
`boolean` | `markSupported()`
`int` | `read()`
`int` | `read(byte[] b)`
`int` | `read(byte[] b, int off, int len)`
`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()`
`int` | `readUnsignedByte()`
`int` | `readUnsignedShort()`
`String` | `readUTF()`
`void` | `reset()`
`long` | `skip(long n)`
`int` | `skipBytes(int n)`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### ObjectDecoderInputStream

    public ObjectDecoderInputStream(InputStream in)

  Creates a new `ObjectInput`.

  Parameters:
    `in` - the `InputStream` where the serialized form will be read from

### ObjectDecoderInputStream

    public ObjectDecoderInputStream(InputStream in,
                                    ClassLoader classLoader)

  Creates a new `ObjectInput`.

  Parameters:
    `in` - the `InputStream` where the serialized form will be read from
    `classLoader` - the `ClassLoader` which will load the class of the serialized object

### ObjectDecoderInputStream

    public ObjectDecoderInputStream(InputStream in,
                                    int maxObjectSize)

  Creates a new `ObjectInput`.

  Parameters:
    `in` - the `InputStream` where the serialized form will be read from
    `maxObjectSize` - the maximum byte length of the serialized object. if the length of the received object is greater than this value, a `StreamCorruptedException` will be raised.

### ObjectDecoderInputStream

    public ObjectDecoderInputStream(InputStream in,
                                    ClassLoader classLoader,
                                    int maxObjectSize)

  Creates a new `ObjectInput`.

  Parameters:
    `in` - the `InputStream` where the serialized form will be read from
    `classLoader` - the `ClassLoader` which will load the class of the serialized object
    `maxObjectSize` - the maximum byte length of the serialized object. if the length of the received object is greater than this value, a `StreamCorruptedException` will be raised.

Method Detail

### readObject

    public Object readObject()
                      throws ClassNotFoundException,
                             IOException

  Specified by:
    `readObject` in interface `ObjectInput`
  Throws:
    `ClassNotFoundException`
    `IOException`

### available

    public int available()
                  throws IOException

  Specified by:
    `available` in interface `ObjectInput`
  Overrides:
    `available` in class `InputStream`
  Throws:
    `IOException`

### close

    public void close()
               throws IOException

  Specified by:
    `close` in interface `Closeable`
  Specified by:
    `close` in interface `ObjectInput`
  Overrides:
    `close` in class `InputStream`
  Throws:
    `IOException`

### mark

    public void mark(int readlimit)

  Overrides:
    `mark` in class `InputStream`

### markSupported

    public boolean markSupported()

  Overrides:
    `markSupported` in class `InputStream`

### read

    public int read()
             throws IOException

  Specified by:
    `read` in interface `ObjectInput`
  Specified by:
    `read` in class `InputStream`
  Throws:
    `IOException`

### read

    public final int read(byte[] b,
                          int off,
                          int len)
                   throws IOException

  Specified by:
    `read` in interface `ObjectInput`
  Overrides:
    `read` in class `InputStream`
  Throws:
    `IOException`

### read

    public final int read(byte[] b)
                   throws IOException

  Specified by:
    `read` in interface `ObjectInput`
  Overrides:
    `read` in class `InputStream`
  Throws:
    `IOException`

### readBoolean

    public final boolean readBoolean()
                              throws IOException

  Specified by:
    `readBoolean` in interface `DataInput`
  Throws:
    `IOException`

### readByte

    public final byte readByte()
                        throws IOException

  Specified by:
    `readByte` in interface `DataInput`
  Throws:
    `IOException`

### readChar

    public final char readChar()
                        throws IOException

  Specified by:
    `readChar` in interface `DataInput`
  Throws:
    `IOException`

### readDouble

    public final double readDouble()
                            throws IOException

  Specified by:
    `readDouble` in interface `DataInput`
  Throws:
    `IOException`

### readFloat

    public final float readFloat()
                          throws IOException

  Specified by:
    `readFloat` in interface `DataInput`
  Throws:
    `IOException`

### readFully

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

  Specified by:
    `readFully` in interface `DataInput`
  Throws:
    `IOException`

### readFully

    public final void readFully(byte[] b)
                         throws IOException

  Specified by:
    `readFully` in interface `DataInput`
  Throws:
    `IOException`

### readInt

    public final int readInt()
                      throws IOException

  Specified by:
    `readInt` in interface `DataInput`
  Throws:
    `IOException`

### readLine

    @Deprecated
    public final String readLine()
                          throws IOException

  Deprecated.

  Specified by:
    `readLine` in interface `DataInput`
  Throws:
    `IOException`

### readLong

    public final long readLong()
                        throws IOException

  Specified by:
    `readLong` in interface `DataInput`
  Throws:
    `IOException`

### readShort

    public final short readShort()
                          throws IOException

  Specified by:
    `readShort` in interface `DataInput`
  Throws:
    `IOException`

### readUnsignedByte

    public final int readUnsignedByte()
                               throws IOException

  Specified by:
    `readUnsignedByte` in interface `DataInput`
  Throws:
    `IOException`

### readUnsignedShort

    public final int readUnsignedShort()
                                throws IOException

  Specified by:
    `readUnsignedShort` in interface `DataInput`
  Throws:
    `IOException`

### readUTF

    public final String readUTF()
                         throws IOException

  Specified by:
    `readUTF` in interface `DataInput`
  Throws:
    `IOException`

### reset

    public void reset()
               throws IOException

  Overrides:
    `reset` in class `InputStream`
  Throws:
    `IOException`

### skip

    public long skip(long n)
              throws IOException

  Specified by:
    `skip` in interface `ObjectInput`
  Overrides:
    `skip` in class `InputStream`
  Throws:
    `IOException`

### skipBytes

    public final int skipBytes(int n)
                        throws IOException

  Specified by:
    `skipBytes` in interface `DataInput`
  Throws:
    `IOException`

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2008-2010 JBoss, a division of Red Hat, Inc.. All Rights Reserved.