Top Fields Constructors Methods
org.jboss.marshalling

pack-priv final Class TransformingClassResolver

extends Object
implements ClassResolver
Class Inheritance
All Implemented Interfaces
org.jboss.marshalling.ClassResolver
Imports
java.io.IOException

Author
Richard Opalka

Field Summary

Modifier and TypeField and Description
private final ClassResolver
private final boolean
private final ClassNameTransformer

Constructor Summary

AccessConstructor and Description
pack-priv
TransformingClassResolver(final ClassResolver delegate, final ClassNameTransformer transformer, final boolean in)

Method Summary

Modifier and TypeMethod and Description
public void
annotateClass(final Marshaller
the marshaller to write to
marshaller
,
final Class<?>
the class that was written
clazz
)

Implements org.jboss.marshalling.ClassResolver.annotateClass.

Add optional information about a class to a stream.
public void
annotateProxyClass(final Marshaller
the marshaller to write to
marshaller
,
final Class<?>
the class that was written
proxyClass
)

Implements org.jboss.marshalling.ClassResolver.annotateProxyClass.

Add optional information about a proxy class to a stream.
public String
getClassName(final Class<?>
the class
clazz
)

Implements org.jboss.marshalling.ClassResolver.getClassName.

Get the class name to write for a given class.
public String[]
getProxyInterfaces(final Class<?>
the proxy class
proxyClass
)

Implements org.jboss.marshalling.ClassResolver.getProxyInterfaces.

Get the interface names to write for a given proxy class.
public Class<?>
resolveClass(final Unmarshaller
the unmarshaller from which to read annotation data, if any
unmarshaller
,
final String
the class name
name
,
final long
the serial version UID
serialVersionUID
)

Implements org.jboss.marshalling.ClassResolver.resolveClass.

Load the local class for a class descriptor.
public Class<?>
resolveProxyClass(final Unmarshaller
the unmarshaller from which to read annotation data, if any
unmarshaller
,
final String[]
the class descriptor
interfaces
)

Implements org.jboss.marshalling.ClassResolver.resolveProxyClass.

Load a proxy class that implements the given interfaces.
private String
translate(final String className)

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

delegateback to summary
private final ClassResolver delegate
inback to summary
private final boolean in
transformerback to summary
private final ClassNameTransformer transformer

Constructor Detail

TransformingClassResolverback to summary
pack-priv TransformingClassResolver(final ClassResolver delegate, final ClassNameTransformer transformer, final boolean in)

Method Detail

annotateClassback to summary
public void annotateClass(final Marshaller marshaller, final Class<?> clazz) throws IOException

Implements org.jboss.marshalling.ClassResolver.annotateClass.

Doc from org.jboss.marshalling.ClassResolver.annotateClass.

Add optional information about a class to a stream. The class descriptor will already have been written.

Parameters
marshaller:Marshaller

the marshaller to write to

clazz:Class<?>

the class that was written

Annotations
@Override
Exceptions
IOException:
if an error occurs
annotateProxyClassback to summary
public void annotateProxyClass(final Marshaller marshaller, final Class<?> proxyClass) throws IOException

Implements org.jboss.marshalling.ClassResolver.annotateProxyClass.

Doc from org.jboss.marshalling.ClassResolver.annotateProxyClass.

Add optional information about a proxy class to a stream. The class descriptor will already have been written.

Parameters
marshaller:Marshaller

the marshaller to write to

proxyClass:Class<?>

the class that was written

Annotations
@Override
Exceptions
IOException:
if an error occurs
getClassNameback to summary
public String getClassName(final Class<?> clazz) throws IOException

Implements org.jboss.marshalling.ClassResolver.getClassName.

Doc from org.jboss.marshalling.ClassResolver.getClassName.

Get the class name to write for a given class. The class name will be written as part of the class descriptor.

Parameters
clazz:Class<?>

the class

Returns:String

the class name

Annotations
@Override
Exceptions
IOException:
if an error occurs
getProxyInterfacesback to summary
public String[] getProxyInterfaces(final Class<?> proxyClass) throws IOException

Implements org.jboss.marshalling.ClassResolver.getProxyInterfaces.

Doc from org.jboss.marshalling.ClassResolver.getProxyInterfaces.

Get the interface names to write for a given proxy class. The interface names will be written as part of the class descriptor.

Parameters
proxyClass:Class<?>

the proxy class

Returns:String[]

the proxy class interface names

Annotations
@Override
Exceptions
IOException:
if an error occurs
resolveClassback to summary
public Class<?> resolveClass(final Unmarshaller unmarshaller, final String name, final long serialVersionUID) throws IOException, ClassNotFoundException

Implements org.jboss.marshalling.ClassResolver.resolveClass.

Doc from org.jboss.marshalling.ClassResolver.resolveClass.

Load the local class for a class descriptor. The class descriptor has already been read, but any data written by annotateClass(Marshaller, Class) should be read by this method.

Parameters
unmarshaller:Unmarshaller

the unmarshaller from which to read annotation data, if any

name:String

the class name

serialVersionUID:long

the serial version UID

Returns:Class<?>

the corresponding class

Annotations
@Override
Exceptions
IOException:
if an I/O error occurs
ClassNotFoundException:
if the class could not be loaded
resolveProxyClassback to summary
public Class<?> resolveProxyClass(final Unmarshaller unmarshaller, final String[] interfaces) throws IOException, ClassNotFoundException

Implements org.jboss.marshalling.ClassResolver.resolveProxyClass.

Doc from org.jboss.marshalling.ClassResolver.resolveProxyClass.

Load a proxy class that implements the given interfaces.

Parameters
unmarshaller:Unmarshaller

the unmarshaller from which to read annotation data, if any

interfaces:String[]

the class descriptor

Returns:Class<?>

the proxy class

Annotations
@Override
Exceptions
IOException:
if an I/O error occurs
ClassNotFoundException:
if the proxy class could not be loaded
translateback to summary
private String translate(final String className)