JML

java.io
Class ObjectInputStream

java.lang.Object
  extended byjava.io.InputStream
      extended byjava.io.ObjectInputStream
All Implemented Interfaces:
Closeable, DataInput, ObjectInput, ObjectStreamConstants

public class ObjectInputStream
extends InputStream
implements ObjectInput, ObjectStreamConstants


Nested Class Summary
private  class ObjectInputStream.BlockDataInputStream
           
private static class ObjectInputStream.Caches
           
private static class ObjectInputStream.CallbackContext
           
static class ObjectInputStream.GetField
           
private  class ObjectInputStream.GetFieldImpl
           
private static class ObjectInputStream.HandleTable
           
private static class ObjectInputStream.PeekInputStream
           
private static class ObjectInputStream.ValidationList
           
 
Field Summary
private  ObjectInputStream.BlockDataInputStream bin
           
private  boolean closed
           
private  ObjectInputStream.CallbackContext curContext
           
private  boolean defaultDataEnd
           
private  int depth
           
private  boolean enableOverride
           
private  boolean enableResolve
           
private  ObjectInputStream.HandleTable handles
           
private static int NULL_HANDLE
           
private  int passHandle
           
private static HashMap primClasses
           
private  byte[] primVals
           
private static Object unsharedMarker
           
private  ObjectInputStream.ValidationList vlist
           
 
Fields inherited from class java.io.InputStream
 
Fields inherited from interface java.io.ObjectStreamConstants
baseWireHandle, PROTOCOL_VERSION_1, PROTOCOL_VERSION_2, SC_BLOCK_DATA, SC_ENUM, SC_EXTERNALIZABLE, SC_SERIALIZABLE, SC_WRITE_METHOD, STREAM_MAGIC, STREAM_VERSION, SUBCLASS_IMPLEMENTATION_PERMISSION, SUBSTITUTION_PERMISSION, TC_ARRAY, TC_BASE, TC_BLOCKDATA, TC_BLOCKDATALONG, TC_CLASS, TC_CLASSDESC, TC_ENDBLOCKDATA, TC_ENUM, TC_EXCEPTION, TC_LONGSTRING, TC_MAX, TC_NULL, TC_OBJECT, TC_PROXYCLASSDESC, TC_REFERENCE, TC_RESET, TC_STRING
 
Constructor Summary
protected ObjectInputStream()
           
  ObjectInputStream(InputStream)
           
 
Method Summary
private static boolean auditSubclass(Class)
           
 int available()
           
private static void bytesToDoubles(byte[], int, double[], int, int)
           
private static void bytesToFloats(byte[], int, float[], int, int)
           
private  Object checkResolve(Object)
           
private  void clear()
           
private static Object cloneArray(Object)
           
 void close()
           
private  void defaultReadFields(Object, ObjectStreamClass)
           
 void defaultReadObject()
           
protected  boolean enableResolveObject(boolean)
           
private  void handleReset()
           
private static ClassLoader latestUserDefinedLoader()
           
 int read()
           
 int read(byte[], int, int)
           
private  Object readArray(boolean)
           
 boolean readBoolean()
           
 byte readByte()
           
 char readChar()
           
private  Class readClass(boolean)
           
private  ObjectStreamClass readClassDesc(boolean)
           
protected  ObjectStreamClass readClassDescriptor()
           
 double readDouble()
           
private  Enum readEnum(boolean)
           
private  void readExternalData(Externalizable, ObjectStreamClass)
           
private  IOException readFatalException()
           
 ObjectInputStream.GetField readFields()
           
 float readFloat()
           
 void readFully(byte[])
           
 void readFully(byte[], int, int)
           
private  Object readHandle(boolean)
           
 int readInt()
           
 String readLine()
           
 long readLong()
           
private  ObjectStreamClass readNonProxyDesc(boolean)
           
private  Object readNull()
           
 Object readObject()
           
private  Object readObject0(boolean)
           
protected  Object readObjectOverride()
           
private  Object readOrdinaryObject(boolean)
           
private  ObjectStreamClass readProxyDesc(boolean)
           
private  void readSerialData(Object, ObjectStreamClass)
           
 short readShort()
           
