Interface ICqlWriteClient
The contract for synchronous write operations.
Namespace: Cassandra.Mapping
Assembly: Cassandra.dll
Syntax
public interface ICqlWriteClient
Methods
Delete<T>(Cql)
Deletes from the table for the POCO type specified (T) using the CQL string specified. Prepends "DELETE FROM tablename " to the CQL statement you specify, getting the tablename appropriately from the POCO Type T.
Declaration
void Delete<T>(Cql cql)
Parameters
Type | Name | Description |
---|---|---|
Cql | cql |
Type Parameters
Name | Description |
---|---|
T |
Delete<T>(string, params object[])
Deletes from the table for the POCO type specified (T) using the CQL string and bind variable values specified. Prepends "DELETE FROM tablname " to the CQL string you specify, getting the tablename appropriately from the POCO Type T.
Declaration
void Delete<T>(string cql, params object[] args)
Parameters
Type | Name | Description |
---|---|---|
string | cql | |
object[] | args |
Type Parameters
Name | Description |
---|---|
T |
Delete<T>(T, CqlQueryOptions)
Deletes the specified POCO from Cassandra.
Declaration
void Delete<T>(T poco, CqlQueryOptions queryOptions = null)
Parameters
Type | Name | Description |
---|---|---|
T | poco | |
CqlQueryOptions | queryOptions |
Type Parameters
Name | Description |
---|---|
T |
Execute(Cql)
Executes the arbitrary CQL statement specified.
Declaration
void Execute(Cql cql)
Parameters
Type | Name | Description |
---|---|---|
Cql | cql |
Execute(string, params object[])
Executes an arbitrary CQL string with the bind variable values specified.
Declaration
void Execute(string cql, params object[] args)
Parameters
Type | Name | Description |
---|---|---|
string | cql | |
object[] | args |
Insert<T>(T, CqlQueryOptions)
Inserts the specified POCO in Cassandra.
Declaration
void Insert<T>(T poco, CqlQueryOptions queryOptions = null)
Parameters
Type | Name | Description |
---|---|---|
T | poco | |
CqlQueryOptions | queryOptions |
Type Parameters
Name | Description |
---|---|
T |
Insert<T>(T, bool, CqlQueryOptions)
Inserts the specified POCO in Cassandra.
Declaration
void Insert<T>(T poco, bool insertNulls, CqlQueryOptions queryOptions = null)
Parameters
Type | Name | Description |
---|---|---|
T | poco | The POCO instance |
bool | insertNulls | Determines if the query must be generated using
Use
Use |
CqlQueryOptions | queryOptions | Optional query options |
Type Parameters
Name | Description |
---|---|
T |
Insert<T>(T, bool, int?, CqlQueryOptions)
Inserts the specified POCO in Cassandra.
Declaration
void Insert<T>(T poco, bool insertNulls, int? ttl, CqlQueryOptions queryOptions = null)
Parameters
Type | Name | Description |
---|---|---|
T | poco | The POCO instance |
bool | insertNulls | Determines if the query must be generated using
Use
Use |
int? | ttl | Time to live (in seconds) for the inserted values. If set, the inserted values are automatically removed from the database after the specified time. |
CqlQueryOptions | queryOptions | Optional query options |
Type Parameters
Name | Description |
---|---|
T |
Update<T>(Cql)
Updates the table for the POCO type specified (T) using the CQL statement specified. Prepends "UPDATE tablename" to the CQL statement you specify, getting the tablename appropriately from the POCO Type T.
Declaration
void Update<T>(Cql cql)
Parameters
Type | Name | Description |
---|---|---|
Cql | cql |
Type Parameters
Name | Description |
---|---|
T |
Update<T>(string, params object[])
Updates the table for the POCO type specified (T) using the CQL string and bind variable values specified. Prepends "UPDATE tablename " to the CQL string you specify, getting the tablename appropriately from the POCO Type T.
Declaration
void Update<T>(string cql, params object[] args)
Parameters
Type | Name | Description |
---|---|---|
string | cql | |
object[] | args |
Type Parameters
Name | Description |
---|---|
T | The POCO Type being updated. |
Update<T>(T, CqlQueryOptions)
Updates the POCO specified in Cassandra.
Declaration
void Update<T>(T poco, CqlQueryOptions queryOptions = null)
Parameters
Type | Name | Description |
---|---|---|
T | poco | |
CqlQueryOptions | queryOptions |
Type Parameters
Name | Description |
---|---|
T |