org.apache.camel.component.salesforce.internal.client
Class SyncResponseCallback

java.lang.Object
  extended by org.apache.camel.component.salesforce.internal.client.SyncResponseCallback
All Implemented Interfaces:
RestClient.ResponseCallback

public class SyncResponseCallback
extends Object
implements RestClient.ResponseCallback

Thin wrapper to handle callbacks for RestClient.ResponseCallback and allow waiting for results


Constructor Summary
SyncResponseCallback()
           
 
Method Summary
 boolean await(long duration, TimeUnit unit)
           
 SalesforceException getException()
           
 InputStream getResponse()
           
 void onResponse(InputStream response, SalesforceException exception)
           
 void reset()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SyncResponseCallback

public SyncResponseCallback()
Method Detail

onResponse

public void onResponse(InputStream response,
                       SalesforceException exception)
Specified by:
onResponse in interface RestClient.ResponseCallback

reset

public void reset()

await

public boolean await(long duration,
                     TimeUnit unit)
              throws InterruptedException
Throws:
InterruptedException

getResponse

public InputStream getResponse()

getException

public SalesforceException getException()


Apache Camel