Trigger.cpp
Go to the documentation of this file.
1 //
2 // Trigger.cpp
3 // Contains the class "Trigger"
4 //
5 
6 // HISTORY
7 //
8 // 1.0.0 2011-06-06, VWi
9 // Initial version
10 
11 
12 #include "Trigger.hpp"
13 #include "../tools/errorhandler.hpp"
14 #include <sstream> // for std::ostringstream
15 
16 namespace datatypes
17 {
18 
20  : m_number (0)
21 {
23 }
24 
28 Trigger::Trigger (UINT32 number, UINT8 sourceId)
29  : m_number (number)
30 {
32  m_sourceId = sourceId;
33 }
34 
35 
36 // MSVC requires that virtual destructors are located in the cpp-file ...
38 {}
39 
40 
42 {
43  m_number = number;
44 }
45 
46 
47 //
48 // For debug
49 //
50 std::string Trigger::toString()
51 {
52  std::ostringstream stream;
53 
54  stream << "DeviceID="
55  << m_sourceId
56  << ", Number="
57  << m_number;
58 
59  return stream.str();
60 }
61 
62 } // namespace datatypes
63 
UINT32 m_number
The trigger counter.
Definition: Trigger.hpp:45
uint32_t UINT32
Contains the classes Trigger.
Trigger()
Default constructor.
Definition: Trigger.cpp:19
void setNumber(UINT32 number)
Definition: Trigger.cpp:41
virtual ~Trigger()
Destructor.
Definition: Trigger.cpp:37
std::string toString()
Definition: Trigger.cpp:50
uint8_t UINT8


libsick_ldmrs
Author(s): SICK AG , Martin Günther , Jochen Sprickerhof
autogenerated on Mon Oct 26 2020 03:27:30