Package org.eclipse.rap.rwt.remote
Class AbstractOperationHandler
- java.lang.Object
-
- org.eclipse.rap.rwt.remote.AbstractOperationHandler
-
- All Implemented Interfaces:
java.io.Serializable,OperationHandler
public abstract class AbstractOperationHandler extends java.lang.Object implements OperationHandler, java.io.Serializable
This class provides an empty implementation of theOperationHandlerinterface, to minimize the effort required to implement this interface.Subclasses only need to override those methods that are needed to handle the expected operations for the corresponding remote type. Methods that are not overridden will throw an
UnsupportedOperationException.It is recommended to extend this base class rather than to implement the OperationHandler interface itself.
- Since:
- 2.0
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description AbstractOperationHandler()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidhandleCall(java.lang.String method, JsonObject parameters)Handles a call operation from the remote object.voidhandleNotify(java.lang.String event, JsonObject properties)Handles a notify operation from the remote object.voidhandleSet(JsonObject properties)Handles a set operation from the remote object.
-
-
-
Method Detail
-
handleSet
public void handleSet(JsonObject properties)
Description copied from interface:OperationHandlerHandles a set operation from the remote object. With a set operation, the remote object informs the receiver that one or more properties have changed their values. The implementation of this method must apply the new property values to the target object in a suitable order.- Specified by:
handleSetin interfaceOperationHandler- Parameters:
properties- a map with the properties- Since:
- 2.1
-
handleCall
public void handleCall(java.lang.String method, JsonObject parameters)Description copied from interface:OperationHandlerHandles a call operation from the remote object. With a call operation, the remote object instructs the receiver to call a method on the target object. The method call may be parameterized with the given properties.- Specified by:
handleCallin interfaceOperationHandler- Parameters:
method- the name of the method to callparameters- the parameters for the method call, may be empty but nevernull- Since:
- 2.1
-
handleNotify
public void handleNotify(java.lang.String event, JsonObject properties)Description copied from interface:OperationHandlerHandles a notify operation from the remote object. With a notify operation, the remote object notifies the receiver that an event has occurred. An implementation of this method must notify the corresponding listeners attached to the target object.- Specified by:
handleNotifyin interfaceOperationHandler- Parameters:
event- the name of the event that occurredproperties- the event properties, may be empty but nevernull- Since:
- 2.1
-
-