Nix (Dev) 3.5.10
dev - 3.5.10 - 1af9301
Loading...
Searching...
No Matches
J1939Settings.hpp
Go to the documentation of this file.
1#ifndef IV_SRC_MODEL_COMMS_J1939SETTINGS_HPP_
2#define IV_SRC_MODEL_COMMS_J1939SETTINGS_HPP_
3
5
7{
8
9struct Settings
10{
12 Settings(const Settings &other);
13 Settings(Settings &&other) noexcept;
15
16 Settings &operator=(const Settings &other);
17 Settings &operator=(Settings &&other) noexcept;
18
19 bool load(const iv::file::xml::node &node);
20 bool save(iv::file::xml::node &node) const;
21
22 bool sendHeartbeat {false};
25
26private:
27 struct Keys
28 {
29 static constexpr std::string_view sendHeartbeat {"SendHeartbeat"};
30 static constexpr std::string_view heartbeatSendTime {"HeartbeatSendTime"};
31 static constexpr std::string_view timeOutWait {"TimeOutWait"};
32 };
33
35 {
36 static constexpr bool sendHeartbeat {false};
37 static constexpr uint32_t heartbeatSendTime {1000};
38 static constexpr uint32_t timeOutWait {1000};
39 };
40};
41
42}// namespace iv::model::comms::j1939
43
44#endif//IV_SRC_MODEL_COMMS_J1939SETTINGS_HPP_
Definition xmlFile.hpp:15
Definition J1939Settings.cpp:4
std::chrono::milliseconds pollTime
Definition types.hpp:44
static constexpr bool sendHeartbeat
Definition J1939Settings.hpp:36
static constexpr uint32_t heartbeatSendTime
Definition J1939Settings.hpp:37
static constexpr uint32_t timeOutWait
Definition J1939Settings.hpp:38
Definition J1939Settings.hpp:28
static constexpr std::string_view timeOutWait
Definition J1939Settings.hpp:31
static constexpr std::string_view sendHeartbeat
Definition J1939Settings.hpp:29
static constexpr std::string_view heartbeatSendTime
Definition J1939Settings.hpp:30
Definition J1939Settings.hpp:10
Settings & operator=(const Settings &other)
bool save(iv::file::xml::node &node) const
Definition J1939Settings.cpp:27
iv::types::pollTime heartbeatSendTime
Definition J1939Settings.hpp:23
Settings(const Settings &other)
Settings & operator=(Settings &&other) noexcept
Settings(Settings &&other) noexcept
bool load(const iv::file::xml::node &node)
Definition J1939Settings.cpp:18
iv::types::pollTime timeOutWait
Definition J1939Settings.hpp:24
bool sendHeartbeat
Definition J1939Settings.hpp:22