Package wt.feedback
Class WTContextUpdate
java.lang.Object
wt.feedback.WTContextUpdate
- All Implemented Interfaces:
Externalizable,Serializable,MethodFeedback
Feedback object to carry updates to client's
WTContext object.
This class can be used by server-side methods to push updates to a client's
WTContext as a side effect of performing an operation.
For example, if some client-side classes use the WTContext object to cache
frequently used objects, server-side operations that change these objects can automatically
push new values into the client's WTContext object. This is useful if the
currently executing method does not normally carry such updated objects as part of its
return value.
Supported API: true
Extendable: true
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionPublic no-arg constructor required by Externalizable.WTContextUpdate(Object key, Object value) Construct a newWTContextUpdateobject. -
Method Summary
Modifier and TypeMethodDescriptionvoidexecute()Perform feedback operation in client.voidreadExternal(ObjectInput input_stream) Called during marshaling on the client side.voidwriteExternal(ObjectOutput output_stream) Called during marshaling on the server side.
-
Constructor Details
-
WTContextUpdate
public WTContextUpdate()Public no-arg constructor required by Externalizable. This constructor is only used on the client-side when receiving the object.
Supported API: true -
WTContextUpdate
Construct a newWTContextUpdateobject.
Supported API: true- Parameters:
key- the hashtable keyvalue- the value
-
-
Method Details
-
execute
public void execute()Perform feedback operation in client. This method is automatically invoked when the feedback is received in the client's RMI reply marshalling stream. It has the effect of putting this objects key and value into the current thread'sWTContextobject.
Supported API: true- Specified by:
executein interfaceMethodFeedback
-
readExternal
Called during marshaling on the client side.
Supported API: true- Specified by:
readExternalin interfaceExternalizable- Throws:
IOExceptionClassNotFoundException
-
writeExternal
Called during marshaling on the server side.
Supported API: true- Specified by:
writeExternalin interfaceExternalizable- Throws:
IOException
-