kaos.robots.util
Class ActionStatusCallbackImpl

java.lang.Object
  extended by kaos.robots.util.ActionStatusCallbackImpl
All Implemented Interfaces:
ActionStatusCallback, InfoStatusCallback

public class ActionStatusCallbackImpl
extends java.lang.Object
implements ActionStatusCallback


Constructor Summary
ActionStatusCallbackImpl(java.lang.String action)
           
 
Method Summary
 java.lang.String getCompletionStatus()
           
 java.lang.Object getResult()
           
 void onAborted(java.util.Calendar time, java.lang.Object r)
          This method is invoked when the requested action is aborted.
 void onAccepted(java.util.Calendar time, java.lang.Object acceptInfo)
          This method is invoked when the request is accepted by the receiver.
 void onCompleted(java.util.Calendar time, java.lang.Object result)
          This method is invoked upon completion of the request.
 void onRefused(java.util.Calendar time, java.lang.Object r)
          This method is invoked when the request is refused by the receiver.
 void onStarted(java.util.Calendar time, java.lang.Object startInfo)
          This method is invoked when the requested action starts.
 void reset()
          Reset callback settings.
 void setResult(java.lang.Object result)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ActionStatusCallbackImpl

public ActionStatusCallbackImpl(java.lang.String action)
Method Detail

onAccepted

public void onAccepted(java.util.Calendar time,
                       java.lang.Object acceptInfo)
This method is invoked when the request is accepted by the receiver.

Specified by:
onAccepted in interface InfoStatusCallback
Parameters:
time - Calendar time of acceptance.
acceptInfo - Object containing additional (optional) info about the acceptance.

onRefused

public void onRefused(java.util.Calendar time,
                      java.lang.Object r)
This method is invoked when the request is refused by the receiver.

Specified by:
onRefused in interface InfoStatusCallback
Parameters:
time - Calendar time of refusal.
reason - Object containing the reason for refusing the request.

onStarted

public void onStarted(java.util.Calendar time,
                      java.lang.Object startInfo)
This method is invoked when the requested action starts.

Specified by:
onStarted in interface ActionStatusCallback
Parameters:
time - Calendar time of starting an action.
startInfo - Object containing additional (optional) info about the start of the action.

onCompleted

public void onCompleted(java.util.Calendar time,
                        java.lang.Object result)
This method is invoked upon completion of the request.

Specified by:
onCompleted in interface InfoStatusCallback
Parameters:
time - Calendar time of information/action completion.
result - Object containing the result of the requested action.

onAborted

public void onAborted(java.util.Calendar time,
                      java.lang.Object r)
This method is invoked when the requested action is aborted.

Specified by:
onAborted in interface ActionStatusCallback
Parameters:
time - Calendar time of aborting an action.
reason - Object containing the reason for aborting an action.

setResult

public void setResult(java.lang.Object result)

getResult

public java.lang.Object getResult()

getCompletionStatus

public java.lang.String getCompletionStatus()

reset

public void reset()
Description copied from interface: InfoStatusCallback
Reset callback settings.

Specified by:
reset in interface InfoStatusCallback