BmnRoot 26.10.0-233-gb9bbe585
Software framework of the BM@N experiment
Loading...
Searching...
No Matches
TangoConnection Class Reference

#include <TangoConnection.h>

Collaboration diagram for TangoConnection:

Public Types

enum  enumDBMS { MySQL , PgSQL }

Public Member Functions

virtual ~TangoConnection ()
TSQLServer * GetSQLServer ()

Static Public Member Functions

static TangoConnection * Open ()
static TangoConnection * Open (enumDBMS database_type, const char *strDBHost, const char *strDBName, const char *strUID, const char *strPassword)
static const char * DbToString ()

Static Protected Attributes

static mapSQLServer * mapConnection = nullptr

Private Member Functions

 TangoConnection (TSQLServer *pSQLServer)

Static Private Member Functions

static TangoConnection * OpenConnection (const TString &connect_string, const char *strDBHost, const char *strUID, const char *strPassword)

Private Attributes

TSQLServer * tango_db_server

Detailed Description

Definition at line 26 of file TangoConnection.h.

Member Enumeration Documentation

◆ enumDBMS

Enumerator
MySQL 
PgSQL 

Definition at line 29 of file TangoConnection.h.

Constructor & Destructor Documentation

◆ ~TangoConnection()

TangoConnection::~TangoConnection ( )
virtual

Definition at line 85 of file TangoConnection.cxx.

◆ TangoConnection()

TangoConnection::TangoConnection ( TSQLServer * pSQLServer)
private

Definition at line 14 of file TangoConnection.cxx.

References tango_db_server.

Referenced by Open(), Open(), and OpenConnection().

Here is the caller graph for this function:

Member Function Documentation

◆ DbToString()

const char * TangoConnection::DbToString ( )
inlinestatic

Definition at line 45 of file TangoConnection.h.

◆ GetSQLServer()

TSQLServer * TangoConnection::GetSQLServer ( )
inline

Definition at line 43 of file TangoConnection.h.

References tango_db_server.

Referenced by TangoData::GetTangoParameter().

Here is the caller graph for this function:

◆ Open() [1/2]

TangoConnection * TangoConnection::Open ( )
static

Definition at line 54 of file TangoConnection.cxx.

References TangoConnection(), TString::Format(), OpenConnection(), TANGO_DB_HOST, TANGO_DB_NAME, TANGO_DB_PASSWORD, and TANGO_DB_USERNAME.

Referenced by TangoData::GetTangoParameter().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ Open() [2/2]

TangoConnection * TangoConnection::Open ( enumDBMS database_type,
const char * strDBHost,
const char * strDBName,
const char * strUID,
const char * strPassword )
static

Definition at line 61 of file TangoConnection.cxx.

References TangoConnection(), TString::Format(), MySQL, OpenConnection(), and PgSQL.

Here is the call graph for this function:

◆ OpenConnection()

TangoConnection * TangoConnection::OpenConnection ( const TString & connect_string,
const char * strDBHost,
const char * strUID,
const char * strPassword )
staticprivate

Definition at line 19 of file TangoConnection.cxx.

References TangoConnection(), TSQLServer::Connect(), TString::Data(), i, and mapConnection.

Referenced by Open(), and Open().

Here is the call graph for this function:
Here is the caller graph for this function:

Member Data Documentation

◆ mapConnection

mapSQLServer * TangoConnection::mapConnection = nullptr
staticprotected

Definition at line 48 of file TangoConnection.h.

Referenced by OpenConnection().

◆ tango_db_server

TSQLServer* TangoConnection::tango_db_server
private

Definition at line 51 of file TangoConnection.h.

Referenced by TangoConnection(), and GetSQLServer().


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