ORM C++
Loading...
Searching...
No Matches
orm::db::relations Namespace Reference

Functions

auto createTableStatements (const SqlDialect &dialect, model::ModelView owner, BackendType backend=BackendType::Empty) -> std::vector< std::string >
auto dropTableStatements (const SqlDialect &dialect, model::ModelView owner) -> std::vector< std::string >
auto linkStatement (const SqlDialect &dialect, model::ModelView owner, model::RelationView relation, const binding::PrimaryKey &ownerKey, const binding::PrimaryKey &targetKey, BackendType backend=BackendType::Empty) -> Statement
auto linkInsertSpec (model::ModelView owner, model::RelationView relation, const binding::PrimaryKey &ownerKey, const binding::PrimaryKey &targetKey) -> InsertIfAbsentSpec
auto unlinkStatement (const SqlDialect &dialect, model::ModelView owner, model::RelationView relation, const binding::PrimaryKey &ownerKey, const binding::PrimaryKey &targetKey, BackendType backend=BackendType::Empty) -> Statement
auto collectionSelectStatement (const SqlDialect &dialect, model::ModelView owner, model::RelationView relation, std::string targetSelectSql, const std::vector< binding::PrimaryKey > &ownerKeys, bool joinedValues, BackendType backend=BackendType::Empty) -> Statement

Function Documentation

◆ collectionSelectStatement()

auto orm::db::relations::collectionSelectStatement ( const SqlDialect & dialect,
model::ModelView owner,
model::RelationView relation,
std::string targetSelectSql,
const std::vector< binding::PrimaryKey > & ownerKeys,
bool joinedValues,
BackendType backend = BackendType::Empty ) -> Statement
nodiscardexport

◆ createTableStatements()

auto orm::db::relations::createTableStatements ( const SqlDialect & dialect,
model::ModelView owner,
BackendType backend = BackendType::Empty ) -> std::vector< std::string >
nodiscardexport

◆ dropTableStatements()

auto orm::db::relations::dropTableStatements ( const SqlDialect & dialect,
model::ModelView owner ) -> std::vector< std::string >
nodiscardexport

◆ linkInsertSpec()

auto orm::db::relations::linkInsertSpec ( model::ModelView owner,
model::RelationView relation,
const binding::PrimaryKey & ownerKey,
const binding::PrimaryKey & targetKey ) -> InsertIfAbsentSpec
nodiscardexport

◆ linkStatement()

auto orm::db::relations::linkStatement ( const SqlDialect & dialect,
model::ModelView owner,
model::RelationView relation,
const binding::PrimaryKey & ownerKey,
const binding::PrimaryKey & targetKey,
BackendType backend = BackendType::Empty ) -> Statement
nodiscardexport

◆ unlinkStatement()

auto orm::db::relations::unlinkStatement ( const SqlDialect & dialect,
model::ModelView owner,
model::RelationView relation,
const binding::PrimaryKey & ownerKey,
const binding::PrimaryKey & targetKey,
BackendType backend = BackendType::Empty ) -> Statement
nodiscardexport