BmnRoot 26.10.0-18-g4e3414f9
Software framework of the BM@N experiment
Loading...
Searching...
No Matches
ElogPerson Class Reference

ElogPerson.h Class for the table: person_. More...

#include <ElogPerson.h>

Collaboration diagram for ElogPerson:

Public Member Functions

virtual ~ElogPerson ()
TString GetPersonId ()
 get person id of the current person
TString GetPersonName ()
 get person name of the current person
bool GetIsActive ()
 get is active of the current person
TString * GetEmail ()
 get email of the current person
int SetPersonName (TString person_name)
 set person name of the current person
int SetIsActive (bool is_active)
 set is active of the current person
int SetEmail (TString *email)
 set email of the current person
void Print ()
 print information about current person
virtual ~ElogPerson ()
TString GetPersonId ()
 get person id of the current person
TString GetPersonName ()
 get person name of the current person
bool GetIsActive ()
 get is active of the current person
TString * GetEmail ()
 get email of the current person
int SetPersonName (TString person_name)
 set person name of the current person
int SetIsActive (bool is_active)
 set is active of the current person
int SetEmail (TString *email)
 set email of the current person
void Print ()
 print information about current person

Static Public Member Functions

static ElogPerson * CreatePerson (TString person_name, bool is_active, TString *email)
 add new person to the database
static ElogPerson * GetPerson (TString person_id)
 get person from the database
static int CheckPersonExists (TString person_id)
 check person exists in the database: 1 - true, 0 - false, <0 - database operation error
static int DeletePerson (TString person_id)
 delete person from the database
static int PrintAll ()
 print all persons
static TObjArray * GetPersonByName (TString person_name_part)
 get persons from the database by name or its part
static int CheckPersonExistsByName (TString person_name_part)
 check persons exists in the database by name or its part: >=1 - person count, 0 - false, <0 - database operation error
static int DeletePersonByName (TString person_name_part)
 delete persons from the database by name or its part >=1 - affected count, 0 - persons not found, <0 - database operation error
static ElogPerson * CreatePerson (TString person_name, bool is_active, TString *email)
 add new person to the database
static ElogPerson * GetPerson (TString person_id)
 get person from the database
static int CheckPersonExists (TString person_id)
 check person exists in the database: 1 - true, 0 - false, <0 - database operation error
static int DeletePerson (TString person_id)
 delete person from the database
static int PrintAll ()
 print all persons
static TObjArray * GetPersonByName (TString person_name_part)
 get persons from the database by name or its part
static int CheckPersonExistsByName (TString person_name_part)
 check persons exists in the database by name or its part: >=1 - person count, 0 - false, <0 - database operation error
static int DeletePersonByName (TString person_name_part)
 delete persons from the database by name or its part >=1 - affected count, 0 - persons not found, <0 - database operation error

Private Member Functions

 ElogPerson (ElogConnection *db_connect, TString person_id, TString person_name, bool is_active, TString *email)
 ElogPerson (ElogConnection *db_connect, TString person_id, TString person_name, bool is_active, TString *email)

Private Attributes

ElogConnection * connectionDB
 connection to the database
TString str_person_id
 person id
TString str_person_name
 person name
bool b_is_active
 is active
TString * str_email
 email

Detailed Description

Definition at line 18 of file ElogPerson.h.

Constructor & Destructor Documentation

◆ ElogPerson() [1/2]

ElogPerson::ElogPerson ( ElogConnection * db_connect,
TString person_id,
TString person_name,
bool is_active,
TString * email )
private

Definition at line 16 of file ElogPerson.cxx.

References b_is_active, connectionDB, str_email, str_person_id, and str_person_name.

Referenced by CreatePerson(), DeletePersonByName(), GetPerson(), and GetPersonByName().

Here is the caller graph for this function:

◆ ~ElogPerson() [1/2]

ElogPerson::~ElogPerson ( )
virtual

Definition at line 31 of file ElogPerson.cxx.

References connectionDB, and str_email.

◆ ElogPerson() [2/2]

ElogPerson::ElogPerson ( ElogConnection * db_connect,
TString person_id,
TString person_name,
bool is_active,
TString * email )
private

◆ ~ElogPerson() [2/2]

virtual ElogPerson::~ElogPerson ( )
virtual

