-
Notifications
You must be signed in to change notification settings - Fork 3
/
Check.cpp
executable file
·111 lines (79 loc) · 1.56 KB
/
Check.cpp
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
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
#include "Check.h"
#include "CheckData.h"
CCheck::CCheck()
{
m_pData.reset(new CCheckData);
}
CCheck::CCheck(const CCheck & other)
{
m_pData.reset(new CCheckData(*other.m_pData));
}
CCheck::CCheck(CCheck&& other)
{
m_pData.swap(other.m_pData);
}
CCheck::~CCheck()
{
}
bool CCheck::operator==(const CCheck& rhs) const
{
return GetId() == rhs.GetId();
}
CCheck& CCheck::operator=(const CCheck& rhs)
{
m_pData.reset(new CCheckData(*rhs.m_pData));
return *this;
}
CCheck& CCheck::operator=(CCheck&& rhs)
{
m_pData.swap(rhs.m_pData);
return *this;
}
void CCheck::SetId( const std::string& strId )
{
m_pData->m_strId = strId;
}
void CCheck::SetName( const std::string& strName )
{
m_pData->m_strName = strName;
}
void CCheck::SetNote( const std::string& strNote )
{
m_pData->m_strNote = strNote;
}
void CCheck::SetInterval( const std::string& strInterval )
{
m_pData->m_strInterval = strInterval;
}
void CCheck::SetTcp( const std::string& strTcp )
{
m_pData->m_strTcp = strTcp;
}
void CCheck::SetTimeout( const std::string& strTimeout )
{
m_pData->m_strTimeout = strTimeout;
}
std::string CCheck::GetId() const
{
return m_pData->m_strId;
}
std::string CCheck::GetName() const
{
return m_pData->m_strName;
}
std::string CCheck::GetNote() const
{
return m_pData->m_strNote;
}
std::string CCheck::GetTcp() const
{
return m_pData->m_strTcp;
}
std::string CCheck::GetTimeout() const
{
return m_pData->m_strTimeout;
}
std::string CCheck::GetInterval() const
{
return m_pData->m_strInterval;
}