Interface MobileAsyncClient

All Superinterfaces:
AutoCloseable, AwsClient, SdkAutoCloseable, SdkClient

@Generated("software.amazon.awssdk:codegen") @ThreadSafe public interface MobileAsyncClient extends AwsClient
Service client for accessing AWS Mobile asynchronously. This can be created using the static builder() method.The asynchronous client performs non-blocking I/O when configured with any
invalid reference
SdkAsyncHttpClient
supported in the SDK. However, full non-blocking is not guaranteed as the async client may perform blocking calls in some cases such as credentials retrieval and endpoint discovery as part of the async API call.

AWS Mobile Service provides mobile app and website developers with capabilities required to configure AWS resources and bootstrap their developer desktop projects with the necessary SDKs, constants, tools and samples to make use of those resources.

  • Field Details

  • Method Details

    • createProject

      default CompletableFuture<CreateProjectResponse> createProject(CreateProjectRequest createProjectRequest)

      Creates an AWS Mobile Hub project.

      Parameters:
      createProjectRequest - Request structure used to request a project be created.
      Returns:
      A Java Future containing the result of the CreateProject operation returned by the service.
      The CompletableFuture returned by this method can be completed exceptionally with the following exceptions.
      • InternalFailureException The service has encountered an unexpected error condition which prevents it from servicing the request.
      • ServiceUnavailableException The service is temporarily unavailable. The request should be retried after some time delay.
      • UnauthorizedException Credentials of the caller are insufficient to authorize the request.
      • TooManyRequestsException Too many requests have been received for this AWS account in too short a time. The request should be retried after some time delay.
      • BadRequestException The request cannot be processed because some parameter is not valid or the project state prevents the operation from being performed.
      • NotFoundException No entity can be found with the specified identifier.
      • LimitExceededException There are too many AWS Mobile Hub projects in the account or the account has exceeded the maximum number of resources in some AWS service. You should create another sub-account using AWS Organizations or remove some resources and retry your request.
      • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.
      • SdkClientException If any client side error occurs such as an IO related failure, failure to get credentials, etc.
      • MobileException Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.
      See Also:
    • createProject

      default CompletableFuture<CreateProjectResponse> createProject(Consumer<CreateProjectRequest.Builder> createProjectRequest)

      Creates an AWS Mobile Hub project.


      This is a convenience which creates an instance of the CreateProjectRequest.Builder avoiding the need to create one manually via CreateProjectRequest.builder()

      Parameters:
      createProjectRequest - A Consumer that will call methods on CreateProjectRequest.Builder to create a request. Request structure used to request a project be created.
      Returns:
      A Java Future containing the result of the CreateProject operation returned by the service.
      The CompletableFuture returned by this method can be completed exceptionally with the following exceptions.
      • InternalFailureException The service has encountered an unexpected error condition which prevents it from servicing the request.
      • ServiceUnavailableException The service is temporarily unavailable. The request should be retried after some time delay.
      • UnauthorizedException Credentials of the caller are insufficient to authorize the request.
      • TooManyRequestsException Too many requests have been received for this AWS account in too short a time. The request should be retried after some time delay.
      • BadRequestException The request cannot be processed because some parameter is not valid or the project state prevents the operation from being performed.
      • NotFoundException No entity can be found with the specified identifier.
      • LimitExceededException There are too many AWS Mobile Hub projects in the account or the account has exceeded the maximum number of resources in some AWS service. You should create another sub-account using AWS Organizations or remove some resources and retry your request.
      • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.
      • SdkClientException If any client side error occurs such as an IO related failure, failure to get credentials, etc.
      • MobileException Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.
      See Also:
    • deleteProject

      default CompletableFuture<DeleteProjectResponse> deleteProject(DeleteProjectRequest deleteProjectRequest)

      Delets a project in AWS Mobile Hub.

      Parameters:
      deleteProjectRequest - Request structure used to request a project be deleted.
      Returns:
      A Java Future containing the result of the DeleteProject operation returned by the service.
      The CompletableFuture returned by this method can be completed exceptionally with the following exceptions.
      • InternalFailureException The service has encountered an unexpected error condition which prevents it from servicing the request.
      • ServiceUnavailableException The service is temporarily unavailable. The request should be retried after some time delay.
      • UnauthorizedException Credentials of the caller are insufficient to authorize the request.
      • TooManyRequestsException Too many requests have been received for this AWS account in too short a time. The request should be retried after some time delay.
      • NotFoundException No entity can be found with the specified identifier.
      • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.
      • SdkClientException If any client side error occurs such as an IO related failure, failure to get credentials, etc.
      • MobileException Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.
      See Also:
    • deleteProject

      default CompletableFuture<DeleteProjectResponse> deleteProject(Consumer<DeleteProjectRequest.Builder> deleteProjectRequest)

      Delets a project in AWS Mobile Hub.


      This is a convenience which creates an instance of the DeleteProjectRequest.Builder avoiding the need to create one manually via DeleteProjectRequest.builder()

      Parameters:
      deleteProjectRequest - A Consumer that will call methods on DeleteProjectRequest.Builder to create a request. Request structure used to request a project be deleted.
      Returns:
      A Java Future containing the result of the DeleteProject operation returned by the service.
      The CompletableFuture returned by this method can be completed exceptionally with the following exceptions.
      • InternalFailureException The service has encountered an unexpected error condition which prevents it from servicing the request.
      • ServiceUnavailableException The service is temporarily unavailable. The request should be retried after some time delay.
      • UnauthorizedException Credentials of the caller are insufficient to authorize the request.
      • TooManyRequestsException Too many requests have been received for this AWS account in too short a time. The request should be retried after some time delay.
      • NotFoundException No entity can be found with the specified identifier.
      • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.
      • SdkClientException If any client side error occurs such as an IO related failure, failure to get credentials, etc.
      • MobileException Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.
      See Also:
    • describeBundle

      default CompletableFuture<DescribeBundleResponse> describeBundle(DescribeBundleRequest describeBundleRequest)

      Get the bundle details for the requested bundle id.

      Parameters:
      describeBundleRequest - Request structure to request the details of a specific bundle.
      Returns:
      A Java Future containing the result of the DescribeBundle operation returned by the service.
      The CompletableFuture returned by this method can be completed exceptionally with the following exceptions.
      • InternalFailureException The service has encountered an unexpected error condition which prevents it from servicing the request.
      • ServiceUnavailableException The service is temporarily unavailable. The request should be retried after some time delay.
      • UnauthorizedException Credentials of the caller are insufficient to authorize the request.
      • TooManyRequestsException Too many requests have been received for this AWS account in too short a time. The request should be retried after some time delay.
      • BadRequestException The request cannot be processed because some parameter is not valid or the project state prevents the operation from being performed.
      • NotFoundException No entity can be found with the specified identifier.
      • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.
      • SdkClientException If any client side error occurs such as an IO related failure, failure to get credentials, etc.
      • MobileException Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.
      See Also:
    • describeBundle

      default CompletableFuture<DescribeBundleResponse> describeBundle(Consumer<DescribeBundleRequest.Builder> describeBundleRequest)

      Get the bundle details for the requested bundle id.


      This is a convenience which creates an instance of the DescribeBundleRequest.Builder avoiding the need to create one manually via DescribeBundleRequest.builder()

      Parameters:
      describeBundleRequest - A Consumer that will call methods on DescribeBundleRequest.Builder to create a request. Request structure to request the details of a specific bundle.
      Returns:
      A Java Future containing the result of the DescribeBundle operation returned by the service.
      The CompletableFuture returned by this method can be completed exceptionally with the following exceptions.
      • InternalFailureException The service has encountered an unexpected error condition which prevents it from servicing the request.
      • ServiceUnavailableException The service is temporarily unavailable. The request should be retried after some time delay.
      • UnauthorizedException Credentials of the caller are insufficient to authorize the request.
      • TooManyRequestsException Too many requests have been received for this AWS account in too short a time. The request should be retried after some time delay.
      • BadRequestException The request cannot be processed because some parameter is not valid or the project state prevents the operation from being performed.
      • NotFoundException No entity can be found with the specified identifier.
      • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.
      • SdkClientException If any client side error occurs such as an IO related failure, failure to get credentials, etc.
      • MobileException Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.
      See Also:
    • describeProject

      default CompletableFuture<DescribeProjectResponse> describeProject(DescribeProjectRequest describeProjectRequest)

      Gets details about a project in AWS Mobile Hub.

      Parameters:
      describeProjectRequest - Request structure used to request details about a project.
      Returns:
      A Java Future containing the result of the DescribeProject operation returned by the service.
      The CompletableFuture returned by this method can be completed exceptionally with the following exceptions.
      • InternalFailureException The service has encountered an unexpected error condition which prevents it from servicing the request.
      • ServiceUnavailableException The service is temporarily unavailable. The request should be retried after some time delay.
      • UnauthorizedException Credentials of the caller are insufficient to authorize the request.
      • TooManyRequestsException Too many requests have been received for this AWS account in too short a time. The request should be retried after some time delay.
      • BadRequestException The request cannot be processed because some parameter is not valid or the project state prevents the operation from being performed.
      • NotFoundException No entity can be found with the specified identifier.
      • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.
      • SdkClientException If any client side error occurs such as an IO related failure, failure to get credentials, etc.
      • MobileException Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.
      See Also:
    • describeProject

      default CompletableFuture<DescribeProjectResponse> describeProject(Consumer<DescribeProjectRequest.Builder> describeProjectRequest)

      Gets details about a project in AWS Mobile Hub.


      This is a convenience which creates an instance of the DescribeProjectRequest.Builder avoiding the need to create one manually via DescribeProjectRequest.builder()

      Parameters:
      describeProjectRequest - A Consumer that will call methods on DescribeProjectRequest.Builder to create a request. Request structure used to request details about a project.
      Returns:
      A Java Future containing the result of the DescribeProject operation returned by the service.
      The CompletableFuture returned by this method can be completed exceptionally with the following exceptions.
      • InternalFailureException The service has encountered an unexpected error condition which prevents it from servicing the request.
      • ServiceUnavailableException The service is temporarily unavailable. The request should be retried after some time delay.
      • UnauthorizedException Credentials of the caller are insufficient to authorize the request.
      • TooManyRequestsException Too many requests have been received for this AWS account in too short a time. The request should be retried after some time delay.
      • BadRequestException The request cannot be processed because some parameter is not valid or the project state prevents the operation from being performed.
      • NotFoundException No entity can be found with the specified identifier.
      • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.
      • SdkClientException If any client side error occurs such as an IO related failure, failure to get credentials, etc.
      • MobileException Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.
      See Also:
    • exportBundle

      default CompletableFuture<ExportBundleResponse> exportBundle(ExportBundleRequest exportBundleRequest)

      Generates customized software development kit (SDK) and or tool packages used to integrate mobile web or mobile app clients with backend AWS resources.

      Parameters:
      exportBundleRequest - Request structure used to request generation of custom SDK and tool packages required to integrate mobile web or app clients with backed AWS resources.
      Returns:
      A Java Future containing the result of the ExportBundle operation returned by the service.
      The CompletableFuture returned by this method can be completed exceptionally with the following exceptions.
      • InternalFailureException The service has encountered an unexpected error condition which prevents it from servicing the request.
      • ServiceUnavailableException The service is temporarily unavailable. The request should be retried after some time delay.
      • UnauthorizedException Credentials of the caller are insufficient to authorize the request.
      • TooManyRequestsException Too many requests have been received for this AWS account in too short a time. The request should be retried after some time delay.
      • BadRequestException The request cannot be processed because some parameter is not valid or the project state prevents the operation from being performed.
      • NotFoundException No entity can be found with the specified identifier.
      • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.
      • SdkClientException If any client side error occurs such as an IO related failure, failure to get credentials, etc.
      • MobileException Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.
      See Also:
    • exportBundle

      default CompletableFuture<ExportBundleResponse> exportBundle(Consumer<ExportBundleRequest.Builder> exportBundleRequest)

      Generates customized software development kit (SDK) and or tool packages used to integrate mobile web or mobile app clients with backend AWS resources.


      This is a convenience which creates an instance of the ExportBundleRequest.Builder avoiding the need to create one manually via ExportBundleRequest.builder()

      Parameters:
      exportBundleRequest - A Consumer that will call methods on ExportBundleRequest.Builder to create a request. Request structure used to request generation of custom SDK and tool packages required to integrate mobile web or app clients with backed AWS resources.
      Returns:
      A Java Future containing the result of the ExportBundle operation returned by the service.
      The CompletableFuture returned by this method can be completed exceptionally with the following exceptions.
      • InternalFailureException The service has encountered an unexpected error condition which prevents it from servicing the request.
      • ServiceUnavailableException The service is temporarily unavailable. The request should be retried after some time delay.
      • UnauthorizedException Credentials of the caller are insufficient to authorize the request.
      • TooManyRequestsException Too many requests have been received for this AWS account in too short a time. The request should be retried after some time delay.
      • BadRequestException The request cannot be processed because some parameter is not valid or the project state prevents the operation from being performed.
      • NotFoundException No entity can be found with the specified identifier.
      • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.
      • SdkClientException If any client side error occurs such as an IO related failure, failure to get credentials, etc.
      • MobileException Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.
      See Also:
    • exportProject

      default CompletableFuture<ExportProjectResponse> exportProject(ExportProjectRequest exportProjectRequest)

      Exports project configuration to a snapshot which can be downloaded and shared. Note that mobile app push credentials are encrypted in exported projects, so they can only be shared successfully within the same AWS account.

      Parameters:
      exportProjectRequest - Request structure used in requests to export project configuration details.
      Returns:
      A Java Future containing the result of the ExportProject operation returned by the service.
      The CompletableFuture returned by this method can be completed exceptionally with the following exceptions.
      • InternalFailureException The service has encountered an unexpected error condition which prevents it from servicing the request.
      • ServiceUnavailableException The service is temporarily unavailable. The request should be retried after some time delay.
      • UnauthorizedException Credentials of the caller are insufficient to authorize the request.
      • TooManyRequestsException Too many requests have been received for this AWS account in too short a time. The request should be retried after some time delay.
      • BadRequestException The request cannot be processed because some parameter is not valid or the project state prevents the operation from being performed.
      • NotFoundException No entity can be found with the specified identifier.
      • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.
      • SdkClientException If any client side error occurs such as an IO related failure, failure to get credentials, etc.
      • MobileException Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.
      See Also:
    • exportProject

      default CompletableFuture<ExportProjectResponse> exportProject(Consumer<ExportProjectRequest.Builder> exportProjectRequest)

      Exports project configuration to a snapshot which can be downloaded and shared. Note that mobile app push credentials are encrypted in exported projects, so they can only be shared successfully within the same AWS account.


      This is a convenience which creates an instance of the ExportProjectRequest.Builder avoiding the need to create one manually via ExportProjectRequest.builder()

      Parameters:
      exportProjectRequest - A Consumer that will call methods on ExportProjectRequest.Builder to create a request. Request structure used in requests to export project configuration details.
      Returns:
      A Java Future containing the result of the ExportProject operation returned by the service.
      The CompletableFuture returned by this method can be completed exceptionally with the following exceptions.
      • InternalFailureException The service has encountered an unexpected error condition which prevents it from servicing the request.
      • ServiceUnavailableException The service is temporarily unavailable. The request should be retried after some time delay.
      • UnauthorizedException Credentials of the caller are insufficient to authorize the request.
      • TooManyRequestsException Too many requests have been received for this AWS account in too short a time. The request should be retried after some time delay.
      • BadRequestException The request cannot be processed because some parameter is not valid or the project state prevents the operation from being performed.
      • NotFoundException No entity can be found with the specified identifier.
      • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.
      • SdkClientException If any client side error occurs such as an IO related failure, failure to get credentials, etc.
      • MobileException Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.
      See Also:
    • listBundles

      default CompletableFuture<ListBundlesResponse> listBundles(ListBundlesRequest listBundlesRequest)

      List all available bundles.

      Parameters:
      listBundlesRequest - Request structure to request all available bundles.
      Returns:
      A Java Future containing the result of the ListBundles operation returned by the service.
      The CompletableFuture returned by this method can be completed exceptionally with the following exceptions.
      • InternalFailureException The service has encountered an unexpected error condition which prevents it from servicing the request.
      • ServiceUnavailableException The service is temporarily unavailable. The request should be retried after some time delay.
      • UnauthorizedException Credentials of the caller are insufficient to authorize the request.
      • TooManyRequestsException Too many requests have been received for this AWS account in too short a time. The request should be retried after some time delay.
      • BadRequestException The request cannot be processed because some parameter is not valid or the project state prevents the operation from being performed.
      • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.
      • SdkClientException If any client side error occurs such as an IO related failure, failure to get credentials, etc.
      • MobileException Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.
      See Also:
    • listBundles

      default CompletableFuture<ListBundlesResponse> listBundles(Consumer<ListBundlesRequest.Builder> listBundlesRequest)

      List all available bundles.


      This is a convenience which creates an instance of the ListBundlesRequest.Builder avoiding the need to create one manually via ListBundlesRequest.builder()

      Parameters:
      listBundlesRequest - A Consumer that will call methods on ListBundlesRequest.Builder to create a request. Request structure to request all available bundles.
      Returns:
      A Java Future containing the result of the ListBundles operation returned by the service.
      The CompletableFuture returned by this method can be completed exceptionally with the following exceptions.
      • InternalFailureException The service has encountered an unexpected error condition which prevents it from servicing the request.
      • ServiceUnavailableException The service is temporarily unavailable. The request should be retried after some time delay.
      • UnauthorizedException Credentials of the caller are insufficient to authorize the request.
      • TooManyRequestsException Too many requests have been received for this AWS account in too short a time. The request should be retried after some time delay.
      • BadRequestException The request cannot be processed because some parameter is not valid or the project state prevents the operation from being performed.
      • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.
      • SdkClientException If any client side error occurs such as an IO related failure, failure to get credentials, etc.
      • MobileException Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.
      See Also:
    • listBundles

      default CompletableFuture<ListBundlesResponse> listBundles()

      List all available bundles.

      Returns:
      A Java Future containing the result of the ListBundles operation returned by the service.
      The CompletableFuture returned by this method can be completed exceptionally with the following exceptions.
      • InternalFailureException The service has encountered an unexpected error condition which prevents it from servicing the request.
      • ServiceUnavailableException The service is temporarily unavailable. The request should be retried after some time delay.
      • UnauthorizedException Credentials of the caller are insufficient to authorize the request.
      • TooManyRequestsException Too many requests have been received for this AWS account in too short a time. The request should be retried after some time delay.
      • BadRequestException The request cannot be processed because some parameter is not valid or the project state prevents the operation from being performed.
      • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.
      • SdkClientException If any client side error occurs such as an IO related failure, failure to get credentials, etc.
      • MobileException Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.
      See Also:
    • listBundlesPaginator

      default ListBundlesPublisher listBundlesPaginator()

      This is a variant of listBundles(software.amazon.awssdk.services.mobile.model.ListBundlesRequest) operation. The return type is a custom publisher that can be subscribed to request a stream of response pages. SDK will internally handle making service calls for you.

      When the operation is called, an instance of this class is returned. At this point, no service calls are made yet and so there is no guarantee that the request is valid. If there are errors in your request, you will see the failures only after you start streaming the data. The subscribe method should be called as a request to start streaming data. For more info, see Publisher.subscribe(org.reactivestreams.Subscriber). Each call to the subscribe method will result in a new Subscription i.e., a new contract to stream data from the starting request.

      The following are few ways to use the response class:

      1) Using the subscribe helper method
       
       software.amazon.awssdk.services.mobile.paginators.ListBundlesPublisher publisher = client.listBundlesPaginator(request);
       CompletableFuture<Void> future = publisher.subscribe(res -> { // Do something with the response });
       future.get();
       
       
      2) Using a custom subscriber
       
       software.amazon.awssdk.services.mobile.paginators.ListBundlesPublisher publisher = client.listBundlesPaginator(request);
       publisher.subscribe(new Subscriber<software.amazon.awssdk.services.mobile.model.ListBundlesResponse>() {
       
       public void onSubscribe(org.reactivestreams.Subscriber subscription) { //... };
       
       
       public void onNext(software.amazon.awssdk.services.mobile.model.ListBundlesResponse response) { //... };
       });
       
      As the response is a publisher, it can work well with third party reactive streams implementations like RxJava2.

      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 listBundles(software.amazon.awssdk.services.mobile.model.ListBundlesRequest) operation.

      Returns:
      A custom publisher that can be subscribed to request a stream of response pages.
      The CompletableFuture returned by this method can be completed exceptionally with the following exceptions.
      • InternalFailureException The service has encountered an unexpected error condition which prevents it from servicing the request.
      • ServiceUnavailableException The service is temporarily unavailable. The request should be retried after some time delay.
      • UnauthorizedException Credentials of the caller are insufficient to authorize the request.
      • TooManyRequestsException Too many requests have been received for this AWS account in too short a time. The request should be retried after some time delay.
      • BadRequestException The request cannot be processed because some parameter is not valid or the project state prevents the operation from being performed.
      • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.
      • SdkClientException If any client side error occurs such as an IO related failure, failure to get credentials, etc.
      • MobileException Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.
      See Also:
    • listBundlesPaginator

      default ListBundlesPublisher listBundlesPaginator(ListBundlesRequest listBundlesRequest)

      This is a variant of listBundles(software.amazon.awssdk.services.mobile.model.ListBundlesRequest) operation. The return type is a custom publisher that can be subscribed to request a stream of response pages. SDK will internally handle making service calls for you.

      When the operation is called, an instance of this class is returned. At this point, no service calls are made yet and so there is no guarantee that the request is valid. If there are errors in your request, you will see the failures only after you start streaming the data. The subscribe method should be called as a request to start streaming data. For more info, see Publisher.subscribe(org.reactivestreams.Subscriber). Each call to the subscribe method will result in a new Subscription i.e., a new contract to stream data from the starting request.

      The following are few ways to use the response class:

      1) Using the subscribe helper method
       
       software.amazon.awssdk.services.mobile.paginators.ListBundlesPublisher publisher = client.listBundlesPaginator(request);
       CompletableFuture<Void> future = publisher.subscribe(res -> { // Do something with the response });
       future.get();
       
       
      2) Using a custom subscriber
       
       software.amazon.awssdk.services.mobile.paginators.ListBundlesPublisher publisher = client.listBundlesPaginator(request);
       publisher.subscribe(new Subscriber<software.amazon.awssdk.services.mobile.model.ListBundlesResponse>() {
       
       public void onSubscribe(org.reactivestreams.Subscriber subscription) { //... };
       
       
       public void onNext(software.amazon.awssdk.services.mobile.model.ListBundlesResponse response) { //... };
       });
       
      As the response is a publisher, it can work well with third party reactive streams implementations like RxJava2.

      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 listBundles(software.amazon.awssdk.services.mobile.model.ListBundlesRequest) operation.

      Parameters:
      listBundlesRequest - Request structure to request all available bundles.
      Returns:
      A custom publisher that can be subscribed to request a stream of response pages.
      The CompletableFuture returned by this method can be completed exceptionally with the following exceptions.
      • InternalFailureException The service has encountered an unexpected error condition which prevents it from servicing the request.
      • ServiceUnavailableException The service is temporarily unavailable. The request should be retried after some time delay.
      • UnauthorizedException Credentials of the caller are insufficient to authorize the request.
      • TooManyRequestsException Too many requests have been received for this AWS account in too short a time. The request should be retried after some time delay.
      • BadRequestException The request cannot be processed because some parameter is not valid or the project state prevents the operation from being performed.
      • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.
      • SdkClientException If any client side error occurs such as an IO related failure, failure to get credentials, etc.
      • MobileException Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.
      See Also:
    • listBundlesPaginator

      default ListBundlesPublisher listBundlesPaginator(Consumer<ListBundlesRequest.Builder> listBundlesRequest)

      This is a variant of listBundles(software.amazon.awssdk.services.mobile.model.ListBundlesRequest) operation. The return type is a custom publisher that can be subscribed to request a stream of response pages. SDK will internally handle making service calls for you.

      When the operation is called, an instance of this class is returned. At this point, no service calls are made yet and so there is no guarantee that the request is valid. If there are errors in your request, you will see the failures only after you start streaming the data. The subscribe method should be called as a request to start streaming data. For more info, see Publisher.subscribe(org.reactivestreams.Subscriber). Each call to the subscribe method will result in a new Subscription i.e., a new contract to stream data from the starting request.

      The following are few ways to use the response class:

      1) Using the subscribe helper method
       
       software.amazon.awssdk.services.mobile.paginators.ListBundlesPublisher publisher = client.listBundlesPaginator(request);
       CompletableFuture<Void> future = publisher.subscribe(res -> { // Do something with the response });
       future.get();
       
       
      2) Using a custom subscriber
       
       software.amazon.awssdk.services.mobile.paginators.ListBundlesPublisher publisher = client.listBundlesPaginator(request);
       publisher.subscribe(new Subscriber<software.amazon.awssdk.services.mobile.model.ListBundlesResponse>() {
       
       public void onSubscribe(org.reactivestreams.Subscriber subscription) { //... };
       
       
       public void onNext(software.amazon.awssdk.services.mobile.model.ListBundlesResponse response) { //... };
       });
       
      As the response is a publisher, it can work well with third party reactive streams implementations like RxJava2.

      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 listBundles(software.amazon.awssdk.services.mobile.model.ListBundlesRequest) operation.


      This is a convenience which creates an instance of the ListBundlesRequest.Builder avoiding the need to create one manually via ListBundlesRequest.builder()

      Parameters:
      listBundlesRequest - A Consumer that will call methods on ListBundlesRequest.Builder to create a request. Request structure to request all available bundles.
      Returns:
      A custom publisher that can be subscribed to request a stream of response pages.
      The CompletableFuture returned by this method can be completed exceptionally with the following exceptions.
      • InternalFailureException The service has encountered an unexpected error condition which prevents it from servicing the request.
      • ServiceUnavailableException The service is temporarily unavailable. The request should be retried after some time delay.
      • UnauthorizedException Credentials of the caller are insufficient to authorize the request.
      • TooManyRequestsException Too many requests have been received for this AWS account in too short a time. The request should be retried after some time delay.
      • BadRequestException The request cannot be processed because some parameter is not valid or the project state prevents the operation from being performed.
      • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.
      • SdkClientException If any client side error occurs such as an IO related failure, failure to get credentials, etc.
      • MobileException Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.
      See Also:
    • listProjects

      default CompletableFuture<ListProjectsResponse> listProjects(ListProjectsRequest listProjectsRequest)

      Lists projects in AWS Mobile Hub.

      Parameters:
      listProjectsRequest - Request structure used to request projects list in AWS Mobile Hub.
      Returns:
      A Java Future containing the result of the ListProjects operation returned by the service.
      The CompletableFuture returned by this method can be completed exceptionally with the following exceptions.
      • InternalFailureException The service has encountered an unexpected error condition which prevents it from servicing the request.
      • ServiceUnavailableException The service is temporarily unavailable. The request should be retried after some time delay.
      • UnauthorizedException Credentials of the caller are insufficient to authorize the request.
      • TooManyRequestsException Too many requests have been received for this AWS account in too short a time. The request should be retried after some time delay.
      • BadRequestException The request cannot be processed because some parameter is not valid or the project state prevents the operation from being performed.
      • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.
      • SdkClientException If any client side error occurs such as an IO related failure, failure to get credentials, etc.
      • MobileException Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.
      See Also:
    • listProjects

      default CompletableFuture<ListProjectsResponse> listProjects(Consumer<ListProjectsRequest.Builder> listProjectsRequest)

      Lists projects in AWS Mobile Hub.


      This is a convenience which creates an instance of the ListProjectsRequest.Builder avoiding the need to create one manually via ListProjectsRequest.builder()

      Parameters:
      listProjectsRequest - A Consumer that will call methods on ListProjectsRequest.Builder to create a request. Request structure used to request projects list in AWS Mobile Hub.
      Returns:
      A Java Future containing the result of the ListProjects operation returned by the service.
      The CompletableFuture returned by this method can be completed exceptionally with the following exceptions.
      • InternalFailureException The service has encountered an unexpected error condition which prevents it from servicing the request.
      • ServiceUnavailableException The service is temporarily unavailable. The request should be retried after some time delay.
      • UnauthorizedException Credentials of the caller are insufficient to authorize the request.
      • TooManyRequestsException Too many requests have been received for this AWS account in too short a time. The request should be retried after some time delay.
      • BadRequestException The request cannot be processed because some parameter is not valid or the project state prevents the operation from being performed.
      • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.
      • SdkClientException If any client side error occurs such as an IO related failure, failure to get credentials, etc.
      • MobileException Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.
      See Also:
    • listProjects

      default CompletableFuture<ListProjectsResponse> listProjects()

      Lists projects in AWS Mobile Hub.

      Returns:
      A Java Future containing the result of the ListProjects operation returned by the service.
      The CompletableFuture returned by this method can be completed exceptionally with the following exceptions.
      • InternalFailureException The service has encountered an unexpected error condition which prevents it from servicing the request.
      • ServiceUnavailableException The service is temporarily unavailable. The request should be retried after some time delay.
      • UnauthorizedException Credentials of the caller are insufficient to authorize the request.
      • TooManyRequestsException Too many requests have been received for this AWS account in too short a time. The request should be retried after some time delay.
      • BadRequestException The request cannot be processed because some parameter is not valid or the project state prevents the operation from being performed.
      • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.
      • SdkClientException If any client side error occurs such as an IO related failure, failure to get credentials, etc.
      • MobileException Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.
      See Also:
    • listProjectsPaginator

      default ListProjectsPublisher listProjectsPaginator()

      This is a variant of listProjects(software.amazon.awssdk.services.mobile.model.ListProjectsRequest) operation. The return type is a custom publisher that can be subscribed to request a stream of response pages. SDK will internally handle making service calls for you.

      When the operation is called, an instance of this class is returned. At this point, no service calls are made yet and so there is no guarantee that the request is valid. If there are errors in your request, you will see the failures only after you start streaming the data. The subscribe method should be called as a request to start streaming data. For more info, see Publisher.subscribe(org.reactivestreams.Subscriber). Each call to the subscribe method will result in a new Subscription i.e., a new contract to stream data from the starting request.

      The following are few ways to use the response class:

      1) Using the subscribe helper method
       
       software.amazon.awssdk.services.mobile.paginators.ListProjectsPublisher publisher = client.listProjectsPaginator(request);
       CompletableFuture<Void> future = publisher.subscribe(res -> { // Do something with the response });
       future.get();
       
       
      2) Using a custom subscriber
       
       software.amazon.awssdk.services.mobile.paginators.ListProjectsPublisher publisher = client.listProjectsPaginator(request);
       publisher.subscribe(new Subscriber<software.amazon.awssdk.services.mobile.model.ListProjectsResponse>() {
       
       public void onSubscribe(org.reactivestreams.Subscriber subscription) { //... };
       
       
       public void onNext(software.amazon.awssdk.services.mobile.model.ListProjectsResponse response) { //... };
       });
       
      As the response is a publisher, it can work well with third party reactive streams implementations like RxJava2.

      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 listProjects(software.amazon.awssdk.services.mobile.model.ListProjectsRequest) operation.

      Returns:
      A custom publisher that can be subscribed to request a stream of response pages.
      The CompletableFuture returned by this method can be completed exceptionally with the following exceptions.
      • InternalFailureException The service has encountered an unexpected error condition which prevents it from servicing the request.
      • ServiceUnavailableException The service is temporarily unavailable. The request should be retried after some time delay.
      • UnauthorizedException Credentials of the caller are insufficient to authorize the request.
      • TooManyRequestsException Too many requests have been received for this AWS account in too short a time. The request should be retried after some time delay.
      • BadRequestException The request cannot be processed because some parameter is not valid or the project state prevents the operation from being performed.
      • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.
      • SdkClientException If any client side error occurs such as an IO related failure, failure to get credentials, etc.
      • MobileException Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.
      See Also:
    • listProjectsPaginator

      default ListProjectsPublisher listProjectsPaginator(ListProjectsRequest listProjectsRequest)

      This is a variant of listProjects(software.amazon.awssdk.services.mobile.model.ListProjectsRequest) operation. The return type is a custom publisher that can be subscribed to request a stream of response pages. SDK will internally handle making service calls for you.

      When the operation is called, an instance of this class is returned. At this point, no service calls are made yet and so there is no guarantee that the request is valid. If there are errors in your request, you will see the failures only after you start streaming the data. The subscribe method should be called as a request to start streaming data. For more info, see Publisher.subscribe(org.reactivestreams.Subscriber). Each call to the subscribe method will result in a new Subscription i.e., a new contract to stream data from the starting request.

      The following are few ways to use the response class:

      1) Using the subscribe helper method
       
       software.amazon.awssdk.services.mobile.paginators.ListProjectsPublisher publisher = client.listProjectsPaginator(request);
       CompletableFuture<Void> future = publisher.subscribe(res -> { // Do something with the response });
       future.get();
       
       
      2) Using a custom subscriber
       
       software.amazon.awssdk.services.mobile.paginators.ListProjectsPublisher publisher = client.listProjectsPaginator(request);
       publisher.subscribe(new Subscriber<software.amazon.awssdk.services.mobile.model.ListProjectsResponse>() {
       
       public void onSubscribe(org.reactivestreams.Subscriber subscription) { //... };
       
       
       public void onNext(software.amazon.awssdk.services.mobile.model.ListProjectsResponse response) { //... };
       });
       
      As the response is a publisher, it can work well with third party reactive streams implementations like RxJava2.

      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 listProjects(software.amazon.awssdk.services.mobile.model.ListProjectsRequest) operation.

      Parameters:
      listProjectsRequest - Request structure used to request projects list in AWS Mobile Hub.
      Returns:
      A custom publisher that can be subscribed to request a stream of response pages.
      The CompletableFuture returned by this method can be completed exceptionally with the following exceptions.
      • InternalFailureException The service has encountered an unexpected error condition which prevents it from servicing the request.
      • ServiceUnavailableException The service is temporarily unavailable. The request should be retried after some time delay.
      • UnauthorizedException Credentials of the caller are insufficient to authorize the request.
      • TooManyRequestsException Too many requests have been received for this AWS account in too short a time. The request should be retried after some time delay.
      • BadRequestException The request cannot be processed because some parameter is not valid or the project state prevents the operation from being performed.
      • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.
      • SdkClientException If any client side error occurs such as an IO related failure, failure to get credentials, etc.
      • MobileException Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.
      See Also:
    • listProjectsPaginator

      default ListProjectsPublisher listProjectsPaginator(Consumer<ListProjectsRequest.Builder> listProjectsRequest)

      This is a variant of listProjects(software.amazon.awssdk.services.mobile.model.ListProjectsRequest) operation. The return type is a custom publisher that can be subscribed to request a stream of response pages. SDK will internally handle making service calls for you.

      When the operation is called, an instance of this class is returned. At this point, no service calls are made yet and so there is no guarantee that the request is valid. If there are errors in your request, you will see the failures only after you start streaming the data. The subscribe method should be called as a request to start streaming data. For more info, see Publisher.subscribe(org.reactivestreams.Subscriber). Each call to the subscribe method will result in a new Subscription i.e., a new contract to stream data from the starting request.

      The following are few ways to use the response class:

      1) Using the subscribe helper method
       
       software.amazon.awssdk.services.mobile.paginators.ListProjectsPublisher publisher = client.listProjectsPaginator(request);
       CompletableFuture<Void> future = publisher.subscribe(res -> { // Do something with the response });
       future.get();
       
       
      2) Using a custom subscriber
       
       software.amazon.awssdk.services.mobile.paginators.ListProjectsPublisher publisher = client.listProjectsPaginator(request);
       publisher.subscribe(new Subscriber<software.amazon.awssdk.services.mobile.model.ListProjectsResponse>() {
       
       public void onSubscribe(org.reactivestreams.Subscriber subscription) { //... };
       
       
       public void onNext(software.amazon.awssdk.services.mobile.model.ListProjectsResponse response) { //... };
       });
       
      As the response is a publisher, it can work well with third party reactive streams implementations like RxJava2.

      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 listProjects(software.amazon.awssdk.services.mobile.model.ListProjectsRequest) operation.


      This is a convenience which creates an instance of the ListProjectsRequest.Builder avoiding the need to create one manually via ListProjectsRequest.builder()

      Parameters:
      listProjectsRequest - A Consumer that will call methods on ListProjectsRequest.Builder to create a request. Request structure used to request projects list in AWS Mobile Hub.
      Returns:
      A custom publisher that can be subscribed to request a stream of response pages.
      The CompletableFuture returned by this method can be completed exceptionally with the following exceptions.
      • InternalFailureException The service has encountered an unexpected error condition which prevents it from servicing the request.
      • ServiceUnavailableException The service is temporarily unavailable. The request should be retried after some time delay.
      • UnauthorizedException Credentials of the caller are insufficient to authorize the request.
      • TooManyRequestsException Too many requests have been received for this AWS account in too short a time. The request should be retried after some time delay.
      • BadRequestException The request cannot be processed because some parameter is not valid or the project state prevents the operation from being performed.
      • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.
      • SdkClientException If any client side error occurs such as an IO related failure, failure to get credentials, etc.
      • MobileException Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.
      See Also:
    • updateProject

      default CompletableFuture<UpdateProjectResponse> updateProject(UpdateProjectRequest updateProjectRequest)

      Update an existing project.

      Parameters:
      updateProjectRequest - Request structure used for requests to update project configuration.
      Returns:
      A Java Future containing the result of the UpdateProject operation returned by the service.
      The CompletableFuture returned by this method can be completed exceptionally with the following exceptions.
      • InternalFailureException The service has encountered an unexpected error condition which prevents it from servicing the request.
      • ServiceUnavailableException The service is temporarily unavailable. The request should be retried after some time delay.
      • UnauthorizedException Credentials of the caller are insufficient to authorize the request.
      • TooManyRequestsException Too many requests have been received for this AWS account in too short a time. The request should be retried after some time delay.
      • BadRequestException The request cannot be processed because some parameter is not valid or the project state prevents the operation from being performed.
      • NotFoundException No entity can be found with the specified identifier.
      • AccountActionRequiredException Account Action is required in order to continue the request.
      • LimitExceededException There are too many AWS Mobile Hub projects in the account or the account has exceeded the maximum number of resources in some AWS service. You should create another sub-account using AWS Organizations or remove some resources and retry your request.
      • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.
      • SdkClientException If any client side error occurs such as an IO related failure, failure to get credentials, etc.
      • MobileException Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.
      See Also:
    • updateProject

      default CompletableFuture<UpdateProjectResponse> updateProject(Consumer<UpdateProjectRequest.Builder> updateProjectRequest)

      Update an existing project.


      This is a convenience which creates an instance of the UpdateProjectRequest.Builder avoiding the need to create one manually via UpdateProjectRequest.builder()

      Parameters:
      updateProjectRequest - A Consumer that will call methods on UpdateProjectRequest.Builder to create a request. Request structure used for requests to update project configuration.
      Returns:
      A Java Future containing the result of the UpdateProject operation returned by the service.
      The CompletableFuture returned by this method can be completed exceptionally with the following exceptions.
      • InternalFailureException The service has encountered an unexpected error condition which prevents it from servicing the request.
      • ServiceUnavailableException The service is temporarily unavailable. The request should be retried after some time delay.
      • UnauthorizedException Credentials of the caller are insufficient to authorize the request.
      • TooManyRequestsException Too many requests have been received for this AWS account in too short a time. The request should be retried after some time delay.
      • BadRequestException The request cannot be processed because some parameter is not valid or the project state prevents the operation from being performed.
      • NotFoundException No entity can be found with the specified identifier.
      • AccountActionRequiredException Account Action is required in order to continue the request.
      • LimitExceededException There are too many AWS Mobile Hub projects in the account or the account has exceeded the maximum number of resources in some AWS service. You should create another sub-account using AWS Organizations or remove some resources and retry your request.
      • SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.
      • SdkClientException If any client side error occurs such as an IO related failure, failure to get credentials, etc.
      • MobileException Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.
      See Also:
    • serviceClientConfiguration

      default MobileServiceClientConfiguration serviceClientConfiguration()
      Description copied from interface: SdkClient
      The SDK service client configuration exposes client settings to the user, e.g., ClientOverrideConfiguration
      Specified by:
      serviceClientConfiguration in interface AwsClient
      Specified by:
      serviceClientConfiguration in interface SdkClient
      Returns:
      SdkServiceClientConfiguration
    • create

      static MobileAsyncClient create()
      Create a MobileAsyncClient with the region loaded from the DefaultAwsRegionProviderChain and credentials loaded from the DefaultCredentialsProvider.
    • builder

      static MobileAsyncClientBuilder builder()
      Create a builder that can be used to configure and create a MobileAsyncClient.