FACT++  1.0
const vector< string > StateMachineImp::GetEventNames ( )

Return all event names of the StateMachine

Returns
A vector of strings with all event names of the state machine. The event names all have the SERVER/ pre-fix removed.

Definition at line 371 of file StateMachineImp.cc.

References fListOfEvents, fMutexEvt, fName, and i.

Referenced by IsQueueEmpty().

372 {
373  vector<string> v;
374 
375  const string &name = fName + "/";
376  const int len = name.length();
377 
378  const lock_guard<mutex> guard(fMutexEvt);
379 
380  for (vector<EventImp*>::const_iterator i=fListOfEvents.begin();
381  i!=fListOfEvents.end(); i++)
382  {
383  const string evt = (*i)->GetName();
384 
385  v.push_back(evt.substr(0, len)==name ? evt.substr(len) : evt);
386  }
387 
388  return v;
389 }
int i
Definition: db_dim_client.c:21
std::vector< EventImp * > fListOfEvents
std::string fName
std::mutex fMutexEvt
Mutex to ensure thread-safe access to the command fifo.

+ Here is the caller graph for this function: