Interface GetOption


public interface GetOption
Options for getting a record.
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static final GetOption
    ComparisonCeiling option will make the get operation to search for the record whose key is the lowest key ≥ to the supplied key.
    static final GetOption
    ComparisonEqual sets the Get() operation to compare the stored key for equality.
    static final GetOption
    ComparisonFloor option will make the get operation to search for the record whose key is the highest key ≤ to the supplied key.
    static final GetOption
    ComparisonHigher option will make the get operation to search for the record whose key is strictly > to the supplied key.
    static final GetOption
    ComparisonLower option will make the get operation to search for the record whose key is strictly < to the supplied key.
    static final GetOption
    The specified value will be excluded from the result.
    static final GetOption
    The specified value will be included in the result.
  • Method Summary

    Static Methods
    Modifier and Type
    Method
    Description
    static GetOption
    IncludeValue(boolean includeValue)
    Creates and returns a GetOption that specifies whether to include a value.
    static GetOption
    PartitionKey(String partitionKey)
    PartitionKey overrides the partition routing with the specified `partitionKey` instead of the regular record key.
    static GetOption
    UseIndex(String secondaryIndexName)
    UseIndex let the users specify a different index to follow for the list operation
  • Field Details

    • ComparisonEqual

      static final GetOption ComparisonEqual
      ComparisonEqual sets the Get() operation to compare the stored key for equality.
    • ComparisonFloor

      static final GetOption ComparisonFloor
      ComparisonFloor option will make the get operation to search for the record whose key is the highest key ≤ to the supplied key.
    • ComparisonCeiling

      static final GetOption ComparisonCeiling
      ComparisonCeiling option will make the get operation to search for the record whose key is the lowest key ≥ to the supplied key.
    • ComparisonLower

      static final GetOption ComparisonLower
      ComparisonLower option will make the get operation to search for the record whose key is strictly < to the supplied key.
    • ComparisonHigher

      static final GetOption ComparisonHigher
      ComparisonHigher option will make the get operation to search for the record whose key is strictly > to the supplied key.
    • IncludeValue

      static final GetOption IncludeValue
      The specified value will be included in the result.
    • ExcludeValue

      static final GetOption ExcludeValue
      The specified value will be excluded from the result.
  • Method Details

    • PartitionKey

      static GetOption PartitionKey(String partitionKey)
      PartitionKey overrides the partition routing with the specified `partitionKey` instead of the regular record key.

      Records with the same partitionKey will always be guaranteed to be co-located in the same Oxia shard.

      Parameters:
      partitionKey - the partition key to use
      Returns:
      the GetOption.
    • IncludeValue

      static GetOption IncludeValue(boolean includeValue)
      Creates and returns a GetOption that specifies whether to include a value. This method is used to configure whether a value should be included in the operation.
      Parameters:
      includeValue - A boolean flag indicating whether the value should be included. - true: The value will be included. - false: The value will not be included.
      Returns:
      A GetOption instance representing the include value setting.
    • UseIndex

      static GetOption UseIndex(String secondaryIndexName)
      UseIndex let the users specify a different index to follow for the list operation

      Note: if the secondary index is not unique, which primary record is returned is undefined.

      Parameters:
      secondaryIndexName - the name of the secondary index to use for the list operation
      Returns:
      the GetOption.