public class SimplePojoClp<T>
extends Object
A class loader proxy able to serialize simple POJOs between two class loaders. It only works for simple POJOs following the Java Beans semantics. The local and remote classes do not have to match or even be derived from each other as long as their properties match. Any bean properties that the source bean exposes but the target bean does not will silently be ignored.
Constructor and Description |
---|
SimplePojoClp(Class<? extends T> localImplementationClass,
ClassLoader remoteClassLoader) |
SimplePojoClp(Class<? extends T> localImplementationClass,
ClassLoader remoteClassLoader,
String remoteImplementationClassName) |
Modifier and Type | Method and Description |
---|---|
T |
createLocalObject(Object remoteInstance) |
Object |
createRemoteObject(T localInstance) |
public SimplePojoClp(Class<? extends T> localImplementationClass, ClassLoader remoteClassLoader) throws ClassNotFoundException
ClassNotFoundException
public SimplePojoClp(Class<? extends T> localImplementationClass, ClassLoader remoteClassLoader, String remoteImplementationClassName) throws ClassNotFoundException
ClassNotFoundException
public T createLocalObject(Object remoteInstance) throws IllegalAccessException, InstantiationException
IllegalAccessException
InstantiationException
public Object createRemoteObject(T localInstance) throws IllegalAccessException, InstantiationException
IllegalAccessException
InstantiationException