org.apache.catalina.util
Class CustomObjectInputStream
ObjectInputStream
org.apache.catalina.util.CustomObjectInputStream
public final class CustomObjectInputStream
extends ObjectInputStream
Custom subclass of ObjectInputStream
that loads from the
class loader for this web application. This allows classes defined only
with the web application to be found correctly.
Version:
- Craig R. McClanahan
- Bip Thelin
CustomObjectInputStream(InputStream stream, ClassLoader classLoader) - Construct a new instance of CustomObjectInputStream
|
Class | resolveClass(ObjectStreamClass classDesc) - Load the local class equivalent of the specified stream class
description, by using the class loader assigned to this Context.
|
CustomObjectInputStream
public CustomObjectInputStream(InputStream stream,
ClassLoader classLoader)
throws IOException
Construct a new instance of CustomObjectInputStream
stream
- The input stream we will read fromclassLoader
- The class loader used to instantiate objects
resolveClass
public Class resolveClass(ObjectStreamClass classDesc)
throws ClassNotFoundException,
IOException
Load the local class equivalent of the specified stream class
description, by using the class loader assigned to this Context.
classDesc
- Class description from the input stream
Copyright B) 2000-2003 Apache Software Foundation. All Rights Reserved.