All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.amazonaws.services.simpleemailv2.AmazonSimpleEmailServiceV2AsyncClient Maven / Gradle / Ivy

/*
 * Copyright 2017-2022 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.simpleemailv2;

import javax.annotation.Generated;

import com.amazonaws.services.simpleemailv2.model.*;
import com.amazonaws.client.AwsAsyncClientParams;
import com.amazonaws.annotation.ThreadSafe;

import java.util.concurrent.ExecutorService;

/**
 * Client for accessing Amazon SES V2 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 SES API v2 *

* Amazon SES is an Amazon Web Services service that you can use to send email * messages to your customers. *

*

* If you're new to Amazon SES API v2, you might find it helpful to review the Amazon Simple Email Service Developer Guide. The * Amazon SES Developer Guide provides information and code samples that demonstrate how to use Amazon SES API v2 * features programmatically. *

*/ @ThreadSafe @Generated("com.amazonaws:aws-java-sdk-code-generator") public class AmazonSimpleEmailServiceV2AsyncClient extends AmazonSimpleEmailServiceV2Client implements AmazonSimpleEmailServiceV2Async { private static final int DEFAULT_THREAD_POOL_SIZE = 50; private final java.util.concurrent.ExecutorService executorService; public static AmazonSimpleEmailServiceV2AsyncClientBuilder asyncBuilder() { return AmazonSimpleEmailServiceV2AsyncClientBuilder.standard(); } /** * Constructs a new asynchronous client to invoke service methods on Amazon SES V2 using the specified parameters. * * @param asyncClientParams * Object providing client parameters. */ AmazonSimpleEmailServiceV2AsyncClient(AwsAsyncClientParams asyncClientParams) { this(asyncClientParams, false); } /** * Constructs a new asynchronous client to invoke service methods on Amazon SES V2 using the specified parameters. * * @param asyncClientParams * Object providing client parameters. * @param endpointDiscoveryEnabled * true will enable endpoint discovery if the service supports it. */ AmazonSimpleEmailServiceV2AsyncClient(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 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 createContactAsync(CreateContactRequest request) { return createContactAsync(request, null); } @Override public java.util.concurrent.Future createContactAsync(final CreateContactRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final CreateContactRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public CreateContactResult call() throws Exception { CreateContactResult result = null; try { result = executeCreateContact(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 createContactListAsync(CreateContactListRequest request) { return createContactListAsync(request, null); } @Override public java.util.concurrent.Future createContactListAsync(final CreateContactListRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final CreateContactListRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public CreateContactListResult call() throws Exception { CreateContactListResult result = null; try { result = executeCreateContactList(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 createDedicatedIpPoolAsync(CreateDedicatedIpPoolRequest request) { return createDedicatedIpPoolAsync(request, null); } @Override public java.util.concurrent.Future createDedicatedIpPoolAsync(final CreateDedicatedIpPoolRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final CreateDedicatedIpPoolRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public CreateDedicatedIpPoolResult call() throws Exception { CreateDedicatedIpPoolResult result = null; try { result = executeCreateDedicatedIpPool(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 createDeliverabilityTestReportAsync(CreateDeliverabilityTestReportRequest request) { return createDeliverabilityTestReportAsync(request, null); } @Override public java.util.concurrent.Future createDeliverabilityTestReportAsync( final CreateDeliverabilityTestReportRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final CreateDeliverabilityTestReportRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public CreateDeliverabilityTestReportResult call() throws Exception { CreateDeliverabilityTestReportResult result = null; try { result = executeCreateDeliverabilityTestReport(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 createEmailIdentityAsync(CreateEmailIdentityRequest request) { return createEmailIdentityAsync(request, null); } @Override public java.util.concurrent.Future createEmailIdentityAsync(final CreateEmailIdentityRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final CreateEmailIdentityRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public CreateEmailIdentityResult call() throws Exception { CreateEmailIdentityResult result = null; try { result = executeCreateEmailIdentity(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 createEmailIdentityPolicyAsync(CreateEmailIdentityPolicyRequest request) { return createEmailIdentityPolicyAsync(request, null); } @Override public java.util.concurrent.Future createEmailIdentityPolicyAsync(final CreateEmailIdentityPolicyRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final CreateEmailIdentityPolicyRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public CreateEmailIdentityPolicyResult call() throws Exception { CreateEmailIdentityPolicyResult result = null; try { result = executeCreateEmailIdentityPolicy(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 createEmailTemplateAsync(CreateEmailTemplateRequest request) { return createEmailTemplateAsync(request, null); } @Override public java.util.concurrent.Future createEmailTemplateAsync(final CreateEmailTemplateRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final CreateEmailTemplateRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public CreateEmailTemplateResult call() throws Exception { CreateEmailTemplateResult result = null; try { result = executeCreateEmailTemplate(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 createImportJobAsync(CreateImportJobRequest request) { return createImportJobAsync(request, null); } @Override public java.util.concurrent.Future createImportJobAsync(final CreateImportJobRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final CreateImportJobRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public CreateImportJobResult call() throws Exception { CreateImportJobResult result = null; try { result = executeCreateImportJob(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 deleteContactAsync(DeleteContactRequest request) { return deleteContactAsync(request, null); } @Override public java.util.concurrent.Future deleteContactAsync(final DeleteContactRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final DeleteContactRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public DeleteContactResult call() throws Exception { DeleteContactResult result = null; try { result = executeDeleteContact(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 deleteContactListAsync(DeleteContactListRequest request) { return deleteContactListAsync(request, null); } @Override public java.util.concurrent.Future deleteContactListAsync(final DeleteContactListRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final DeleteContactListRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public DeleteContactListResult call() throws Exception { DeleteContactListResult result = null; try { result = executeDeleteContactList(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 deleteDedicatedIpPoolAsync(DeleteDedicatedIpPoolRequest request) { return deleteDedicatedIpPoolAsync(request, null); } @Override public java.util.concurrent.Future deleteDedicatedIpPoolAsync(final DeleteDedicatedIpPoolRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final DeleteDedicatedIpPoolRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public DeleteDedicatedIpPoolResult call() throws Exception { DeleteDedicatedIpPoolResult result = null; try { result = executeDeleteDedicatedIpPool(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 deleteEmailIdentityAsync(DeleteEmailIdentityRequest request) { return deleteEmailIdentityAsync(request, null); } @Override public java.util.concurrent.Future deleteEmailIdentityAsync(final DeleteEmailIdentityRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final DeleteEmailIdentityRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public DeleteEmailIdentityResult call() throws Exception { DeleteEmailIdentityResult result = null; try { result = executeDeleteEmailIdentity(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 deleteEmailIdentityPolicyAsync(DeleteEmailIdentityPolicyRequest request) { return deleteEmailIdentityPolicyAsync(request, null); } @Override public java.util.concurrent.Future deleteEmailIdentityPolicyAsync(final DeleteEmailIdentityPolicyRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final DeleteEmailIdentityPolicyRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public DeleteEmailIdentityPolicyResult call() throws Exception { DeleteEmailIdentityPolicyResult result = null; try { result = executeDeleteEmailIdentityPolicy(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 deleteEmailTemplateAsync(DeleteEmailTemplateRequest request) { return deleteEmailTemplateAsync(request, null); } @Override public java.util.concurrent.Future deleteEmailTemplateAsync(final DeleteEmailTemplateRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final DeleteEmailTemplateRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public DeleteEmailTemplateResult call() throws Exception { DeleteEmailTemplateResult result = null; try { result = executeDeleteEmailTemplate(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 deleteSuppressedDestinationAsync(DeleteSuppressedDestinationRequest request) { return deleteSuppressedDestinationAsync(request, null); } @Override public java.util.concurrent.Future deleteSuppressedDestinationAsync(final DeleteSuppressedDestinationRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final DeleteSuppressedDestinationRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public DeleteSuppressedDestinationResult call() throws Exception { DeleteSuppressedDestinationResult result = null; try { result = executeDeleteSuppressedDestination(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 getAccountAsync(GetAccountRequest request) { return getAccountAsync(request, null); } @Override public java.util.concurrent.Future getAccountAsync(final GetAccountRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final GetAccountRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public GetAccountResult call() throws Exception { GetAccountResult result = null; try { result = executeGetAccount(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 getBlacklistReportsAsync(GetBlacklistReportsRequest request) { return getBlacklistReportsAsync(request, null); } @Override public java.util.concurrent.Future getBlacklistReportsAsync(final GetBlacklistReportsRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final GetBlacklistReportsRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public GetBlacklistReportsResult call() throws Exception { GetBlacklistReportsResult result = null; try { result = executeGetBlacklistReports(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 getConfigurationSetAsync(GetConfigurationSetRequest request) { return getConfigurationSetAsync(request, null); } @Override public java.util.concurrent.Future getConfigurationSetAsync(final GetConfigurationSetRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final GetConfigurationSetRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public GetConfigurationSetResult call() throws Exception { GetConfigurationSetResult result = null; try { result = executeGetConfigurationSet(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 getConfigurationSetEventDestinationsAsync( GetConfigurationSetEventDestinationsRequest request) { return getConfigurationSetEventDestinationsAsync(request, null); } @Override public java.util.concurrent.Future getConfigurationSetEventDestinationsAsync( final GetConfigurationSetEventDestinationsRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final GetConfigurationSetEventDestinationsRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public GetConfigurationSetEventDestinationsResult call() throws Exception { GetConfigurationSetEventDestinationsResult result = null; try { result = executeGetConfigurationSetEventDestinations(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 getContactAsync(GetContactRequest request) { return getContactAsync(request, null); } @Override public java.util.concurrent.Future getContactAsync(final GetContactRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final GetContactRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public GetContactResult call() throws Exception { GetContactResult result = null; try { result = executeGetContact(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 getContactListAsync(GetContactListRequest request) { return getContactListAsync(request, null); } @Override public java.util.concurrent.Future getContactListAsync(final GetContactListRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final GetContactListRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public GetContactListResult call() throws Exception { GetContactListResult result = null; try { result = executeGetContactList(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 getDedicatedIpAsync(GetDedicatedIpRequest request) { return getDedicatedIpAsync(request, null); } @Override public java.util.concurrent.Future getDedicatedIpAsync(final GetDedicatedIpRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final GetDedicatedIpRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public GetDedicatedIpResult call() throws Exception { GetDedicatedIpResult result = null; try { result = executeGetDedicatedIp(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 getDedicatedIpsAsync(GetDedicatedIpsRequest request) { return getDedicatedIpsAsync(request, null); } @Override public java.util.concurrent.Future getDedicatedIpsAsync(final GetDedicatedIpsRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final GetDedicatedIpsRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public GetDedicatedIpsResult call() throws Exception { GetDedicatedIpsResult result = null; try { result = executeGetDedicatedIps(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 getDeliverabilityDashboardOptionsAsync( GetDeliverabilityDashboardOptionsRequest request) { return getDeliverabilityDashboardOptionsAsync(request, null); } @Override public java.util.concurrent.Future getDeliverabilityDashboardOptionsAsync( final GetDeliverabilityDashboardOptionsRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final GetDeliverabilityDashboardOptionsRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public GetDeliverabilityDashboardOptionsResult call() throws Exception { GetDeliverabilityDashboardOptionsResult result = null; try { result = executeGetDeliverabilityDashboardOptions(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 getDeliverabilityTestReportAsync(GetDeliverabilityTestReportRequest request) { return getDeliverabilityTestReportAsync(request, null); } @Override public java.util.concurrent.Future getDeliverabilityTestReportAsync(final GetDeliverabilityTestReportRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final GetDeliverabilityTestReportRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public GetDeliverabilityTestReportResult call() throws Exception { GetDeliverabilityTestReportResult result = null; try { result = executeGetDeliverabilityTestReport(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 getDomainDeliverabilityCampaignAsync( GetDomainDeliverabilityCampaignRequest request) { return getDomainDeliverabilityCampaignAsync(request, null); } @Override public java.util.concurrent.Future getDomainDeliverabilityCampaignAsync( final GetDomainDeliverabilityCampaignRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final GetDomainDeliverabilityCampaignRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public GetDomainDeliverabilityCampaignResult call() throws Exception { GetDomainDeliverabilityCampaignResult result = null; try { result = executeGetDomainDeliverabilityCampaign(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 getDomainStatisticsReportAsync(GetDomainStatisticsReportRequest request) { return getDomainStatisticsReportAsync(request, null); } @Override public java.util.concurrent.Future getDomainStatisticsReportAsync(final GetDomainStatisticsReportRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final GetDomainStatisticsReportRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public GetDomainStatisticsReportResult call() throws Exception { GetDomainStatisticsReportResult result = null; try { result = executeGetDomainStatisticsReport(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 getEmailIdentityAsync(GetEmailIdentityRequest request) { return getEmailIdentityAsync(request, null); } @Override public java.util.concurrent.Future getEmailIdentityAsync(final GetEmailIdentityRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final GetEmailIdentityRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public GetEmailIdentityResult call() throws Exception { GetEmailIdentityResult result = null; try { result = executeGetEmailIdentity(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 getEmailIdentityPoliciesAsync(GetEmailIdentityPoliciesRequest request) { return getEmailIdentityPoliciesAsync(request, null); } @Override public java.util.concurrent.Future getEmailIdentityPoliciesAsync(final GetEmailIdentityPoliciesRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final GetEmailIdentityPoliciesRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public GetEmailIdentityPoliciesResult call() throws Exception { GetEmailIdentityPoliciesResult result = null; try { result = executeGetEmailIdentityPolicies(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 getEmailTemplateAsync(GetEmailTemplateRequest request) { return getEmailTemplateAsync(request, null); } @Override public java.util.concurrent.Future getEmailTemplateAsync(final GetEmailTemplateRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final GetEmailTemplateRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public GetEmailTemplateResult call() throws Exception { GetEmailTemplateResult result = null; try { result = executeGetEmailTemplate(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 getImportJobAsync(GetImportJobRequest request) { return getImportJobAsync(request, null); } @Override public java.util.concurrent.Future getImportJobAsync(final GetImportJobRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final GetImportJobRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public GetImportJobResult call() throws Exception { GetImportJobResult result = null; try { result = executeGetImportJob(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 getSuppressedDestinationAsync(GetSuppressedDestinationRequest request) { return getSuppressedDestinationAsync(request, null); } @Override public java.util.concurrent.Future getSuppressedDestinationAsync(final GetSuppressedDestinationRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final GetSuppressedDestinationRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public GetSuppressedDestinationResult call() throws Exception { GetSuppressedDestinationResult result = null; try { result = executeGetSuppressedDestination(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 listContactListsAsync(ListContactListsRequest request) { return listContactListsAsync(request, null); } @Override public java.util.concurrent.Future listContactListsAsync(final ListContactListsRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final ListContactListsRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public ListContactListsResult call() throws Exception { ListContactListsResult result = null; try { result = executeListContactLists(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 listContactsAsync(ListContactsRequest request) { return listContactsAsync(request, null); } @Override public java.util.concurrent.Future listContactsAsync(final ListContactsRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final ListContactsRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public ListContactsResult call() throws Exception { ListContactsResult result = null; try { result = executeListContacts(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 listDedicatedIpPoolsAsync(ListDedicatedIpPoolsRequest request) { return listDedicatedIpPoolsAsync(request, null); } @Override public java.util.concurrent.Future listDedicatedIpPoolsAsync(final ListDedicatedIpPoolsRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final ListDedicatedIpPoolsRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public ListDedicatedIpPoolsResult call() throws Exception { ListDedicatedIpPoolsResult result = null; try { result = executeListDedicatedIpPools(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 listDeliverabilityTestReportsAsync(ListDeliverabilityTestReportsRequest request) { return listDeliverabilityTestReportsAsync(request, null); } @Override public java.util.concurrent.Future listDeliverabilityTestReportsAsync( final ListDeliverabilityTestReportsRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final ListDeliverabilityTestReportsRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public ListDeliverabilityTestReportsResult call() throws Exception { ListDeliverabilityTestReportsResult result = null; try { result = executeListDeliverabilityTestReports(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 listDomainDeliverabilityCampaignsAsync( ListDomainDeliverabilityCampaignsRequest request) { return listDomainDeliverabilityCampaignsAsync(request, null); } @Override public java.util.concurrent.Future listDomainDeliverabilityCampaignsAsync( final ListDomainDeliverabilityCampaignsRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final ListDomainDeliverabilityCampaignsRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public ListDomainDeliverabilityCampaignsResult call() throws Exception { ListDomainDeliverabilityCampaignsResult result = null; try { result = executeListDomainDeliverabilityCampaigns(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 listEmailIdentitiesAsync(ListEmailIdentitiesRequest request) { return listEmailIdentitiesAsync(request, null); } @Override public java.util.concurrent.Future listEmailIdentitiesAsync(final ListEmailIdentitiesRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final ListEmailIdentitiesRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public ListEmailIdentitiesResult call() throws Exception { ListEmailIdentitiesResult result = null; try { result = executeListEmailIdentities(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 listEmailTemplatesAsync(ListEmailTemplatesRequest request) { return listEmailTemplatesAsync(request, null); } @Override public java.util.concurrent.Future listEmailTemplatesAsync(final ListEmailTemplatesRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final ListEmailTemplatesRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public ListEmailTemplatesResult call() throws Exception { ListEmailTemplatesResult result = null; try { result = executeListEmailTemplates(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 listImportJobsAsync(ListImportJobsRequest request) { return listImportJobsAsync(request, null); } @Override public java.util.concurrent.Future listImportJobsAsync(final ListImportJobsRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final ListImportJobsRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public ListImportJobsResult call() throws Exception { ListImportJobsResult result = null; try { result = executeListImportJobs(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 listSuppressedDestinationsAsync(ListSuppressedDestinationsRequest request) { return listSuppressedDestinationsAsync(request, null); } @Override public java.util.concurrent.Future listSuppressedDestinationsAsync(final ListSuppressedDestinationsRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final ListSuppressedDestinationsRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public ListSuppressedDestinationsResult call() throws Exception { ListSuppressedDestinationsResult result = null; try { result = executeListSuppressedDestinations(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 listTagsForResourceAsync(ListTagsForResourceRequest request) { return listTagsForResourceAsync(request, null); } @Override public java.util.concurrent.Future listTagsForResourceAsync(final ListTagsForResourceRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final ListTagsForResourceRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public ListTagsForResourceResult call() throws Exception { ListTagsForResourceResult result = null; try { result = executeListTagsForResource(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 putAccountDedicatedIpWarmupAttributesAsync( PutAccountDedicatedIpWarmupAttributesRequest request) { return putAccountDedicatedIpWarmupAttributesAsync(request, null); } @Override public java.util.concurrent.Future putAccountDedicatedIpWarmupAttributesAsync( final PutAccountDedicatedIpWarmupAttributesRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final PutAccountDedicatedIpWarmupAttributesRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public PutAccountDedicatedIpWarmupAttributesResult call() throws Exception { PutAccountDedicatedIpWarmupAttributesResult result = null; try { result = executePutAccountDedicatedIpWarmupAttributes(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 putAccountDetailsAsync(PutAccountDetailsRequest request) { return putAccountDetailsAsync(request, null); } @Override public java.util.concurrent.Future putAccountDetailsAsync(final PutAccountDetailsRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final PutAccountDetailsRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public PutAccountDetailsResult call() throws Exception { PutAccountDetailsResult result = null; try { result = executePutAccountDetails(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 putAccountSendingAttributesAsync(PutAccountSendingAttributesRequest request) { return putAccountSendingAttributesAsync(request, null); } @Override public java.util.concurrent.Future putAccountSendingAttributesAsync(final PutAccountSendingAttributesRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final PutAccountSendingAttributesRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public PutAccountSendingAttributesResult call() throws Exception { PutAccountSendingAttributesResult result = null; try { result = executePutAccountSendingAttributes(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 putAccountSuppressionAttributesAsync( PutAccountSuppressionAttributesRequest request) { return putAccountSuppressionAttributesAsync(request, null); } @Override public java.util.concurrent.Future putAccountSuppressionAttributesAsync( final PutAccountSuppressionAttributesRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final PutAccountSuppressionAttributesRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public PutAccountSuppressionAttributesResult call() throws Exception { PutAccountSuppressionAttributesResult result = null; try { result = executePutAccountSuppressionAttributes(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 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 putConfigurationSetReputationOptionsAsync( PutConfigurationSetReputationOptionsRequest request) { return putConfigurationSetReputationOptionsAsync(request, null); } @Override public java.util.concurrent.Future putConfigurationSetReputationOptionsAsync( final PutConfigurationSetReputationOptionsRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final PutConfigurationSetReputationOptionsRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public PutConfigurationSetReputationOptionsResult call() throws Exception { PutConfigurationSetReputationOptionsResult result = null; try { result = executePutConfigurationSetReputationOptions(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 putConfigurationSetSendingOptionsAsync( PutConfigurationSetSendingOptionsRequest request) { return putConfigurationSetSendingOptionsAsync(request, null); } @Override public java.util.concurrent.Future putConfigurationSetSendingOptionsAsync( final PutConfigurationSetSendingOptionsRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final PutConfigurationSetSendingOptionsRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public PutConfigurationSetSendingOptionsResult call() throws Exception { PutConfigurationSetSendingOptionsResult result = null; try { result = executePutConfigurationSetSendingOptions(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 putConfigurationSetSuppressionOptionsAsync( PutConfigurationSetSuppressionOptionsRequest request) { return putConfigurationSetSuppressionOptionsAsync(request, null); } @Override public java.util.concurrent.Future putConfigurationSetSuppressionOptionsAsync( final PutConfigurationSetSuppressionOptionsRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final PutConfigurationSetSuppressionOptionsRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public PutConfigurationSetSuppressionOptionsResult call() throws Exception { PutConfigurationSetSuppressionOptionsResult result = null; try { result = executePutConfigurationSetSuppressionOptions(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 putConfigurationSetTrackingOptionsAsync( PutConfigurationSetTrackingOptionsRequest request) { return putConfigurationSetTrackingOptionsAsync(request, null); } @Override public java.util.concurrent.Future putConfigurationSetTrackingOptionsAsync( final PutConfigurationSetTrackingOptionsRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final PutConfigurationSetTrackingOptionsRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public PutConfigurationSetTrackingOptionsResult call() throws Exception { PutConfigurationSetTrackingOptionsResult result = null; try { result = executePutConfigurationSetTrackingOptions(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 putDedicatedIpInPoolAsync(PutDedicatedIpInPoolRequest request) { return putDedicatedIpInPoolAsync(request, null); } @Override public java.util.concurrent.Future putDedicatedIpInPoolAsync(final PutDedicatedIpInPoolRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final PutDedicatedIpInPoolRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public PutDedicatedIpInPoolResult call() throws Exception { PutDedicatedIpInPoolResult result = null; try { result = executePutDedicatedIpInPool(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 putDedicatedIpWarmupAttributesAsync(PutDedicatedIpWarmupAttributesRequest request) { return putDedicatedIpWarmupAttributesAsync(request, null); } @Override public java.util.concurrent.Future putDedicatedIpWarmupAttributesAsync( final PutDedicatedIpWarmupAttributesRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final PutDedicatedIpWarmupAttributesRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public PutDedicatedIpWarmupAttributesResult call() throws Exception { PutDedicatedIpWarmupAttributesResult result = null; try { result = executePutDedicatedIpWarmupAttributes(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 putDeliverabilityDashboardOptionAsync( PutDeliverabilityDashboardOptionRequest request) { return putDeliverabilityDashboardOptionAsync(request, null); } @Override public java.util.concurrent.Future putDeliverabilityDashboardOptionAsync( final PutDeliverabilityDashboardOptionRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final PutDeliverabilityDashboardOptionRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public PutDeliverabilityDashboardOptionResult call() throws Exception { PutDeliverabilityDashboardOptionResult result = null; try { result = executePutDeliverabilityDashboardOption(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 putEmailIdentityConfigurationSetAttributesAsync( PutEmailIdentityConfigurationSetAttributesRequest request) { return putEmailIdentityConfigurationSetAttributesAsync(request, null); } @Override public java.util.concurrent.Future putEmailIdentityConfigurationSetAttributesAsync( final PutEmailIdentityConfigurationSetAttributesRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final PutEmailIdentityConfigurationSetAttributesRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public PutEmailIdentityConfigurationSetAttributesResult call() throws Exception { PutEmailIdentityConfigurationSetAttributesResult result = null; try { result = executePutEmailIdentityConfigurationSetAttributes(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 putEmailIdentityDkimAttributesAsync(PutEmailIdentityDkimAttributesRequest request) { return putEmailIdentityDkimAttributesAsync(request, null); } @Override public java.util.concurrent.Future putEmailIdentityDkimAttributesAsync( final PutEmailIdentityDkimAttributesRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final PutEmailIdentityDkimAttributesRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public PutEmailIdentityDkimAttributesResult call() throws Exception { PutEmailIdentityDkimAttributesResult result = null; try { result = executePutEmailIdentityDkimAttributes(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 putEmailIdentityDkimSigningAttributesAsync( PutEmailIdentityDkimSigningAttributesRequest request) { return putEmailIdentityDkimSigningAttributesAsync(request, null); } @Override public java.util.concurrent.Future putEmailIdentityDkimSigningAttributesAsync( final PutEmailIdentityDkimSigningAttributesRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final PutEmailIdentityDkimSigningAttributesRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public PutEmailIdentityDkimSigningAttributesResult call() throws Exception { PutEmailIdentityDkimSigningAttributesResult result = null; try { result = executePutEmailIdentityDkimSigningAttributes(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 putEmailIdentityFeedbackAttributesAsync( PutEmailIdentityFeedbackAttributesRequest request) { return putEmailIdentityFeedbackAttributesAsync(request, null); } @Override public java.util.concurrent.Future putEmailIdentityFeedbackAttributesAsync( final PutEmailIdentityFeedbackAttributesRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final PutEmailIdentityFeedbackAttributesRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public PutEmailIdentityFeedbackAttributesResult call() throws Exception { PutEmailIdentityFeedbackAttributesResult result = null; try { result = executePutEmailIdentityFeedbackAttributes(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 putEmailIdentityMailFromAttributesAsync( PutEmailIdentityMailFromAttributesRequest request) { return putEmailIdentityMailFromAttributesAsync(request, null); } @Override public java.util.concurrent.Future putEmailIdentityMailFromAttributesAsync( final PutEmailIdentityMailFromAttributesRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final PutEmailIdentityMailFromAttributesRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public PutEmailIdentityMailFromAttributesResult call() throws Exception { PutEmailIdentityMailFromAttributesResult result = null; try { result = executePutEmailIdentityMailFromAttributes(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 putSuppressedDestinationAsync(PutSuppressedDestinationRequest request) { return putSuppressedDestinationAsync(request, null); } @Override public java.util.concurrent.Future putSuppressedDestinationAsync(final PutSuppressedDestinationRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final PutSuppressedDestinationRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public PutSuppressedDestinationResult call() throws Exception { PutSuppressedDestinationResult result = null; try { result = executePutSuppressedDestination(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 sendBulkEmailAsync(SendBulkEmailRequest request) { return sendBulkEmailAsync(request, null); } @Override public java.util.concurrent.Future sendBulkEmailAsync(final SendBulkEmailRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final SendBulkEmailRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public SendBulkEmailResult call() throws Exception { SendBulkEmailResult result = null; try { result = executeSendBulkEmail(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 tagResourceAsync(TagResourceRequest request) { return tagResourceAsync(request, null); } @Override public java.util.concurrent.Future tagResourceAsync(final TagResourceRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final TagResourceRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public TagResourceResult call() throws Exception { TagResourceResult result = null; try { result = executeTagResource(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 testRenderEmailTemplateAsync(TestRenderEmailTemplateRequest request) { return testRenderEmailTemplateAsync(request, null); } @Override public java.util.concurrent.Future testRenderEmailTemplateAsync(final TestRenderEmailTemplateRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final TestRenderEmailTemplateRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public TestRenderEmailTemplateResult call() throws Exception { TestRenderEmailTemplateResult result = null; try { result = executeTestRenderEmailTemplate(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 untagResourceAsync(UntagResourceRequest request) { return untagResourceAsync(request, null); } @Override public java.util.concurrent.Future untagResourceAsync(final UntagResourceRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final UntagResourceRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public UntagResourceResult call() throws Exception { UntagResourceResult result = null; try { result = executeUntagResource(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 updateConfigurationSetEventDestinationAsync( UpdateConfigurationSetEventDestinationRequest request) { return updateConfigurationSetEventDestinationAsync(request, null); } @Override public java.util.concurrent.Future updateConfigurationSetEventDestinationAsync( final UpdateConfigurationSetEventDestinationRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final UpdateConfigurationSetEventDestinationRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public UpdateConfigurationSetEventDestinationResult call() throws Exception { UpdateConfigurationSetEventDestinationResult result = null; try { result = executeUpdateConfigurationSetEventDestination(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 updateContactAsync(UpdateContactRequest request) { return updateContactAsync(request, null); } @Override public java.util.concurrent.Future updateContactAsync(final UpdateContactRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final UpdateContactRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public UpdateContactResult call() throws Exception { UpdateContactResult result = null; try { result = executeUpdateContact(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 updateContactListAsync(UpdateContactListRequest request) { return updateContactListAsync(request, null); } @Override public java.util.concurrent.Future updateContactListAsync(final UpdateContactListRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final UpdateContactListRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public UpdateContactListResult call() throws Exception { UpdateContactListResult result = null; try { result = executeUpdateContactList(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 updateCustomVerificationEmailTemplateAsync( UpdateCustomVerificationEmailTemplateRequest request) { return updateCustomVerificationEmailTemplateAsync(request, null); } @Override public java.util.concurrent.Future updateCustomVerificationEmailTemplateAsync( final UpdateCustomVerificationEmailTemplateRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final UpdateCustomVerificationEmailTemplateRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public UpdateCustomVerificationEmailTemplateResult call() throws Exception { UpdateCustomVerificationEmailTemplateResult result = null; try { result = executeUpdateCustomVerificationEmailTemplate(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 updateEmailIdentityPolicyAsync(UpdateEmailIdentityPolicyRequest request) { return updateEmailIdentityPolicyAsync(request, null); } @Override public java.util.concurrent.Future updateEmailIdentityPolicyAsync(final UpdateEmailIdentityPolicyRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final UpdateEmailIdentityPolicyRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public UpdateEmailIdentityPolicyResult call() throws Exception { UpdateEmailIdentityPolicyResult result = null; try { result = executeUpdateEmailIdentityPolicy(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 updateEmailTemplateAsync(UpdateEmailTemplateRequest request) { return updateEmailTemplateAsync(request, null); } @Override public java.util.concurrent.Future updateEmailTemplateAsync(final UpdateEmailTemplateRequest request, final com.amazonaws.handlers.AsyncHandler asyncHandler) { final UpdateEmailTemplateRequest finalRequest = beforeClientExecution(request); return executorService.submit(new java.util.concurrent.Callable() { @Override public UpdateEmailTemplateResult call() throws Exception { UpdateEmailTemplateResult result = null; try { result = executeUpdateEmailTemplate(finalRequest); } catch (Exception ex) { if (asyncHandler != null) { asyncHandler.onError(ex); } throw ex; } if (asyncHandler != null) { asyncHandler.onSuccess(finalRequest, result); } return result; } }); } /** * Shuts down the client, releasing all managed resources. This includes forcibly terminating all pending * asynchronous service calls. Clients who wish to give pending asynchronous service calls time to complete should * call {@code getExecutorService().shutdown()} followed by {@code getExecutorService().awaitTermination()} prior to * calling this method. */ @Override public void shutdown() { super.shutdown(); executorService.shutdownNow(); } }




© 2015 - 2025 Weber Informatics LLC | Privacy Policy