Lightweight 0.20260303.0
Loading...
Searching...
No Matches
Lightweight::SqlScopedTraceLogger Class Reference

Enables protocol-level ODBC trace logging for the given connection. More...

#include <SqlScopedTraceLogger.hpp>

Public Member Functions

 SqlScopedTraceLogger (SqlConnection &connection)
 Constructs a scoped trace logger for the given SQL connection, logging to standard output.
 
 SqlScopedTraceLogger (SqlStatement &stmt)
 Constructs a scoped trace logger for the given SQL statement, logging to standard output.
 
 SqlScopedTraceLogger (SQLHDBC hDbc, std::filesystem::path const &logFile)
 Constructs a scoped trace logger for the given native ODBC handle, logging to the specified file.
 
 SqlScopedTraceLogger (SqlScopedTraceLogger &&)=delete
 
SqlScopedTraceLoggeroperator= (SqlScopedTraceLogger &&)=delete
 
 SqlScopedTraceLogger (SqlScopedTraceLogger const &)=delete
 
SqlScopedTraceLoggeroperator= (SqlScopedTraceLogger const &)=delete
 

Detailed Description

Enables protocol-level ODBC trace logging for the given connection.

The trace logging is active for the lifetime of this object.

The logging output is sent to the standard output stream.

Definition at line 19 of file SqlScopedTraceLogger.hpp.

Constructor & Destructor Documentation

◆ SqlScopedTraceLogger() [1/3]

Lightweight::SqlScopedTraceLogger::SqlScopedTraceLogger ( SqlConnection connection)
inlineexplicit

Constructs a scoped trace logger for the given SQL connection, logging to standard output.

Definition at line 25 of file SqlScopedTraceLogger.hpp.

◆ SqlScopedTraceLogger() [2/3]

Lightweight::SqlScopedTraceLogger::SqlScopedTraceLogger ( SqlStatement stmt)
inlineexplicit

Constructs a scoped trace logger for the given SQL statement, logging to standard output.

Definition at line 37 of file SqlScopedTraceLogger.hpp.

◆ SqlScopedTraceLogger() [3/3]

Lightweight::SqlScopedTraceLogger::SqlScopedTraceLogger ( SQLHDBC  hDbc,
std::filesystem::path const &  logFile 
)
inlineexplicit

Constructs a scoped trace logger for the given native ODBC handle, logging to the specified file.

Definition at line 49 of file SqlScopedTraceLogger.hpp.

◆ ~SqlScopedTraceLogger()

Lightweight::SqlScopedTraceLogger::~SqlScopedTraceLogger ( )
inline

Definition at line 61 of file SqlScopedTraceLogger.hpp.


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