Member Function Documentation

◆ CheckPersonExists() [1/2]

int ElogPerson::CheckPersonExists ( TString person_id)
static

Definition at line 163 of file ElogPerson.cxx.

References TString::Data(), TString::Format(), ElogConnection::GetSQLServer(), TSQLStatement::NextResultRow(), ElogConnection::Open(), TSQLStatement::Process(), TSQLServer::Statement(), and TSQLStatement::StoreResult().

Here is the call graph for this function:

◆ CheckPersonExists() [2/2]

int ElogPerson::CheckPersonExists ( TString person_id)
static

◆ CheckPersonExistsByName() [1/2]

int ElogPerson::CheckPersonExistsByName ( TString person_name_part)
static

Definition at line 459 of file ElogPerson.cxx.

References TString::Data(), TString::Format(), TSQLStatement::GetInt(), ElogConnection::GetSQLServer(), TSQLStatement::NextResultRow(), ElogConnection::Open(), TSQLStatement::Process(), TSQLServer::Statement(), and TSQLStatement::StoreResult().

Here is the call graph for this function:

◆ CheckPersonExistsByName() [2/2]

int ElogPerson::CheckPersonExistsByName ( TString person_name_part)
static

◆ CreatePerson() [1/2]

ElogPerson * ElogPerson::CreatePerson ( TString person_name,
bool is_active,
TString * email )
static

◆ CreatePerson() [2/2]

ElogPerson * ElogPerson::CreatePerson ( TString person_name,
bool is_active,
TString * email )
static

References ElogPerson().

Here is the call graph for this function:

◆ DeletePerson() [1/2]

int ElogPerson::DeletePerson ( TString person_id)
static

Definition at line 203 of file ElogPerson.cxx.

References TString::Format(), ElogConnection::GetSQLServer(), TSQLStatement::NextIteration(), ElogConnection::Open(), TSQLStatement::Process(), TSQLStatement::SetString(), and TSQLServer::Statement().

Here is the call graph for this function:

◆ DeletePerson() [2/2]

int ElogPerson::DeletePerson ( TString person_id)
static

◆ DeletePersonByName() [1/2]

int ElogPerson::DeletePersonByName ( TString person_name_part)
static

Definition at line 502 of file ElogPerson.cxx.

References TString::Format(), TSQLStatement::GetNumAffectedRows(), ElogConnection::GetSQLServer(), TSQLStatement::NextIteration(), ElogConnection::Open(), TSQLStatement::Process(), TSQLStatement::SetString(), and TSQLServer::Statement().

Here is the call graph for this function:

◆ DeletePersonByName() [2/2]

int ElogPerson::DeletePersonByName ( TString person_name_part)
static

References ElogPerson().

Here is the call graph for this function:

◆ GetEmail() [1/2]

TString * ElogPerson::GetEmail ( )
inline

Definition at line 62 of file ElogPerson.h.

References str_email.

◆ GetEmail() [2/2]

TString * ElogPerson::GetEmail ( )
inline

Definition at line 62 of file ElogPerson.h.

References str_email.

◆ GetIsActive() [1/2]

bool ElogPerson::GetIsActive ( )
inline

Definition at line 60 of file ElogPerson.h.

References b_is_active.

◆ GetIsActive() [2/2]

bool ElogPerson::GetIsActive ( )
inline

Definition at line 60 of file ElogPerson.h.

References b_is_active.

◆ GetPerson() [1/2]

ElogPerson * ElogPerson::GetPerson ( TString person_id)
static

Definition at line 110 of file ElogPerson.cxx.

References ElogPerson(), TString::Data(), TString::Format(), TSQLStatement::GetInt(), ElogConnection::GetSQLServer(), TSQLStatement::GetString(), TSQLStatement::IsNull(), TSQLStatement::NextResultRow(), ElogConnection::Open(), TSQLStatement::Process(), TSQLServer::Statement(), and TSQLStatement::StoreResult().

Here is the call graph for this function:

◆ GetPerson() [2/2]

ElogPerson * ElogPerson::GetPerson ( TString person_id)
static

References ElogPerson().

Here is the call graph for this function:

◆ GetPersonByName() [1/2]

TObjArray * ElogPerson::GetPersonByName ( TString person_name_part)
static

