BmnRoot 26.10.0-210-gc52d34b0
Software framework of the BM@N experiment
Loading...
Searching...
No Matches
ElogType.h
Go to the documentation of this file.
1// ----------------------------------------------------------------------
2// ElogType header file
3// Generated 27-11-2017
4// ----------------------------------------------------------------------
5
6/** ElogType.h
7 ** Class for the table: type_
8 **/
9
10#ifndef ElogType_H
11#define ElogType_H 1
12
13#include "ElogConnection.h"
14#include "TDatime.h"
15#include "TString.h"
16
18{
19 private:
20 /* GENERATED PRIVATE MEMBERS (SHOULD NOT BE CHANGED MANUALLY) */
21 /// connection to the database
23
24 /// type id
26 /// type text
28
29 // Constructor
30 ElogType(ElogConnection* db_connect, int type_id, TString type_text);
31 /* END OF PRIVATE GENERATED PART (SHOULD NOT BE CHANGED MANUALLY) */
32
33 public:
34 /* GENERATED PUBLIC MEMBERS (SHOULD NOT BE CHANGED MANUALLY) */
35 virtual ~ElogType(); // Destructor
36
37 // static class functions
38 /// add new type to the database
39 static ElogType* CreateType(TString type_text);
40 /// get type from the database
41 static ElogType* GetType(int type_id);
42 /// get type from the database
43 static ElogType* GetType(TString type_text);
44 /// check type exists in the database: 1- true, 0 - false, <0 - database operation error
45 static int CheckTypeExists(int type_id);
46 /// check type exists in the database: 1- true, 0 - false, <0 - database operation error
47 static int CheckTypeExists(TString type_text);
48 /// delete type from the database
49 static int DeleteType(int type_id);
50 /// delete type from the database
51 static int DeleteType(TString type_text);
52 /// print all types
53 static int PrintAll();
54
55 // Getters
56 /// get type id of the current type
57 int GetTypeId() { return i_type_id; }
58 /// get type text of the current type
60
61 // Setters
62 /// set type text of the current type
63 int SetTypeText(TString type_text);
64
65 /// print information about current type
66 void Print();
67 /* END OF PUBLIC GENERATED PART (SHOULD NOT BE CHANGED MANUALLY) */
68
70};
71
72#endif
#define ClassDef(name, id)
ElogType.h Class for the table: type_.
Definition ElogType.h:18
ElogType(ElogConnection *db_connect, int type_id, TString type_text)
Definition ElogType.cxx:16
static ElogType * CreateType(TString type_text)
add new type to the database
Definition ElogType.cxx:32
static int DeleteType(int type_id)
delete type from the database
Definition ElogType.cxx:262
virtual ~ElogType()
Definition ElogType.cxx:25
static int PrintAll()
print all types
Definition ElogType.cxx:322
int i_type_id
type id
Definition ElogType.h:25
static ElogType * GetType(int type_id)
get type from the database
Definition ElogType.cxx:90
TString str_type_text
type text
Definition ElogType.h:27
TString GetTypeText()
get type text of the current type
Definition ElogType.h:59
static int CheckTypeExists(int type_id)
check type exists in the database: 1- true, 0 - false, <0 - database operation error
Definition ElogType.cxx:182
int GetTypeId()
get type id of the current type
Definition ElogType.h:57
void Print()
print information about current type
Definition ElogType.cxx:396
int SetTypeText(TString type_text)
set type text of the current type
Definition ElogType.cxx:363
ElogConnection * connectionDB
connection to the database
Definition ElogType.h:22