windmill_api/models/
auto_pull_mode.rs1use crate::models;
12use serde::{Deserialize, Serialize};
13
14#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)]
16pub enum AutoPullMode {
17 #[serde(rename = "auto")]
18 Auto,
19 #[serde(rename = "webhook")]
20 Webhook,
21 #[serde(rename = "polling")]
22 Polling,
23
24}
25
26impl std::fmt::Display for AutoPullMode {
27 fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result {
28 match self {
29 Self::Auto => write!(f, "auto"),
30 Self::Webhook => write!(f, "webhook"),
31 Self::Polling => write!(f, "polling"),
32 }
33 }
34}
35
36impl Default for AutoPullMode {
37 fn default() -> AutoPullMode {
38 Self::Auto
39 }
40}
41