FACT++  1.0
template<class T , class S >
StateMachinePowerControl< T, S >::StateMachinePowerControl ( ostream &  out = cout)
inline

Definition at line 365 of file temperature.cc.

References Temperature::State::kConnected, Temperature::State::kDisconnected, Temperature::State::kValid, StateMachinePowerControl< T, S >::SetDebugRx(), and StateMachinePowerControl< T, S >::SetVerbosity().

365  :
366  StateMachineAsio<T>(out, "TEMPERATURE"), fPower(*this, *this)
367  {
368  // State names
369  T::AddStateName(Temperature::State::kDisconnected, "NoConnection",
370  "No connection to web-server could be established recently");
371 
372  T::AddStateName(Temperature::State::kConnected, "Connected",
373  "Connection established, but no valid data received");
374 
375  T::AddStateName(Temperature::State::kValid, "Valid",
376  "Connection established, received data valid");
377 
378  // Verbosity commands
379  T::AddEvent("SET_VERBOSE", "B:1")
380  (bind(&StateMachinePowerControl::SetVerbosity, this, placeholders::_1))
381  ("Set verbosity state"
382  "|verbosity[bool]:disable or enable verbosity for interpreted data (yes/no)");
383 
384  T::AddEvent("SET_DEBUG_RX", "B:1")
385  (bind(&StateMachinePowerControl::SetDebugRx, this, placeholders::_1))
386  ("Set debux-rx state"
387  "|debug[bool]:dump received text and parsed text to console (yes/no)");
388 
389  }
int SetVerbosity(const EventImp &evt)
Definition: pwrctrl.cc:349
int SetDebugRx(const EventImp &evt)
Definition: pwrctrl.cc:359

+ Here is the call graph for this function: