Class CqlQuery<TEntity>
Represents a Linq query that gets evaluated as a CQL statement.
Inheritance
CqlQuery<TEntity>
Assembly: Cassandra.dll
Syntax
public class CqlQuery<TEntity> : CqlQueryBase<TEntity>, IStatement, IQueryable<TEntity>, IEnumerable<TEntity>, IOrderedQueryable, IQueryable, IEnumerable
Type Parameters
Properties
Provider
IQueryable.Provider implementation
Declaration
public IQueryProvider Provider { get; }
Property Value
Methods
ExecutePaged()
Executes the query and returns a page of results
Declaration
public IPage<TEntity> ExecutePaged()
Returns
Type |
Description |
IPage<TEntity> |
|
ExecutePaged(string)
Executes the query with the provided execution profile and returns a page of results
Declaration
public IPage<TEntity> ExecutePaged(string executionProfile)
Parameters
Type |
Name |
Description |
string |
executionProfile |
|
Returns
Type |
Description |
IPage<TEntity> |
|
ExecutePagedAsync()
Asynchronously executes the query and returns a task of a page of results
Declaration
public Task<IPage<TEntity>> ExecutePagedAsync()
Returns
ExecutePagedAsync(string)
Asynchronously executes the query with the provided execution profile and returns a task of a page of results
Declaration
public Task<IPage<TEntity>> ExecutePagedAsync(string executionProfile)
Parameters
Type |
Name |
Description |
string |
executionProfile |
|
Returns
GetCql(out object[])
Declaration
protected override string GetCql(out object[] values)
Parameters
Type |
Name |
Description |
object[] |
values |
|
Returns
Overrides
GetEnumerator()
Declaration
public IEnumerator<TEntity> GetEnumerator()
Returns
SetConsistencyLevel(ConsistencyLevel?)
Declaration
public CqlQuery<TEntity> SetConsistencyLevel(ConsistencyLevel? consistencyLevel)
Parameters
Returns
SetPageSize(int)
Sets the page size for this query.
The page size controls how much resulting rows will be retrieved
simultaneously (the goal being to avoid loading too much results
in memory for queries yielding large results). Please note that
while value as low as 1 can be used, it is highly discouraged to
use such a low value in practice as it will yield very poor
performance. If in doubt, leaving the default is probably a good
idea.
Declaration
public CqlQuery<TEntity> SetPageSize(int pageSize)
Parameters
Type |
Name |
Description |
int |
pageSize |
|
Returns
Type |
Description |
CqlQuery<TEntity> |
This instance
|
SetPagingState(byte[])
Sets the paging state, a token representing the current page state of query used to continue paging by retrieving the following result page.
Setting the paging state will disable automatic paging.
Declaration
public CqlQuery<TEntity> SetPagingState(byte[] pagingState)
Parameters
Type |
Name |
Description |
byte[] |
pagingState |
|
Returns
Type |
Description |
CqlQuery<TEntity> |
This instance
|
SetSerialConsistencyLevel(ConsistencyLevel)
Declaration
public CqlQuery<TEntity> SetSerialConsistencyLevel(ConsistencyLevel consistencyLevel)
Parameters
Returns
ToString()
Generates and returns cql query for this instance
Declaration
public override string ToString()
Returns
Overrides
Implements
Extension Methods