java.beans
Class ObjectInputStreamWithLoader

java.lang.Object
  |
  +--java.io.InputStream
        |
        +--java.io.ObjectInputStream
              |
              +--java.beans.ObjectInputStreamWithLoader

class ObjectInputStreamWithLoader
extends ObjectInputStream

This subclass of ObjectInputStream delegates loading of classes to an existing ClassLoader.


Inner classes inherited from class java.io.ObjectInputStream
ObjectInputStream.GetField, ObjectInputStream.GetFieldImpl
 
Field Summary
private  ClassLoader loader
           
 
Fields inherited from class java.io.ObjectInputStream
abortClassNotFoundException, abortIOException, blockDataMode, buffer, callbacks, classdesc, classes, count, currCode, currentClass, currentClassDesc, currentGetFields, currentObject, data, dis, enableResolve, enableSubclassImplementation, in, INITIAL_BUFFER_SIZE, nextWireOffset, readObjectArglist, recursionDepth, spClass, wireHandle2Object
 
Fields inherited from class java.io.InputStream
SKIP_BUFFER_SIZE, skipBuffer
 
Constructor Summary
ObjectInputStreamWithLoader(InputStream in, ClassLoader loader)
          Loader must be non-null;
 
Method Summary
private  Class primitiveType(char type)
          Make a primitive array class
protected  Class resolveClass(ObjectStreamClass classDesc)
          Use the given ClassLoader rather than using the system class
 
Methods inherited from class java.io.ObjectInputStream
allocateNewArray, allocateNewObject, assignWireOffset, available, close, defaultReadObject, doValidations, enableResolveObject, inputArray, inputClassDescriptor, inputClassFields, inputObject, invokeObjectReader, loadClass0, peekCode, pushbackCode, read, read, readBoolean, readByte, readChar, readCode, readDouble, readFields, readFloat, readFully, readFully, readInt, readLine, readLong, readObject, readObject, readObjectOverride, readShort, readStreamHeader, readUnsignedByte, readUnsignedShort, readUTF, refill, registerValidation, resetStream, resolveObject, setBlockData, skipBytes, SkipToEndOfBlockData
 
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, registerNatives, toString, wait, wait, wait
 

Field Detail

loader

private ClassLoader loader
Constructor Detail

ObjectInputStreamWithLoader

public ObjectInputStreamWithLoader(InputStream in,
                                   ClassLoader loader)
                            throws IOException,
                                   StreamCorruptedException
Loader must be non-null;
Method Detail

primitiveType

private Class primitiveType(char type)
Make a primitive array class

resolveClass

protected Class resolveClass(ObjectStreamClass classDesc)
                      throws IOException,
                             ClassNotFoundException
Use the given ClassLoader rather than using the system class
Overrides:
resolveClass in class ObjectInputStream