Class DefaultCompositeApiClient
java.lang.Object
org.apache.camel.support.service.BaseService
org.apache.camel.support.service.ServiceSupport
org.apache.camel.component.salesforce.internal.client.AbstractClientBase
org.apache.camel.component.salesforce.internal.client.DefaultCompositeApiClient
- All Implemented Interfaces:
AutoCloseable,CompositeApiClient,HttpClientHolder,SalesforceSession.SalesforceSessionListener,org.apache.camel.Service,org.apache.camel.ShutdownableService,org.apache.camel.StatefulService,org.apache.camel.SuspendableService
-
Nested Class Summary
Nested classes/interfaces inherited from class org.apache.camel.component.salesforce.internal.client.AbstractClientBase
AbstractClientBase.ClientResponseCallbackNested classes/interfaces inherited from interface org.apache.camel.component.salesforce.internal.client.CompositeApiClient
CompositeApiClient.Operation<T,R>, CompositeApiClient.ResponseCallback<T> -
Field Summary
Fields inherited from class org.apache.camel.component.salesforce.internal.client.AbstractClientBase
accessToken, APPLICATION_JSON_UTF8, APPLICATION_XML_UTF8, httpClient, instanceUrl, log, loginConfig, session, versionFields inherited from class org.apache.camel.support.service.BaseService
BUILT, FAILED, INITIALIZED, INITIALIZING, lock, NEW, SHUTDOWN, SHUTTING_DOWN, STARTED, STARTING, status, STOPPED, STOPPING, SUSPENDED, SUSPENDING -
Constructor Summary
ConstructorsConstructorDescriptionDefaultCompositeApiClient(SalesforceEndpointConfig configuration, String version, SalesforceSession session, SalesforceHttpClient httpClient, SalesforceLoginConfig loginConfig) -
Method Summary
Modifier and TypeMethodDescriptionprotected voidsetAccessToken(org.eclipse.jetty.client.Request request) voidsubmitComposite(SObjectComposite composite, Map<String, List<String>> headers, CompositeApiClient.ResponseCallback<SObjectCompositeResponse> callback) voidsubmitCompositeBatch(SObjectBatch batch, Map<String, List<String>> headers, CompositeApiClient.ResponseCallback<SObjectBatchResponse> callback) voidsubmitCompositeRaw(InputStream raw, Map<String, List<String>> headers, CompositeApiClient.ResponseCallback<InputStream> callback, String compositeMethod) voidsubmitCompositeTree(SObjectTree tree, Map<String, List<String>> headers, CompositeApiClient.ResponseCallback<SObjectTreeResponse> callback) Submits given nodes (records) of SObjects and their children as a tree in a single request.Methods inherited from class org.apache.camel.component.salesforce.internal.client.AbstractClientBase
createRestException, doHttpRequest, doStart, doStop, getHttpClient, getRequest, getRequest, onLogin, onLogout, setAccessToken, setInstanceUrlMethods inherited from class org.apache.camel.support.service.BaseService
build, doBuild, doFail, doInit, doLifecycleChange, doResume, doShutdown, doSuspend, fail, getStatus, init, isBuild, isInit, isNew, isRunAllowed, isShutdown, isStarted, isStarting, isStartingOrStarted, isStopped, isStopping, isStoppingOrStopped, isSuspended, isSuspending, isSuspendingOrSuspended, resume, shutdown, start, stop, suspendMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.apache.camel.Service
build, close, init, start, stopMethods inherited from interface org.apache.camel.ShutdownableService
shutdownMethods inherited from interface org.apache.camel.StatefulService
getStatus, isRunAllowed, isStarted, isStarting, isStopped, isStopping, isSuspendingMethods inherited from interface org.apache.camel.SuspendableService
isSuspended, resume, suspend
-
Constructor Details
-
DefaultCompositeApiClient
public DefaultCompositeApiClient(SalesforceEndpointConfig configuration, String version, SalesforceSession session, SalesforceHttpClient httpClient, SalesforceLoginConfig loginConfig) throws SalesforceException - Throws:
SalesforceException
-
-
Method Details
-
submitCompositeRaw
public void submitCompositeRaw(InputStream raw, Map<String, List<String>> headers, CompositeApiClient.ResponseCallback<InputStream> callback, String compositeMethod) throws SalesforceException- Specified by:
submitCompositeRawin interfaceCompositeApiClient- Throws:
SalesforceException
-
submitComposite
public void submitComposite(SObjectComposite composite, Map<String, List<String>> headers, CompositeApiClient.ResponseCallback<SObjectCompositeResponse> callback) throws SalesforceException- Specified by:
submitCompositein interfaceCompositeApiClient- Throws:
SalesforceException
-
submitCompositeBatch
public void submitCompositeBatch(SObjectBatch batch, Map<String, List<String>> headers, CompositeApiClient.ResponseCallback<SObjectBatchResponse> callback) throws SalesforceException- Specified by:
submitCompositeBatchin interfaceCompositeApiClient- Throws:
SalesforceException
-
submitCompositeTree
public void submitCompositeTree(SObjectTree tree, Map<String, List<String>> headers, CompositeApiClient.ResponseCallback<SObjectTreeResponse> callback) throws SalesforceExceptionDescription copied from interface:CompositeApiClientSubmits given nodes (records) of SObjects and their children as a tree in a single request. And updates theIdparameter of each object to the value returned from the API call.- Specified by:
submitCompositeTreein interfaceCompositeApiClient- Parameters:
tree- SObject tree to submitcallback-CompositeApiClient.ResponseCallbackto handle response or exception- Throws:
SalesforceException
-
setAccessToken
protected void setAccessToken(org.eclipse.jetty.client.Request request) - Specified by:
setAccessTokenin classAbstractClientBase
-