Package net.sf.jasperreports.engine.util
Class LocalVirtualizationSerializer
- java.lang.Object
-
- net.sf.jasperreports.engine.util.VirtualizationSerializer
-
- net.sf.jasperreports.engine.util.LocalVirtualizationSerializer
-
public class LocalVirtualizationSerializer extends VirtualizationSerializer
- Author:
- Lucian Chirita (lucianc@users.sourceforge.net)
-
-
Field Summary
Fields Modifier and Type Field Description protected ConcurrentMap<Integer,Class<?>>
classes
protected AtomicInteger
classIndex
protected ConcurrentMap<Class<?>,Integer>
classIndexes
protected static int
CLASSLOADER_IDX_NOT_SET
protected AtomicInteger
classLoaderIndex
protected ConcurrentMap<Integer,ClassLoader>
classLoaders
protected ConcurrentMap<ClassLoader,Integer>
classLoadersIndexes
-
Constructor Summary
Constructors Constructor Description LocalVirtualizationSerializer()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description protected VirtualizationInput
createInput(JRVirtualizationContext context, InputStream in)
protected VirtualizationOutput
createOutput(JRVirtualizationContext context, OutputStream out)
int
getClassDescriptorIdx(Class<?> clazz)
Class<?>
getClassForDescriptorIdx(int descriptorIdx)
int
getClassloaderIdx(Class<?> clazz)
protected static boolean
isAncestorClassLoader(ClassLoader loader)
Class<?>
resolveClass(ObjectStreamClass desc, int loaderIdx)
-
Methods inherited from class net.sf.jasperreports.engine.util.VirtualizationSerializer
readData, readData, writeData, writeData
-
-
-
-
Field Detail
-
CLASSLOADER_IDX_NOT_SET
protected static final int CLASSLOADER_IDX_NOT_SET
- See Also:
- Constant Field Values
-
classLoaderIndex
protected final AtomicInteger classLoaderIndex
-
classLoadersIndexes
protected final ConcurrentMap<ClassLoader,Integer> classLoadersIndexes
-
classLoaders
protected final ConcurrentMap<Integer,ClassLoader> classLoaders
-
classIndex
protected final AtomicInteger classIndex
-
classIndexes
protected final ConcurrentMap<Class<?>,Integer> classIndexes
-
classes
protected final ConcurrentMap<Integer,Class<?>> classes
-
-
Method Detail
-
isAncestorClassLoader
protected static boolean isAncestorClassLoader(ClassLoader loader)
-
getClassloaderIdx
public int getClassloaderIdx(Class<?> clazz)
-
resolveClass
public Class<?> resolveClass(ObjectStreamClass desc, int loaderIdx) throws ClassNotFoundException
- Throws:
ClassNotFoundException
-
getClassDescriptorIdx
public int getClassDescriptorIdx(Class<?> clazz)
-
getClassForDescriptorIdx
public Class<?> getClassForDescriptorIdx(int descriptorIdx)
-
createOutput
protected VirtualizationOutput createOutput(JRVirtualizationContext context, OutputStream out) throws IOException
- Specified by:
createOutput
in classVirtualizationSerializer
- Throws:
IOException
-
createInput
protected VirtualizationInput createInput(JRVirtualizationContext context, InputStream in) throws IOException
- Specified by:
createInput
in classVirtualizationSerializer
- Throws:
IOException
-
-