Interface AsyncDynamoSimplifiedClientInterface

All Superinterfaces:
AutoCloseable
All Known Implementing Classes:
AsyncDynamoSimplifiedClient

public interface AsyncDynamoSimplifiedClientInterface extends AutoCloseable
Interface for AsyncDynamoSimplifiedClient to enable mocking and polymorphic usage.
  • Method Summary

    Modifier and Type
    Method
    Description
    Returns an async cross-table batch get builder for retrieving items from multiple tables.
    Returns an async cross-table batch write builder for putting/deleting items across multiple tables.
    void
     
    <T> @NonNull AsyncEntityTable<T>
    entityTable(@NonNull Class<T> entityClass)
    Returns an AsyncEntityTable for the given entity class, enabling single-table design with auto-computed composite keys and discriminator filtering.
    @NonNull CompletableFuture<software.amazon.awssdk.services.dynamodb.model.ExecuteStatementResponse>
    executeStatement(@NonNull software.amazon.awssdk.services.dynamodb.model.ExecuteStatementRequest request)
    Executes a PartiQL statement against DynamoDB asynchronously.
    @NonNull software.amazon.awssdk.services.dynamodb.DynamoDbAsyncClient
    Returns the underlying DynamoDbAsyncClient.
    @NonNull software.amazon.awssdk.enhanced.dynamodb.DynamoDbEnhancedAsyncClient
    Returns the underlying DynamoDbEnhancedAsyncClient.
    Lists all DynamoDB tables asynchronously.
    <T> @NonNull AsyncTable<T>
    table(@NonNull String tableName, @NonNull Class<T> itemClass)
    Returns a typed AsyncTable for the given table name and item class.
    <T> @NonNull AsyncTable<T>
    table(@NonNull String tableName, @NonNull Class<T> itemClass, @NonNull Consumer<software.amazon.awssdk.enhanced.dynamodb.mapper.StaticTableSchema.Builder<T>> configurator)
    Returns a typed AsyncTable for the given table name and item class, using a StaticTableSchema configured by the provided consumer.
    <T> @NonNull AsyncTable<T>
    table(@NonNull String tableName, @NonNull software.amazon.awssdk.enhanced.dynamodb.TableSchema<T> schema)
    Returns a typed AsyncTable for the given table name and custom schema.
    Starts building an async transactional read operation across one or more tables.
    Starts building an async transactional write operation across one or more tables.
  • Method Details

    • table

      <T> @NonNull AsyncTable<T> table(@NonNull String tableName, @NonNull Class<T> itemClass)
      Returns a typed AsyncTable for the given table name and item class.
      Type Parameters:
      T - the item type
      Parameters:
      tableName - the name of the DynamoDB table
      itemClass - the class of items stored in the table
      Returns:
      an AsyncTable<T> for the specified table
    • table

      <T> @NonNull AsyncTable<T> table(@NonNull String tableName, @NonNull software.amazon.awssdk.enhanced.dynamodb.TableSchema<T> schema)
      Returns a typed AsyncTable for the given table name and custom schema.
      Type Parameters:
      T - the item type
      Parameters:
      tableName - the name of the DynamoDB table
      schema - the table schema defining item mapping
      Returns:
      an AsyncTable<T> for the specified table
    • table

      <T> @NonNull AsyncTable<T> table(@NonNull String tableName, @NonNull Class<T> itemClass, @NonNull Consumer<software.amazon.awssdk.enhanced.dynamodb.mapper.StaticTableSchema.Builder<T>> configurator)
      Returns a typed AsyncTable for the given table name and item class, using a StaticTableSchema configured by the provided consumer.
      Type Parameters:
      T - the item type
      Parameters:
      tableName - the name of the DynamoDB table
      itemClass - the class of items stored in the table
      configurator - a consumer to configure the StaticTableSchema.Builder
      Returns:
      an AsyncTable<T> for the specified table
    • entityTable

      <T> @NonNull AsyncEntityTable<T> entityTable(@NonNull Class<T> entityClass)
      Returns an AsyncEntityTable for the given entity class, enabling single-table design with auto-computed composite keys and discriminator filtering.
      Type Parameters:
      T - the entity type
      Parameters:
      entityClass - the entity class annotated with @Entity
      Returns:
      an AsyncEntityTable<T> for single-table design
    • transactGet

      @NonNull AsyncTransactGetBuilder transactGet()
      Starts building an async transactional read operation across one or more tables.
      Returns:
      an async transact get builder
    • transactWrite

      @NonNull AsyncTransactWriteBuilder transactWrite()
      Starts building an async transactional write operation across one or more tables.
      Returns:
      an async transact write builder
    • batchGet

      @NonNull AsyncCrossTableBatchGetBuilder batchGet()
      Returns an async cross-table batch get builder for retrieving items from multiple tables.
      Returns:
      an async cross-table batch get builder
    • batchWrite

      @NonNull AsyncCrossTableBatchWriteBuilder batchWrite()
      Returns an async cross-table batch write builder for putting/deleting items across multiple tables.
      Returns:
      an async cross-table batch write builder
    • getEnhancedClient

      @NonNull software.amazon.awssdk.enhanced.dynamodb.DynamoDbEnhancedAsyncClient getEnhancedClient()
      Returns the underlying DynamoDbEnhancedAsyncClient.
      Returns:
      the enhanced async DynamoDB client
    • getDynamoDbClient

      @NonNull software.amazon.awssdk.services.dynamodb.DynamoDbAsyncClient getDynamoDbClient()
      Returns the underlying DynamoDbAsyncClient.
      Returns:
      the DynamoDB async client
    • listTables

      @NonNull CompletableFuture<List<String>> listTables()
      Lists all DynamoDB tables asynchronously.
      Returns:
      a CompletableFuture containing a list of table names
    • executeStatement

      @NonNull CompletableFuture<software.amazon.awssdk.services.dynamodb.model.ExecuteStatementResponse> executeStatement(@NonNull software.amazon.awssdk.services.dynamodb.model.ExecuteStatementRequest request)
      Executes a PartiQL statement against DynamoDB asynchronously.
      Parameters:
      request - the PartiQL request to execute
      Returns:
      a CompletableFuture containing the response
    • close

      void close()
      Specified by:
      close in interface AutoCloseable