Click or drag to resize

Mapper Class

The default CQL client implementation which uses the DataStax driver ISession provided in the constructor for running queries against a Cassandra cluster.
Inheritance Hierarchy
SystemObject
  Dse.MappingMapper

Namespace:  Dse.Mapping
Assembly:  Dse (in Dse.dll) Version: 2.6.0
Syntax
C#
public class Mapper : IMapper, ICqlQueryAsyncClient, 
	ICqlWriteAsyncClient, ICqlQueryClient, ICqlWriteClient

The Mapper type exposes the following members.

Constructors
  NameDescription
Public methodMapper(ISession)
Creates a new instance of the mapper using Global mapping definitions.
Public methodMapper(ISession, MappingConfiguration)
Creates a new instance of the mapper using the configuration provided
Top
Methods
  NameDescription
Public methodConvertCqlArgumentTValue, TDatabase
Public methodCreateBatch
Creates a new batch.

To set the consistency level, timestamp and other batch options, use WithOptions(ActionCqlQueryOptions). Individual options for each query within the batch will be ignored.

Public methodCreateBatch(BatchType)
Creates a new batch.

To set the consistency level, timestamp and other batch options, use WithOptions(ActionCqlQueryOptions). Individual options for each query within the batch will be ignored.

Public methodDeleteT(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.
Public methodDeleteT(String, 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.
Public methodDeleteT(T, CqlQueryOptions)
Deletes the specified POCO from Cassandra.
Public methodDeleteAsyncT(Cql)
Deletes from the table for the POCO type specified (T) using the CQL statement specified. Prepends "DELETE FROM tablename " to the CQL statement you specify, getting the tablename appropriately from the POCO Type T.
Public methodDeleteAsyncT(String, 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.
Public methodDeleteAsyncT(T, CqlQueryOptions)
Deletes the specified POCO from Cassandra.
Public methodDeleteIfT(Cql)
Deletes from the table for the POCO type specified (T) using the Cql query specified. Prepends "DELETE FROM tablename " to the CQL statement you specify, getting the tablename appropriately from the POCO Type T.

Returns information whether it was applied or not. If it was not applied, it returns details of the existing values.

Public methodDeleteIfT(String, Object)
Deletes from the table for the POCO type specified (T) using the CQL string specified and query parameters specified. Prepends "DELETE FROM tablename " to the CQL statement you specify, getting the tablename appropriately from the POCO Type T.

Returns information whether it was applied or not. If it was not applied, it returns details of the existing values.

Public methodDeleteIfAsyncT(Cql)
Deletes from the table for the POCO type specified (T) using the Cql query specified. Prepends "DELETE FROM tablename " to the CQL statement you specify, getting the tablename appropriately from the POCO Type T.

Returns information whether it was applied or not. If it was not applied, it returns details of the existing values.

Public methodDeleteIfAsyncT(String, Object)
Deletes from the table for the POCO type specified (T) using the CQL string specified and query parameters specified. Prepends "DELETE FROM tablename " to the CQL statement you specify, getting the tablename appropriately from the POCO Type T.

Returns information whether it was applied or not. If it was not applied, it returns details of the existing values.

Public methodEquals
Determines whether the specified object is equal to the current object.
(Inherited from Object.)
Public methodExecute(Cql)
Executes the arbitrary CQL statement specified.
Public methodExecute(ICqlBatch)
Executes the batch specfied synchronously.
Public methodExecute(String, Object)
Executes an arbitrary CQL string with the bind variable values specified.
Public methodExecuteAsync(Cql)
Executes an arbitrary CQL statement.
Public methodExecuteAsync(ICqlBatch)
Executes the batch specified asynchronously.
Public methodExecuteAsync(String, Object)
Executes an arbitrary CQL string with the bind variable values specified.
Public methodExecuteConditionalT
Executes a batch that contains a Lightweight transaction.
Public methodExecuteConditionalAsyncT
Executes a batch that contains a Lightweight transaction.
Public methodFetchT(Cql)
Gets a list of T from Cassandra using the CQL statement specified.
Public methodFetchT(CqlQueryOptions)
Gets a list of all T from Cassandra.
Public methodFetchT(String, Object)
Gets a list of T from Cassandra using the CQL statement and parameter values specified.
Public methodFetchAsyncT(Cql)
Gets a list of T from Cassandra using the CQL statement specified.
Public methodFetchAsyncT(CqlQueryOptions)
Gets a list of all T from Cassandra.
Public methodFetchAsyncT(String, Object)
Gets a list of T from Cassandra using the CQL statement and parameter values specified.
Public methodFetchPageT(Cql)
Gets a paged list of T results from Cassandra. Suitable for manually page through all the results of a query.
Public methodFetchPageT(CqlQueryOptions)
Gets a paged list of T results from Cassandra using the CQL statement specified. Suitable for manually page through all the results of a query.
Public methodFetchPageT(Int32, Byte, String, Object)
Gets a paged list of T results from Cassandra. Suitable for manually page through all the results of a query.
Public methodFetchPageAsyncT(Cql)
Gets a paged list of T results from Cassandra. Suitable for manually page through all the results of a query.
Public methodFetchPageAsyncT(CqlQueryOptions)
Gets a paged list of T results from Cassandra using the CQL statement specified. Suitable for manually page through all the results of a query.
Public methodFetchPageAsyncT(Int32, Byte, String, Object)
Gets a paged list of T results from Cassandra. Suitable for manually page through all the results of a query.
Public methodFirstT(Cql)
Gets the first T from Cassandra using the CQL statement specified. Will throw if no records are returned.
Public methodFirstT(String, Object)
Gets the first T from Cassandra using the CQL statement and parameter values specified. Will throw if no records are returned.
Public methodFirstAsyncT(Cql)
Gets the first T from Cassandra using the CQL specified. Will throw if no records are returned.
Public methodFirstAsyncT(String, Object)
Gets the first T from Cassandra using the CQL statement and parameter values specified. Will throw if no records are returned.
Public methodFirstOrDefaultT(Cql)
Gets the first T from Cassandra using the CQL statement specified. Will return the default value of T if no records are found.
Public methodFirstOrDefaultT(String, Object)
Gets the first T from Cassandra using the CQL statement and parameter values specified. Will return the default value of T is no records are found.
Public methodFirstOrDefaultAsyncT(Cql)
Gets the first T from Cassandra using the CQL specified. Will return the default value of T if no records are found.
Public methodFirstOrDefaultAsyncT(String, Object)
Gets the first T from Cassandra using the CQL statement and parameter values specified. Will return the default value of T is no records are found.
Public methodGetHashCode
Serves as the default hash function.
(Inherited from Object.)
Public methodGetType
Gets the Type of the current instance.
(Inherited from Object.)
Public methodInsertT(T, CqlQueryOptions)
Inserts the specified POCO in Cassandra.
Public methodInsertT(T, Boolean, CqlQueryOptions)
Inserts the specified POCO in Cassandra.
Public methodInsertT(T, Boolean, NullableInt32, CqlQueryOptions)
Inserts the specified POCO in Cassandra.
Public methodInsertAsyncT(T, CqlQueryOptions)
Inserts the specified POCO in Cassandra.
Public methodInsertAsyncT(T, Boolean, CqlQueryOptions)
Inserts the specified POCO in Cassandra.
Public methodInsertAsyncT(T, Boolean, NullableInt32, CqlQueryOptions)
Inserts the specified POCO in Cassandra.
Public methodInsertIfNotExistsT(T, CqlQueryOptions)
Inserts the specified POCO in Cassandra, if not exists.

Returns information whether it was applied or not. If it was not applied, it returns details of the existing values.

Public methodInsertIfNotExistsT(T, Boolean, CqlQueryOptions)
Inserts the specified POCO in Cassandra, if not exists.
Public methodInsertIfNotExistsT(T, Boolean, NullableInt32, CqlQueryOptions)
Inserts the specified POCO in Cassandra, if not exists.
Public methodInsertIfNotExistsAsyncT(T, CqlQueryOptions)
Inserts the specified POCO in Cassandra, if not exists.

Returns information whether it was applied or not. If it was not applied, it returns details of the existing values.

Public methodInsertIfNotExistsAsyncT(T, Boolean, CqlQueryOptions)
Inserts the specified POCO in Cassandra, if not exists.
Public methodInsertIfNotExistsAsyncT(T, Boolean, NullableInt32, CqlQueryOptions)
Inserts the specified POCO in Cassandra, if not exists.
Public methodSingleT(Cql)
Gets a single T from Cassandra using the CQL statement specified. Will throw if no records or more than one record is returned.
Public methodSingleT(String, Object)
Gets a single T from Cassandra using the CQL statement and parameter values specified. Will throw if no records or more than one record is returned.
Public methodSingleAsyncT(Cql)
Gets a single T from Cassandra using the CQL statement specified. Will throw if no records or more than one record is returned.
Public methodSingleAsyncT(String, Object)
Gets a single T from Cassandra using the CQL statement and parameter values specified. Will throw if no records or more than one record is returned.
Public methodSingleOrDefaultT(Cql)
Gets a single T from Cassandra using the CQL statement specified. Will return the default value of T if no records are found. Will throw if more than one record is returned.
Public methodSingleOrDefaultT(String, Object)
Gets a single T from Cassandra using the CQL statement and parameter values specified. Will return the default value of T if no records are found. Will throw if more than one record is returned.
Public methodSingleOrDefaultAsyncT(Cql)
Gets a single T from Cassandra using the CQL statement specified. Will return the default value of T if no records are found. Will throw if more than one record is returned.
Public methodSingleOrDefaultAsyncT(String, Object)
Gets a single T from Cassandra using the CQL statement and parameter values specified. Will return the default value of T if no records are found. Will throw if more than one record is returned.
Public methodToString
Returns a string that represents the current object.
(Inherited from Object.)
Public methodUpdateT(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.
Public methodUpdateT(String, 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.
Public methodUpdateT(T, CqlQueryOptions)
Updates the POCO specified in Cassandra.
Public methodUpdateAsyncT(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.
Public methodUpdateAsyncT(String, 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.
Public methodUpdateAsyncT(T, CqlQueryOptions)
Updates the POCO specified in Cassandra.
Public methodUpdateIfT(Cql)
Updates the table for the poco type specified (T) using the CQL statement specified, using lightweight transactions. Prepends "UPDATE tablename" to the CQL statement you specify, getting the table name appropriately from the POCO Type T.

Returns information whether it was applied or not. If it was not applied, it returns details of the existing values.

Public methodUpdateIfT(String, Object)
Updates the table for the poco type specified (T) using the CQL statement specified, using lightweight transactions. Prepends "UPDATE tablename" to the CQL statement you specify, getting the table name appropriately from the POCO Type T.

Returns information whether it was applied or not. If it was not applied, it returns details of the existing values.

Public methodUpdateIfAsyncT(Cql)
Updates the table for the poco type specified (T) using the CQL statement specified, using lightweight transactions. Prepends "UPDATE tablename" to the CQL statement you specify, getting the table name appropriately from the POCO Type T.

Returns information whether it was applied or not. If it was not applied, it returns details of the existing values.

Public methodUpdateIfAsyncT(String, Object)
Updates the table for the poco type specified (T) using the CQL statement specified, using lightweight transactions. Prepends "UPDATE tablename" to the CQL statement you specify, getting the table name appropriately from the POCO Type T.

Returns information whether it was applied or not. If it was not applied, it returns details of the existing values.

Top
See Also

Reference

Dse.MappingMapper