com.amazonaws.services.chimesdkvoice.AmazonChimeSDKVoiceAsyncClient Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of aws-java-sdk-chimesdkvoice Show documentation
Show all versions of aws-java-sdk-chimesdkvoice Show documentation
The AWS Java SDK for Amazon Chime SDK Voice module holds the client classes that are used for communicating with Amazon Chime SDK Voice Service
/*
* Copyright 2018-2023 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.chimesdkvoice;
import javax.annotation.Generated;
import com.amazonaws.services.chimesdkvoice.model.*;
import com.amazonaws.client.AwsAsyncClientParams;
import com.amazonaws.annotation.ThreadSafe;
import java.util.concurrent.ExecutorService;
/**
* Client for accessing Amazon Chime SDK Voice 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.
*
*
* The Amazon Chime SDK telephony APIs in this section enable developers to create PSTN calling solutions that use
* Amazon Chime SDK Voice Connectors, and Amazon Chime SDK SIP media applications. Developers can also order and manage
* phone numbers, create and manage Voice Connectors and SIP media applications, and run voice analytics.
*
*/
@ThreadSafe
@Generated("com.amazonaws:aws-java-sdk-code-generator")
public class AmazonChimeSDKVoiceAsyncClient extends AmazonChimeSDKVoiceClient implements AmazonChimeSDKVoiceAsync {
private static final int DEFAULT_THREAD_POOL_SIZE = 50;
private final java.util.concurrent.ExecutorService executorService;
public static AmazonChimeSDKVoiceAsyncClientBuilder asyncBuilder() {
return AmazonChimeSDKVoiceAsyncClientBuilder.standard();
}
/**
* Constructs a new asynchronous client to invoke service methods on Amazon Chime SDK Voice using the specified
* parameters.
*
* @param asyncClientParams
* Object providing client parameters.
*/
AmazonChimeSDKVoiceAsyncClient(AwsAsyncClientParams asyncClientParams) {
this(asyncClientParams, false);
}
/**
* Constructs a new asynchronous client to invoke service methods on Amazon Chime SDK Voice using the specified
* parameters.
*
* @param asyncClientParams
* Object providing client parameters.
* @param endpointDiscoveryEnabled
* true will enable endpoint discovery if the service supports it.
*/
AmazonChimeSDKVoiceAsyncClient(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 associatePhoneNumbersWithVoiceConnectorAsync(
AssociatePhoneNumbersWithVoiceConnectorRequest request) {
return associatePhoneNumbersWithVoiceConnectorAsync(request, null);
}
@Override
public java.util.concurrent.Future associatePhoneNumbersWithVoiceConnectorAsync(
final AssociatePhoneNumbersWithVoiceConnectorRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final AssociatePhoneNumbersWithVoiceConnectorRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public AssociatePhoneNumbersWithVoiceConnectorResult call() throws Exception {
AssociatePhoneNumbersWithVoiceConnectorResult result = null;
try {
result = executeAssociatePhoneNumbersWithVoiceConnector(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 associatePhoneNumbersWithVoiceConnectorGroupAsync(
AssociatePhoneNumbersWithVoiceConnectorGroupRequest request) {
return associatePhoneNumbersWithVoiceConnectorGroupAsync(request, null);
}
@Override
public java.util.concurrent.Future associatePhoneNumbersWithVoiceConnectorGroupAsync(
final AssociatePhoneNumbersWithVoiceConnectorGroupRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final AssociatePhoneNumbersWithVoiceConnectorGroupRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public AssociatePhoneNumbersWithVoiceConnectorGroupResult call() throws Exception {
AssociatePhoneNumbersWithVoiceConnectorGroupResult result = null;
try {
result = executeAssociatePhoneNumbersWithVoiceConnectorGroup(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 batchDeletePhoneNumberAsync(BatchDeletePhoneNumberRequest request) {
return batchDeletePhoneNumberAsync(request, null);
}
@Override
public java.util.concurrent.Future batchDeletePhoneNumberAsync(final BatchDeletePhoneNumberRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final BatchDeletePhoneNumberRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public BatchDeletePhoneNumberResult call() throws Exception {
BatchDeletePhoneNumberResult result = null;
try {
result = executeBatchDeletePhoneNumber(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 batchUpdatePhoneNumberAsync(BatchUpdatePhoneNumberRequest request) {
return batchUpdatePhoneNumberAsync(request, null);
}
@Override
public java.util.concurrent.Future batchUpdatePhoneNumberAsync(final BatchUpdatePhoneNumberRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final BatchUpdatePhoneNumberRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public BatchUpdatePhoneNumberResult call() throws Exception {
BatchUpdatePhoneNumberResult result = null;
try {
result = executeBatchUpdatePhoneNumber(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 createPhoneNumberOrderAsync(CreatePhoneNumberOrderRequest request) {
return createPhoneNumberOrderAsync(request, null);
}
@Override
public java.util.concurrent.Future createPhoneNumberOrderAsync(final CreatePhoneNumberOrderRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final CreatePhoneNumberOrderRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public CreatePhoneNumberOrderResult call() throws Exception {
CreatePhoneNumberOrderResult result = null;
try {
result = executeCreatePhoneNumberOrder(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 createProxySessionAsync(CreateProxySessionRequest request) {
return createProxySessionAsync(request, null);
}
@Override
public java.util.concurrent.Future createProxySessionAsync(final CreateProxySessionRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final CreateProxySessionRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public CreateProxySessionResult call() throws Exception {
CreateProxySessionResult result = null;
try {
result = executeCreateProxySession(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 createSipMediaApplicationAsync(CreateSipMediaApplicationRequest request) {
return createSipMediaApplicationAsync(request, null);
}
@Override
public java.util.concurrent.Future createSipMediaApplicationAsync(final CreateSipMediaApplicationRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final CreateSipMediaApplicationRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public CreateSipMediaApplicationResult call() throws Exception {
CreateSipMediaApplicationResult result = null;
try {
result = executeCreateSipMediaApplication(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 createSipMediaApplicationCallAsync(CreateSipMediaApplicationCallRequest request) {
return createSipMediaApplicationCallAsync(request, null);
}
@Override
public java.util.concurrent.Future createSipMediaApplicationCallAsync(
final CreateSipMediaApplicationCallRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final CreateSipMediaApplicationCallRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public CreateSipMediaApplicationCallResult call() throws Exception {
CreateSipMediaApplicationCallResult result = null;
try {
result = executeCreateSipMediaApplicationCall(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 createSipRuleAsync(CreateSipRuleRequest request) {
return createSipRuleAsync(request, null);
}
@Override
public java.util.concurrent.Future createSipRuleAsync(final CreateSipRuleRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final CreateSipRuleRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public CreateSipRuleResult call() throws Exception {
CreateSipRuleResult result = null;
try {
result = executeCreateSipRule(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 createVoiceConnectorAsync(CreateVoiceConnectorRequest request) {
return createVoiceConnectorAsync(request, null);
}
@Override
public java.util.concurrent.Future createVoiceConnectorAsync(final CreateVoiceConnectorRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final CreateVoiceConnectorRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public CreateVoiceConnectorResult call() throws Exception {
CreateVoiceConnectorResult result = null;
try {
result = executeCreateVoiceConnector(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 createVoiceConnectorGroupAsync(CreateVoiceConnectorGroupRequest request) {
return createVoiceConnectorGroupAsync(request, null);
}
@Override
public java.util.concurrent.Future createVoiceConnectorGroupAsync(final CreateVoiceConnectorGroupRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final CreateVoiceConnectorGroupRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public CreateVoiceConnectorGroupResult call() throws Exception {
CreateVoiceConnectorGroupResult result = null;
try {
result = executeCreateVoiceConnectorGroup(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 createVoiceProfileAsync(CreateVoiceProfileRequest request) {
return createVoiceProfileAsync(request, null);
}
@Override
public java.util.concurrent.Future createVoiceProfileAsync(final CreateVoiceProfileRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final CreateVoiceProfileRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public CreateVoiceProfileResult call() throws Exception {
CreateVoiceProfileResult result = null;
try {
result = executeCreateVoiceProfile(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 createVoiceProfileDomainAsync(CreateVoiceProfileDomainRequest request) {
return createVoiceProfileDomainAsync(request, null);
}
@Override
public java.util.concurrent.Future createVoiceProfileDomainAsync(final CreateVoiceProfileDomainRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final CreateVoiceProfileDomainRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public CreateVoiceProfileDomainResult call() throws Exception {
CreateVoiceProfileDomainResult result = null;
try {
result = executeCreateVoiceProfileDomain(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 deletePhoneNumberAsync(DeletePhoneNumberRequest request) {
return deletePhoneNumberAsync(request, null);
}
@Override
public java.util.concurrent.Future deletePhoneNumberAsync(final DeletePhoneNumberRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final DeletePhoneNumberRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public DeletePhoneNumberResult call() throws Exception {
DeletePhoneNumberResult result = null;
try {
result = executeDeletePhoneNumber(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 deleteProxySessionAsync(DeleteProxySessionRequest request) {
return deleteProxySessionAsync(request, null);
}
@Override
public java.util.concurrent.Future deleteProxySessionAsync(final DeleteProxySessionRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final DeleteProxySessionRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public DeleteProxySessionResult call() throws Exception {
DeleteProxySessionResult result = null;
try {
result = executeDeleteProxySession(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 deleteSipMediaApplicationAsync(DeleteSipMediaApplicationRequest request) {
return deleteSipMediaApplicationAsync(request, null);
}
@Override
public java.util.concurrent.Future deleteSipMediaApplicationAsync(final DeleteSipMediaApplicationRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final DeleteSipMediaApplicationRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public DeleteSipMediaApplicationResult call() throws Exception {
DeleteSipMediaApplicationResult result = null;
try {
result = executeDeleteSipMediaApplication(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 deleteSipRuleAsync(DeleteSipRuleRequest request) {
return deleteSipRuleAsync(request, null);
}
@Override
public java.util.concurrent.Future deleteSipRuleAsync(final DeleteSipRuleRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final DeleteSipRuleRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public DeleteSipRuleResult call() throws Exception {
DeleteSipRuleResult result = null;
try {
result = executeDeleteSipRule(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 deleteVoiceConnectorAsync(DeleteVoiceConnectorRequest request) {
return deleteVoiceConnectorAsync(request, null);
}
@Override
public java.util.concurrent.Future deleteVoiceConnectorAsync(final DeleteVoiceConnectorRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final DeleteVoiceConnectorRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public DeleteVoiceConnectorResult call() throws Exception {
DeleteVoiceConnectorResult result = null;
try {
result = executeDeleteVoiceConnector(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 deleteVoiceConnectorEmergencyCallingConfigurationAsync(
DeleteVoiceConnectorEmergencyCallingConfigurationRequest request) {
return deleteVoiceConnectorEmergencyCallingConfigurationAsync(request, null);
}
@Override
public java.util.concurrent.Future deleteVoiceConnectorEmergencyCallingConfigurationAsync(
final DeleteVoiceConnectorEmergencyCallingConfigurationRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final DeleteVoiceConnectorEmergencyCallingConfigurationRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public DeleteVoiceConnectorEmergencyCallingConfigurationResult call() throws Exception {
DeleteVoiceConnectorEmergencyCallingConfigurationResult result = null;
try {
result = executeDeleteVoiceConnectorEmergencyCallingConfiguration(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 deleteVoiceConnectorGroupAsync(DeleteVoiceConnectorGroupRequest request) {
return deleteVoiceConnectorGroupAsync(request, null);
}
@Override
public java.util.concurrent.Future deleteVoiceConnectorGroupAsync(final DeleteVoiceConnectorGroupRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final DeleteVoiceConnectorGroupRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public DeleteVoiceConnectorGroupResult call() throws Exception {
DeleteVoiceConnectorGroupResult result = null;
try {
result = executeDeleteVoiceConnectorGroup(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 deleteVoiceConnectorOriginationAsync(
DeleteVoiceConnectorOriginationRequest request) {
return deleteVoiceConnectorOriginationAsync(request, null);
}
@Override
public java.util.concurrent.Future deleteVoiceConnectorOriginationAsync(
final DeleteVoiceConnectorOriginationRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final DeleteVoiceConnectorOriginationRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public DeleteVoiceConnectorOriginationResult call() throws Exception {
DeleteVoiceConnectorOriginationResult result = null;
try {
result = executeDeleteVoiceConnectorOrigination(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 deleteVoiceConnectorProxyAsync(DeleteVoiceConnectorProxyRequest request) {
return deleteVoiceConnectorProxyAsync(request, null);
}
@Override
public java.util.concurrent.Future deleteVoiceConnectorProxyAsync(final DeleteVoiceConnectorProxyRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final DeleteVoiceConnectorProxyRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public DeleteVoiceConnectorProxyResult call() throws Exception {
DeleteVoiceConnectorProxyResult result = null;
try {
result = executeDeleteVoiceConnectorProxy(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 deleteVoiceConnectorStreamingConfigurationAsync(
DeleteVoiceConnectorStreamingConfigurationRequest request) {
return deleteVoiceConnectorStreamingConfigurationAsync(request, null);
}
@Override
public java.util.concurrent.Future deleteVoiceConnectorStreamingConfigurationAsync(
final DeleteVoiceConnectorStreamingConfigurationRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final DeleteVoiceConnectorStreamingConfigurationRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public DeleteVoiceConnectorStreamingConfigurationResult call() throws Exception {
DeleteVoiceConnectorStreamingConfigurationResult result = null;
try {
result = executeDeleteVoiceConnectorStreamingConfiguration(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 deleteVoiceConnectorTerminationAsync(
DeleteVoiceConnectorTerminationRequest request) {
return deleteVoiceConnectorTerminationAsync(request, null);
}
@Override
public java.util.concurrent.Future deleteVoiceConnectorTerminationAsync(
final DeleteVoiceConnectorTerminationRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final DeleteVoiceConnectorTerminationRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public DeleteVoiceConnectorTerminationResult call() throws Exception {
DeleteVoiceConnectorTerminationResult result = null;
try {
result = executeDeleteVoiceConnectorTermination(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 deleteVoiceConnectorTerminationCredentialsAsync(
DeleteVoiceConnectorTerminationCredentialsRequest request) {
return deleteVoiceConnectorTerminationCredentialsAsync(request, null);
}
@Override
public java.util.concurrent.Future deleteVoiceConnectorTerminationCredentialsAsync(
final DeleteVoiceConnectorTerminationCredentialsRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final DeleteVoiceConnectorTerminationCredentialsRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public DeleteVoiceConnectorTerminationCredentialsResult call() throws Exception {
DeleteVoiceConnectorTerminationCredentialsResult result = null;
try {
result = executeDeleteVoiceConnectorTerminationCredentials(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 deleteVoiceProfileAsync(DeleteVoiceProfileRequest request) {
return deleteVoiceProfileAsync(request, null);
}
@Override
public java.util.concurrent.Future deleteVoiceProfileAsync(final DeleteVoiceProfileRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final DeleteVoiceProfileRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public DeleteVoiceProfileResult call() throws Exception {
DeleteVoiceProfileResult result = null;
try {
result = executeDeleteVoiceProfile(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 deleteVoiceProfileDomainAsync(DeleteVoiceProfileDomainRequest request) {
return deleteVoiceProfileDomainAsync(request, null);
}
@Override
public java.util.concurrent.Future deleteVoiceProfileDomainAsync(final DeleteVoiceProfileDomainRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final DeleteVoiceProfileDomainRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public DeleteVoiceProfileDomainResult call() throws Exception {
DeleteVoiceProfileDomainResult result = null;
try {
result = executeDeleteVoiceProfileDomain(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 disassociatePhoneNumbersFromVoiceConnectorAsync(
DisassociatePhoneNumbersFromVoiceConnectorRequest request) {
return disassociatePhoneNumbersFromVoiceConnectorAsync(request, null);
}
@Override
public java.util.concurrent.Future disassociatePhoneNumbersFromVoiceConnectorAsync(
final DisassociatePhoneNumbersFromVoiceConnectorRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final DisassociatePhoneNumbersFromVoiceConnectorRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public DisassociatePhoneNumbersFromVoiceConnectorResult call() throws Exception {
DisassociatePhoneNumbersFromVoiceConnectorResult result = null;
try {
result = executeDisassociatePhoneNumbersFromVoiceConnector(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 disassociatePhoneNumbersFromVoiceConnectorGroupAsync(
DisassociatePhoneNumbersFromVoiceConnectorGroupRequest request) {
return disassociatePhoneNumbersFromVoiceConnectorGroupAsync(request, null);
}
@Override
public java.util.concurrent.Future disassociatePhoneNumbersFromVoiceConnectorGroupAsync(
final DisassociatePhoneNumbersFromVoiceConnectorGroupRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final DisassociatePhoneNumbersFromVoiceConnectorGroupRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public DisassociatePhoneNumbersFromVoiceConnectorGroupResult call() throws Exception {
DisassociatePhoneNumbersFromVoiceConnectorGroupResult result = null;
try {
result = executeDisassociatePhoneNumbersFromVoiceConnectorGroup(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 getGlobalSettingsAsync(GetGlobalSettingsRequest request) {
return getGlobalSettingsAsync(request, null);
}
@Override
public java.util.concurrent.Future getGlobalSettingsAsync(final GetGlobalSettingsRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final GetGlobalSettingsRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public GetGlobalSettingsResult call() throws Exception {
GetGlobalSettingsResult result = null;
try {
result = executeGetGlobalSettings(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 getPhoneNumberAsync(GetPhoneNumberRequest request) {
return getPhoneNumberAsync(request, null);
}
@Override
public java.util.concurrent.Future getPhoneNumberAsync(final GetPhoneNumberRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final GetPhoneNumberRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public GetPhoneNumberResult call() throws Exception {
GetPhoneNumberResult result = null;
try {
result = executeGetPhoneNumber(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 getPhoneNumberOrderAsync(GetPhoneNumberOrderRequest request) {
return getPhoneNumberOrderAsync(request, null);
}
@Override
public java.util.concurrent.Future getPhoneNumberOrderAsync(final GetPhoneNumberOrderRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final GetPhoneNumberOrderRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public GetPhoneNumberOrderResult call() throws Exception {
GetPhoneNumberOrderResult result = null;
try {
result = executeGetPhoneNumberOrder(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 getPhoneNumberSettingsAsync(GetPhoneNumberSettingsRequest request) {
return getPhoneNumberSettingsAsync(request, null);
}
@Override
public java.util.concurrent.Future getPhoneNumberSettingsAsync(final GetPhoneNumberSettingsRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final GetPhoneNumberSettingsRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public GetPhoneNumberSettingsResult call() throws Exception {
GetPhoneNumberSettingsResult result = null;
try {
result = executeGetPhoneNumberSettings(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 getProxySessionAsync(GetProxySessionRequest request) {
return getProxySessionAsync(request, null);
}
@Override
public java.util.concurrent.Future getProxySessionAsync(final GetProxySessionRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final GetProxySessionRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public GetProxySessionResult call() throws Exception {
GetProxySessionResult result = null;
try {
result = executeGetProxySession(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 getSipMediaApplicationAsync(GetSipMediaApplicationRequest request) {
return getSipMediaApplicationAsync(request, null);
}
@Override
public java.util.concurrent.Future getSipMediaApplicationAsync(final GetSipMediaApplicationRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final GetSipMediaApplicationRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public GetSipMediaApplicationResult call() throws Exception {
GetSipMediaApplicationResult result = null;
try {
result = executeGetSipMediaApplication(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 getSipMediaApplicationAlexaSkillConfigurationAsync(
GetSipMediaApplicationAlexaSkillConfigurationRequest request) {
return getSipMediaApplicationAlexaSkillConfigurationAsync(request, null);
}
@Override
public java.util.concurrent.Future getSipMediaApplicationAlexaSkillConfigurationAsync(
final GetSipMediaApplicationAlexaSkillConfigurationRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final GetSipMediaApplicationAlexaSkillConfigurationRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public GetSipMediaApplicationAlexaSkillConfigurationResult call() throws Exception {
GetSipMediaApplicationAlexaSkillConfigurationResult result = null;
try {
result = executeGetSipMediaApplicationAlexaSkillConfiguration(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 getSipMediaApplicationLoggingConfigurationAsync(
GetSipMediaApplicationLoggingConfigurationRequest request) {
return getSipMediaApplicationLoggingConfigurationAsync(request, null);
}
@Override
public java.util.concurrent.Future getSipMediaApplicationLoggingConfigurationAsync(
final GetSipMediaApplicationLoggingConfigurationRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final GetSipMediaApplicationLoggingConfigurationRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public GetSipMediaApplicationLoggingConfigurationResult call() throws Exception {
GetSipMediaApplicationLoggingConfigurationResult result = null;
try {
result = executeGetSipMediaApplicationLoggingConfiguration(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 getSipRuleAsync(GetSipRuleRequest request) {
return getSipRuleAsync(request, null);
}
@Override
public java.util.concurrent.Future getSipRuleAsync(final GetSipRuleRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final GetSipRuleRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public GetSipRuleResult call() throws Exception {
GetSipRuleResult result = null;
try {
result = executeGetSipRule(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 getSpeakerSearchTaskAsync(GetSpeakerSearchTaskRequest request) {
return getSpeakerSearchTaskAsync(request, null);
}
@Override
public java.util.concurrent.Future getSpeakerSearchTaskAsync(final GetSpeakerSearchTaskRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final GetSpeakerSearchTaskRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public GetSpeakerSearchTaskResult call() throws Exception {
GetSpeakerSearchTaskResult result = null;
try {
result = executeGetSpeakerSearchTask(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 getVoiceConnectorAsync(GetVoiceConnectorRequest request) {
return getVoiceConnectorAsync(request, null);
}
@Override
public java.util.concurrent.Future getVoiceConnectorAsync(final GetVoiceConnectorRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final GetVoiceConnectorRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public GetVoiceConnectorResult call() throws Exception {
GetVoiceConnectorResult result = null;
try {
result = executeGetVoiceConnector(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 getVoiceConnectorEmergencyCallingConfigurationAsync(
GetVoiceConnectorEmergencyCallingConfigurationRequest request) {
return getVoiceConnectorEmergencyCallingConfigurationAsync(request, null);
}
@Override
public java.util.concurrent.Future getVoiceConnectorEmergencyCallingConfigurationAsync(
final GetVoiceConnectorEmergencyCallingConfigurationRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final GetVoiceConnectorEmergencyCallingConfigurationRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public GetVoiceConnectorEmergencyCallingConfigurationResult call() throws Exception {
GetVoiceConnectorEmergencyCallingConfigurationResult result = null;
try {
result = executeGetVoiceConnectorEmergencyCallingConfiguration(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 getVoiceConnectorGroupAsync(GetVoiceConnectorGroupRequest request) {
return getVoiceConnectorGroupAsync(request, null);
}
@Override
public java.util.concurrent.Future getVoiceConnectorGroupAsync(final GetVoiceConnectorGroupRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final GetVoiceConnectorGroupRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public GetVoiceConnectorGroupResult call() throws Exception {
GetVoiceConnectorGroupResult result = null;
try {
result = executeGetVoiceConnectorGroup(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 getVoiceConnectorLoggingConfigurationAsync(
GetVoiceConnectorLoggingConfigurationRequest request) {
return getVoiceConnectorLoggingConfigurationAsync(request, null);
}
@Override
public java.util.concurrent.Future getVoiceConnectorLoggingConfigurationAsync(
final GetVoiceConnectorLoggingConfigurationRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final GetVoiceConnectorLoggingConfigurationRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public GetVoiceConnectorLoggingConfigurationResult call() throws Exception {
GetVoiceConnectorLoggingConfigurationResult result = null;
try {
result = executeGetVoiceConnectorLoggingConfiguration(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 getVoiceConnectorOriginationAsync(GetVoiceConnectorOriginationRequest request) {
return getVoiceConnectorOriginationAsync(request, null);
}
@Override
public java.util.concurrent.Future getVoiceConnectorOriginationAsync(final GetVoiceConnectorOriginationRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final GetVoiceConnectorOriginationRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public GetVoiceConnectorOriginationResult call() throws Exception {
GetVoiceConnectorOriginationResult result = null;
try {
result = executeGetVoiceConnectorOrigination(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 getVoiceConnectorProxyAsync(GetVoiceConnectorProxyRequest request) {
return getVoiceConnectorProxyAsync(request, null);
}
@Override
public java.util.concurrent.Future getVoiceConnectorProxyAsync(final GetVoiceConnectorProxyRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final GetVoiceConnectorProxyRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public GetVoiceConnectorProxyResult call() throws Exception {
GetVoiceConnectorProxyResult result = null;
try {
result = executeGetVoiceConnectorProxy(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 getVoiceConnectorStreamingConfigurationAsync(
GetVoiceConnectorStreamingConfigurationRequest request) {
return getVoiceConnectorStreamingConfigurationAsync(request, null);
}
@Override
public java.util.concurrent.Future getVoiceConnectorStreamingConfigurationAsync(
final GetVoiceConnectorStreamingConfigurationRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final GetVoiceConnectorStreamingConfigurationRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public GetVoiceConnectorStreamingConfigurationResult call() throws Exception {
GetVoiceConnectorStreamingConfigurationResult result = null;
try {
result = executeGetVoiceConnectorStreamingConfiguration(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 getVoiceConnectorTerminationAsync(GetVoiceConnectorTerminationRequest request) {
return getVoiceConnectorTerminationAsync(request, null);
}
@Override
public java.util.concurrent.Future getVoiceConnectorTerminationAsync(final GetVoiceConnectorTerminationRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final GetVoiceConnectorTerminationRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public GetVoiceConnectorTerminationResult call() throws Exception {
GetVoiceConnectorTerminationResult result = null;
try {
result = executeGetVoiceConnectorTermination(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 getVoiceConnectorTerminationHealthAsync(
GetVoiceConnectorTerminationHealthRequest request) {
return getVoiceConnectorTerminationHealthAsync(request, null);
}
@Override
public java.util.concurrent.Future getVoiceConnectorTerminationHealthAsync(
final GetVoiceConnectorTerminationHealthRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final GetVoiceConnectorTerminationHealthRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public GetVoiceConnectorTerminationHealthResult call() throws Exception {
GetVoiceConnectorTerminationHealthResult result = null;
try {
result = executeGetVoiceConnectorTerminationHealth(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 getVoiceProfileAsync(GetVoiceProfileRequest request) {
return getVoiceProfileAsync(request, null);
}
@Override
public java.util.concurrent.Future getVoiceProfileAsync(final GetVoiceProfileRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final GetVoiceProfileRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public GetVoiceProfileResult call() throws Exception {
GetVoiceProfileResult result = null;
try {
result = executeGetVoiceProfile(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 getVoiceProfileDomainAsync(GetVoiceProfileDomainRequest request) {
return getVoiceProfileDomainAsync(request, null);
}
@Override
public java.util.concurrent.Future getVoiceProfileDomainAsync(final GetVoiceProfileDomainRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final GetVoiceProfileDomainRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public GetVoiceProfileDomainResult call() throws Exception {
GetVoiceProfileDomainResult result = null;
try {
result = executeGetVoiceProfileDomain(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 getVoiceToneAnalysisTaskAsync(GetVoiceToneAnalysisTaskRequest request) {
return getVoiceToneAnalysisTaskAsync(request, null);
}
@Override
public java.util.concurrent.Future getVoiceToneAnalysisTaskAsync(final GetVoiceToneAnalysisTaskRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final GetVoiceToneAnalysisTaskRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public GetVoiceToneAnalysisTaskResult call() throws Exception {
GetVoiceToneAnalysisTaskResult result = null;
try {
result = executeGetVoiceToneAnalysisTask(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 listAvailableVoiceConnectorRegionsAsync(
ListAvailableVoiceConnectorRegionsRequest request) {
return listAvailableVoiceConnectorRegionsAsync(request, null);
}
@Override
public java.util.concurrent.Future listAvailableVoiceConnectorRegionsAsync(
final ListAvailableVoiceConnectorRegionsRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final ListAvailableVoiceConnectorRegionsRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public ListAvailableVoiceConnectorRegionsResult call() throws Exception {
ListAvailableVoiceConnectorRegionsResult result = null;
try {
result = executeListAvailableVoiceConnectorRegions(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 listPhoneNumberOrdersAsync(ListPhoneNumberOrdersRequest request) {
return listPhoneNumberOrdersAsync(request, null);
}
@Override
public java.util.concurrent.Future listPhoneNumberOrdersAsync(final ListPhoneNumberOrdersRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final ListPhoneNumberOrdersRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public ListPhoneNumberOrdersResult call() throws Exception {
ListPhoneNumberOrdersResult result = null;
try {
result = executeListPhoneNumberOrders(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 listPhoneNumbersAsync(ListPhoneNumbersRequest request) {
return listPhoneNumbersAsync(request, null);
}
@Override
public java.util.concurrent.Future listPhoneNumbersAsync(final ListPhoneNumbersRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final ListPhoneNumbersRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public ListPhoneNumbersResult call() throws Exception {
ListPhoneNumbersResult result = null;
try {
result = executeListPhoneNumbers(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 listProxySessionsAsync(ListProxySessionsRequest request) {
return listProxySessionsAsync(request, null);
}
@Override
public java.util.concurrent.Future listProxySessionsAsync(final ListProxySessionsRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final ListProxySessionsRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public ListProxySessionsResult call() throws Exception {
ListProxySessionsResult result = null;
try {
result = executeListProxySessions(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 listSipMediaApplicationsAsync(ListSipMediaApplicationsRequest request) {
return listSipMediaApplicationsAsync(request, null);
}
@Override
public java.util.concurrent.Future listSipMediaApplicationsAsync(final ListSipMediaApplicationsRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final ListSipMediaApplicationsRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public ListSipMediaApplicationsResult call() throws Exception {
ListSipMediaApplicationsResult result = null;
try {
result = executeListSipMediaApplications(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 listSipRulesAsync(ListSipRulesRequest request) {
return listSipRulesAsync(request, null);
}
@Override
public java.util.concurrent.Future listSipRulesAsync(final ListSipRulesRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final ListSipRulesRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public ListSipRulesResult call() throws Exception {
ListSipRulesResult result = null;
try {
result = executeListSipRules(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 listSupportedPhoneNumberCountriesAsync(
ListSupportedPhoneNumberCountriesRequest request) {
return listSupportedPhoneNumberCountriesAsync(request, null);
}
@Override
public java.util.concurrent.Future listSupportedPhoneNumberCountriesAsync(
final ListSupportedPhoneNumberCountriesRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final ListSupportedPhoneNumberCountriesRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public ListSupportedPhoneNumberCountriesResult call() throws Exception {
ListSupportedPhoneNumberCountriesResult result = null;
try {
result = executeListSupportedPhoneNumberCountries(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 listVoiceConnectorGroupsAsync(ListVoiceConnectorGroupsRequest request) {
return listVoiceConnectorGroupsAsync(request, null);
}
@Override
public java.util.concurrent.Future listVoiceConnectorGroupsAsync(final ListVoiceConnectorGroupsRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final ListVoiceConnectorGroupsRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public ListVoiceConnectorGroupsResult call() throws Exception {
ListVoiceConnectorGroupsResult result = null;
try {
result = executeListVoiceConnectorGroups(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 listVoiceConnectorTerminationCredentialsAsync(
ListVoiceConnectorTerminationCredentialsRequest request) {
return listVoiceConnectorTerminationCredentialsAsync(request, null);
}
@Override
public java.util.concurrent.Future listVoiceConnectorTerminationCredentialsAsync(
final ListVoiceConnectorTerminationCredentialsRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final ListVoiceConnectorTerminationCredentialsRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public ListVoiceConnectorTerminationCredentialsResult call() throws Exception {
ListVoiceConnectorTerminationCredentialsResult result = null;
try {
result = executeListVoiceConnectorTerminationCredentials(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 listVoiceConnectorsAsync(ListVoiceConnectorsRequest request) {
return listVoiceConnectorsAsync(request, null);
}
@Override
public java.util.concurrent.Future listVoiceConnectorsAsync(final ListVoiceConnectorsRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final ListVoiceConnectorsRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public ListVoiceConnectorsResult call() throws Exception {
ListVoiceConnectorsResult result = null;
try {
result = executeListVoiceConnectors(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 listVoiceProfileDomainsAsync(ListVoiceProfileDomainsRequest request) {
return listVoiceProfileDomainsAsync(request, null);
}
@Override
public java.util.concurrent.Future listVoiceProfileDomainsAsync(final ListVoiceProfileDomainsRequest request,
final com.amazonaws.handlers.AsyncHandler