0.08.01
C++ Open Travel Request Parsing Library
Toggle main menu visibility
Loading...
Searching...
No Matches
DBType.hpp
Go to the documentation of this file.
1
#ifndef __OPENTREP_DBTYPE_HPP
2
#define __OPENTREP_DBTYPE_HPP
3
4
// //////////////////////////////////////////////////////////////////////
5
// Import section
6
// //////////////////////////////////////////////////////////////////////
7
// STL
8
#include <string>
9
// OpenTrep
10
#include <
opentrep/OPENTREP_Types.hpp
>
11
12
namespace
OPENTREP
{
13
17
struct
DBType
{
18
public
:
19
typedef
enum
{
20
NODB
= 0,
21
SQLITE3
,
22
PG
,
23
MYSQL
,
24
LAST_VALUE
25
} EN_DBType;
26
31
static
const
std::string&
getLabel
(
const
EN_DBType&);
32
36
static
EN_DBType
getType
(
const
char
);
37
41
static
char
getTypeLabel
(
const
EN_DBType&);
42
46
static
std::string
getTypeLabelAsString
(
const
EN_DBType&);
47
51
static
std::string
describeLabels
();
52
56
EN_DBType
getType
()
const
;
57
61
char
getTypeAsChar
()
const
;
62
66
std::string
getTypeAsString
()
const
;
67
72
const
std::string
describe
()
const
;
73
74
public
:
78
bool
operator==
(
const
EN_DBType&)
const
;
79
bool
operator==
(
const
DBType
&)
const
;
80
81
public
:
85
DBType
(
const
EN_DBType&);
89
DBType
(
const
char
iType);
93
DBType
(
const
std::string& iType);
97
DBType
(
const
DBType
&);
98
99
private
:
103
DBType
();
104
105
106
private
:
110
static
const
std::string _labels[
LAST_VALUE
];
114
static
const
char
_typeLabels[
LAST_VALUE
];
115
116
private
:
117
// //////// Attributes /////////
121
EN_DBType _type;
122
};
123
124
}
125
#endif
// __OPENTREP_DBTYPE_HPP
OPENTREP_Types.hpp
OPENTREP
Definition
BasChronometer.cpp:10
OPENTREP::DBType
Enumeration of database types.
Definition
DBType.hpp:17
OPENTREP::DBType::describeLabels
static std::string describeLabels()
Definition
DBType.cpp:105
OPENTREP::DBType::DBType
DBType(const EN_DBType &)
Definition
DBType.cpp:30
OPENTREP::DBType::describe
const std::string describe() const
Definition
DBType.cpp:135
OPENTREP::DBType::getTypeLabelAsString
static std::string getTypeLabelAsString(const EN_DBType &)
Definition
DBType.cpp:98
OPENTREP::DBType::getType
EN_DBType getType() const
Definition
DBType.cpp:117
OPENTREP::DBType::operator==
bool operator==(const EN_DBType &) const
Definition
DBType.cpp:142
OPENTREP::DBType::getTypeAsString
std::string getTypeAsString() const
Definition
DBType.cpp:128
OPENTREP::DBType::getTypeLabel
static char getTypeLabel(const EN_DBType &)
Definition
DBType.cpp:93
OPENTREP::DBType::getLabel
static const std::string & getLabel(const EN_DBType &)
Definition
DBType.cpp:88
OPENTREP::DBType::getTypeAsChar
char getTypeAsChar() const
Definition
DBType.cpp:122
OPENTREP::DBType::MYSQL
@ MYSQL
Definition
DBType.hpp:23
OPENTREP::DBType::PG
@ PG
Definition
DBType.hpp:22
OPENTREP::DBType::LAST_VALUE
@ LAST_VALUE
Definition
DBType.hpp:24
OPENTREP::DBType::SQLITE3
@ SQLITE3
Definition
DBType.hpp:21
OPENTREP::DBType::NODB
@ NODB
Definition
DBType.hpp:20
Generated on
for OpenTREP by
1.17.0