relx 0.1.0
A Modern C++23 Type-Safe SQL Query Builder
Loading...
Searching...
No Matches
relx::schema::drop_table< Table > Class Template Reference

Generate DROP TABLE SQL statement for a table struct. More...

#include <relx/schema/table.hpp>

Public Member Functions

 drop_table (const Table &table_instance)
 
drop_tableif_exists (bool if_exists=true)
 
drop_tablecascade (bool cascade=true)
 
drop_tablerestrict (bool restrict=true)
 
std::string to_sql () const
 
const std::vector< std::string > & bind_params () const
 

Detailed Description

template<TableConcept Table>
class relx::schema::drop_table< Table >

Generate DROP TABLE SQL statement for a table struct.

Template Parameters
TableThe table struct type
Parameters
table_instanceAn instance of the table
if_existsWhether to include the IF EXISTS clause
Returns
SQL string to drop the table

Definition at line 190 of file table.hpp.

Constructor & Destructor Documentation

◆ drop_table()

template<TableConcept Table>
relx::schema::drop_table< Table >::drop_table ( const Table &  table_instance)
inline

Definition at line 192 of file table.hpp.

Member Function Documentation

◆ bind_params()

template<TableConcept Table>
const std::vector< std::string > & relx::schema::drop_table< Table >::bind_params ( ) const
inline

Definition at line 231 of file table.hpp.

◆ cascade()

template<TableConcept Table>
drop_table & relx::schema::drop_table< Table >::cascade ( bool  cascade = true)
inline

Definition at line 199 of file table.hpp.

◆ if_exists()

template<TableConcept Table>
drop_table & relx::schema::drop_table< Table >::if_exists ( bool  if_exists = true)
inline

Definition at line 194 of file table.hpp.

◆ restrict()

template<TableConcept Table>
drop_table & relx::schema::drop_table< Table >::restrict ( bool  restrict = true)
inline

Definition at line 204 of file table.hpp.

◆ to_sql()

template<TableConcept Table>
std::string relx::schema::drop_table< Table >::to_sql ( ) const
inline

Definition at line 209 of file table.hpp.


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