Class SingleKeyItemConditional

java.lang.Object
software.amazon.awssdk.enhanced.dynamodb.internal.conditional.SingleKeyItemConditional
All Implemented Interfaces:
QueryConditional

public class SingleKeyItemConditional extends Object implements QueryConditional
A QueryConditional implementation that matches values from a specific key using a supplied operator for the sort key value comparison. The partition key value will always have an equivalence comparison applied.

This class is used by higher-level (more specific) QueryConditional implementations such as QueryConditional.sortGreaterThan(Key) to reduce code duplication.

  • Constructor Details

    • SingleKeyItemConditional

      public SingleKeyItemConditional(Key key, String operator)
  • Method Details

    • expression

      public Expression expression(TableSchema<?> tableSchema, String indexName)
      Description copied from interface: QueryConditional
      Generates a conditional Expression based on specific context that is supplied as arguments.
      Specified by:
      expression in interface QueryConditional
      Parameters:
      tableSchema - A TableSchema that this expression will be used with
      indexName - The specific index name of the index this expression will be used with
      Returns:
      A specific Expression that can be used as part of a query request
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object