-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathsql_table.cpp
More file actions
80 lines (60 loc) · 1.3 KB
/
sql_table.cpp
File metadata and controls
80 lines (60 loc) · 1.3 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
#include "stdafx.h"
#include "sql_table.h"
void orm::sql::swap(orm::sql::sql_table &left, orm::sql::sql_table &right)
{
using std::swap;
swap(left._schema, right._schema);
swap(left._table, right._table);
}
orm::sql::sql_table::sql_table()
{
}
orm::sql::sql_table::sql_table(const orm::sql::sql_table &other) :
_schema(other._schema)
, _table(other._table)
{
}
orm::sql::sql_table::sql_table(orm::sql::sql_table &&other) :
orm::sql::sql_table()
{
swap(*this, other);
}
orm::sql::sql_table::~sql_table()
{
}
orm::sql::sql_table &orm::sql::sql_table::operator =(orm::sql::sql_table other)
{
swap(*this, other);
return *this;
}
bool orm::sql::sql_table::operator ==(const orm::sql::sql_table &other) const
{
bool result = (this == &other);
if (this != &other)
{
result = (_schema == other._schema)
&& (_table == other._table);
}
return result;
}
bool orm::sql::sql_table::operator !=(const orm::sql::sql_table &other) const
{
bool result = !(*this == other);
return result;
}
void orm::sql::sql_table::SetSchema(const std::string &schema)
{
_schema = schema;
}
std::string orm::sql::sql_table::GetSchema() const
{
return _schema;
}
void orm::sql::sql_table::SetTable(const std::string &table)
{
_table = table;
}
std::string orm::sql::sql_table::GetTable() const
{
return _table;
}