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

software.amazon.awssdk.services.s3outposts.S3OutpostsClient Maven / Gradle / Ivy

Go to download

The AWS Java SDK for S3 Outposts module holds the client classes that are used for communicating with S3 Outposts.

There is a newer version: 2.29.39
Show newest version
/*
 * Copyright 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 software.amazon.awssdk.services.s3outposts;

import java.util.function.Consumer;
import software.amazon.awssdk.annotations.Generated;
import software.amazon.awssdk.awscore.exception.AwsServiceException;
import software.amazon.awssdk.core.SdkClient;
import software.amazon.awssdk.core.exception.SdkClientException;
import software.amazon.awssdk.regions.ServiceMetadata;
import software.amazon.awssdk.services.s3outposts.model.AccessDeniedException;
import software.amazon.awssdk.services.s3outposts.model.ConflictException;
import software.amazon.awssdk.services.s3outposts.model.CreateEndpointRequest;
import software.amazon.awssdk.services.s3outposts.model.CreateEndpointResponse;
import software.amazon.awssdk.services.s3outposts.model.DeleteEndpointRequest;
import software.amazon.awssdk.services.s3outposts.model.DeleteEndpointResponse;
import software.amazon.awssdk.services.s3outposts.model.InternalServerException;
import software.amazon.awssdk.services.s3outposts.model.ListEndpointsRequest;
import software.amazon.awssdk.services.s3outposts.model.ListEndpointsResponse;
import software.amazon.awssdk.services.s3outposts.model.ResourceNotFoundException;
import software.amazon.awssdk.services.s3outposts.model.S3OutpostsException;
import software.amazon.awssdk.services.s3outposts.model.ValidationException;
import software.amazon.awssdk.services.s3outposts.paginators.ListEndpointsIterable;

/**
 * Service client for accessing Amazon S3 Outposts. This can be created using the static {@link #builder()} method.
 *
 * 

* Amazon S3 on Outposts provides access to S3 on Outposts operations. *

*/ @Generated("software.amazon.awssdk:codegen") public interface S3OutpostsClient extends SdkClient { String SERVICE_NAME = "s3-outposts"; /** * Create a {@link S3OutpostsClient} with the region loaded from the * {@link software.amazon.awssdk.regions.providers.DefaultAwsRegionProviderChain} and credentials loaded from the * {@link software.amazon.awssdk.auth.credentials.DefaultCredentialsProvider}. */ static S3OutpostsClient create() { return builder().build(); } /** * Create a builder that can be used to configure and create a {@link S3OutpostsClient}. */ static S3OutpostsClientBuilder builder() { return new DefaultS3OutpostsClientBuilder(); } /** *

* S3 on Outposts access points simplify managing data access at scale for shared datasets in Amazon S3 on Outposts. * S3 on Outposts uses endpoints to connect to Outposts buckets so that you can perform actions within your virtual * private cloud (VPC). *

*

* This action creates an endpoint and associates it with the specified Outpost. *

*

*

* Related actions include: *

* * * @param createEndpointRequest * @return Result of the CreateEndpoint operation returned by the service. * @throws InternalServerException * There was an exception with the internal server. * @throws ValidationException * There was an exception validating this data. * @throws AccessDeniedException * Access was denied for this action. * @throws ResourceNotFoundException * The requested resource was not found. * @throws ConflictException * There was a conflict with this action, and it could not be completed. * @throws SdkException * Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for * catch all scenarios. * @throws SdkClientException * If any client side error occurs such as an IO related failure, failure to get credentials, etc. * @throws S3OutpostsException * Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type. * @sample S3OutpostsClient.CreateEndpoint * @see AWS API * Documentation */ default CreateEndpointResponse createEndpoint(CreateEndpointRequest createEndpointRequest) throws InternalServerException, ValidationException, AccessDeniedException, ResourceNotFoundException, ConflictException, AwsServiceException, SdkClientException, S3OutpostsException { throw new UnsupportedOperationException(); } /** *

* S3 on Outposts access points simplify managing data access at scale for shared datasets in Amazon S3 on Outposts. * S3 on Outposts uses endpoints to connect to Outposts buckets so that you can perform actions within your virtual * private cloud (VPC). *

*

* This action creates an endpoint and associates it with the specified Outpost. *

*

*

* Related actions include: *

* *
*

* This is a convenience which creates an instance of the {@link CreateEndpointRequest.Builder} avoiding the need to * create one manually via {@link CreateEndpointRequest#builder()} *

* * @param createEndpointRequest * A {@link Consumer} that will call methods on {@link CreateEndpointRequest.Builder} to create a request. * @return Result of the CreateEndpoint operation returned by the service. * @throws InternalServerException * There was an exception with the internal server. * @throws ValidationException * There was an exception validating this data. * @throws AccessDeniedException * Access was denied for this action. * @throws ResourceNotFoundException * The requested resource was not found. * @throws ConflictException * There was a conflict with this action, and it could not be completed. * @throws SdkException * Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for * catch all scenarios. * @throws SdkClientException * If any client side error occurs such as an IO related failure, failure to get credentials, etc. * @throws S3OutpostsException * Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type. * @sample S3OutpostsClient.CreateEndpoint * @see AWS API * Documentation */ default CreateEndpointResponse createEndpoint(Consumer createEndpointRequest) throws InternalServerException, ValidationException, AccessDeniedException, ResourceNotFoundException, ConflictException, AwsServiceException, SdkClientException, S3OutpostsException { return createEndpoint(CreateEndpointRequest.builder().applyMutation(createEndpointRequest).build()); } /** *

* S3 on Outposts access points simplify managing data access at scale for shared datasets in Amazon S3 on Outposts. * S3 on Outposts uses endpoints to connect to Outposts buckets so that you can perform actions within your virtual * private cloud (VPC). *

*

* This action deletes an endpoint. *

*

*

* Related actions include: *

* * * @param deleteEndpointRequest * @return Result of the DeleteEndpoint operation returned by the service. * @throws InternalServerException * There was an exception with the internal server. * @throws AccessDeniedException * Access was denied for this action. * @throws ResourceNotFoundException * The requested resource was not found. * @throws ValidationException * There was an exception validating this data. * @throws SdkException * Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for * catch all scenarios. * @throws SdkClientException * If any client side error occurs such as an IO related failure, failure to get credentials, etc. * @throws S3OutpostsException * Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type. * @sample S3OutpostsClient.DeleteEndpoint * @see AWS API * Documentation */ default DeleteEndpointResponse deleteEndpoint(DeleteEndpointRequest deleteEndpointRequest) throws InternalServerException, AccessDeniedException, ResourceNotFoundException, ValidationException, AwsServiceException, SdkClientException, S3OutpostsException { throw new UnsupportedOperationException(); } /** *

* S3 on Outposts access points simplify managing data access at scale for shared datasets in Amazon S3 on Outposts. * S3 on Outposts uses endpoints to connect to Outposts buckets so that you can perform actions within your virtual * private cloud (VPC). *

*

* This action deletes an endpoint. *

*

*

* Related actions include: *

* *
*

* This is a convenience which creates an instance of the {@link DeleteEndpointRequest.Builder} avoiding the need to * create one manually via {@link DeleteEndpointRequest#builder()} *

* * @param deleteEndpointRequest * A {@link Consumer} that will call methods on {@link DeleteEndpointRequest.Builder} to create a request. * @return Result of the DeleteEndpoint operation returned by the service. * @throws InternalServerException * There was an exception with the internal server. * @throws AccessDeniedException * Access was denied for this action. * @throws ResourceNotFoundException * The requested resource was not found. * @throws ValidationException * There was an exception validating this data. * @throws SdkException * Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for * catch all scenarios. * @throws SdkClientException * If any client side error occurs such as an IO related failure, failure to get credentials, etc. * @throws S3OutpostsException * Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type. * @sample S3OutpostsClient.DeleteEndpoint * @see AWS API * Documentation */ default DeleteEndpointResponse deleteEndpoint(Consumer deleteEndpointRequest) throws InternalServerException, AccessDeniedException, ResourceNotFoundException, ValidationException, AwsServiceException, SdkClientException, S3OutpostsException { return deleteEndpoint(DeleteEndpointRequest.builder().applyMutation(deleteEndpointRequest).build()); } /** *

* S3 on Outposts access points simplify managing data access at scale for shared datasets in Amazon S3 on Outposts. * S3 on Outposts uses endpoints to connect to Outposts buckets so that you can perform actions within your virtual * private cloud (VPC). *

*

* This action lists endpoints associated with the Outpost. *

*

*

* Related actions include: *

* * * @param listEndpointsRequest * @return Result of the ListEndpoints operation returned by the service. * @throws InternalServerException * There was an exception with the internal server. * @throws ResourceNotFoundException * The requested resource was not found. * @throws AccessDeniedException * Access was denied for this action. * @throws ValidationException * There was an exception validating this data. * @throws SdkException * Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for * catch all scenarios. * @throws SdkClientException * If any client side error occurs such as an IO related failure, failure to get credentials, etc. * @throws S3OutpostsException * Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type. * @sample S3OutpostsClient.ListEndpoints * @see AWS API * Documentation */ default ListEndpointsResponse listEndpoints(ListEndpointsRequest listEndpointsRequest) throws InternalServerException, ResourceNotFoundException, AccessDeniedException, ValidationException, AwsServiceException, SdkClientException, S3OutpostsException { throw new UnsupportedOperationException(); } /** *

* S3 on Outposts access points simplify managing data access at scale for shared datasets in Amazon S3 on Outposts. * S3 on Outposts uses endpoints to connect to Outposts buckets so that you can perform actions within your virtual * private cloud (VPC). *

*

* This action lists endpoints associated with the Outpost. *

*

*

* Related actions include: *

* *
*

* This is a convenience which creates an instance of the {@link ListEndpointsRequest.Builder} avoiding the need to * create one manually via {@link ListEndpointsRequest#builder()} *

* * @param listEndpointsRequest * A {@link Consumer} that will call methods on {@link ListEndpointsRequest.Builder} to create a request. * @return Result of the ListEndpoints operation returned by the service. * @throws InternalServerException * There was an exception with the internal server. * @throws ResourceNotFoundException * The requested resource was not found. * @throws AccessDeniedException * Access was denied for this action. * @throws ValidationException * There was an exception validating this data. * @throws SdkException * Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for * catch all scenarios. * @throws SdkClientException * If any client side error occurs such as an IO related failure, failure to get credentials, etc. * @throws S3OutpostsException * Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type. * @sample S3OutpostsClient.ListEndpoints * @see AWS API * Documentation */ default ListEndpointsResponse listEndpoints(Consumer listEndpointsRequest) throws InternalServerException, ResourceNotFoundException, AccessDeniedException, ValidationException, AwsServiceException, SdkClientException, S3OutpostsException { return listEndpoints(ListEndpointsRequest.builder().applyMutation(listEndpointsRequest).build()); } /** *

* S3 on Outposts access points simplify managing data access at scale for shared datasets in Amazon S3 on Outposts. * S3 on Outposts uses endpoints to connect to Outposts buckets so that you can perform actions within your virtual * private cloud (VPC). *

*

* This action lists endpoints associated with the Outpost. *

*

*

* Related actions include: *

* *
*

* This is a variant of * {@link #listEndpoints(software.amazon.awssdk.services.s3outposts.model.ListEndpointsRequest)} operation. The * return type is a custom iterable that can be used to iterate through all the pages. SDK will internally handle * making service calls for you. *

*

* When this operation is called, a custom iterable is returned but no service calls are made yet. So there is no * guarantee that the request is valid. As you iterate through the iterable, SDK will start lazily loading response * pages by making service calls until there are no pages left or your iteration stops. If there are errors in your * request, you will see the failures only after you start iterating through the iterable. *

* *

* The following are few ways to iterate through the response pages: *

* 1) Using a Stream * *
     * {@code
     * software.amazon.awssdk.services.s3outposts.paginators.ListEndpointsIterable responses = client.listEndpointsPaginator(request);
     * responses.stream().forEach(....);
     * }
     * 
* * 2) Using For loop * *
     * {
     *     @code
     *     software.amazon.awssdk.services.s3outposts.paginators.ListEndpointsIterable responses = client
     *             .listEndpointsPaginator(request);
     *     for (software.amazon.awssdk.services.s3outposts.model.ListEndpointsResponse response : responses) {
     *         // do something;
     *     }
     * }
     * 
* * 3) Use iterator directly * *
     * {@code
     * software.amazon.awssdk.services.s3outposts.paginators.ListEndpointsIterable responses = client.listEndpointsPaginator(request);
     * responses.iterator().forEachRemaining(....);
     * }
     * 
*

* Please notice that the configuration of MaxResults won't limit the number of results you get with the * paginator. It only limits the number of results in each page. *

*

* Note: If you prefer to have control on service calls, use the * {@link #listEndpoints(software.amazon.awssdk.services.s3outposts.model.ListEndpointsRequest)} operation. *

* * @param listEndpointsRequest * @return A custom iterable that can be used to iterate through all the response pages. * @throws InternalServerException * There was an exception with the internal server. * @throws ResourceNotFoundException * The requested resource was not found. * @throws AccessDeniedException * Access was denied for this action. * @throws ValidationException * There was an exception validating this data. * @throws SdkException * Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for * catch all scenarios. * @throws SdkClientException * If any client side error occurs such as an IO related failure, failure to get credentials, etc. * @throws S3OutpostsException * Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type. * @sample S3OutpostsClient.ListEndpoints * @see AWS API * Documentation */ default ListEndpointsIterable listEndpointsPaginator(ListEndpointsRequest listEndpointsRequest) throws InternalServerException, ResourceNotFoundException, AccessDeniedException, ValidationException, AwsServiceException, SdkClientException, S3OutpostsException { throw new UnsupportedOperationException(); } /** *

* S3 on Outposts access points simplify managing data access at scale for shared datasets in Amazon S3 on Outposts. * S3 on Outposts uses endpoints to connect to Outposts buckets so that you can perform actions within your virtual * private cloud (VPC). *

*

* This action lists endpoints associated with the Outpost. *

*

*

* Related actions include: *

* *
*

* This is a variant of * {@link #listEndpoints(software.amazon.awssdk.services.s3outposts.model.ListEndpointsRequest)} operation. The * return type is a custom iterable that can be used to iterate through all the pages. SDK will internally handle * making service calls for you. *

*

* When this operation is called, a custom iterable is returned but no service calls are made yet. So there is no * guarantee that the request is valid. As you iterate through the iterable, SDK will start lazily loading response * pages by making service calls until there are no pages left or your iteration stops. If there are errors in your * request, you will see the failures only after you start iterating through the iterable. *

* *

* The following are few ways to iterate through the response pages: *

* 1) Using a Stream * *
     * {@code
     * software.amazon.awssdk.services.s3outposts.paginators.ListEndpointsIterable responses = client.listEndpointsPaginator(request);
     * responses.stream().forEach(....);
     * }
     * 
* * 2) Using For loop * *
     * {
     *     @code
     *     software.amazon.awssdk.services.s3outposts.paginators.ListEndpointsIterable responses = client
     *             .listEndpointsPaginator(request);
     *     for (software.amazon.awssdk.services.s3outposts.model.ListEndpointsResponse response : responses) {
     *         // do something;
     *     }
     * }
     * 
* * 3) Use iterator directly * *
     * {@code
     * software.amazon.awssdk.services.s3outposts.paginators.ListEndpointsIterable responses = client.listEndpointsPaginator(request);
     * responses.iterator().forEachRemaining(....);
     * }
     * 
*

* Please notice that the configuration of MaxResults won't limit the number of results you get with the * paginator. It only limits the number of results in each page. *

*

* Note: If you prefer to have control on service calls, use the * {@link #listEndpoints(software.amazon.awssdk.services.s3outposts.model.ListEndpointsRequest)} operation. *

*

* This is a convenience which creates an instance of the {@link ListEndpointsRequest.Builder} avoiding the need to * create one manually via {@link ListEndpointsRequest#builder()} *

* * @param listEndpointsRequest * A {@link Consumer} that will call methods on {@link ListEndpointsRequest.Builder} to create a request. * @return A custom iterable that can be used to iterate through all the response pages. * @throws InternalServerException * There was an exception with the internal server. * @throws ResourceNotFoundException * The requested resource was not found. * @throws AccessDeniedException * Access was denied for this action. * @throws ValidationException * There was an exception validating this data. * @throws SdkException * Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for * catch all scenarios. * @throws SdkClientException * If any client side error occurs such as an IO related failure, failure to get credentials, etc. * @throws S3OutpostsException * Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type. * @sample S3OutpostsClient.ListEndpoints * @see AWS API * Documentation */ default ListEndpointsIterable listEndpointsPaginator(Consumer listEndpointsRequest) throws InternalServerException, ResourceNotFoundException, AccessDeniedException, ValidationException, AwsServiceException, SdkClientException, S3OutpostsException { return listEndpointsPaginator(ListEndpointsRequest.builder().applyMutation(listEndpointsRequest).build()); } static ServiceMetadata serviceMetadata() { return ServiceMetadata.of("s3-outposts"); } }




© 2015 - 2025 Weber Informatics LLC | Privacy Policy