public final class CreateTableStatement
extends java.lang.Object
| Modifier and Type | Class and Description |
|---|---|
static class |
CreateTableStatement.Raw |
| Modifier and Type | Field and Description |
|---|---|
protected java.lang.String |
keyspaceName |
| Constructor and Description |
|---|
CreateTableStatement(java.lang.String keyspaceName,
java.lang.String tableName,
java.util.Map<ColumnIdentifier,CQL3Type.Raw> rawColumns,
java.util.Set<ColumnIdentifier> staticColumns,
java.util.List<ColumnIdentifier> partitionKeyColumns,
java.util.List<ColumnIdentifier> clusteringColumns,
java.util.LinkedHashMap<ColumnIdentifier,java.lang.Boolean> clusteringOrder,
TableAttributes attrs,
boolean ifNotExists) |
| Modifier and Type | Method and Description |
|---|---|
Keyspaces |
apply(Keyspaces schema)
Apply a statement transformation to a schema snapshot.
|
void |
authorize(ClientState client)
Perform any access verification necessary for the statement.
|
TableMetadata.Builder |
builder(Types types) |
ResultMessage |
execute(QueryState state,
boolean locally) |
ResultMessage |
execute(QueryState state,
QueryOptions options,
long queryStartNanoTime)
Execute the statement and return the resulting result or null if there is no result.
|
ResultMessage |
executeLocally(QueryState state,
QueryOptions options)
Variant of execute used for internal query against the system tables, and thus only query the local node.
|
AuditLogContext |
getAuditLogContext()
Provides the context needed for audit logging statements.
|
static TableMetadata.Builder |
parse(java.lang.String cql,
java.lang.String keyspace) |
java.lang.String |
toString() |
void |
validate(ClientState state)
Perform additional validation required by the statment.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitgetBindVariables, getFunctions, getPartitionKeyBindVariableIndexes, hasConditionspublic CreateTableStatement(java.lang.String keyspaceName,
java.lang.String tableName,
java.util.Map<ColumnIdentifier,CQL3Type.Raw> rawColumns,
java.util.Set<ColumnIdentifier> staticColumns,
java.util.List<ColumnIdentifier> partitionKeyColumns,
java.util.List<ColumnIdentifier> clusteringColumns,
java.util.LinkedHashMap<ColumnIdentifier,java.lang.Boolean> clusteringOrder,
TableAttributes attrs,
boolean ifNotExists)
public Keyspaces apply(Keyspaces schema)
SchemaTransformationschema - Keyspaces to base the transformation onpublic void authorize(ClientState client)
CQLStatementclient - the current client statepublic AuditLogContext getAuditLogContext()
CQLStatementpublic java.lang.String toString()
toString in class java.lang.Objectpublic TableMetadata.Builder builder(Types types)
public static TableMetadata.Builder parse(java.lang.String cql, java.lang.String keyspace)
public final void validate(ClientState state)
CQLStatementvalidate in interface CQLStatementstate - the current client statepublic ResultMessage execute(QueryState state, QueryOptions options, long queryStartNanoTime)
CQLStatementexecute in interface CQLStatementstate - the current query stateoptions - options for this query (consistency, variables, pageSize, ...)queryStartNanoTime - the timestamp returned by System.nanoTime() when this statement was receivedpublic ResultMessage executeLocally(QueryState state, QueryOptions options)
CQLStatementexecuteLocally in interface CQLStatementstate - the current query statepublic ResultMessage execute(QueryState state, boolean locally)
Copyright © 2009-2019 The Apache Software Foundation