protected  void readStreamHeader()
           
private  String readString(boolean)
           
(package private)  String readTypeString()
           
 Object readUnshared()
           
 int readUnsignedByte()
           
 int readUnsignedShort()
           
 String readUTF()
           
 void registerValidation(ObjectInputValidation, int)
           
protected  Class resolveClass(ObjectStreamClass)
           
protected  Object resolveObject(Object)
           
protected  Class resolveProxyClass(String[])
           
 int skipBytes(int)
           
private  void skipCustomData()
           
private  void verifySubclass()
           
 
Methods inherited from class java.io.InputStream
mark, markSupported, read, reset, skip
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface java.io.ObjectInput
read, skip
 

Field Detail

enableOverride

private final boolean enableOverride

defaultDataEnd

private boolean defaultDataEnd

unsharedMarker

private static final Object unsharedMarker

bin

private final ObjectInputStream.BlockDataInputStream bin

closed

private boolean closed

passHandle

private int passHandle

primClasses

private static final HashMap primClasses

curContext

private ObjectInputStream.CallbackContext curContext

handles

private final ObjectInputStream.HandleTable handles

depth

private int depth

primVals

private byte[] primVals

vlist

private final ObjectInputStream.ValidationList vlist

NULL_HANDLE

private static final int NULL_HANDLE

enableResolve

private boolean enableResolve
Constructor Detail

ObjectInputStream

public ObjectInputStream(InputStream)
                  throws IOException
Throws:
IOException

ObjectInputStream

protected ObjectInputStream()
                     throws IOException,
                            SecurityException
Throws:
IOException
SecurityException
Method Detail

readObject

public final Object readObject()
                        throws IOException,
                               ClassNotFoundException
Specified by:
readObject in interface ObjectInput
Throws:
IOException
ClassNotFoundException

readObjectOverride

protected Object readObjectOverride()
                             throws IOException,
                                    ClassNotFoundException
Throws:
IOException
ClassNotFoundException

readUnshared

public Object readUnshared()
                    throws IOException,
                           ClassNotFoundException
Throws:
IOException
ClassNotFoundException

defaultReadObject

public void defaultReadObject()
                       throws IOException,
                              ClassNotFoundException
Throws:
IOException
ClassNotFoundException

readFields

public ObjectInputStream.GetField readFields()
                                      throws IOException,
                                             ClassNotFoundException
Throws:
IOException
ClassNotFoundException

registerValidation

public void registerValidation(ObjectInputValidation,
                               int)
                        throws NotActiveException,
                               InvalidObjectException
Throws:
NotActiveException
InvalidObjectException

resolveClass

protected Class resolveClass(ObjectStreamClass)
                      throws IOException,
                             ClassNotFoundException
Throws:
IOException
ClassNotFoundException

resolveProxyClass

protected Class resolveProxyClass(String[])
                           throws IOException,
                                  ClassNotFoundException
Throws:
IOException
ClassNotFoundException

resolveObject

protected Object resolveObject(Object)
                        throws IOException
Throws:
IOException

enableResolveObject

protected boolean enableResolveObject(boolean)
                               throws SecurityException
Throws:
SecurityException

readStreamHeader

protected void readStreamHeader()
                         throws IOException,
                                StreamCorruptedException
Throws:
IOException
StreamCorruptedException

readClassDescriptor

protected ObjectStreamClass readClassDescriptor()
                                         throws IOException,
                                                ClassNotFoundException
Throws:
IOException
ClassNotFoundException

read

public int read()
         throws IOException
Specified by:
read in interface ObjectInput
Throws:
IOException

read

public int read(byte[],
                int,
                int)
         throws IOException
Specified by:
read in interface ObjectInput
Overrides:
read in class InputStream
Throws:
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 ObjectInput
Overrides:
close in class InputStream
Throws:
IOException

readBoolean

public boolean readBoolean()
                    throws IOException
Specified by:
readBoolean in interface DataInput
Throws:
IOException

readByte

public byte readByte()
              throws IOException
Specified by:
readByte in interface DataInput
Throws:
IOException

readUnsignedByte

public int readUnsignedByte()
                     throws IOException
