org.apache.commons.io.input
public class ClassLoaderObjectInputStream extends ObjectInputStream
ClassLoader
rather than the system default.
This is useful in dynamic container environments.
Since: Commons IO 1.1
Version: $Id: ClassLoaderObjectInputStream.java 437567 2006-08-28 06:39:07Z bayard $
Field Summary | |
---|---|
ClassLoader | classLoader The class loader to use. |
Constructor Summary | |
---|---|
ClassLoaderObjectInputStream(ClassLoader classLoader, InputStream inputStream)
Constructs a new ClassLoaderObjectInputStream.
|
Method Summary | |
---|---|
protected Class | resolveClass(ObjectStreamClass objectStreamClass)
Resolve a class specified by the descriptor using the
specified ClassLoader or the super ClassLoader.
|
Parameters: classLoader the ClassLoader from which classes should be loaded inputStream the InputStream to work on
Throws: IOException in case of an I/O error StreamCorruptedException if the stream is corrupted
Parameters: objectStreamClass descriptor of the class
Returns: the Class object described by the ObjectStreamClass
Throws: IOException in case of an I/O error ClassNotFoundException if the Class cannot be found