HCE project C++ developers source code library
1.1.1
HCE project developer library
Main Page
Namespaces
Classes
Files
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
DRCESessionOptions.cpp
Go to the documentation of this file.
1
#include <utility>
2
3
#include "
DRCESessionOptions.hpp
"
4
5
namespace
HCE
6
{
7
namespace
drce
8
{
9
//-----------------------------------------------------------------------------
10
SessionOptions::SessionOptions
(
void
)
11
:
sessionType
(
SessionType
::stHostShell),
port
(0),
userName
(
""
),
userPassword
(
""
),
shellName
(
""
), environments(),
timeout
(0),
tmode
(0)
12
{
13
}
14
//-----------------------------------------------------------------------------
15
SessionOptions::SessionOptions
(
const
SessionOptions
& rhs)
16
:
sessionType
(
SessionType
::stHostShell),
port
(0),
userName
(
""
),
userPassword
(
""
),
shellName
(
""
), environments(),
timeout
(0),
tmode
(0)
17
{
18
(*this) = rhs;
19
}
20
//-----------------------------------------------------------------------------
21
SessionOptions::SessionOptions
(
SessionOptions
&& rhs)
22
:
sessionType
(
SessionType
::stHostShell),
port
(0),
userName
(
""
),
userPassword
(
""
),
shellName
(
""
), environments(),
timeout
(0),
tmode
(0)
23
{
24
(*this) = std::forward<SessionOptions>(rhs);
25
}
26
//-----------------------------------------------------------------------------
27
SessionOptions
&
SessionOptions::operator=
(
const
SessionOptions
& rhs)
28
{
29
if
(
this
!=&rhs)
30
{
31
sessionType
= rhs.
sessionType
;
32
port
= rhs.
port
;
33
userName
= rhs.
userName
;
34
userPassword
= rhs.
userPassword
;
35
shellName
= rhs.
shellName
;
36
environments
= rhs.
environments
;
37
timeout
= rhs.
timeout
;
38
tmode
= rhs.
tmode
;
39
}
40
return
*
this
;
41
}
42
//-----------------------------------------------------------------------------
43
SessionOptions
&
SessionOptions::operator=
(
SessionOptions
&& rhs)
44
{
45
if
(
this
!=&rhs)
46
{
47
sessionType
= std::move(rhs.sessionType);
48
port
= std::move(rhs.port);
49
userName
= std::move(rhs.userName);
50
userPassword
= std::move(rhs.userPassword);
51
shellName
= std::move(rhs.shellName);
52
environments
= std::move(rhs.environments);
53
timeout
= std::move(rhs.timeout);
54
tmode
= std::move(rhs.tmode);
55
}
56
return
*
this
;
57
}
58
//-----------------------------------------------------------------------------
59
void
SessionOptions::clear
(
void
)
60
{
61
sessionType
= SessionType::stHostShell;
62
port
= 0;
63
userName
.clear();
64
userPassword
.clear();
65
shellName
.clear();
66
environments
.clear();
67
timeout
= 0;
68
tmode
= 0;
69
}
70
//-----------------------------------------------------------------------------
71
//-----------------------------------------------------------------------------
72
}
// namespace drce
73
}
// namespace HCE
sources
DRCE
src
DRCESessionOptions.cpp
Generated on Mon Jan 13 2014 13:08:36 for HCE project C++ developers source code library by
1.8.1.2