com.amazonaws.services.simpleemail.AmazonSimpleEmailServiceAsyncClient Maven / Gradle / Ivy
Show all versions of aws-java-sdk-ses Show documentation
/*
* Copyright 2019-2024 Amazon.com, Inc. or its affiliates. All Rights Reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License"). You may not use this file except in compliance with
* the License. A copy of the License is located at
*
* http://aws.amazon.com/apache2.0
*
* or in the "license" file accompanying this file. This file is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
* CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions
* and limitations under the License.
*/
package com.amazonaws.services.simpleemail;
import static java.util.concurrent.Executors.newFixedThreadPool;
import javax.annotation.Generated;
import com.amazonaws.services.simpleemail.model.*;
import com.amazonaws.client.AwsAsyncClientParams;
import com.amazonaws.annotation.ThreadSafe;
import com.amazonaws.ClientConfiguration;
import com.amazonaws.auth.AWSCredentials;
import com.amazonaws.auth.AWSCredentialsProvider;
import java.util.concurrent.ExecutorService;
import com.amazonaws.auth.DefaultAWSCredentialsProviderChain;
/**
* Client for accessing Amazon SES asynchronously. Each asynchronous method will return a Java Future object
* representing the asynchronous operation; overloads which accept an {@code AsyncHandler} can be used to receive
* notification when an asynchronous operation completes.
*
* Amazon Simple Email Service
*
* This document contains reference information for the Amazon Simple Email
* Service (Amazon SES) API, version 2010-12-01. This document is best used in conjunction with the Amazon SES Developer Guide.
*
*
*
* For a list of Amazon SES endpoints to use in service requests, see Regions and Amazon SES in the Amazon SES Developer Guide.
*
*
*
* This documentation contains reference information related to the following:
*
*
* -
*
*
* -
*
*
* -
*
*
* -
*
* Common Errors
*
*
*
*/
@ThreadSafe
@Generated("com.amazonaws:aws-java-sdk-code-generator")
public class AmazonSimpleEmailServiceAsyncClient extends AmazonSimpleEmailServiceClient implements AmazonSimpleEmailServiceAsync {
private static final int DEFAULT_THREAD_POOL_SIZE = 50;
private final java.util.concurrent.ExecutorService executorService;
/**
* Constructs a new asynchronous client to invoke service methods on Amazon SES. A credentials provider chain will
* be used that searches for credentials in this order:
*
* - Environment Variables - AWS_ACCESS_KEY_ID and AWS_SECRET_KEY
* - Java System Properties - aws.accessKeyId and aws.secretKey
* - Credential profiles file at the default location (~/.aws/credentials) shared by all AWS SDKs and the AWS CLI
* - Instance profile credentials delivered through the Amazon EC2 metadata service
*
*
* Asynchronous methods are delegated to a fixed-size thread pool containing 50 threads (to match the default
* maximum number of concurrent connections to the service).
*
* @see com.amazonaws.auth.DefaultAWSCredentialsProviderChain
* @see java.util.concurrent.Executors#newFixedThreadPool(int)
* @deprecated use {@link AmazonSimpleEmailServiceAsyncClientBuilder#defaultClient()}
*/
@Deprecated
public AmazonSimpleEmailServiceAsyncClient() {
this(DefaultAWSCredentialsProviderChain.getInstance());
}
/**
* Constructs a new asynchronous client to invoke service methods on Amazon SES. A credentials provider chain will
* be used that searches for credentials in this order:
*
* - Environment Variables - AWS_ACCESS_KEY_ID and AWS_SECRET_KEY
* - Java System Properties - aws.accessKeyId and aws.secretKey
* - Credential profiles file at the default location (~/.aws/credentials) shared by all AWS SDKs and the AWS CLI
* - Instance profile credentials delivered through the Amazon EC2 metadata service
*
*
* Asynchronous methods are delegated to a fixed-size thread pool containing a number of threads equal to the
* maximum number of concurrent connections configured via {@code ClientConfiguration.getMaxConnections()}.
*
* @param clientConfiguration
* The client configuration options controlling how this client connects to Amazon SES (ex: proxy settings,
* retry counts, etc).
*
* @see com.amazonaws.auth.DefaultAWSCredentialsProviderChain
* @see java.util.concurrent.Executors#newFixedThreadPool(int)
* @deprecated use {@link AmazonSimpleEmailServiceAsyncClientBuilder#withClientConfiguration(ClientConfiguration)}
*/
@Deprecated
public AmazonSimpleEmailServiceAsyncClient(ClientConfiguration clientConfiguration) {
this(DefaultAWSCredentialsProviderChain.getInstance(), clientConfiguration, newFixedThreadPool(clientConfiguration.getMaxConnections()));
}
/**
* Constructs a new asynchronous client to invoke service methods on Amazon SES using the specified AWS account
* credentials.
*
* Asynchronous methods are delegated to a fixed-size thread pool containing 50 threads (to match the default
* maximum number of concurrent connections to the service).
*
* @param awsCredentials
* The AWS credentials (access key ID and secret key) to use when authenticating with AWS services.
* @see java.util.concurrent.Executors#newFixedThreadPool(int)
* @deprecated use {@link AmazonSimpleEmailServiceAsyncClientBuilder#withCredentials(AWSCredentialsProvider)}
*/
@Deprecated
public AmazonSimpleEmailServiceAsyncClient(AWSCredentials awsCredentials) {
this(awsCredentials, newFixedThreadPool(DEFAULT_THREAD_POOL_SIZE));
}
/**
* Constructs a new asynchronous client to invoke service methods on Amazon SES using the specified AWS account
* credentials and executor service. Default client settings will be used.
*
* @param awsCredentials
* The AWS credentials (access key ID and secret key) to use when authenticating with AWS services.
* @param executorService
* The executor service by which all asynchronous requests will be executed.
* @deprecated use {@link AmazonSimpleEmailServiceAsyncClientBuilder#withCredentials(AWSCredentialsProvider)} and
* {@link AmazonSimpleEmailServiceAsyncClientBuilder#withExecutorFactory(com.amazonaws.client.builder.ExecutorFactory)}
*/
@Deprecated
public AmazonSimpleEmailServiceAsyncClient(AWSCredentials awsCredentials, ExecutorService executorService) {
this(awsCredentials, configFactory.getConfig(), executorService);
}
/**
* Constructs a new asynchronous client to invoke service methods on Amazon SES using the specified AWS account
* credentials, executor service, and client configuration options.
*
* @param awsCredentials
* The AWS credentials (access key ID and secret key) to use when authenticating with AWS services.
* @param clientConfiguration
* Client configuration options (ex: max retry limit, proxy settings, etc).
* @param executorService
* The executor service by which all asynchronous requests will be executed.
* @deprecated use {@link AmazonSimpleEmailServiceAsyncClientBuilder#withCredentials(AWSCredentialsProvider)} and
* {@link AmazonSimpleEmailServiceAsyncClientBuilder#withClientConfiguration(ClientConfiguration)} and
* {@link AmazonSimpleEmailServiceAsyncClientBuilder#withExecutorFactory(com.amazonaws.client.builder.ExecutorFactory)}
*/
@Deprecated
public AmazonSimpleEmailServiceAsyncClient(AWSCredentials awsCredentials, ClientConfiguration clientConfiguration, ExecutorService executorService) {
super(awsCredentials, clientConfiguration);
this.executorService = executorService;
}
/**
* Constructs a new asynchronous client to invoke service methods on Amazon SES using the specified AWS account
* credentials provider. Default client settings will be used.
*
* Asynchronous methods are delegated to a fixed-size thread pool containing 50 threads (to match the default
* maximum number of concurrent connections to the service).
*
* @param awsCredentialsProvider
* The AWS credentials provider which will provide credentials to authenticate requests with AWS services.
* @see java.util.concurrent.Executors#newFixedThreadPool(int)
* @deprecated use {@link AmazonSimpleEmailServiceAsyncClientBuilder#withCredentials(AWSCredentialsProvider)}
*/
@Deprecated
public AmazonSimpleEmailServiceAsyncClient(AWSCredentialsProvider awsCredentialsProvider) {
this(awsCredentialsProvider, newFixedThreadPool(DEFAULT_THREAD_POOL_SIZE));
}
/**
* Constructs a new asynchronous client to invoke service methods on Amazon SES using the provided AWS account
* credentials provider and client configuration options.
*
* Asynchronous methods are delegated to a fixed-size thread pool containing a number of threads equal to the
* maximum number of concurrent connections configured via {@code ClientConfiguration.getMaxConnections()}.
*
* @param awsCredentialsProvider
* The AWS credentials provider which will provide credentials to authenticate requests with AWS services.
* @param clientConfiguration
* Client configuration options (ex: max retry limit, proxy settings, etc).
*
* @see com.amazonaws.auth.DefaultAWSCredentialsProviderChain
* @see java.util.concurrent.Executors#newFixedThreadPool(int)
* @deprecated use {@link AmazonSimpleEmailServiceAsyncClientBuilder#withCredentials(AWSCredentialsProvider)} and
* {@link AmazonSimpleEmailServiceAsyncClientBuilder#withClientConfiguration(ClientConfiguration)}
*/
@Deprecated
public AmazonSimpleEmailServiceAsyncClient(AWSCredentialsProvider awsCredentialsProvider, ClientConfiguration clientConfiguration) {
this(awsCredentialsProvider, clientConfiguration, newFixedThreadPool(clientConfiguration.getMaxConnections()));
}
/**
* Constructs a new asynchronous client to invoke service methods on Amazon SES using the specified AWS account
* credentials provider and executor service. Default client settings will be used.
*
* @param awsCredentialsProvider
* The AWS credentials provider which will provide credentials to authenticate requests with AWS services.
* @param executorService
* The executor service by which all asynchronous requests will be executed.
* @deprecated use {@link AmazonSimpleEmailServiceAsyncClientBuilder#withCredentials(AWSCredentialsProvider)} and
* {@link AmazonSimpleEmailServiceAsyncClientBuilder#withExecutorFactory(com.amazonaws.client.builder.ExecutorFactory)}
*/
@Deprecated
public AmazonSimpleEmailServiceAsyncClient(AWSCredentialsProvider awsCredentialsProvider, ExecutorService executorService) {
this(awsCredentialsProvider, configFactory.getConfig(), executorService);
}
/**
* Constructs a new asynchronous client to invoke service methods on Amazon SES using the specified AWS account
* credentials provider, executor service, and client configuration options.
*
* @param awsCredentialsProvider
* The AWS credentials provider which will provide credentials to authenticate requests with AWS services.
* @param clientConfiguration
* Client configuration options (ex: max retry limit, proxy settings, etc).
* @param executorService
* The executor service by which all asynchronous requests will be executed.
* @deprecated use {@link AmazonSimpleEmailServiceAsyncClientBuilder#withCredentials(AWSCredentialsProvider)} and
* {@link AmazonSimpleEmailServiceAsyncClientBuilder#withClientConfiguration(ClientConfiguration)} and
* {@link AmazonSimpleEmailServiceAsyncClientBuilder#withExecutorFactory(com.amazonaws.client.builder.ExecutorFactory)}
*/
@Deprecated
public AmazonSimpleEmailServiceAsyncClient(AWSCredentialsProvider awsCredentialsProvider, ClientConfiguration clientConfiguration,
ExecutorService executorService) {
super(awsCredentialsProvider, clientConfiguration);
this.executorService = executorService;
}
public static AmazonSimpleEmailServiceAsyncClientBuilder asyncBuilder() {
return AmazonSimpleEmailServiceAsyncClientBuilder.standard();
}
/**
* Constructs a new asynchronous client to invoke service methods on Amazon SES using the specified parameters.
*
* @param asyncClientParams
* Object providing client parameters.
*/
AmazonSimpleEmailServiceAsyncClient(AwsAsyncClientParams asyncClientParams) {
this(asyncClientParams, false);
}
/**
* Constructs a new asynchronous client to invoke service methods on Amazon SES using the specified parameters.
*
* @param asyncClientParams
* Object providing client parameters.
* @param endpointDiscoveryEnabled
* true will enable endpoint discovery if the service supports it.
*/
AmazonSimpleEmailServiceAsyncClient(AwsAsyncClientParams asyncClientParams, boolean endpointDiscoveryEnabled) {
super(asyncClientParams, endpointDiscoveryEnabled);
this.executorService = asyncClientParams.getExecutor();
}
/**
* Returns the executor service used by this client to execute async requests.
*
* @return The executor service used by this client to execute async requests.
*/
public ExecutorService getExecutorService() {
return executorService;
}
@Override
public java.util.concurrent.Future cloneReceiptRuleSetAsync(CloneReceiptRuleSetRequest request) {
return cloneReceiptRuleSetAsync(request, null);
}
@Override
public java.util.concurrent.Future cloneReceiptRuleSetAsync(final CloneReceiptRuleSetRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final CloneReceiptRuleSetRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public CloneReceiptRuleSetResult call() throws Exception {
CloneReceiptRuleSetResult result = null;
try {
result = executeCloneReceiptRuleSet(finalRequest);
} catch (Exception ex) {
if (asyncHandler != null) {
asyncHandler.onError(ex);
}
throw ex;
}
if (asyncHandler != null) {
asyncHandler.onSuccess(finalRequest, result);
}
return result;
}
});
}
@Override
public java.util.concurrent.Future createConfigurationSetAsync(CreateConfigurationSetRequest request) {
return createConfigurationSetAsync(request, null);
}
@Override
public java.util.concurrent.Future createConfigurationSetAsync(final CreateConfigurationSetRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final CreateConfigurationSetRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public CreateConfigurationSetResult call() throws Exception {
CreateConfigurationSetResult result = null;
try {
result = executeCreateConfigurationSet(finalRequest);
} catch (Exception ex) {
if (asyncHandler != null) {
asyncHandler.onError(ex);
}
throw ex;
}
if (asyncHandler != null) {
asyncHandler.onSuccess(finalRequest, result);
}
return result;
}
});
}
@Override
public java.util.concurrent.Future createConfigurationSetEventDestinationAsync(
CreateConfigurationSetEventDestinationRequest request) {
return createConfigurationSetEventDestinationAsync(request, null);
}
@Override
public java.util.concurrent.Future createConfigurationSetEventDestinationAsync(
final CreateConfigurationSetEventDestinationRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final CreateConfigurationSetEventDestinationRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public CreateConfigurationSetEventDestinationResult call() throws Exception {
CreateConfigurationSetEventDestinationResult result = null;
try {
result = executeCreateConfigurationSetEventDestination(finalRequest);
} catch (Exception ex) {
if (asyncHandler != null) {
asyncHandler.onError(ex);
}
throw ex;
}
if (asyncHandler != null) {
asyncHandler.onSuccess(finalRequest, result);
}
return result;
}
});
}
@Override
public java.util.concurrent.Future createConfigurationSetTrackingOptionsAsync(
CreateConfigurationSetTrackingOptionsRequest request) {
return createConfigurationSetTrackingOptionsAsync(request, null);
}
@Override
public java.util.concurrent.Future createConfigurationSetTrackingOptionsAsync(
final CreateConfigurationSetTrackingOptionsRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final CreateConfigurationSetTrackingOptionsRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public CreateConfigurationSetTrackingOptionsResult call() throws Exception {
CreateConfigurationSetTrackingOptionsResult result = null;
try {
result = executeCreateConfigurationSetTrackingOptions(finalRequest);
} catch (Exception ex) {
if (asyncHandler != null) {
asyncHandler.onError(ex);
}
throw ex;
}
if (asyncHandler != null) {
asyncHandler.onSuccess(finalRequest, result);
}
return result;
}
});
}
@Override
public java.util.concurrent.Future createCustomVerificationEmailTemplateAsync(
CreateCustomVerificationEmailTemplateRequest request) {
return createCustomVerificationEmailTemplateAsync(request, null);
}
@Override
public java.util.concurrent.Future createCustomVerificationEmailTemplateAsync(
final CreateCustomVerificationEmailTemplateRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final CreateCustomVerificationEmailTemplateRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public CreateCustomVerificationEmailTemplateResult call() throws Exception {
CreateCustomVerificationEmailTemplateResult result = null;
try {
result = executeCreateCustomVerificationEmailTemplate(finalRequest);
} catch (Exception ex) {
if (asyncHandler != null) {
asyncHandler.onError(ex);
}
throw ex;
}
if (asyncHandler != null) {
asyncHandler.onSuccess(finalRequest, result);
}
return result;
}
});
}
@Override
public java.util.concurrent.Future createReceiptFilterAsync(CreateReceiptFilterRequest request) {
return createReceiptFilterAsync(request, null);
}
@Override
public java.util.concurrent.Future createReceiptFilterAsync(final CreateReceiptFilterRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final CreateReceiptFilterRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public CreateReceiptFilterResult call() throws Exception {
CreateReceiptFilterResult result = null;
try {
result = executeCreateReceiptFilter(finalRequest);
} catch (Exception ex) {
if (asyncHandler != null) {
asyncHandler.onError(ex);
}
throw ex;
}
if (asyncHandler != null) {
asyncHandler.onSuccess(finalRequest, result);
}
return result;
}
});
}
@Override
public java.util.concurrent.Future createReceiptRuleAsync(CreateReceiptRuleRequest request) {
return createReceiptRuleAsync(request, null);
}
@Override
public java.util.concurrent.Future createReceiptRuleAsync(final CreateReceiptRuleRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final CreateReceiptRuleRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public CreateReceiptRuleResult call() throws Exception {
CreateReceiptRuleResult result = null;
try {
result = executeCreateReceiptRule(finalRequest);
} catch (Exception ex) {
if (asyncHandler != null) {
asyncHandler.onError(ex);
}
throw ex;
}
if (asyncHandler != null) {
asyncHandler.onSuccess(finalRequest, result);
}
return result;
}
});
}
@Override
public java.util.concurrent.Future createReceiptRuleSetAsync(CreateReceiptRuleSetRequest request) {
return createReceiptRuleSetAsync(request, null);
}
@Override
public java.util.concurrent.Future createReceiptRuleSetAsync(final CreateReceiptRuleSetRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final CreateReceiptRuleSetRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public CreateReceiptRuleSetResult call() throws Exception {
CreateReceiptRuleSetResult result = null;
try {
result = executeCreateReceiptRuleSet(finalRequest);
} catch (Exception ex) {
if (asyncHandler != null) {
asyncHandler.onError(ex);
}
throw ex;
}
if (asyncHandler != null) {
asyncHandler.onSuccess(finalRequest, result);
}
return result;
}
});
}
@Override
public java.util.concurrent.Future createTemplateAsync(CreateTemplateRequest request) {
return createTemplateAsync(request, null);
}
@Override
public java.util.concurrent.Future createTemplateAsync(final CreateTemplateRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final CreateTemplateRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public CreateTemplateResult call() throws Exception {
CreateTemplateResult result = null;
try {
result = executeCreateTemplate(finalRequest);
} catch (Exception ex) {
if (asyncHandler != null) {
asyncHandler.onError(ex);
}
throw ex;
}
if (asyncHandler != null) {
asyncHandler.onSuccess(finalRequest, result);
}
return result;
}
});
}
@Override
public java.util.concurrent.Future deleteConfigurationSetAsync(DeleteConfigurationSetRequest request) {
return deleteConfigurationSetAsync(request, null);
}
@Override
public java.util.concurrent.Future deleteConfigurationSetAsync(final DeleteConfigurationSetRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final DeleteConfigurationSetRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public DeleteConfigurationSetResult call() throws Exception {
DeleteConfigurationSetResult result = null;
try {
result = executeDeleteConfigurationSet(finalRequest);
} catch (Exception ex) {
if (asyncHandler != null) {
asyncHandler.onError(ex);
}
throw ex;
}
if (asyncHandler != null) {
asyncHandler.onSuccess(finalRequest, result);
}
return result;
}
});
}
@Override
public java.util.concurrent.Future deleteConfigurationSetEventDestinationAsync(
DeleteConfigurationSetEventDestinationRequest request) {
return deleteConfigurationSetEventDestinationAsync(request, null);
}
@Override
public java.util.concurrent.Future deleteConfigurationSetEventDestinationAsync(
final DeleteConfigurationSetEventDestinationRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final DeleteConfigurationSetEventDestinationRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public DeleteConfigurationSetEventDestinationResult call() throws Exception {
DeleteConfigurationSetEventDestinationResult result = null;
try {
result = executeDeleteConfigurationSetEventDestination(finalRequest);
} catch (Exception ex) {
if (asyncHandler != null) {
asyncHandler.onError(ex);
}
throw ex;
}
if (asyncHandler != null) {
asyncHandler.onSuccess(finalRequest, result);
}
return result;
}
});
}
@Override
public java.util.concurrent.Future deleteConfigurationSetTrackingOptionsAsync(
DeleteConfigurationSetTrackingOptionsRequest request) {
return deleteConfigurationSetTrackingOptionsAsync(request, null);
}
@Override
public java.util.concurrent.Future deleteConfigurationSetTrackingOptionsAsync(
final DeleteConfigurationSetTrackingOptionsRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final DeleteConfigurationSetTrackingOptionsRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public DeleteConfigurationSetTrackingOptionsResult call() throws Exception {
DeleteConfigurationSetTrackingOptionsResult result = null;
try {
result = executeDeleteConfigurationSetTrackingOptions(finalRequest);
} catch (Exception ex) {
if (asyncHandler != null) {
asyncHandler.onError(ex);
}
throw ex;
}
if (asyncHandler != null) {
asyncHandler.onSuccess(finalRequest, result);
}
return result;
}
});
}
@Override
public java.util.concurrent.Future deleteCustomVerificationEmailTemplateAsync(
DeleteCustomVerificationEmailTemplateRequest request) {
return deleteCustomVerificationEmailTemplateAsync(request, null);
}
@Override
public java.util.concurrent.Future deleteCustomVerificationEmailTemplateAsync(
final DeleteCustomVerificationEmailTemplateRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final DeleteCustomVerificationEmailTemplateRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public DeleteCustomVerificationEmailTemplateResult call() throws Exception {
DeleteCustomVerificationEmailTemplateResult result = null;
try {
result = executeDeleteCustomVerificationEmailTemplate(finalRequest);
} catch (Exception ex) {
if (asyncHandler != null) {
asyncHandler.onError(ex);
}
throw ex;
}
if (asyncHandler != null) {
asyncHandler.onSuccess(finalRequest, result);
}
return result;
}
});
}
@Override
public java.util.concurrent.Future deleteIdentityAsync(DeleteIdentityRequest request) {
return deleteIdentityAsync(request, null);
}
@Override
public java.util.concurrent.Future deleteIdentityAsync(final DeleteIdentityRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final DeleteIdentityRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public DeleteIdentityResult call() throws Exception {
DeleteIdentityResult result = null;
try {
result = executeDeleteIdentity(finalRequest);
} catch (Exception ex) {
if (asyncHandler != null) {
asyncHandler.onError(ex);
}
throw ex;
}
if (asyncHandler != null) {
asyncHandler.onSuccess(finalRequest, result);
}
return result;
}
});
}
@Override
public java.util.concurrent.Future deleteIdentityPolicyAsync(DeleteIdentityPolicyRequest request) {
return deleteIdentityPolicyAsync(request, null);
}
@Override
public java.util.concurrent.Future deleteIdentityPolicyAsync(final DeleteIdentityPolicyRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final DeleteIdentityPolicyRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public DeleteIdentityPolicyResult call() throws Exception {
DeleteIdentityPolicyResult result = null;
try {
result = executeDeleteIdentityPolicy(finalRequest);
} catch (Exception ex) {
if (asyncHandler != null) {
asyncHandler.onError(ex);
}
throw ex;
}
if (asyncHandler != null) {
asyncHandler.onSuccess(finalRequest, result);
}
return result;
}
});
}
@Override
public java.util.concurrent.Future deleteReceiptFilterAsync(DeleteReceiptFilterRequest request) {
return deleteReceiptFilterAsync(request, null);
}
@Override
public java.util.concurrent.Future deleteReceiptFilterAsync(final DeleteReceiptFilterRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final DeleteReceiptFilterRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public DeleteReceiptFilterResult call() throws Exception {
DeleteReceiptFilterResult result = null;
try {
result = executeDeleteReceiptFilter(finalRequest);
} catch (Exception ex) {
if (asyncHandler != null) {
asyncHandler.onError(ex);
}
throw ex;
}
if (asyncHandler != null) {
asyncHandler.onSuccess(finalRequest, result);
}
return result;
}
});
}
@Override
public java.util.concurrent.Future deleteReceiptRuleAsync(DeleteReceiptRuleRequest request) {
return deleteReceiptRuleAsync(request, null);
}
@Override
public java.util.concurrent.Future deleteReceiptRuleAsync(final DeleteReceiptRuleRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final DeleteReceiptRuleRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public DeleteReceiptRuleResult call() throws Exception {
DeleteReceiptRuleResult result = null;
try {
result = executeDeleteReceiptRule(finalRequest);
} catch (Exception ex) {
if (asyncHandler != null) {
asyncHandler.onError(ex);
}
throw ex;
}
if (asyncHandler != null) {
asyncHandler.onSuccess(finalRequest, result);
}
return result;
}
});
}
@Override
public java.util.concurrent.Future deleteReceiptRuleSetAsync(DeleteReceiptRuleSetRequest request) {
return deleteReceiptRuleSetAsync(request, null);
}
@Override
public java.util.concurrent.Future deleteReceiptRuleSetAsync(final DeleteReceiptRuleSetRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final DeleteReceiptRuleSetRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public DeleteReceiptRuleSetResult call() throws Exception {
DeleteReceiptRuleSetResult result = null;
try {
result = executeDeleteReceiptRuleSet(finalRequest);
} catch (Exception ex) {
if (asyncHandler != null) {
asyncHandler.onError(ex);
}
throw ex;
}
if (asyncHandler != null) {
asyncHandler.onSuccess(finalRequest, result);
}
return result;
}
});
}
@Override
public java.util.concurrent.Future deleteTemplateAsync(DeleteTemplateRequest request) {
return deleteTemplateAsync(request, null);
}
@Override
public java.util.concurrent.Future deleteTemplateAsync(final DeleteTemplateRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final DeleteTemplateRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public DeleteTemplateResult call() throws Exception {
DeleteTemplateResult result = null;
try {
result = executeDeleteTemplate(finalRequest);
} catch (Exception ex) {
if (asyncHandler != null) {
asyncHandler.onError(ex);
}
throw ex;
}
if (asyncHandler != null) {
asyncHandler.onSuccess(finalRequest, result);
}
return result;
}
});
}
@Override
public java.util.concurrent.Future deleteVerifiedEmailAddressAsync(DeleteVerifiedEmailAddressRequest request) {
return deleteVerifiedEmailAddressAsync(request, null);
}
@Override
public java.util.concurrent.Future deleteVerifiedEmailAddressAsync(final DeleteVerifiedEmailAddressRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final DeleteVerifiedEmailAddressRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public DeleteVerifiedEmailAddressResult call() throws Exception {
DeleteVerifiedEmailAddressResult result = null;
try {
result = executeDeleteVerifiedEmailAddress(finalRequest);
} catch (Exception ex) {
if (asyncHandler != null) {
asyncHandler.onError(ex);
}
throw ex;
}
if (asyncHandler != null) {
asyncHandler.onSuccess(finalRequest, result);
}
return result;
}
});
}
@Override
public java.util.concurrent.Future describeActiveReceiptRuleSetAsync(DescribeActiveReceiptRuleSetRequest request) {
return describeActiveReceiptRuleSetAsync(request, null);
}
@Override
public java.util.concurrent.Future describeActiveReceiptRuleSetAsync(final DescribeActiveReceiptRuleSetRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final DescribeActiveReceiptRuleSetRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public DescribeActiveReceiptRuleSetResult call() throws Exception {
DescribeActiveReceiptRuleSetResult result = null;
try {
result = executeDescribeActiveReceiptRuleSet(finalRequest);
} catch (Exception ex) {
if (asyncHandler != null) {
asyncHandler.onError(ex);
}
throw ex;
}
if (asyncHandler != null) {
asyncHandler.onSuccess(finalRequest, result);
}
return result;
}
});
}
@Override
public java.util.concurrent.Future describeConfigurationSetAsync(DescribeConfigurationSetRequest request) {
return describeConfigurationSetAsync(request, null);
}
@Override
public java.util.concurrent.Future describeConfigurationSetAsync(final DescribeConfigurationSetRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final DescribeConfigurationSetRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public DescribeConfigurationSetResult call() throws Exception {
DescribeConfigurationSetResult result = null;
try {
result = executeDescribeConfigurationSet(finalRequest);
} catch (Exception ex) {
if (asyncHandler != null) {
asyncHandler.onError(ex);
}
throw ex;
}
if (asyncHandler != null) {
asyncHandler.onSuccess(finalRequest, result);
}
return result;
}
});
}
@Override
public java.util.concurrent.Future describeReceiptRuleAsync(DescribeReceiptRuleRequest request) {
return describeReceiptRuleAsync(request, null);
}
@Override
public java.util.concurrent.Future describeReceiptRuleAsync(final DescribeReceiptRuleRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final DescribeReceiptRuleRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public DescribeReceiptRuleResult call() throws Exception {
DescribeReceiptRuleResult result = null;
try {
result = executeDescribeReceiptRule(finalRequest);
} catch (Exception ex) {
if (asyncHandler != null) {
asyncHandler.onError(ex);
}
throw ex;
}
if (asyncHandler != null) {
asyncHandler.onSuccess(finalRequest, result);
}
return result;
}
});
}
@Override
public java.util.concurrent.Future describeReceiptRuleSetAsync(DescribeReceiptRuleSetRequest request) {
return describeReceiptRuleSetAsync(request, null);
}
@Override
public java.util.concurrent.Future describeReceiptRuleSetAsync(final DescribeReceiptRuleSetRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final DescribeReceiptRuleSetRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public DescribeReceiptRuleSetResult call() throws Exception {
DescribeReceiptRuleSetResult result = null;
try {
result = executeDescribeReceiptRuleSet(finalRequest);
} catch (Exception ex) {
if (asyncHandler != null) {
asyncHandler.onError(ex);
}
throw ex;
}
if (asyncHandler != null) {
asyncHandler.onSuccess(finalRequest, result);
}
return result;
}
});
}
@Override
public java.util.concurrent.Future getAccountSendingEnabledAsync(GetAccountSendingEnabledRequest request) {
return getAccountSendingEnabledAsync(request, null);
}
@Override
public java.util.concurrent.Future getAccountSendingEnabledAsync(final GetAccountSendingEnabledRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final GetAccountSendingEnabledRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public GetAccountSendingEnabledResult call() throws Exception {
GetAccountSendingEnabledResult result = null;
try {
result = executeGetAccountSendingEnabled(finalRequest);
} catch (Exception ex) {
if (asyncHandler != null) {
asyncHandler.onError(ex);
}
throw ex;
}
if (asyncHandler != null) {
asyncHandler.onSuccess(finalRequest, result);
}
return result;
}
});
}
@Override
public java.util.concurrent.Future getCustomVerificationEmailTemplateAsync(
GetCustomVerificationEmailTemplateRequest request) {
return getCustomVerificationEmailTemplateAsync(request, null);
}
@Override
public java.util.concurrent.Future getCustomVerificationEmailTemplateAsync(
final GetCustomVerificationEmailTemplateRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final GetCustomVerificationEmailTemplateRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public GetCustomVerificationEmailTemplateResult call() throws Exception {
GetCustomVerificationEmailTemplateResult result = null;
try {
result = executeGetCustomVerificationEmailTemplate(finalRequest);
} catch (Exception ex) {
if (asyncHandler != null) {
asyncHandler.onError(ex);
}
throw ex;
}
if (asyncHandler != null) {
asyncHandler.onSuccess(finalRequest, result);
}
return result;
}
});
}
@Override
public java.util.concurrent.Future getIdentityDkimAttributesAsync(GetIdentityDkimAttributesRequest request) {
return getIdentityDkimAttributesAsync(request, null);
}
@Override
public java.util.concurrent.Future getIdentityDkimAttributesAsync(final GetIdentityDkimAttributesRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final GetIdentityDkimAttributesRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public GetIdentityDkimAttributesResult call() throws Exception {
GetIdentityDkimAttributesResult result = null;
try {
result = executeGetIdentityDkimAttributes(finalRequest);
} catch (Exception ex) {
if (asyncHandler != null) {
asyncHandler.onError(ex);
}
throw ex;
}
if (asyncHandler != null) {
asyncHandler.onSuccess(finalRequest, result);
}
return result;
}
});
}
@Override
public java.util.concurrent.Future getIdentityMailFromDomainAttributesAsync(
GetIdentityMailFromDomainAttributesRequest request) {
return getIdentityMailFromDomainAttributesAsync(request, null);
}
@Override
public java.util.concurrent.Future getIdentityMailFromDomainAttributesAsync(
final GetIdentityMailFromDomainAttributesRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final GetIdentityMailFromDomainAttributesRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public GetIdentityMailFromDomainAttributesResult call() throws Exception {
GetIdentityMailFromDomainAttributesResult result = null;
try {
result = executeGetIdentityMailFromDomainAttributes(finalRequest);
} catch (Exception ex) {
if (asyncHandler != null) {
asyncHandler.onError(ex);
}
throw ex;
}
if (asyncHandler != null) {
asyncHandler.onSuccess(finalRequest, result);
}
return result;
}
});
}
@Override
public java.util.concurrent.Future getIdentityNotificationAttributesAsync(
GetIdentityNotificationAttributesRequest request) {
return getIdentityNotificationAttributesAsync(request, null);
}
@Override
public java.util.concurrent.Future getIdentityNotificationAttributesAsync(
final GetIdentityNotificationAttributesRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final GetIdentityNotificationAttributesRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public GetIdentityNotificationAttributesResult call() throws Exception {
GetIdentityNotificationAttributesResult result = null;
try {
result = executeGetIdentityNotificationAttributes(finalRequest);
} catch (Exception ex) {
if (asyncHandler != null) {
asyncHandler.onError(ex);
}
throw ex;
}
if (asyncHandler != null) {
asyncHandler.onSuccess(finalRequest, result);
}
return result;
}
});
}
@Override
public java.util.concurrent.Future getIdentityPoliciesAsync(GetIdentityPoliciesRequest request) {
return getIdentityPoliciesAsync(request, null);
}
@Override
public java.util.concurrent.Future getIdentityPoliciesAsync(final GetIdentityPoliciesRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final GetIdentityPoliciesRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public GetIdentityPoliciesResult call() throws Exception {
GetIdentityPoliciesResult result = null;
try {
result = executeGetIdentityPolicies(finalRequest);
} catch (Exception ex) {
if (asyncHandler != null) {
asyncHandler.onError(ex);
}
throw ex;
}
if (asyncHandler != null) {
asyncHandler.onSuccess(finalRequest, result);
}
return result;
}
});
}
@Override
public java.util.concurrent.Future getIdentityVerificationAttributesAsync(
GetIdentityVerificationAttributesRequest request) {
return getIdentityVerificationAttributesAsync(request, null);
}
@Override
public java.util.concurrent.Future getIdentityVerificationAttributesAsync(
final GetIdentityVerificationAttributesRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final GetIdentityVerificationAttributesRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public GetIdentityVerificationAttributesResult call() throws Exception {
GetIdentityVerificationAttributesResult result = null;
try {
result = executeGetIdentityVerificationAttributes(finalRequest);
} catch (Exception ex) {
if (asyncHandler != null) {
asyncHandler.onError(ex);
}
throw ex;
}
if (asyncHandler != null) {
asyncHandler.onSuccess(finalRequest, result);
}
return result;
}
});
}
@Override
public java.util.concurrent.Future getSendQuotaAsync(GetSendQuotaRequest request) {
return getSendQuotaAsync(request, null);
}
@Override
public java.util.concurrent.Future getSendQuotaAsync(final GetSendQuotaRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final GetSendQuotaRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public GetSendQuotaResult call() throws Exception {
GetSendQuotaResult result = null;
try {
result = executeGetSendQuota(finalRequest);
} catch (Exception ex) {
if (asyncHandler != null) {
asyncHandler.onError(ex);
}
throw ex;
}
if (asyncHandler != null) {
asyncHandler.onSuccess(finalRequest, result);
}
return result;
}
});
}
/**
* Simplified method form for invoking the GetSendQuota operation.
*
* @see #getSendQuotaAsync(GetSendQuotaRequest)
*/
@Override
public java.util.concurrent.Future getSendQuotaAsync() {
return getSendQuotaAsync(new GetSendQuotaRequest());
}
/**
* Simplified method form for invoking the GetSendQuota operation with an AsyncHandler.
*
* @see #getSendQuotaAsync(GetSendQuotaRequest, com.amazonaws.handlers.AsyncHandler)
*/
@Override
public java.util.concurrent.Future getSendQuotaAsync(
com.amazonaws.handlers.AsyncHandler asyncHandler) {
return getSendQuotaAsync(new GetSendQuotaRequest(), asyncHandler);
}
@Override
public java.util.concurrent.Future getSendStatisticsAsync(GetSendStatisticsRequest request) {
return getSendStatisticsAsync(request, null);
}
@Override
public java.util.concurrent.Future getSendStatisticsAsync(final GetSendStatisticsRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final GetSendStatisticsRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public GetSendStatisticsResult call() throws Exception {
GetSendStatisticsResult result = null;
try {
result = executeGetSendStatistics(finalRequest);
} catch (Exception ex) {
if (asyncHandler != null) {
asyncHandler.onError(ex);
}
throw ex;
}
if (asyncHandler != null) {
asyncHandler.onSuccess(finalRequest, result);
}
return result;
}
});
}
/**
* Simplified method form for invoking the GetSendStatistics operation.
*
* @see #getSendStatisticsAsync(GetSendStatisticsRequest)
*/
@Override
public java.util.concurrent.Future getSendStatisticsAsync() {
return getSendStatisticsAsync(new GetSendStatisticsRequest());
}
/**
* Simplified method form for invoking the GetSendStatistics operation with an AsyncHandler.
*
* @see #getSendStatisticsAsync(GetSendStatisticsRequest, com.amazonaws.handlers.AsyncHandler)
*/
@Override
public java.util.concurrent.Future getSendStatisticsAsync(
com.amazonaws.handlers.AsyncHandler asyncHandler) {
return getSendStatisticsAsync(new GetSendStatisticsRequest(), asyncHandler);
}
@Override
public java.util.concurrent.Future getTemplateAsync(GetTemplateRequest request) {
return getTemplateAsync(request, null);
}
@Override
public java.util.concurrent.Future getTemplateAsync(final GetTemplateRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final GetTemplateRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public GetTemplateResult call() throws Exception {
GetTemplateResult result = null;
try {
result = executeGetTemplate(finalRequest);
} catch (Exception ex) {
if (asyncHandler != null) {
asyncHandler.onError(ex);
}
throw ex;
}
if (asyncHandler != null) {
asyncHandler.onSuccess(finalRequest, result);
}
return result;
}
});
}
@Override
public java.util.concurrent.Future listConfigurationSetsAsync(ListConfigurationSetsRequest request) {
return listConfigurationSetsAsync(request, null);
}
@Override
public java.util.concurrent.Future listConfigurationSetsAsync(final ListConfigurationSetsRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final ListConfigurationSetsRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public ListConfigurationSetsResult call() throws Exception {
ListConfigurationSetsResult result = null;
try {
result = executeListConfigurationSets(finalRequest);
} catch (Exception ex) {
if (asyncHandler != null) {
asyncHandler.onError(ex);
}
throw ex;
}
if (asyncHandler != null) {
asyncHandler.onSuccess(finalRequest, result);
}
return result;
}
});
}
@Override
public java.util.concurrent.Future listCustomVerificationEmailTemplatesAsync(
ListCustomVerificationEmailTemplatesRequest request) {
return listCustomVerificationEmailTemplatesAsync(request, null);
}
@Override
public java.util.concurrent.Future listCustomVerificationEmailTemplatesAsync(
final ListCustomVerificationEmailTemplatesRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final ListCustomVerificationEmailTemplatesRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public ListCustomVerificationEmailTemplatesResult call() throws Exception {
ListCustomVerificationEmailTemplatesResult result = null;
try {
result = executeListCustomVerificationEmailTemplates(finalRequest);
} catch (Exception ex) {
if (asyncHandler != null) {
asyncHandler.onError(ex);
}
throw ex;
}
if (asyncHandler != null) {
asyncHandler.onSuccess(finalRequest, result);
}
return result;
}
});
}
@Override
public java.util.concurrent.Future listIdentitiesAsync(ListIdentitiesRequest request) {
return listIdentitiesAsync(request, null);
}
@Override
public java.util.concurrent.Future listIdentitiesAsync(final ListIdentitiesRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final ListIdentitiesRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public ListIdentitiesResult call() throws Exception {
ListIdentitiesResult result = null;
try {
result = executeListIdentities(finalRequest);
} catch (Exception ex) {
if (asyncHandler != null) {
asyncHandler.onError(ex);
}
throw ex;
}
if (asyncHandler != null) {
asyncHandler.onSuccess(finalRequest, result);
}
return result;
}
});
}
/**
* Simplified method form for invoking the ListIdentities operation.
*
* @see #listIdentitiesAsync(ListIdentitiesRequest)
*/
@Override
public java.util.concurrent.Future listIdentitiesAsync() {
return listIdentitiesAsync(new ListIdentitiesRequest());
}
/**
* Simplified method form for invoking the ListIdentities operation with an AsyncHandler.
*
* @see #listIdentitiesAsync(ListIdentitiesRequest, com.amazonaws.handlers.AsyncHandler)
*/
@Override
public java.util.concurrent.Future listIdentitiesAsync(
com.amazonaws.handlers.AsyncHandler asyncHandler) {
return listIdentitiesAsync(new ListIdentitiesRequest(), asyncHandler);
}
@Override
public java.util.concurrent.Future listIdentityPoliciesAsync(ListIdentityPoliciesRequest request) {
return listIdentityPoliciesAsync(request, null);
}
@Override
public java.util.concurrent.Future listIdentityPoliciesAsync(final ListIdentityPoliciesRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final ListIdentityPoliciesRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public ListIdentityPoliciesResult call() throws Exception {
ListIdentityPoliciesResult result = null;
try {
result = executeListIdentityPolicies(finalRequest);
} catch (Exception ex) {
if (asyncHandler != null) {
asyncHandler.onError(ex);
}
throw ex;
}
if (asyncHandler != null) {
asyncHandler.onSuccess(finalRequest, result);
}
return result;
}
});
}
@Override
public java.util.concurrent.Future listReceiptFiltersAsync(ListReceiptFiltersRequest request) {
return listReceiptFiltersAsync(request, null);
}
@Override
public java.util.concurrent.Future listReceiptFiltersAsync(final ListReceiptFiltersRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final ListReceiptFiltersRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public ListReceiptFiltersResult call() throws Exception {
ListReceiptFiltersResult result = null;
try {
result = executeListReceiptFilters(finalRequest);
} catch (Exception ex) {
if (asyncHandler != null) {
asyncHandler.onError(ex);
}
throw ex;
}
if (asyncHandler != null) {
asyncHandler.onSuccess(finalRequest, result);
}
return result;
}
});
}
@Override
public java.util.concurrent.Future listReceiptRuleSetsAsync(ListReceiptRuleSetsRequest request) {
return listReceiptRuleSetsAsync(request, null);
}
@Override
public java.util.concurrent.Future listReceiptRuleSetsAsync(final ListReceiptRuleSetsRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final ListReceiptRuleSetsRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public ListReceiptRuleSetsResult call() throws Exception {
ListReceiptRuleSetsResult result = null;
try {
result = executeListReceiptRuleSets(finalRequest);
} catch (Exception ex) {
if (asyncHandler != null) {
asyncHandler.onError(ex);
}
throw ex;
}
if (asyncHandler != null) {
asyncHandler.onSuccess(finalRequest, result);
}
return result;
}
});
}
@Override
public java.util.concurrent.Future listTemplatesAsync(ListTemplatesRequest request) {
return listTemplatesAsync(request, null);
}
@Override
public java.util.concurrent.Future listTemplatesAsync(final ListTemplatesRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final ListTemplatesRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public ListTemplatesResult call() throws Exception {
ListTemplatesResult result = null;
try {
result = executeListTemplates(finalRequest);
} catch (Exception ex) {
if (asyncHandler != null) {
asyncHandler.onError(ex);
}
throw ex;
}
if (asyncHandler != null) {
asyncHandler.onSuccess(finalRequest, result);
}
return result;
}
});
}
@Override
public java.util.concurrent.Future listVerifiedEmailAddressesAsync(ListVerifiedEmailAddressesRequest request) {
return listVerifiedEmailAddressesAsync(request, null);
}
@Override
public java.util.concurrent.Future listVerifiedEmailAddressesAsync(final ListVerifiedEmailAddressesRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final ListVerifiedEmailAddressesRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public ListVerifiedEmailAddressesResult call() throws Exception {
ListVerifiedEmailAddressesResult result = null;
try {
result = executeListVerifiedEmailAddresses(finalRequest);
} catch (Exception ex) {
if (asyncHandler != null) {
asyncHandler.onError(ex);
}
throw ex;
}
if (asyncHandler != null) {
asyncHandler.onSuccess(finalRequest, result);
}
return result;
}
});
}
/**
* Simplified method form for invoking the ListVerifiedEmailAddresses operation.
*
* @see #listVerifiedEmailAddressesAsync(ListVerifiedEmailAddressesRequest)
*/
@Override
public java.util.concurrent.Future listVerifiedEmailAddressesAsync() {
return listVerifiedEmailAddressesAsync(new ListVerifiedEmailAddressesRequest());
}
/**
* Simplified method form for invoking the ListVerifiedEmailAddresses operation with an AsyncHandler.
*
* @see #listVerifiedEmailAddressesAsync(ListVerifiedEmailAddressesRequest, com.amazonaws.handlers.AsyncHandler)
*/
@Override
public java.util.concurrent.Future listVerifiedEmailAddressesAsync(
com.amazonaws.handlers.AsyncHandler asyncHandler) {
return listVerifiedEmailAddressesAsync(new ListVerifiedEmailAddressesRequest(), asyncHandler);
}
@Override
public java.util.concurrent.Future putConfigurationSetDeliveryOptionsAsync(
PutConfigurationSetDeliveryOptionsRequest request) {
return putConfigurationSetDeliveryOptionsAsync(request, null);
}
@Override
public java.util.concurrent.Future putConfigurationSetDeliveryOptionsAsync(
final PutConfigurationSetDeliveryOptionsRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final PutConfigurationSetDeliveryOptionsRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public PutConfigurationSetDeliveryOptionsResult call() throws Exception {
PutConfigurationSetDeliveryOptionsResult result = null;
try {
result = executePutConfigurationSetDeliveryOptions(finalRequest);
} catch (Exception ex) {
if (asyncHandler != null) {
asyncHandler.onError(ex);
}
throw ex;
}
if (asyncHandler != null) {
asyncHandler.onSuccess(finalRequest, result);
}
return result;
}
});
}
@Override
public java.util.concurrent.Future putIdentityPolicyAsync(PutIdentityPolicyRequest request) {
return putIdentityPolicyAsync(request, null);
}
@Override
public java.util.concurrent.Future putIdentityPolicyAsync(final PutIdentityPolicyRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final PutIdentityPolicyRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public PutIdentityPolicyResult call() throws Exception {
PutIdentityPolicyResult result = null;
try {
result = executePutIdentityPolicy(finalRequest);
} catch (Exception ex) {
if (asyncHandler != null) {
asyncHandler.onError(ex);
}
throw ex;
}
if (asyncHandler != null) {
asyncHandler.onSuccess(finalRequest, result);
}
return result;
}
});
}
@Override
public java.util.concurrent.Future reorderReceiptRuleSetAsync(ReorderReceiptRuleSetRequest request) {
return reorderReceiptRuleSetAsync(request, null);
}
@Override
public java.util.concurrent.Future reorderReceiptRuleSetAsync(final ReorderReceiptRuleSetRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final ReorderReceiptRuleSetRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public ReorderReceiptRuleSetResult call() throws Exception {
ReorderReceiptRuleSetResult result = null;
try {
result = executeReorderReceiptRuleSet(finalRequest);
} catch (Exception ex) {
if (asyncHandler != null) {
asyncHandler.onError(ex);
}
throw ex;
}
if (asyncHandler != null) {
asyncHandler.onSuccess(finalRequest, result);
}
return result;
}
});
}
@Override
public java.util.concurrent.Future sendBounceAsync(SendBounceRequest request) {
return sendBounceAsync(request, null);
}
@Override
public java.util.concurrent.Future sendBounceAsync(final SendBounceRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final SendBounceRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public SendBounceResult call() throws Exception {
SendBounceResult result = null;
try {
result = executeSendBounce(finalRequest);
} catch (Exception ex) {
if (asyncHandler != null) {
asyncHandler.onError(ex);
}
throw ex;
}
if (asyncHandler != null) {
asyncHandler.onSuccess(finalRequest, result);
}
return result;
}
});
}
@Override
public java.util.concurrent.Future sendBulkTemplatedEmailAsync(SendBulkTemplatedEmailRequest request) {
return sendBulkTemplatedEmailAsync(request, null);
}
@Override
public java.util.concurrent.Future sendBulkTemplatedEmailAsync(final SendBulkTemplatedEmailRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final SendBulkTemplatedEmailRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public SendBulkTemplatedEmailResult call() throws Exception {
SendBulkTemplatedEmailResult result = null;
try {
result = executeSendBulkTemplatedEmail(finalRequest);
} catch (Exception ex) {
if (asyncHandler != null) {
asyncHandler.onError(ex);
}
throw ex;
}
if (asyncHandler != null) {
asyncHandler.onSuccess(finalRequest, result);
}
return result;
}
});
}
@Override
public java.util.concurrent.Future sendCustomVerificationEmailAsync(SendCustomVerificationEmailRequest request) {
return sendCustomVerificationEmailAsync(request, null);
}
@Override
public java.util.concurrent.Future sendCustomVerificationEmailAsync(final SendCustomVerificationEmailRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final SendCustomVerificationEmailRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public SendCustomVerificationEmailResult call() throws Exception {
SendCustomVerificationEmailResult result = null;
try {
result = executeSendCustomVerificationEmail(finalRequest);
} catch (Exception ex) {
if (asyncHandler != null) {
asyncHandler.onError(ex);
}
throw ex;
}
if (asyncHandler != null) {
asyncHandler.onSuccess(finalRequest, result);
}
return result;
}
});
}
@Override
public java.util.concurrent.Future sendEmailAsync(SendEmailRequest request) {
return sendEmailAsync(request, null);
}
@Override
public java.util.concurrent.Future sendEmailAsync(final SendEmailRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final SendEmailRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public SendEmailResult call() throws Exception {
SendEmailResult result = null;
try {
result = executeSendEmail(finalRequest);
} catch (Exception ex) {
if (asyncHandler != null) {
asyncHandler.onError(ex);
}
throw ex;
}
if (asyncHandler != null) {
asyncHandler.onSuccess(finalRequest, result);
}
return result;
}
});
}
@Override
public java.util.concurrent.Future sendRawEmailAsync(SendRawEmailRequest request) {
return sendRawEmailAsync(request, null);
}
@Override
public java.util.concurrent.Future sendRawEmailAsync(final SendRawEmailRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final SendRawEmailRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public SendRawEmailResult call() throws Exception {
SendRawEmailResult result = null;
try {
result = executeSendRawEmail(finalRequest);
} catch (Exception ex) {
if (asyncHandler != null) {
asyncHandler.onError(ex);
}
throw ex;
}
if (asyncHandler != null) {
asyncHandler.onSuccess(finalRequest, result);
}
return result;
}
});
}
@Override
public java.util.concurrent.Future sendTemplatedEmailAsync(SendTemplatedEmailRequest request) {
return sendTemplatedEmailAsync(request, null);
}
@Override
public java.util.concurrent.Future sendTemplatedEmailAsync(final SendTemplatedEmailRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final SendTemplatedEmailRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public SendTemplatedEmailResult call() throws Exception {
SendTemplatedEmailResult result = null;
try {
result = executeSendTemplatedEmail(finalRequest);
} catch (Exception ex) {
if (asyncHandler != null) {
asyncHandler.onError(ex);
}
throw ex;
}
if (asyncHandler != null) {
asyncHandler.onSuccess(finalRequest, result);
}
return result;
}
});
}
@Override
public java.util.concurrent.Future setActiveReceiptRuleSetAsync(SetActiveReceiptRuleSetRequest request) {
return setActiveReceiptRuleSetAsync(request, null);
}
@Override
public java.util.concurrent.Future setActiveReceiptRuleSetAsync(final SetActiveReceiptRuleSetRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final SetActiveReceiptRuleSetRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public SetActiveReceiptRuleSetResult call() throws Exception {
SetActiveReceiptRuleSetResult result = null;
try {
result = executeSetActiveReceiptRuleSet(finalRequest);
} catch (Exception ex) {
if (asyncHandler != null) {
asyncHandler.onError(ex);
}
throw ex;
}
if (asyncHandler != null) {
asyncHandler.onSuccess(finalRequest, result);
}
return result;
}
});
}
@Override
public java.util.concurrent.Future setIdentityDkimEnabledAsync(SetIdentityDkimEnabledRequest request) {
return setIdentityDkimEnabledAsync(request, null);
}
@Override
public java.util.concurrent.Future setIdentityDkimEnabledAsync(final SetIdentityDkimEnabledRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final SetIdentityDkimEnabledRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public SetIdentityDkimEnabledResult call() throws Exception {
SetIdentityDkimEnabledResult result = null;
try {
result = executeSetIdentityDkimEnabled(finalRequest);
} catch (Exception ex) {
if (asyncHandler != null) {
asyncHandler.onError(ex);
}
throw ex;
}
if (asyncHandler != null) {
asyncHandler.onSuccess(finalRequest, result);
}
return result;
}
});
}
@Override
public java.util.concurrent.Future setIdentityFeedbackForwardingEnabledAsync(
SetIdentityFeedbackForwardingEnabledRequest request) {
return setIdentityFeedbackForwardingEnabledAsync(request, null);
}
@Override
public java.util.concurrent.Future setIdentityFeedbackForwardingEnabledAsync(
final SetIdentityFeedbackForwardingEnabledRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final SetIdentityFeedbackForwardingEnabledRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public SetIdentityFeedbackForwardingEnabledResult call() throws Exception {
SetIdentityFeedbackForwardingEnabledResult result = null;
try {
result = executeSetIdentityFeedbackForwardingEnabled(finalRequest);
} catch (Exception ex) {
if (asyncHandler != null) {
asyncHandler.onError(ex);
}
throw ex;
}
if (asyncHandler != null) {
asyncHandler.onSuccess(finalRequest, result);
}
return result;
}
});
}
@Override
public java.util.concurrent.Future setIdentityHeadersInNotificationsEnabledAsync(
SetIdentityHeadersInNotificationsEnabledRequest request) {
return setIdentityHeadersInNotificationsEnabledAsync(request, null);
}
@Override
public java.util.concurrent.Future setIdentityHeadersInNotificationsEnabledAsync(
final SetIdentityHeadersInNotificationsEnabledRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final SetIdentityHeadersInNotificationsEnabledRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public SetIdentityHeadersInNotificationsEnabledResult call() throws Exception {
SetIdentityHeadersInNotificationsEnabledResult result = null;
try {
result = executeSetIdentityHeadersInNotificationsEnabled(finalRequest);
} catch (Exception ex) {
if (asyncHandler != null) {
asyncHandler.onError(ex);
}
throw ex;
}
if (asyncHandler != null) {
asyncHandler.onSuccess(finalRequest, result);
}
return result;
}
});
}
@Override
public java.util.concurrent.Future setIdentityMailFromDomainAsync(SetIdentityMailFromDomainRequest request) {
return setIdentityMailFromDomainAsync(request, null);
}
@Override
public java.util.concurrent.Future setIdentityMailFromDomainAsync(final SetIdentityMailFromDomainRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final SetIdentityMailFromDomainRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public SetIdentityMailFromDomainResult call() throws Exception {
SetIdentityMailFromDomainResult result = null;
try {
result = executeSetIdentityMailFromDomain(finalRequest);
} catch (Exception ex) {
if (asyncHandler != null) {
asyncHandler.onError(ex);
}
throw ex;
}
if (asyncHandler != null) {
asyncHandler.onSuccess(finalRequest, result);
}
return result;
}
});
}
@Override
public java.util.concurrent.Future setIdentityNotificationTopicAsync(SetIdentityNotificationTopicRequest request) {
return setIdentityNotificationTopicAsync(request, null);
}
@Override
public java.util.concurrent.Future setIdentityNotificationTopicAsync(final SetIdentityNotificationTopicRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final SetIdentityNotificationTopicRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public SetIdentityNotificationTopicResult call() throws Exception {
SetIdentityNotificationTopicResult result = null;
try {
result = executeSetIdentityNotificationTopic(finalRequest);
} catch (Exception ex) {
if (asyncHandler != null) {
asyncHandler.onError(ex);
}
throw ex;
}
if (asyncHandler != null) {
asyncHandler.onSuccess(finalRequest, result);
}
return result;
}
});
}
@Override
public java.util.concurrent.Future setReceiptRulePositionAsync(SetReceiptRulePositionRequest request) {
return setReceiptRulePositionAsync(request, null);
}
@Override
public java.util.concurrent.Future setReceiptRulePositionAsync(final SetReceiptRulePositionRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final SetReceiptRulePositionRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public SetReceiptRulePositionResult call() throws Exception {
SetReceiptRulePositionResult result = null;
try {
result = executeSetReceiptRulePosition(finalRequest);
} catch (Exception ex) {
if (asyncHandler != null) {
asyncHandler.onError(ex);
}
throw ex;
}
if (asyncHandler != null) {
asyncHandler.onSuccess(finalRequest, result);
}
return result;
}
});
}
@Override
public java.util.concurrent.Future testRenderTemplateAsync(TestRenderTemplateRequest request) {
return testRenderTemplateAsync(request, null);
}
@Override
public java.util.concurrent.Future testRenderTemplateAsync(final TestRenderTemplateRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final TestRenderTemplateRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public TestRenderTemplateResult call() throws Exception {
TestRenderTemplateResult result = null;
try {
result = executeTestRenderTemplate(finalRequest);
} catch (Exception ex) {
if (asyncHandler != null) {
asyncHandler.onError(ex);
}
throw ex;
}
if (asyncHandler != null) {
asyncHandler.onSuccess(finalRequest, result);
}
return result;
}
});
}
@Override
public java.util.concurrent.Future updateAccountSendingEnabledAsync(UpdateAccountSendingEnabledRequest request) {
return updateAccountSendingEnabledAsync(request, null);
}
@Override
public java.util.concurrent.Future updateAccountSendingEnabledAsync(final UpdateAccountSendingEnabledRequest request,
final com.amazonaws.handlers.AsyncHandler