◆ GetPersonByName() [2/2]

TObjArray * ElogPerson::GetPersonByName ( TString person_name_part)
static

◆ GetPersonId() [1/2]

TString ElogPerson::GetPersonId ( )
inline

Definition at line 56 of file ElogPerson.h.

References str_person_id.

◆ GetPersonId() [2/2]

TString ElogPerson::GetPersonId ( )
inline

Definition at line 56 of file ElogPerson.h.

References str_person_id.

◆ GetPersonName() [1/2]

TString ElogPerson::GetPersonName ( )
inline

Definition at line 58 of file ElogPerson.h.

References str_person_name.

◆ GetPersonName() [2/2]

TString ElogPerson::GetPersonName ( )
inline

Definition at line 58 of file ElogPerson.h.

References str_person_name.

◆ Print() [1/2]

void ElogPerson::Print ( )

Definition at line 386 of file ElogPerson.cxx.

References b_is_active, str_email, str_person_id, and str_person_name.

◆ Print() [2/2]

void ElogPerson::Print ( )

◆ PrintAll() [1/2]

int ElogPerson::PrintAll ( )
static

Definition at line 233 of file ElogPerson.cxx.

References TString::Format(), TSQLStatement::GetInt(), ElogConnection::GetSQLServer(), TSQLStatement::GetString(), TSQLStatement::IsNull(), TSQLStatement::NextResultRow(), ElogConnection::Open(), TSQLStatement::Process(), TSQLServer::Statement(), and TSQLStatement::StoreResult().

Here is the call graph for this function:

◆ PrintAll() [2/2]

int ElogPerson::PrintAll ( )
static

◆ SetEmail() [1/2]

int ElogPerson::SetEmail ( TString * email)

Definition at line 345 of file ElogPerson.cxx.

References connectionDB, TString::Format(), TSQLStatement::NextIteration(), TSQLStatement::Process(), TSQLStatement::SetNull(), TSQLStatement::SetString(), TSQLServer::Statement(), str_email, and str_person_id.

Here is the call graph for this function:

◆ SetEmail() [2/2]

int ElogPerson::SetEmail ( TString * email)

◆ SetIsActive() [1/2]

int ElogPerson::SetIsActive ( bool is_active)

Definition at line 313 of file ElogPerson.cxx.

References b_is_active, connectionDB, TString::Format(), TSQLStatement::NextIteration(), TSQLStatement::Process(), TSQLStatement::SetInt(), TSQLStatement::SetString(), TSQLServer::Statement(), and str_person_id.

Here is the call graph for this function:

◆ SetIsActive() [2/2]

int ElogPerson::SetIsActive ( bool is_active)

◆ SetPersonName() [1/2]

int ElogPerson::SetPersonName ( TString person_name)

Definition at line 281 of file ElogPerson.cxx.

References connectionDB, TString::Format(), TSQLStatement::NextIteration(), TSQLStatement::Process(), TSQLStatement::SetString(), TSQLServer::Statement(), str_person_id, and str_person_name.

Here is the call graph for this function:

◆ SetPersonName() [2/2]

int ElogPerson::SetPersonName ( TString person_name)

Member Data Documentation

◆ b_is_active

bool ElogPerson::b_is_active
private

Definition at line 30 of file ElogPerson.h.

Referenced by ElogPerson(), GetIsActive(), Print(), and SetIsActive().

◆ connectionDB

ElogConnection * ElogPerson::connectionDB
private

Definition at line 23 of file ElogPerson.h.

Referenced by ElogPerson(), ~ElogPerson(), SetEmail(), SetIsActive(), and SetPersonName().

◆ str_email

TString * ElogPerson::str_email
private

Definition at line 32 of file ElogPerson.h.

Referenced by ElogPerson(), ~ElogPerson(), GetEmail(), Print(), and SetEmail().

◆ str_person_id

TString ElogPerson::str_person_id
private

Definition at line 26 of file ElogPerson.h.

Referenced by ElogPerson(), GetPersonId(), Print(), SetEmail(), SetIsActive(), and SetPersonName().

◆ str_person_name

TString ElogPerson::str_person_name
private

Definition at line 28 of file ElogPerson.h.

Referenced by ElogPerson(), GetPersonName(), Print(), and SetPersonName().


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