Clio develop
The XRP Ledger API server.
Loading...
Searching...
No Matches
data::cassandra::impl::Statement Class Reference
Inheritance diagram for data::cassandra::impl::Statement:
Collaboration diagram for data::cassandra::impl::Statement:

Public Member Functions

template<typename... Args>
 Statement (std::string_view query, Args &&... args)
 Construct a new statement with optionally provided arguments.
 
 Statement (CassStatement *ptr)
 
template<typename... Args>
void bind (Args &&... args) const
 Binds the given arguments to the statement.
 
template<typename Type >
void bindAt (std::size_t const idx, Type &&value) const
 Binds an argument to a specific index.
 
- Public Member Functions inherited from data::cassandra::impl::ManagedObject< CassStatement >
 ManagedObject (CassStatement *rawPtr, DeleterCallable deleter)
 
 operator CassStatement * () const
 

Additional Inherited Members

- Protected Attributes inherited from data::cassandra::impl::ManagedObject< CassStatement >
std::unique_ptr< CassStatement, void(*)(CassStatement *)> ptr_
 

Constructor & Destructor Documentation

◆ Statement()

template<typename... Args>
data::cassandra::impl::Statement::Statement ( std::string_view query,
Args &&... args )
inlineexplicit

Construct a new statement with optionally provided arguments.

Note: it's up to the user to make sure the bound parameters match the format of the query (e.g. amount of '?' matches count of args).

Member Function Documentation

◆ bind()

template<typename... Args>
void data::cassandra::impl::Statement::bind ( Args &&... args) const
inline

Binds the given arguments to the statement.

Parameters
argsArguments to bind

◆ bindAt()

template<typename Type >
void data::cassandra::impl::Statement::bindAt ( std::size_t const idx,
Type && value ) const
inline

Binds an argument to a specific index.

Parameters
idxThe index of the argument
valueThe value to bind it to

The documentation for this class was generated from the following file: