MCPcopy Create free account
hub / github.com/acking-you/static_flow / parse

Method parse

crates/shared/src/task_status.rs:26–36  ·  view source on GitHub ↗

Parse the LanceDB stored status value.

(value: &str)

Source from the content-addressed store, hash-verified

24impl TaskStatus {
25 /// Parse the LanceDB stored status value.
26 pub fn parse(value: &str) -> Option<Self> {
27 match value {
28 "pending" => Some(Self::Pending),
29 "approved" => Some(Self::Approved),
30 "running" => Some(Self::Running),
31 "done" => Some(Self::Done),
32 "failed" => Some(Self::Failed),
33 "rejected" => Some(Self::Rejected),
34 _ => None,
35 }
36 }
37
38 /// String representation matching the LanceDB stored value.
39 pub fn as_str(self) -> &'static str {

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected