Class AlterTableOptions

java.lang.Object
com.datastax.astra.client.core.options.BaseOptions<AlterTableOptions>
com.datastax.astra.client.tables.commands.options.AlterTableOptions
All Implemented Interfaces:
Cloneable

public class AlterTableOptions extends BaseOptions<AlterTableOptions>
Represents options for altering a table in a database schema. Extends BaseOptions to provide additional functionality for table alteration commands.

This class supports a fluent, chainable API using the Accessors annotation. Common options include specifying whether to include an "IF EXISTS" condition during the operation.

Example usage:

 
 AlterTableOptions options = new AlterTableOptions()
     .ifExists(true);
 
 
  • Field Details

    • IF_EXISTS

      public static final AlterTableOptions IF_EXISTS
      A predefined instance of AlterTableOptions with the "IF EXISTS" condition enabled. This improves syntax for commonly used configurations.
  • Constructor Details

    • AlterTableOptions

      public AlterTableOptions()
      Constructs a new AlterTableOptions instance with default settings. Initializes the options with CommandType.TABLE_ADMIN and the default table serializer.
  • Method Details

    • isIfExists

      public boolean isIfExists()
      Retrieves the value of the "IF EXISTS" condition. This condition determines whether the operation should check for the existence of the table.
      Returns:
      true if the "IF EXISTS" condition is enabled, false otherwise