public class SelectStatement extends java.lang.Object implements CQLStatement
Modifier and Type | Class and Description |
---|---|
static class |
SelectStatement.Parameters |
static class |
SelectStatement.RawStatement |
Modifier and Type | Field and Description |
---|---|
CFMetaData |
cfm |
SelectStatement.Parameters |
parameters |
Constructor and Description |
---|
SelectStatement(CFMetaData cfm,
int boundTerms,
SelectStatement.Parameters parameters,
Selection selection,
Term limit) |
Modifier and Type | Method and Description |
---|---|
void |
checkAccess(ClientState state)
Perform any access verification necessary for the statement.
|
java.lang.String |
columnFamily() |
ResultMessage.Rows |
execute(QueryState state,
QueryOptions options)
Execute the statement and return the resulting result or null if there is no result.
|
ResultMessage.Rows |
executeInternal(QueryState state,
QueryOptions options)
Variante of execute used for internal query against the system tables, and thus only query the local node.
|
int |
getBoundTerms()
May be used by custom QueryHandler implementations
|
AbstractBounds<RowPosition> |
getKeyBounds(QueryOptions options)
May be used by custom QueryHandler implementations
|
int |
getLimit(QueryOptions options)
May be used by custom QueryHandler implementations
|
Pageable |
getPageableCommand(QueryOptions options) |
ResultSet.Metadata |
getResultMetadata() |
Selection |
getSelection()
May be used by custom QueryHandler implementations
|
java.util.List<IndexExpression> |
getValidatedIndexExpressions(QueryOptions options)
May be used by custom QueryHandler implementations
|
boolean |
hasClusteringColumnsRestriction()
May be used by custom QueryHandler implementations
|
boolean |
hasPartitionKeyRestriction()
May be used by custom QueryHandler implementations
|
java.lang.String |
keyspace() |
ResultSet |
process(java.util.List<Row> rows) |
ResultMessage.Rows |
processResults(java.util.List<Row> rows,
QueryOptions options,
int limit,
long now) |
void |
validate(ClientState state)
Perform additional validation required by the statment.
|
public final CFMetaData cfm
public final SelectStatement.Parameters parameters
public SelectStatement(CFMetaData cfm, int boundTerms, SelectStatement.Parameters parameters, Selection selection, Term limit)
public ResultSet.Metadata getResultMetadata()
public int getBoundTerms()
getBoundTerms
in interface CQLStatement
public Selection getSelection()
public void checkAccess(ClientState state) throws InvalidRequestException, UnauthorizedException
CQLStatement
checkAccess
in interface CQLStatement
state
- the current client stateInvalidRequestException
UnauthorizedException
public void validate(ClientState state) throws InvalidRequestException
CQLStatement
validate
in interface CQLStatement
state
- the current client stateInvalidRequestException
public ResultMessage.Rows execute(QueryState state, QueryOptions options) throws RequestExecutionException, RequestValidationException
CQLStatement
execute
in interface CQLStatement
state
- the current query stateoptions
- options for this query (consistency, variables, pageSize, ...)RequestExecutionException
RequestValidationException
public Pageable getPageableCommand(QueryOptions options) throws RequestValidationException
RequestValidationException
public ResultMessage.Rows processResults(java.util.List<Row> rows, QueryOptions options, int limit, long now) throws RequestValidationException
RequestValidationException
public ResultMessage.Rows executeInternal(QueryState state, QueryOptions options) throws RequestExecutionException, RequestValidationException
CQLStatement
executeInternal
in interface CQLStatement
state
- the current query stateRequestExecutionException
RequestValidationException
public ResultSet process(java.util.List<Row> rows) throws InvalidRequestException
InvalidRequestException
public java.lang.String keyspace()
public java.lang.String columnFamily()
public AbstractBounds<RowPosition> getKeyBounds(QueryOptions options) throws InvalidRequestException
InvalidRequestException
public int getLimit(QueryOptions options) throws InvalidRequestException
InvalidRequestException
public java.util.List<IndexExpression> getValidatedIndexExpressions(QueryOptions options) throws InvalidRequestException
InvalidRequestException
public boolean hasClusteringColumnsRestriction()
public boolean hasPartitionKeyRestriction()
Copyright © 2016 The Apache Software Foundation