Class UpdateOneOptions

java.lang.Object
com.datastax.astra.client.model.CommandOptions<UpdateOneOptions>
com.datastax.astra.client.model.UpdateOneOptions

public class UpdateOneOptions extends CommandOptions<UpdateOneOptions>
Options for the updateOne operation
  • Constructor Details

    • UpdateOneOptions

      public UpdateOneOptions()
      Default constructor.
  • Method Details

    • upsert

      public UpdateOneOptions upsert(Boolean upsert)
      Upsert flag.
      Parameters:
      upsert - upsert flag
      Returns:
      current command.
    • sort

      public UpdateOneOptions sort(Sort... sort)
      Syntax sugar as delete option is only a sort
      Parameters:
      sort - add a filter
      Returns:
      current command.
    • vectorize

      public UpdateOneOptions vectorize(String vectorize, Sort... sorts)
      Add a criteria with $vectorize in the sort clause
      Parameters:
      vectorize - an expression to look for vectorization
      sorts - The sort criteria to be applied to the delete operation.
      Returns:
      current command
    • vector

      public UpdateOneOptions vector(float[] vector, Sort... sorts)
      Add a criteria with $vector in the sort clause
      Parameters:
      vector - vector float
      sorts - The sort criteria to be applied to the delete operation.
      Returns:
      current command