FACT++  1.0
void EventImp::AddAllowedStates ( const std::string &  states)

Add all states in the string to fAllowedStates.

Parameters
statesA string containing the states. They can either be separated by whitespaces or commas, e.g. "1 2 3 4" or "1, 7, 9, 10". Note that no real consistency check is done.

Definition at line 151 of file EventImp.cc.

References AddAllowedState(), and buffer.

Referenced by StateMachineImp::AddEvent(), and operator()().

152 {
153  stringstream stream(states);
154 
155  const bool sep = stream.str().find(',')==string::npos;
156 
157  string buffer;
158  while (getline(stream, buffer, sep ? ' ' : ','))
159  AddAllowedState(stoi(buffer));
160 }
void AddAllowedState(int state)
Definition: EventImp.cc:136
int buffer[BUFFSIZE]
Definition: db_dim_client.c:14
Warning states
Definition: smartfact.txt:92

+ Here is the call graph for this function:

+ Here is the caller graph for this function: