org.apache.axis2.clientapi
Class Callback

java.lang.Object
  extended byorg.apache.axis2.clientapi.Callback
Direct Known Subclasses:
InOutMEPClient.SyncCallBack

public abstract class Callback
extends java.lang.Object

This Class is the abstract representation of the Callback that would be called in the completion of a Async invocation


Constructor Summary
Callback()
           
 
Method Summary
 boolean isComplete()
          This says has the Async Operation is completed or not.
abstract  void onComplete(AsyncResult result)
          This Method is called by Axis2 once the Async Operation is sucessfully completed and the result returns
abstract  void reportError(java.lang.Exception e)
          This Method is called by Axis2 once the Async Operation fails and the result returns
 void setComplete(boolean complete)
          Method setComplete
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Callback

public Callback()
Method Detail

onComplete

public abstract void onComplete(AsyncResult result)
This Method is called by Axis2 once the Async Operation is sucessfully completed and the result returns

Parameters:
result -

reportError

public abstract void reportError(java.lang.Exception e)
This Method is called by Axis2 once the Async Operation fails and the result returns

Parameters:
e -

isComplete

public boolean isComplete()
This says has the Async Operation is completed or not. this could be useful for poleing with a special callback written for poleing (checking repeatedly time to time). e.g.
          while(!callback.isComplete()){
             Thread.sleep(1000);
          }
          do whatever u need to do
      

Returns:

setComplete

public void setComplete(boolean complete)
Method setComplete

Parameters:
complete -