Specified by:
readUnsignedByte in interface DataInput
Throws:
IOException

readChar

public char readChar()
              throws IOException
Specified by:
readChar in interface DataInput
Throws:
IOException

readShort

public short readShort()
                throws IOException
Specified by:
readShort in interface DataInput
Throws:
IOException

readUnsignedShort

public int readUnsignedShort()
                      throws IOException
Specified by:
readUnsignedShort in interface DataInput
Throws:
IOException

readInt

public int readInt()
            throws IOException
Specified by:
readInt in interface DataInput
Throws:
IOException

readLong

public long readLong()
              throws IOException
Specified by:
readLong in interface DataInput
Throws:
IOException

readFloat

public float readFloat()
                throws IOException
Specified by:
readFloat in interface DataInput
Throws:
IOException

readDouble

public double readDouble()
                  throws IOException
Specified by:
readDouble in interface DataInput
Throws:
IOException

readFully

public void readFully(byte[])
               throws IOException
Specified by:
readFully in interface DataInput
Throws:
IOException

readFully

public void readFully(byte[],
                      int,
                      int)
               throws IOException
Specified by:
readFully in interface DataInput
Throws:
IOException

skipBytes

public int skipBytes(int)
              throws IOException
Specified by:
skipBytes in interface DataInput
Throws:
IOException

readLine

public String readLine()
                throws IOException
Specified by:
readLine in interface DataInput
Throws:
IOException

readUTF

public String readUTF()
               throws IOException
Specified by:
readUTF in interface DataInput
Throws:
IOException

verifySubclass

private void verifySubclass()

auditSubclass

private static boolean auditSubclass(Class)

clear

private void clear()

readObject0

private Object readObject0(boolean)
                    throws IOException
Throws:
IOException

checkResolve

private Object checkResolve(Object)
                     throws IOException
Throws:
IOException

readTypeString

String readTypeString()
                throws IOException
Throws:
IOException

readNull

private Object readNull()
                 throws IOException
Throws:
IOException

readHandle

private Object readHandle(boolean)
                   throws IOException
Throws:
IOException

readClass

private Class readClass(boolean)
                 throws IOException
Throws:
IOException

readClassDesc

private ObjectStreamClass readClassDesc(boolean)
                                 throws IOException
Throws:
IOException

readProxyDesc

private ObjectStreamClass readProxyDesc(boolean)
                                 throws IOException
Throws:
IOException

readNonProxyDesc

private ObjectStreamClass readNonProxyDesc(boolean)
                                    throws IOException
Throws:
IOException

readString

private String readString(boolean)
                   throws IOException
Throws:
IOException

readArray

private Object readArray(boolean)
                  throws IOException
Throws:
IOException

readEnum

private Enum readEnum(boolean)
               throws IOException
Throws:
IOException

readOrdinaryObject

private Object readOrdinaryObject(boolean)
                           throws IOException
Throws:
IOException

readExternalData

private void readExternalData(Externalizable,
                              ObjectStreamClass)
                       throws IOException
Throws:
IOException

readSerialData

private void readSerialData(Object,
                            ObjectStreamClass)
                     throws IOException
Throws:
IOException

skipCustomData

private void skipCustomData()
                     throws IOException
Throws:
IOException

defaultReadFields

private void defaultReadFields(Object,
                               ObjectStreamClass)
                        throws IOException
Throws:
IOException

readFatalException

private IOException readFatalException()
                                throws IOException
Throws:
IOException

handleReset

private void handleReset()
                  throws StreamCorruptedException
Throws:
StreamCorruptedException

bytesToFloats

private static void bytesToFloats(byte[],
                                  int,
                                  float[],
                                  int,
                                  int)

bytesToDoubles

private static void bytesToDoubles(byte[],
                                   int,
                                   double[],
                                   int,
                                   int)

latestUserDefinedLoader

private static ClassLoader latestUserDefinedLoader()

cloneArray

private static Object cloneArray(Object)

JML

JML is Copyright (C) 1998-2002 by Iowa State University and is distributed under the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. This release depends on code from the MultiJava project and is based in part on the Kopi project Copyright (C) 1990-99 DMS Decision Management Systems Ges.m.b.H.