Package com.ibm.ws.serialization
Interface DeserializationObjectResolver
-
public interface DeserializationObjectResolver
Allows resolving objects after deserialization. Typical scenarios are:- A bundle wants to allow an object to be serialized normally, but needs to modify the state of the object after deserialization (for example, to reconnect a serialized Stub).
- A bundle needs to deserialize an object specific to the context in which
it is being deserialized (for example, an EJBContext). In this case, the
bundle should typically use
SerializationContext.addObjectReplacer(com.ibm.ws.serialization.SerializationObjectReplacer)
to add a custom serialized form, andDeserializationContext.addObjectResolver(com.ibm.ws.serialization.DeserializationObjectResolver)
to recognize the object and return a context-specific object. Note that the class of the serialized form will typically need to be made visible viaDeserializationClassProvider
.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description java.lang.Object
resolveObject(java.lang.Object object)
Resolves an object after deserialization.
-
-
-
Method Detail
-
resolveObject
java.lang.Object resolveObject(java.lang.Object object) throws java.io.IOException
Resolves an object after deserialization. If the implementation does not recognize the object then null should be returned.Implementations are strongly encouraged to annotate the parameter with
Sensitive
to avoid tracing user data.- Parameters:
object
- the object being resolved- Returns:
- the resolved object, or null if no resolution is needed
- Throws:
java.io.IOException
- if an error occurs resolving the object
-
-