|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.kuka.roboticsAPI.controllerModel.ControllerService
com.kuka.roboticsAPI.controllerModel.RequestService
public abstract class RequestService
A request service is a part of a controller. Each controller must implement it's own request service.
This service must be able to handle given requests. If it cannot handle a request (because it does not know it's type) it must leave the request untouched. The more requests this service can handle, the better the integration within the RoboticsAPI.
| Constructor Summary | |
|---|---|
RequestService()
|
|
| Method Summary | |
|---|---|
protected void |
initialize()
Initializes this service. |
protected void |
onPerformRequest(IRequest request)
Default handling inside the concrete request service. |
Object |
performRequest(IRequest request)
Performs the given request. |
void |
register(IRequestHandler handler)
Registers a new handler for a request type on the service. |
void |
unregister(IRequestHandler handler)
Unregisters the request handler. |
| Methods inherited from class com.kuka.roboticsAPI.controllerModel.ControllerService |
|---|
dispose, getContext, getController |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public RequestService()
| Method Detail |
|---|
protected void initialize()
ControllerServicePlease note that when the method is called, the controller of the service is not yet initialized. This means that there are no guarantees that the controller is operable.
initialize in class ControllerServiceprotected void onPerformRequest(IRequest request)
Note that the base implementation does nothing with the request.
request - The request which should be performed. Will never be null.public void register(IRequestHandler handler)
The handler will get called when a request of a type supported by the handler is issued to the service and it has no default handler for the request type.
handler - The handler.public void unregister(IRequestHandler handler)
handler - The handler.public Object performRequest(IRequest request)
request - The request which should be performed by this service. null is not allowed.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||