|
Marshalling API version 1.0.0.Beta1 | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface ClassResolver
A class annotater and resolver. Instances of this interface have the opportunity
to append information (such as classloader information, or class bytes) to a written
class descriptor. This information can then be used on unmarshalling to aid in the
selection (or creation) of the proper Class
based on the class descriptor and
the annotation data.
Method Summary | |
---|---|
void |
annotateClass(Marshaller marshaller,
Class<?> clazz)
Add optional information about a class to a stream. |
void |
annotateProxyClass(Marshaller marshaller,
Class<?> proxyClass)
Add optional information about a proxy class to a stream. |
Class<?> |
resolveClass(Unmarshaller unmarshaller,
String name,
long serialVersionUID)
Load the local class for a class descriptor. |
Class<?> |
resolveProxyClass(Unmarshaller unmarshaller,
String[] interfaces)
Load a proxy class that implements the given interfaces. |
Method Detail |
---|
void annotateClass(Marshaller marshaller, Class<?> clazz) throws IOException
marshaller
- the marshaller to write toclazz
- the class that was written
IOException
- if an error occursObjectOutputStream.annotateClass(Class)
void annotateProxyClass(Marshaller marshaller, Class<?> proxyClass) throws IOException
marshaller
- the marshaller to write toproxyClass
- the chass that was written
IOException
- if an error occursObjectOutputStream.annotateProxyClass(Class)
Class<?> resolveClass(Unmarshaller unmarshaller, String name, long serialVersionUID) throws IOException, ClassNotFoundException
annotateClass(Marshaller, Class)
should be read by this method.
unmarshaller
- the unmarshaller from which to read annotation data, if anyname
- the class nameserialVersionUID
- the serial version UID
IOException
- if an I/O error occurs
ClassNotFoundException
- if the class could not be loadedObjectInputStream.resolveClass(java.io.ObjectStreamClass)
Class<?> resolveProxyClass(Unmarshaller unmarshaller, String[] interfaces) throws IOException, ClassNotFoundException
unmarshaller
- the unmarshaller from which to read annotation data, if anyinterfaces
- the class descriptor
IOException
- if an I/O error occurs
ClassNotFoundException
- if the proxy class could not be loadedObjectInputStream.resolveProxyClass(String[])
|
Marshalling API version 1.0.0.Beta1 | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |