Skip to main content

made_core/value_objects/
output_format.rs

1use serde::{Deserialize, Serialize};
2
3/// Wire- and storage-stable structured output format selector.
4#[derive(Debug, Clone, Copy, PartialEq, Eq, Serialize, Deserialize, Default)]
5pub enum OutputFormat {
6    #[default]
7    JsonObject,
8}
9
10impl OutputFormat {
11    #[must_use]
12    pub const fn as_str(self) -> &'static str {
13        match self {
14            Self::JsonObject => "json_object",
15        }
16    }
17}