bios_sdk_invoke/
invoke_enumeration.rs1use serde::{Deserialize, Serialize};
2use tardis::web::poem_openapi;
3
4#[derive(Clone, Debug, PartialEq, Eq, Deserialize, Serialize, poem_openapi::Enum)]
5#[serde(rename_all = "lowercase")]
6pub enum InvokeModuleKind {
7 #[oai(rename = "search")]
8 Search,
9 #[oai(rename = "plugin")]
10 Plugin,
11 #[oai(rename = "kv")]
12 Kv,
13 #[oai(rename = "log")]
14 Log,
15 #[oai(rename = "object")]
16 Object,
17 #[oai(rename = "cache")]
18 Cache,
19 #[oai(rename = "graph")]
20 Graph,
21 #[oai(rename = "stats")]
22 Stats,
23 #[oai(rename = "schedule")]
24 Schedule,
25 #[oai(rename = "iam")]
26 Iam,
27 #[oai(rename = "event")]
28 Event,
29}
30
31impl std::fmt::Display for InvokeModuleKind {
32 fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result {
33 match self {
34 InvokeModuleKind::Search => write!(f, "search"),
35 InvokeModuleKind::Plugin => write!(f, "Plugin"),
36 InvokeModuleKind::Kv => write!(f, "kv"),
37 InvokeModuleKind::Log => write!(f, "log"),
38 InvokeModuleKind::Object => write!(f, "object"),
39 InvokeModuleKind::Cache => write!(f, "cache"),
40 InvokeModuleKind::Graph => write!(f, "graph"),
41 InvokeModuleKind::Stats => write!(f, "stats"),
42 InvokeModuleKind::Schedule => write!(f, "schedule"),
43 InvokeModuleKind::Iam => write!(f, "iam"),
44 InvokeModuleKind::Event => write!(f, "event"),
45 }
46 }
47}