Lines Matching refs:State
21 const EnumToStringMap<Command::State>::Map kMapStatus[] = {
22 {Command::State::kQueued, "queued"},
23 {Command::State::kInProgress, "inProgress"},
24 {Command::State::kPaused, "paused"},
25 {Command::State::kError, "error"},
26 {Command::State::kDone, "done"},
27 {Command::State::kCancelled, "cancelled"},
28 {Command::State::kAborted, "aborted"},
29 {Command::State::kExpired, "expired"},
38 Command::State from, in ReportInvalidStateTransition()
39 Command::State to) { in ReportInvalidStateTransition()
49 LIBWEAVE_EXPORT EnumToStringMap<Command::State>::EnumToStringMap() in EnumToStringMap()
79 Command::State CommandInstance::GetState() const { in GetState()
106 if (!SetStatus(State::kInProgress, error)) in SetProgress()
126 bool result = SetStatus(State::kDone, error); in Complete()
135 return SetStatus(State::kError, error); in SetError()
244 return SetStatus(State::kPaused, error); in Pause()
250 bool result = SetStatus(State::kAborted, error); in Abort()
257 bool result = SetStatus(State::kCancelled, error); in Cancel()
263 bool CommandInstance::SetStatus(Command::State status, ErrorPtr* error) { in SetStatus()
266 if (status == State::kQueued) in SetStatus()
269 case State::kDone: in SetStatus()
270 case State::kCancelled: in SetStatus()
271 case State::kAborted: in SetStatus()
272 case State::kExpired: in SetStatus()
274 case State::kQueued: in SetStatus()
275 case State::kInProgress: in SetStatus()
276 case State::kPaused: in SetStatus()
277 case State::kError: in SetStatus()