FACT++  1.0
State.h
Go to the documentation of this file.
1 #ifndef FACT_State
2 #define FACT_State
3 
4 #include <string>
5 #include <vector>
6 
7 #include "Time.h"
8 
9 struct State
10 {
11  int index;
12  std::string name;
13  std::string comment;
15 
16  static std::vector<State> SplitStates(const std::string &buffer);
17 
18  static bool Compare(const State &i, const State &j) { return i.index<j.index; }
19 
20  State(int i=-256, const std::string &n="", const std::string &c="", const Time &t=Time(Time::none));
21 };
22 
23 #endif
std::string comment
Name (e.g. &#39;Connected&#39;)
Definition: State.h:13
int i
Definition: db_dim_client.c:21
Adds some functionality to boost::posix_time::ptime for our needs.
Definition: Time.h:30
int index
Definition: State.h:11
static bool Compare(const State &i, const State &j)
Definition: State.h:18
State(int i=-256, const std::string &n="", const std::string &c="", const Time &t=Time(Time::none))
Definition: State.cc:42
int buffer[BUFFSIZE]
Definition: db_dim_client.c:14
TT t
Definition: test_client.c:26
std::string name
Index (e.g. 1)
Definition: State.h:12
Time time
Description (e.g. &#39;Connection to hardware established.&#39;)
Definition: State.h:14
Do not initialize the time.
Definition: Time.h:51
static std::vector< State > SplitStates(const std::string &buffer)
Time of state change.
Definition: State.cc:58