com.ibm.bpe.api

Class ReplyContextWrapper

  1. java.lang.Object
  2. extended bycom.ibm.bpe.api.ReplyContextWrapper
All implemented interfaces:
java.io.Serializable, java.lang.Cloneable

  1. public final class ReplyContextWrapper
  2. extends java.lang.Object
  3. implements java.io.Serializable, java.lang.Cloneable
Wraps the reply context passed to the process engine.

When the process engine is accessed through its EJB interface:

The ReplyContextWrapper class defers deserialization until the wrapped ReplyContext is accessed. This allows the process engine to set the appropriate class loader.
Since:
5.0
See Also:
Serialized Form

Field Summary

Modifier and Type Field and Description
  1. static
  2. java.lang.String
COPYRIGHT

Constructor Summary

Constructor and Description
ReplyContextWrapper()
Default constructor needed by deserialization.
ReplyContextWrapper(byte[] buffer)
Constructor that stores the passed serialized object.
ReplyContextWrapper(ReplyContext object)
Constructor that stores the passed object.

Method Summary

Modifier and Type Method and Description
  1. java.lang.Object
clone()
Creates and returns a copy of this object.
  1. static
  2. ReplyContextWrapper
fromByteArray(byte[] buffer)
Factory method that creates a ReplyContextWrapper from a byte array.
  1. ReplyContext
getObject()
Returns the wrapped object.
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

Field Detail

  1. public static final java.lang.String COPYRIGHT
See Also:

Constructor Detail

ReplyContextWrapper

  1. public ReplyContextWrapper()
Default constructor needed by deserialization. Sets the wrapped object to null.

ReplyContextWrapper

  1. public ReplyContextWrapper(ReplyContext object)
Constructor that stores the passed object.
Parameters:
object - The object to wrap. When the ReplyContextWrapper object is used as an EJB parameter or as an EJB return value, then object must implement java.io.Serializable.

ReplyContextWrapper

  1. public ReplyContextWrapper(byte[] buffer)
Constructor that stores the passed serialized object.
Parameters:
buffer - The object to wrap. When the ReplyContextWrapper object is used as an EJB parameter or as an EJB return value, then object must implement java.io.Serializable.

Method Detail

fromByteArray

  1. public static ReplyContextWrapper fromByteArray( byte[] buffer)
Factory method that creates a ReplyContextWrapper from a byte array. The constructor taking a byte array as parameter is private because it is ambiguous (arrays are also objects).
Parameters:
buffer - The serialized object to wrap.
Returns:
A ReplyContextWrapper object.

getObject

  1. public ReplyContext getObject()
  2. throws ProcessException
Returns the wrapped object.

If the ReplyContextWrapper object has been serialized, then deserialized and this is the first time the wrapped object is accessed, the wrapped object is deserialized before it is returned. If the ReplyContextWrapper has never been serialized, or the wrapped object has been accessed before, the wrapped object is returned without deserialization.

Returns:
The wrapped object.
Throws:
ProcessException - if an error occurrs during deserialization of the object.

clone

  1. public java.lang.Object clone()
  2. throws java.lang.CloneNotSupportedException
Creates and returns a copy of this object.

The meaning of "copy" depends on the class of the object. Generally, for any object x, the expression:

 x.clone() != x
is true, and the expression:
 x.clone().getClass() == x.getClass()
is true.

Overrides:
clone in class java.lang.Object
Returns:
A clone of this object.
Throws:
java.lang.CloneNotSupportedException - if the object's class does not support the Cloneable interface.
See Also: