com.amazonaws.services.inspector2.AWSInspector2AsyncClient Maven / Gradle / Ivy
/*
* Copyright 2019-2024 Amazon.com, Inc. or its affiliates. All Rights Reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License"). You may not use this file except in compliance with
* the License. A copy of the License is located at
*
* http://aws.amazon.com/apache2.0
*
* or in the "license" file accompanying this file. This file is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
* CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions
* and limitations under the License.
*/
package com.amazonaws.services.inspector2;
import javax.annotation.Generated;
import com.amazonaws.services.inspector2.model.*;
import com.amazonaws.client.AwsAsyncClientParams;
import com.amazonaws.annotation.ThreadSafe;
import java.util.concurrent.ExecutorService;
/**
* Client for accessing Inspector2 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 Inspector is a vulnerability discovery service that automates continuous scanning for security vulnerabilities
* within your Amazon EC2, Amazon ECR, and Amazon Web Services Lambda environments.
*
*/
@ThreadSafe
@Generated("com.amazonaws:aws-java-sdk-code-generator")
public class AWSInspector2AsyncClient extends AWSInspector2Client implements AWSInspector2Async {
private static final int DEFAULT_THREAD_POOL_SIZE = 50;
private final java.util.concurrent.ExecutorService executorService;
public static AWSInspector2AsyncClientBuilder asyncBuilder() {
return AWSInspector2AsyncClientBuilder.standard();
}
/**
* Constructs a new asynchronous client to invoke service methods on Inspector2 using the specified parameters.
*
* @param asyncClientParams
* Object providing client parameters.
*/
AWSInspector2AsyncClient(AwsAsyncClientParams asyncClientParams) {
this(asyncClientParams, false);
}
/**
* Constructs a new asynchronous client to invoke service methods on Inspector2 using the specified parameters.
*
* @param asyncClientParams
* Object providing client parameters.
* @param endpointDiscoveryEnabled
* true will enable endpoint discovery if the service supports it.
*/
AWSInspector2AsyncClient(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 associateMemberAsync(AssociateMemberRequest request) {
return associateMemberAsync(request, null);
}
@Override
public java.util.concurrent.Future associateMemberAsync(final AssociateMemberRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final AssociateMemberRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public AssociateMemberResult call() throws Exception {
AssociateMemberResult result = null;
try {
result = executeAssociateMember(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 batchGetAccountStatusAsync(BatchGetAccountStatusRequest request) {
return batchGetAccountStatusAsync(request, null);
}
@Override
public java.util.concurrent.Future batchGetAccountStatusAsync(final BatchGetAccountStatusRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final BatchGetAccountStatusRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public BatchGetAccountStatusResult call() throws Exception {
BatchGetAccountStatusResult result = null;
try {
result = executeBatchGetAccountStatus(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 batchGetCodeSnippetAsync(BatchGetCodeSnippetRequest request) {
return batchGetCodeSnippetAsync(request, null);
}
@Override
public java.util.concurrent.Future batchGetCodeSnippetAsync(final BatchGetCodeSnippetRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final BatchGetCodeSnippetRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public BatchGetCodeSnippetResult call() throws Exception {
BatchGetCodeSnippetResult result = null;
try {
result = executeBatchGetCodeSnippet(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 batchGetFindingDetailsAsync(BatchGetFindingDetailsRequest request) {
return batchGetFindingDetailsAsync(request, null);
}
@Override
public java.util.concurrent.Future batchGetFindingDetailsAsync(final BatchGetFindingDetailsRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final BatchGetFindingDetailsRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public BatchGetFindingDetailsResult call() throws Exception {
BatchGetFindingDetailsResult result = null;
try {
result = executeBatchGetFindingDetails(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 batchGetFreeTrialInfoAsync(BatchGetFreeTrialInfoRequest request) {
return batchGetFreeTrialInfoAsync(request, null);
}
@Override
public java.util.concurrent.Future batchGetFreeTrialInfoAsync(final BatchGetFreeTrialInfoRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final BatchGetFreeTrialInfoRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public BatchGetFreeTrialInfoResult call() throws Exception {
BatchGetFreeTrialInfoResult result = null;
try {
result = executeBatchGetFreeTrialInfo(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 batchGetMemberEc2DeepInspectionStatusAsync(
BatchGetMemberEc2DeepInspectionStatusRequest request) {
return batchGetMemberEc2DeepInspectionStatusAsync(request, null);
}
@Override
public java.util.concurrent.Future batchGetMemberEc2DeepInspectionStatusAsync(
final BatchGetMemberEc2DeepInspectionStatusRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final BatchGetMemberEc2DeepInspectionStatusRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public BatchGetMemberEc2DeepInspectionStatusResult call() throws Exception {
BatchGetMemberEc2DeepInspectionStatusResult result = null;
try {
result = executeBatchGetMemberEc2DeepInspectionStatus(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 batchUpdateMemberEc2DeepInspectionStatusAsync(
BatchUpdateMemberEc2DeepInspectionStatusRequest request) {
return batchUpdateMemberEc2DeepInspectionStatusAsync(request, null);
}
@Override
public java.util.concurrent.Future batchUpdateMemberEc2DeepInspectionStatusAsync(
final BatchUpdateMemberEc2DeepInspectionStatusRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final BatchUpdateMemberEc2DeepInspectionStatusRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public BatchUpdateMemberEc2DeepInspectionStatusResult call() throws Exception {
BatchUpdateMemberEc2DeepInspectionStatusResult result = null;
try {
result = executeBatchUpdateMemberEc2DeepInspectionStatus(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 cancelFindingsReportAsync(CancelFindingsReportRequest request) {
return cancelFindingsReportAsync(request, null);
}
@Override
public java.util.concurrent.Future cancelFindingsReportAsync(final CancelFindingsReportRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final CancelFindingsReportRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public CancelFindingsReportResult call() throws Exception {
CancelFindingsReportResult result = null;
try {
result = executeCancelFindingsReport(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 cancelSbomExportAsync(CancelSbomExportRequest request) {
return cancelSbomExportAsync(request, null);
}
@Override
public java.util.concurrent.Future cancelSbomExportAsync(final CancelSbomExportRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final CancelSbomExportRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public CancelSbomExportResult call() throws Exception {
CancelSbomExportResult result = null;
try {
result = executeCancelSbomExport(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 createCisScanConfigurationAsync(CreateCisScanConfigurationRequest request) {
return createCisScanConfigurationAsync(request, null);
}
@Override
public java.util.concurrent.Future createCisScanConfigurationAsync(final CreateCisScanConfigurationRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final CreateCisScanConfigurationRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public CreateCisScanConfigurationResult call() throws Exception {
CreateCisScanConfigurationResult result = null;
try {
result = executeCreateCisScanConfiguration(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 createFilterAsync(CreateFilterRequest request) {
return createFilterAsync(request, null);
}
@Override
public java.util.concurrent.Future createFilterAsync(final CreateFilterRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final CreateFilterRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public CreateFilterResult call() throws Exception {
CreateFilterResult result = null;
try {
result = executeCreateFilter(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 createFindingsReportAsync(CreateFindingsReportRequest request) {
return createFindingsReportAsync(request, null);
}
@Override
public java.util.concurrent.Future createFindingsReportAsync(final CreateFindingsReportRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final CreateFindingsReportRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public CreateFindingsReportResult call() throws Exception {
CreateFindingsReportResult result = null;
try {
result = executeCreateFindingsReport(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 createSbomExportAsync(CreateSbomExportRequest request) {
return createSbomExportAsync(request, null);
}
@Override
public java.util.concurrent.Future createSbomExportAsync(final CreateSbomExportRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final CreateSbomExportRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public CreateSbomExportResult call() throws Exception {
CreateSbomExportResult result = null;
try {
result = executeCreateSbomExport(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 deleteCisScanConfigurationAsync(DeleteCisScanConfigurationRequest request) {
return deleteCisScanConfigurationAsync(request, null);
}
@Override
public java.util.concurrent.Future deleteCisScanConfigurationAsync(final DeleteCisScanConfigurationRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final DeleteCisScanConfigurationRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public DeleteCisScanConfigurationResult call() throws Exception {
DeleteCisScanConfigurationResult result = null;
try {
result = executeDeleteCisScanConfiguration(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 deleteFilterAsync(DeleteFilterRequest request) {
return deleteFilterAsync(request, null);
}
@Override
public java.util.concurrent.Future deleteFilterAsync(final DeleteFilterRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final DeleteFilterRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public DeleteFilterResult call() throws Exception {
DeleteFilterResult result = null;
try {
result = executeDeleteFilter(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 describeOrganizationConfigurationAsync(
DescribeOrganizationConfigurationRequest request) {
return describeOrganizationConfigurationAsync(request, null);
}
@Override
public java.util.concurrent.Future describeOrganizationConfigurationAsync(
final DescribeOrganizationConfigurationRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final DescribeOrganizationConfigurationRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public DescribeOrganizationConfigurationResult call() throws Exception {
DescribeOrganizationConfigurationResult result = null;
try {
result = executeDescribeOrganizationConfiguration(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 disableAsync(DisableRequest request) {
return disableAsync(request, null);
}
@Override
public java.util.concurrent.Future disableAsync(final DisableRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final DisableRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public DisableResult call() throws Exception {
DisableResult result = null;
try {
result = executeDisable(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 disableDelegatedAdminAccountAsync(DisableDelegatedAdminAccountRequest request) {
return disableDelegatedAdminAccountAsync(request, null);
}
@Override
public java.util.concurrent.Future disableDelegatedAdminAccountAsync(final DisableDelegatedAdminAccountRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final DisableDelegatedAdminAccountRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public DisableDelegatedAdminAccountResult call() throws Exception {
DisableDelegatedAdminAccountResult result = null;
try {
result = executeDisableDelegatedAdminAccount(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 disassociateMemberAsync(DisassociateMemberRequest request) {
return disassociateMemberAsync(request, null);
}
@Override
public java.util.concurrent.Future disassociateMemberAsync(final DisassociateMemberRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final DisassociateMemberRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public DisassociateMemberResult call() throws Exception {
DisassociateMemberResult result = null;
try {
result = executeDisassociateMember(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 enableAsync(EnableRequest request) {
return enableAsync(request, null);
}
@Override
public java.util.concurrent.Future enableAsync(final EnableRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final EnableRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public EnableResult call() throws Exception {
EnableResult result = null;
try {
result = executeEnable(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 enableDelegatedAdminAccountAsync(EnableDelegatedAdminAccountRequest request) {
return enableDelegatedAdminAccountAsync(request, null);
}
@Override
public java.util.concurrent.Future enableDelegatedAdminAccountAsync(final EnableDelegatedAdminAccountRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final EnableDelegatedAdminAccountRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public EnableDelegatedAdminAccountResult call() throws Exception {
EnableDelegatedAdminAccountResult result = null;
try {
result = executeEnableDelegatedAdminAccount(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 getCisScanReportAsync(GetCisScanReportRequest request) {
return getCisScanReportAsync(request, null);
}
@Override
public java.util.concurrent.Future getCisScanReportAsync(final GetCisScanReportRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final GetCisScanReportRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public GetCisScanReportResult call() throws Exception {
GetCisScanReportResult result = null;
try {
result = executeGetCisScanReport(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 getCisScanResultDetailsAsync(GetCisScanResultDetailsRequest request) {
return getCisScanResultDetailsAsync(request, null);
}
@Override
public java.util.concurrent.Future getCisScanResultDetailsAsync(final GetCisScanResultDetailsRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final GetCisScanResultDetailsRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public GetCisScanResultDetailsResult call() throws Exception {
GetCisScanResultDetailsResult result = null;
try {
result = executeGetCisScanResultDetails(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 getConfigurationAsync(GetConfigurationRequest request) {
return getConfigurationAsync(request, null);
}
@Override
public java.util.concurrent.Future getConfigurationAsync(final GetConfigurationRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final GetConfigurationRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public GetConfigurationResult call() throws Exception {
GetConfigurationResult result = null;
try {
result = executeGetConfiguration(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 getDelegatedAdminAccountAsync(GetDelegatedAdminAccountRequest request) {
return getDelegatedAdminAccountAsync(request, null);
}
@Override
public java.util.concurrent.Future getDelegatedAdminAccountAsync(final GetDelegatedAdminAccountRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final GetDelegatedAdminAccountRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public GetDelegatedAdminAccountResult call() throws Exception {
GetDelegatedAdminAccountResult result = null;
try {
result = executeGetDelegatedAdminAccount(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 getEc2DeepInspectionConfigurationAsync(
GetEc2DeepInspectionConfigurationRequest request) {
return getEc2DeepInspectionConfigurationAsync(request, null);
}
@Override
public java.util.concurrent.Future getEc2DeepInspectionConfigurationAsync(
final GetEc2DeepInspectionConfigurationRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final GetEc2DeepInspectionConfigurationRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public GetEc2DeepInspectionConfigurationResult call() throws Exception {
GetEc2DeepInspectionConfigurationResult result = null;
try {
result = executeGetEc2DeepInspectionConfiguration(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 getEncryptionKeyAsync(GetEncryptionKeyRequest request) {
return getEncryptionKeyAsync(request, null);
}
@Override
public java.util.concurrent.Future getEncryptionKeyAsync(final GetEncryptionKeyRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final GetEncryptionKeyRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public GetEncryptionKeyResult call() throws Exception {
GetEncryptionKeyResult result = null;
try {
result = executeGetEncryptionKey(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 getFindingsReportStatusAsync(GetFindingsReportStatusRequest request) {
return getFindingsReportStatusAsync(request, null);
}
@Override
public java.util.concurrent.Future getFindingsReportStatusAsync(final GetFindingsReportStatusRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final GetFindingsReportStatusRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public GetFindingsReportStatusResult call() throws Exception {
GetFindingsReportStatusResult result = null;
try {
result = executeGetFindingsReportStatus(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 getMemberAsync(GetMemberRequest request) {
return getMemberAsync(request, null);
}
@Override
public java.util.concurrent.Future getMemberAsync(final GetMemberRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final GetMemberRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public GetMemberResult call() throws Exception {
GetMemberResult result = null;
try {
result = executeGetMember(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 getSbomExportAsync(GetSbomExportRequest request) {
return getSbomExportAsync(request, null);
}
@Override
public java.util.concurrent.Future getSbomExportAsync(final GetSbomExportRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final GetSbomExportRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public GetSbomExportResult call() throws Exception {
GetSbomExportResult result = null;
try {
result = executeGetSbomExport(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 listAccountPermissionsAsync(ListAccountPermissionsRequest request) {
return listAccountPermissionsAsync(request, null);
}
@Override
public java.util.concurrent.Future listAccountPermissionsAsync(final ListAccountPermissionsRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final ListAccountPermissionsRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public ListAccountPermissionsResult call() throws Exception {
ListAccountPermissionsResult result = null;
try {
result = executeListAccountPermissions(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 listCisScanConfigurationsAsync(ListCisScanConfigurationsRequest request) {
return listCisScanConfigurationsAsync(request, null);
}
@Override
public java.util.concurrent.Future listCisScanConfigurationsAsync(final ListCisScanConfigurationsRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final ListCisScanConfigurationsRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public ListCisScanConfigurationsResult call() throws Exception {
ListCisScanConfigurationsResult result = null;
try {
result = executeListCisScanConfigurations(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 listCisScanResultsAggregatedByChecksAsync(
ListCisScanResultsAggregatedByChecksRequest request) {
return listCisScanResultsAggregatedByChecksAsync(request, null);
}
@Override
public java.util.concurrent.Future listCisScanResultsAggregatedByChecksAsync(
final ListCisScanResultsAggregatedByChecksRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final ListCisScanResultsAggregatedByChecksRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public ListCisScanResultsAggregatedByChecksResult call() throws Exception {
ListCisScanResultsAggregatedByChecksResult result = null;
try {
result = executeListCisScanResultsAggregatedByChecks(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 listCisScanResultsAggregatedByTargetResourceAsync(
ListCisScanResultsAggregatedByTargetResourceRequest request) {
return listCisScanResultsAggregatedByTargetResourceAsync(request, null);
}
@Override
public java.util.concurrent.Future listCisScanResultsAggregatedByTargetResourceAsync(
final ListCisScanResultsAggregatedByTargetResourceRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final ListCisScanResultsAggregatedByTargetResourceRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public ListCisScanResultsAggregatedByTargetResourceResult call() throws Exception {
ListCisScanResultsAggregatedByTargetResourceResult result = null;
try {
result = executeListCisScanResultsAggregatedByTargetResource(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 listCisScansAsync(ListCisScansRequest request) {
return listCisScansAsync(request, null);
}
@Override
public java.util.concurrent.Future listCisScansAsync(final ListCisScansRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final ListCisScansRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public ListCisScansResult call() throws Exception {
ListCisScansResult result = null;
try {
result = executeListCisScans(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 listCoverageAsync(ListCoverageRequest request) {
return listCoverageAsync(request, null);
}
@Override
public java.util.concurrent.Future listCoverageAsync(final ListCoverageRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final ListCoverageRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public ListCoverageResult call() throws Exception {
ListCoverageResult result = null;
try {
result = executeListCoverage(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 listCoverageStatisticsAsync(ListCoverageStatisticsRequest request) {
return listCoverageStatisticsAsync(request, null);
}
@Override
public java.util.concurrent.Future listCoverageStatisticsAsync(final ListCoverageStatisticsRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final ListCoverageStatisticsRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public ListCoverageStatisticsResult call() throws Exception {
ListCoverageStatisticsResult result = null;
try {
result = executeListCoverageStatistics(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 listDelegatedAdminAccountsAsync(ListDelegatedAdminAccountsRequest request) {
return listDelegatedAdminAccountsAsync(request, null);
}
@Override
public java.util.concurrent.Future listDelegatedAdminAccountsAsync(final ListDelegatedAdminAccountsRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final ListDelegatedAdminAccountsRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public ListDelegatedAdminAccountsResult call() throws Exception {
ListDelegatedAdminAccountsResult result = null;
try {
result = executeListDelegatedAdminAccounts(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 listFiltersAsync(ListFiltersRequest request) {
return listFiltersAsync(request, null);
}
@Override
public java.util.concurrent.Future listFiltersAsync(final ListFiltersRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final ListFiltersRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public ListFiltersResult call() throws Exception {
ListFiltersResult result = null;
try {
result = executeListFilters(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 listFindingAggregationsAsync(ListFindingAggregationsRequest request) {
return listFindingAggregationsAsync(request, null);
}
@Override
public java.util.concurrent.Future listFindingAggregationsAsync(final ListFindingAggregationsRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final ListFindingAggregationsRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public ListFindingAggregationsResult call() throws Exception {
ListFindingAggregationsResult result = null;
try {
result = executeListFindingAggregations(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 listFindingsAsync(ListFindingsRequest request) {
return listFindingsAsync(request, null);
}
@Override
public java.util.concurrent.Future listFindingsAsync(final ListFindingsRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final ListFindingsRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public ListFindingsResult call() throws Exception {
ListFindingsResult result = null;
try {
result = executeListFindings(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 listMembersAsync(ListMembersRequest request) {
return listMembersAsync(request, null);
}
@Override
public java.util.concurrent.Future listMembersAsync(final ListMembersRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final ListMembersRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public ListMembersResult call() throws Exception {
ListMembersResult result = null;
try {
result = executeListMembers(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 listUsageTotalsAsync(ListUsageTotalsRequest request) {
return listUsageTotalsAsync(request, null);
}
@Override
public java.util.concurrent.Future listUsageTotalsAsync(final ListUsageTotalsRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final ListUsageTotalsRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public ListUsageTotalsResult call() throws Exception {
ListUsageTotalsResult result = null;
try {
result = executeListUsageTotals(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 resetEncryptionKeyAsync(ResetEncryptionKeyRequest request) {
return resetEncryptionKeyAsync(request, null);
}
@Override
public java.util.concurrent.Future resetEncryptionKeyAsync(final ResetEncryptionKeyRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final ResetEncryptionKeyRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public ResetEncryptionKeyResult call() throws Exception {
ResetEncryptionKeyResult result = null;
try {
result = executeResetEncryptionKey(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 searchVulnerabilitiesAsync(SearchVulnerabilitiesRequest request) {
return searchVulnerabilitiesAsync(request, null);
}
@Override
public java.util.concurrent.Future searchVulnerabilitiesAsync(final SearchVulnerabilitiesRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final SearchVulnerabilitiesRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public SearchVulnerabilitiesResult call() throws Exception {
SearchVulnerabilitiesResult result = null;
try {
result = executeSearchVulnerabilities(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 sendCisSessionHealthAsync(SendCisSessionHealthRequest request) {
return sendCisSessionHealthAsync(request, null);
}
@Override
public java.util.concurrent.Future sendCisSessionHealthAsync(final SendCisSessionHealthRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final SendCisSessionHealthRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public SendCisSessionHealthResult call() throws Exception {
SendCisSessionHealthResult result = null;
try {
result = executeSendCisSessionHealth(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 sendCisSessionTelemetryAsync(SendCisSessionTelemetryRequest request) {
return sendCisSessionTelemetryAsync(request, null);
}
@Override
public java.util.concurrent.Future sendCisSessionTelemetryAsync(final SendCisSessionTelemetryRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final SendCisSessionTelemetryRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public SendCisSessionTelemetryResult call() throws Exception {
SendCisSessionTelemetryResult result = null;
try {
result = executeSendCisSessionTelemetry(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 startCisSessionAsync(StartCisSessionRequest request) {
return startCisSessionAsync(request, null);
}
@Override
public java.util.concurrent.Future startCisSessionAsync(final StartCisSessionRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final StartCisSessionRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public StartCisSessionResult call() throws Exception {
StartCisSessionResult result = null;
try {
result = executeStartCisSession(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 stopCisSessionAsync(StopCisSessionRequest request) {
return stopCisSessionAsync(request, null);
}
@Override
public java.util.concurrent.Future stopCisSessionAsync(final StopCisSessionRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final StopCisSessionRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public StopCisSessionResult call() throws Exception {
StopCisSessionResult result = null;
try {
result = executeStopCisSession(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 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 updateCisScanConfigurationAsync(UpdateCisScanConfigurationRequest request) {
return updateCisScanConfigurationAsync(request, null);
}
@Override
public java.util.concurrent.Future updateCisScanConfigurationAsync(final UpdateCisScanConfigurationRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final UpdateCisScanConfigurationRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public UpdateCisScanConfigurationResult call() throws Exception {
UpdateCisScanConfigurationResult result = null;
try {
result = executeUpdateCisScanConfiguration(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 updateConfigurationAsync(UpdateConfigurationRequest request) {
return updateConfigurationAsync(request, null);
}
@Override
public java.util.concurrent.Future updateConfigurationAsync(final UpdateConfigurationRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final UpdateConfigurationRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public UpdateConfigurationResult call() throws Exception {
UpdateConfigurationResult result = null;
try {
result = executeUpdateConfiguration(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 updateEc2DeepInspectionConfigurationAsync(
UpdateEc2DeepInspectionConfigurationRequest request) {
return updateEc2DeepInspectionConfigurationAsync(request, null);
}
@Override
public java.util.concurrent.Future updateEc2DeepInspectionConfigurationAsync(
final UpdateEc2DeepInspectionConfigurationRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final UpdateEc2DeepInspectionConfigurationRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public UpdateEc2DeepInspectionConfigurationResult call() throws Exception {
UpdateEc2DeepInspectionConfigurationResult result = null;
try {
result = executeUpdateEc2DeepInspectionConfiguration(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 updateEncryptionKeyAsync(UpdateEncryptionKeyRequest request) {
return updateEncryptionKeyAsync(request, null);
}
@Override
public java.util.concurrent.Future updateEncryptionKeyAsync(final UpdateEncryptionKeyRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final UpdateEncryptionKeyRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public UpdateEncryptionKeyResult call() throws Exception {
UpdateEncryptionKeyResult result = null;
try {
result = executeUpdateEncryptionKey(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 updateFilterAsync(UpdateFilterRequest request) {
return updateFilterAsync(request, null);
}
@Override
public java.util.concurrent.Future updateFilterAsync(final UpdateFilterRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final UpdateFilterRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public UpdateFilterResult call() throws Exception {
UpdateFilterResult result = null;
try {
result = executeUpdateFilter(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 updateOrgEc2DeepInspectionConfigurationAsync(
UpdateOrgEc2DeepInspectionConfigurationRequest request) {
return updateOrgEc2DeepInspectionConfigurationAsync(request, null);
}
@Override
public java.util.concurrent.Future updateOrgEc2DeepInspectionConfigurationAsync(
final UpdateOrgEc2DeepInspectionConfigurationRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final UpdateOrgEc2DeepInspectionConfigurationRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public UpdateOrgEc2DeepInspectionConfigurationResult call() throws Exception {
UpdateOrgEc2DeepInspectionConfigurationResult result = null;
try {
result = executeUpdateOrgEc2DeepInspectionConfiguration(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 updateOrganizationConfigurationAsync(
UpdateOrganizationConfigurationRequest request) {
return updateOrganizationConfigurationAsync(request, null);
}
@Override
public java.util.concurrent.Future updateOrganizationConfigurationAsync(
final UpdateOrganizationConfigurationRequest request,
final com.amazonaws.handlers.AsyncHandler asyncHandler) {
final UpdateOrganizationConfigurationRequest finalRequest = beforeClientExecution(request);
return executorService.submit(new java.util.concurrent.Callable() {
@Override
public UpdateOrganizationConfigurationResult call() throws Exception {
UpdateOrganizationConfigurationResult result = null;
try {
result = executeUpdateOrganizationConfiguration(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