implemented the first version of statement_cache
This commit is contained in:
@@ -1,21 +1,22 @@
|
||||
#ifndef MATADOR_BASIC_SQL_LOGGER_HPP
|
||||
#define MATADOR_BASIC_SQL_LOGGER_HPP
|
||||
|
||||
#include <memory>
|
||||
#include <string>
|
||||
|
||||
namespace matador::sql {
|
||||
|
||||
/**
|
||||
* @brief Base class for sql logging
|
||||
* @brief Base class for SQL logging
|
||||
*
|
||||
* This class acts as a base class to
|
||||
* implement a concrete logger for sql
|
||||
* implement a concrete logger for SQL
|
||||
* statements.
|
||||
*
|
||||
* It provides interfaces to handle
|
||||
* the establishing and closing of
|
||||
* a database connection as well as
|
||||
* when a sql statement is about to
|
||||
* when a SQL statement is about to
|
||||
* execute or going to be prepared.
|
||||
*/
|
||||
class abstract_sql_logger
|
||||
@@ -94,6 +95,8 @@ public:
|
||||
void on_prepare(const std::string &) override { }
|
||||
};
|
||||
|
||||
const auto null_logger = std::make_shared<null_sql_logger>();
|
||||
|
||||
}
|
||||
|
||||
#endif //MATADOR_BASIC_SQL_LOGGER_HPP
|
||||
|
||||
Reference in New Issue
Block a user