public interface CassandraAdminOperations extends CassandraOperations
ExecutableSelectOperation.ExecutableSelect<T>, ExecutableSelectOperation.SelectWithProjection<T>, ExecutableSelectOperation.SelectWithQuery<T>, ExecutableSelectOperation.SelectWithTable<T>, ExecutableSelectOperation.TerminatingSelect<T>ExecutableInsertOperation.ExecutableInsert<T>, ExecutableInsertOperation.InsertWithOptions<T>, ExecutableInsertOperation.InsertWithTable<T>, ExecutableInsertOperation.TerminatingInsert<T>ExecutableUpdateOperation.ExecutableUpdate, ExecutableUpdateOperation.TerminatingUpdate, ExecutableUpdateOperation.UpdateWithQuery, ExecutableUpdateOperation.UpdateWithTableExecutableDeleteOperation.DeleteWithQuery, ExecutableDeleteOperation.DeleteWithTable, ExecutableDeleteOperation.ExecutableDelete, ExecutableDeleteOperation.TerminatingDelete| Modifier and Type | Method and Description |
|---|---|
void |
createTable(boolean ifNotExists,
com.datastax.oss.driver.api.core.CqlIdentifier tableName,
Class<?> entityClass,
Map<String,Object> optionsByName)
Create a table with the name given and fields corresponding to the given class.
|
void |
dropTable(boolean ifExists,
com.datastax.oss.driver.api.core.CqlIdentifier tableName)
Drops the
named table. |
void |
dropTable(Class<?> entityType)
Drops a table based on the given
entity type. |
void |
dropTable(com.datastax.oss.driver.api.core.CqlIdentifier tableName)
Drops the
named table. |
void |
dropUserType(com.datastax.oss.driver.api.core.CqlIdentifier typeName)
Drops a user type.
|
com.datastax.oss.driver.api.core.metadata.schema.KeyspaceMetadata |
getKeyspaceMetadata()
Returns
KeyspaceMetadata for the current keyspace. |
SchemaFactory |
getSchemaFactory() |
Optional<com.datastax.oss.driver.api.core.metadata.schema.TableMetadata> |
getTableMetadata(com.datastax.oss.driver.api.core.CqlIdentifier keyspace,
com.datastax.oss.driver.api.core.CqlIdentifier tableName)
Lookup
TableMetadata. |
default Optional<com.datastax.oss.driver.api.core.metadata.schema.TableMetadata> |
getTableMetadata(String keyspace,
com.datastax.oss.driver.api.core.CqlIdentifier tableName)
Lookup
TableMetadata. |
batchOps, count, count, delete, delete, delete, delete, deleteById, execute, exists, exists, getConverter, getCqlOperations, getTableName, insert, insert, select, select, select, selectOne, selectOne, selectOne, selectOneById, slice, slice, stream, stream, stream, truncate, update, update, updatequeryinsertupdatedeleteSchemaFactory getSchemaFactory()
SchemaFactory.void createTable(boolean ifNotExists,
com.datastax.oss.driver.api.core.CqlIdentifier tableName,
Class<?> entityClass,
Map<String,Object> optionsByName)
ifNotExists is true, this is a no-op and false is returned. If the table
doesn't exist, parameter ifNotExists is ignored, the table is created and true is returned.ifNotExists - If true, will only create the table if it doesn't exist, else the create operation will be
ignored.tableName - The name of the table.entityClass - The class whose fields determine the columns created.optionsByName - Table options, given by the string option name and the appropriate option value.void dropTable(Class<?> entityType)
entity type. The name of the table is derived from either the simple
name of the entity class or name of the table specified with the Table mapping annotation.entityType - type of the entity for which the table will be dropped.void dropTable(com.datastax.oss.driver.api.core.CqlIdentifier tableName)
named table.tableName - Name of the table to drop.dropTable(boolean, CqlIdentifier)void dropTable(boolean ifExists,
com.datastax.oss.driver.api.core.CqlIdentifier tableName)
named table.ifExists - If true, will only drop the table if it exists, else the drop operation will be ignored.tableName - Name of the table to drop.void dropUserType(com.datastax.oss.driver.api.core.CqlIdentifier typeName)
typeName - must not be null.com.datastax.oss.driver.api.core.metadata.schema.KeyspaceMetadata getKeyspaceMetadata()
KeyspaceMetadata for the current keyspace.KeyspaceMetadata for the current keyspace.default Optional<com.datastax.oss.driver.api.core.metadata.schema.TableMetadata> getTableMetadata(String keyspace, com.datastax.oss.driver.api.core.CqlIdentifier tableName)
TableMetadata.keyspace - must not be empty or null.tableName - must not be null.TableMetadata or null.Optional<com.datastax.oss.driver.api.core.metadata.schema.TableMetadata> getTableMetadata(com.datastax.oss.driver.api.core.CqlIdentifier keyspace, com.datastax.oss.driver.api.core.CqlIdentifier tableName)
TableMetadata.keyspace - must not be null.tableName - must not be null.TableMetadata or null.Copyright © 2011–2021 Pivotal Software, Inc.. All rights reserved.