mutable
A Database System for Research and Fast Prototyping
Loading...
Searching...
No Matches
Public Member Functions | Private Attributes
m::learn_spns Struct Reference

Learn an SPN on every table in the database that is currently in use. More...

#include <DatabaseCommand.hpp>

Inheritance diagram for m::learn_spns:
[legend]
Collaboration diagram for m::learn_spns:
[legend]

Public Member Functions

 learn_spns (std::vector< std::string > args)
 
void accept (DatabaseCommandVisitor &v) override
 
void accept (ConstDatabaseCommandVisitor &v) const override
 
void execute (Diagnostic &diag) override
 Executes the command.
 
const std::vector< std::string > & args () const
 Returns the arguments of this instruction.
 
template<typename T = ast::Command>
requires std::derived_from<T, ast::Command>
Tast ()
 
template<typename T = ast::Command>
requires std::derived_from<T, ast::Command>
const Tast () const
 
std::unique_ptr< ast::Commandast (std::unique_ptr< ast::Command > new_ast)
 
Scheduler::Transactiontransaction ()
 
void transaction (Scheduler::Transaction *t)
 

Private Attributes

std::vector< std::string > args_
 the arguments of this instruction
 
std::unique_ptr< ast::Commandast_
 

‍the AST of the command; optional


 
Scheduler::Transactiont_
 

‍the transaction this command belongs to


 

Detailed Description

Learn an SPN on every table in the database that is currently in use.

Definition at line 86 of file DatabaseCommand.hpp.

Constructor & Destructor Documentation

◆ learn_spns()

m::learn_spns::learn_spns ( std::vector< std::string >  args)
inline

Definition at line 88 of file DatabaseCommand.hpp.

Member Function Documentation

◆ accept() [1/2]

void m::learn_spns::accept ( ConstDatabaseCommandVisitor &  v) const
overridevirtual

Implements m::DatabaseCommand.

◆ accept() [2/2]

void m::learn_spns::accept ( DatabaseCommandVisitor &  v)
overridevirtual

Implements m::DatabaseCommand.

◆ args()

const std::vector< std::string > & m::DatabaseInstruction::args ( ) const
inlineinherited

Returns the arguments of this instruction.

Definition at line 82 of file DatabaseCommand.hpp.

References m::DatabaseInstruction::args_.

◆ ast() [1/3]

template<typename T = ast::Command>
requires std::derived_from<T, ast::Command>
T & m::DatabaseCommand::ast ( )
inlineinherited

Definition at line 39 of file DatabaseCommand.hpp.

References m::DatabaseCommand::ast_, and m::T().

Referenced by m::QueryDatabase::execute().

◆ ast() [2/3]

template<typename T = ast::Command>
requires std::derived_from<T, ast::Command>
const T & m::DatabaseCommand::ast ( ) const
inlineinherited

Definition at line 42 of file DatabaseCommand.hpp.

References m::DatabaseCommand::ast_, and m::T().

◆ ast() [3/3]

std::unique_ptr< ast::Command > m::DatabaseCommand::ast ( std::unique_ptr< ast::Command new_ast)
inlineinherited

Definition at line 44 of file DatabaseCommand.hpp.

References m::DatabaseCommand::ast_.

◆ execute()

void learn_spns::execute ( Diagnostic diag)
overridevirtual

Executes the command.

Implements m::DatabaseCommand.

Definition at line 23 of file DatabaseCommand.cpp.

References m::Diagnostic::err(), m::Catalog::Get(), m::Options::Get(), and m::Diagnostic::out().

◆ transaction() [1/2]

Scheduler::Transaction * m::DatabaseCommand::transaction ( )
inlineinherited

◆ transaction() [2/2]

void m::DatabaseCommand::transaction ( Scheduler::Transaction t)
inlineinherited

Definition at line 49 of file DatabaseCommand.hpp.

References m::DatabaseCommand::t_.

Field Documentation

◆ args_

std::vector<std::string> m::DatabaseInstruction::args_
privateinherited

the arguments of this instruction

Definition at line 76 of file DatabaseCommand.hpp.

Referenced by m::DatabaseInstruction::args().

◆ ast_

std::unique_ptr<ast::Command> m::DatabaseCommand::ast_
privateinherited

‍the AST of the command; optional

Definition at line 24 of file DatabaseCommand.hpp.

Referenced by m::DatabaseCommand::ast().

◆ t_

Scheduler::Transaction* m::DatabaseCommand::t_
privateinherited

‍the transaction this command belongs to

Definition at line 26 of file DatabaseCommand.hpp.

Referenced by m::DatabaseCommand::transaction().


The documentation for this struct was generated from the following files: