Atlas Game Manager
A game manager for f95 and dlsite written in c++
Loading...
Searching...
No Matches
atlas::database::migrations Namespace Reference

Functions

template<>
std::string_view migration< 0 > ()
 
template<>
std::string_view migration< 1 > ()
 
template<>
std::string_view migration< 10 > ()
 
template<>
std::string_view migration< 11 > ()
 
template<>
std::string_view migration< 12 > ()
 
template<>
std::string_view migration< 13 > ()
 
template<>
std::string_view migration< 14 > ()
 
template<>
std::string_view migration< 15 > ()
 
template<>
std::string_view migration< 16 > ()
 
template<>
std::string_view migration< 17 > ()
 
template<>
std::string_view migration< 2 > ()
 
template<>
std::string_view migration< 3 > ()
 
template<>
std::string_view migration< 4 > ()
 
template<>
std::string_view migration< 5 > ()
 
template<>
std::string_view migration< 6 > ()
 
template<>
std::string_view migration< 7 > ()
 
template<>
std::string_view migration< 8 > ()
 
template<>
std::string_view migration< 9 > ()
 
template<std::uint64_t id>
void runUp (Transaction &trans)
 Runs the transaction and marks it as complete in the migrations table.
 
void runUp ()
 Runs all transactions up until hitting MIGRATIONS_VERSION - 1.
 
template<std::uint64_t id>
std::string_view migration ()
 Up must be defined to create/modify the tables that are required.
 

Variables

static constexpr int MIGRATIONS_VERSION { 18 }
 Int to represent what the highest migration is at (Starting at migration 0 we run until we are N <= MIGRATIONS_VERSION)
 

Function Documentation

◆ migration()

template<std::uint64_t id>
std::string_view atlas::database::migrations::migration ( )
nodiscard

Up must be defined to create/modify the tables that are required.

Template Parameters
idID of the migration to run
Returns
Returns the migration string. Must be a valid SQL query

◆ migration< 0 >()

template<>
std::string_view atlas::database::migrations::migration< 0 > ( )

◆ migration< 1 >()

template<>
std::string_view atlas::database::migrations::migration< 1 > ( )

◆ migration< 10 >()

template<>
std::string_view atlas::database::migrations::migration< 10 > ( )

◆ migration< 11 >()

template<>
std::string_view atlas::database::migrations::migration< 11 > ( )

◆ migration< 12 >()

template<>
std::string_view atlas::database::migrations::migration< 12 > ( )

◆ migration< 13 >()

template<>
std::string_view atlas::database::migrations::migration< 13 > ( )

◆ migration< 14 >()

template<>
std::string_view atlas::database::migrations::migration< 14 > ( )

◆ migration< 15 >()

template<>
std::string_view atlas::database::migrations::migration< 15 > ( )

◆ migration< 16 >()

template<>
std::string_view atlas::database::migrations::migration< 16 > ( )

◆ migration< 17 >()

template<>
std::string_view atlas::database::migrations::migration< 17 > ( )

◆ migration< 2 >()

template<>
std::string_view atlas::database::migrations::migration< 2 > ( )

◆ migration< 3 >()

template<>
std::string_view atlas::database::migrations::migration< 3 > ( )

◆ migration< 4 >()

template<>
std::string_view atlas::database::migrations::migration< 4 > ( )

◆ migration< 5 >()

template<>
std::string_view atlas::database::migrations::migration< 5 > ( )

◆ migration< 6 >()

template<>
std::string_view atlas::database::migrations::migration< 6 > ( )

◆ migration< 7 >()

template<>
std::string_view atlas::database::migrations::migration< 7 > ( )

◆ migration< 8 >()

template<>
std::string_view atlas::database::migrations::migration< 8 > ( )

◆ migration< 9 >()

template<>
std::string_view atlas::database::migrations::migration< 9 > ( )

◆ runUp() [1/2]

void atlas::database::migrations::runUp ( )

Runs all transactions up until hitting MIGRATIONS_VERSION - 1.

Exceptions
DatabaseException

◆ runUp() [2/2]

template<std::uint64_t id>
void atlas::database::migrations::runUp ( Transaction & trans)

Runs the transaction and marks it as complete in the migrations table.

Template Parameters
idID of the migration to run.
Parameters
transTransaction to perform the migration on

Variable Documentation

◆ MIGRATIONS_VERSION

int atlas::database::migrations::MIGRATIONS_VERSION { 18 }
inlinestaticconstexpr

Int to represent what the highest migration is at (Starting at migration 0 we run until we are N <= MIGRATIONS_VERSION)