hce-node application
1.4.3
HCE Hierarchical Cluster Engine node application
Main Page
Namespaces
Classes
Files
File List
File Members
hce-node application
HCE project node model
Namespaces
Classes
Files
File List
sources
src
utils
algorithms
applicationFramework
asmXMLParser
base64
coreDumpChecker
DRCE
exec
HCECSM
jsonObjExtractor
kvdb
messageStream
samples
src
CustomMessage.cpp
CustomMessage.hpp
LoggerStream.cpp
LoggerStream.hpp
MessagesCollection.cpp
MessagesCollection.hpp
tests
reduceAdditionCore
reduceCore
reduceDRCE
reduceHandler
reduceSphinx
refine
serializable
sphinx
types
xmlCleaner
File Members
•
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
CustomMessage.hpp
Go to the documentation of this file.
1
14
#ifndef CUSTOM_MESSAGE_HPP
15
#define CUSTOM_MESSAGE_HPP
16
17
#include <sstream>
18
19
#include "
MessagesCollection.hpp
"
20
21
namespace
HCE
22
{
23
//-----------------------------------------------------------------------------
24
class
CustomMessage
25
{
26
public
:
27
struct
MsgConst
28
{
29
MsgConst
(
void
) {}
30
MsgConst
(
char
space_,
char
point_,
char
delimiter_) :
space
(space_),
point
(point_),
delimiter
(delimiter_) {}
31
32
char
space
=
' '
;
33
char
point
=
'.'
;
34
char
delimiter
=
':'
;
35
};
36
public
:
37
explicit
CustomMessage
(
MessagesCollection
& collection);
38
CustomMessage
(
const
CustomMessage
& rhs);
39
CustomMessage
(
CustomMessage
&& rhs);
40
virtual
~CustomMessage
(
void
);
41
42
CustomMessage
&
operator=
(
const
CustomMessage
& rhs);
43
CustomMessage
&
operator=
(
CustomMessage
&& rhs);
44
45
void
setMsgConst
(
const
MsgConst
& msgConst);
46
const
MsgConst
&
getMsgConst
(
void
)
const
{
return
msgConst;}
47
48
std::string
operator()
(
unsigned
int
type
);
49
50
template
<
class
T>
51
std::string
operator()
(
unsigned
int
type
,
const
T& t)
52
{
53
std::stringstream outMsg;
54
outMsg << t;
55
return
makeMessage(type, outMsg.str());
56
}
57
58
const
MessagesCollection
getMessagesCollection
(
void
)
const
{
return
collection;}
59
private
:
60
std::string makeMessage(
unsigned
int
type
);
61
std::string makeMessage(
unsigned
int
type
,
const
std::string& arg);
62
63
MsgConst msgConst;
64
MessagesCollection
collection;
65
};
66
//-----------------------------------------------------------------------------
67
//-----------------------------------------------------------------------------
68
}
// end namespace HCE
69
70
#endif // CUSTOM_MESSAGE_HPP
sources
utils
messageStream
src
CustomMessage.hpp
Generated on Tue Jun 30 2015 19:42:14 for hce-node application by
1.8.1.2