#[doc = r" Error types."] pub mod error { #[doc = r" Error from a TryFrom or FromStr implementation."] pub struct ConversionError(::std::borrow::Cow<'static, str>); impl ::std::error::Error for ConversionError {} impl ::std::fmt::Display for ConversionError { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> Result<(), ::std::fmt::Error> { ::std::fmt::Display::fmt(&self.0, f) } } impl ::std::fmt::Debug for ConversionError { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> Result<(), ::std::fmt::Error> { ::std::fmt::Debug::fmt(&self.0, f) } } impl From<&'static str> for ConversionError { fn from(value: &'static str) -> Self { Self(value.into()) } } impl From for ConversionError { fn from(value: String) -> Self { Self(value.into()) } } } #[doc = "AggregateTransform"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"type\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"as\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"null\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"cross\": {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"drop\": {"] #[doc = " \"default\": true,"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"fields\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/scaleField\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/paramField\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/expr\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"null\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"groupby\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/scaleField\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/paramField\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/expr\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"key\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/scaleField\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/paramField\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/expr\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"ops\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"values\","] #[doc = " \"count\","] #[doc = " \"__count__\","] #[doc = " \"missing\","] #[doc = " \"valid\","] #[doc = " \"sum\","] #[doc = " \"product\","] #[doc = " \"mean\","] #[doc = " \"average\","] #[doc = " \"variance\","] #[doc = " \"variancep\","] #[doc = " \"stdev\","] #[doc = " \"stdevp\","] #[doc = " \"stderr\","] #[doc = " \"distinct\","] #[doc = " \"ci0\","] #[doc = " \"ci1\","] #[doc = " \"median\","] #[doc = " \"q1\","] #[doc = " \"q3\","] #[doc = " \"min\","] #[doc = " \"max\","] #[doc = " \"argmin\","] #[doc = " \"argmax\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"signal\": {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " \"type\": {"] #[doc = " \"enum\": ["] #[doc = " \"aggregate\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(deny_unknown_fields)] pub struct AggregateTransform { #[serde(rename = "as", default, skip_serializing_if = "Option::is_none")] pub as_: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub cross: Option, #[serde(default = "defaults::aggregate_transform_drop")] pub drop: AggregateTransformDrop, #[serde(default, skip_serializing_if = "Option::is_none")] pub fields: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub groupby: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub key: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub ops: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub signal: Option, #[serde(rename = "type")] pub type_: AggregateTransformType, } impl From<&AggregateTransform> for AggregateTransform { fn from(value: &AggregateTransform) -> Self { value.clone() } } #[doc = "AggregateTransformAs"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"null\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AggregateTransformAs { Variant0(Vec), Variant1(SignalRef), } impl From<&AggregateTransformAs> for AggregateTransformAs { fn from(value: &AggregateTransformAs) -> Self { value.clone() } } impl From> for AggregateTransformAs { fn from(value: Vec) -> Self { Self::Variant0(value) } } impl From for AggregateTransformAs { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "AggregateTransformAsVariant0Item"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"null\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AggregateTransformAsVariant0Item { Variant0(String), Variant1(SignalRef), Variant2, } impl From<&AggregateTransformAsVariant0Item> for AggregateTransformAsVariant0Item { fn from(value: &AggregateTransformAsVariant0Item) -> Self { value.clone() } } impl From for AggregateTransformAsVariant0Item { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "AggregateTransformCross"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AggregateTransformCross { Variant0(bool), Variant1(SignalRef), } impl From<&AggregateTransformCross> for AggregateTransformCross { fn from(value: &AggregateTransformCross) -> Self { value.clone() } } impl From for AggregateTransformCross { fn from(value: bool) -> Self { Self::Variant0(value) } } impl From for AggregateTransformCross { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "AggregateTransformDrop"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"default\": true,"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AggregateTransformDrop { Variant0(bool), Variant1(SignalRef), } impl From<&AggregateTransformDrop> for AggregateTransformDrop { fn from(value: &AggregateTransformDrop) -> Self { value.clone() } } impl Default for AggregateTransformDrop { fn default() -> Self { AggregateTransformDrop::Variant0(true) } } impl From for AggregateTransformDrop { fn from(value: bool) -> Self { Self::Variant0(value) } } impl From for AggregateTransformDrop { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "AggregateTransformFields"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/scaleField\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/paramField\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/expr\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"null\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AggregateTransformFields { Variant0(Vec), Variant1(SignalRef), } impl From<&AggregateTransformFields> for AggregateTransformFields { fn from(value: &AggregateTransformFields) -> Self { value.clone() } } impl From> for AggregateTransformFields { fn from(value: Vec) -> Self { Self::Variant0(value) } } impl From for AggregateTransformFields { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "AggregateTransformFieldsVariant0Item"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/scaleField\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/paramField\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/expr\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"null\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AggregateTransformFieldsVariant0Item { Variant0(ScaleField), Variant1(ParamField), Variant2(Expr), Variant3, } impl From<&AggregateTransformFieldsVariant0Item> for AggregateTransformFieldsVariant0Item { fn from(value: &AggregateTransformFieldsVariant0Item) -> Self { value.clone() } } impl From for AggregateTransformFieldsVariant0Item { fn from(value: ScaleField) -> Self { Self::Variant0(value) } } impl From for AggregateTransformFieldsVariant0Item { fn from(value: ParamField) -> Self { Self::Variant1(value) } } impl From for AggregateTransformFieldsVariant0Item { fn from(value: Expr) -> Self { Self::Variant2(value) } } #[doc = "AggregateTransformGroupby"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/scaleField\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/paramField\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/expr\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AggregateTransformGroupby { Variant0(Vec), Variant1(SignalRef), } impl From<&AggregateTransformGroupby> for AggregateTransformGroupby { fn from(value: &AggregateTransformGroupby) -> Self { value.clone() } } impl From> for AggregateTransformGroupby { fn from(value: Vec) -> Self { Self::Variant0(value) } } impl From for AggregateTransformGroupby { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "AggregateTransformGroupbyVariant0Item"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/scaleField\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/paramField\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/expr\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AggregateTransformGroupbyVariant0Item { ScaleField(ScaleField), ParamField(ParamField), Expr(Expr), } impl From<&AggregateTransformGroupbyVariant0Item> for AggregateTransformGroupbyVariant0Item { fn from(value: &AggregateTransformGroupbyVariant0Item) -> Self { value.clone() } } impl From for AggregateTransformGroupbyVariant0Item { fn from(value: ScaleField) -> Self { Self::ScaleField(value) } } impl From for AggregateTransformGroupbyVariant0Item { fn from(value: ParamField) -> Self { Self::ParamField(value) } } impl From for AggregateTransformGroupbyVariant0Item { fn from(value: Expr) -> Self { Self::Expr(value) } } #[doc = "AggregateTransformKey"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/scaleField\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/paramField\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/expr\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AggregateTransformKey { ScaleField(ScaleField), ParamField(ParamField), Expr(Expr), } impl From<&AggregateTransformKey> for AggregateTransformKey { fn from(value: &AggregateTransformKey) -> Self { value.clone() } } impl From for AggregateTransformKey { fn from(value: ScaleField) -> Self { Self::ScaleField(value) } } impl From for AggregateTransformKey { fn from(value: ParamField) -> Self { Self::ParamField(value) } } impl From for AggregateTransformKey { fn from(value: Expr) -> Self { Self::Expr(value) } } #[doc = "AggregateTransformOps"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"values\","] #[doc = " \"count\","] #[doc = " \"__count__\","] #[doc = " \"missing\","] #[doc = " \"valid\","] #[doc = " \"sum\","] #[doc = " \"product\","] #[doc = " \"mean\","] #[doc = " \"average\","] #[doc = " \"variance\","] #[doc = " \"variancep\","] #[doc = " \"stdev\","] #[doc = " \"stdevp\","] #[doc = " \"stderr\","] #[doc = " \"distinct\","] #[doc = " \"ci0\","] #[doc = " \"ci1\","] #[doc = " \"median\","] #[doc = " \"q1\","] #[doc = " \"q3\","] #[doc = " \"min\","] #[doc = " \"max\","] #[doc = " \"argmin\","] #[doc = " \"argmax\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AggregateTransformOps { Variant0(Vec), Variant1(SignalRef), } impl From<&AggregateTransformOps> for AggregateTransformOps { fn from(value: &AggregateTransformOps) -> Self { value.clone() } } impl From> for AggregateTransformOps { fn from(value: Vec) -> Self { Self::Variant0(value) } } impl From for AggregateTransformOps { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "AggregateTransformOpsVariant0Item"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"values\","] #[doc = " \"count\","] #[doc = " \"__count__\","] #[doc = " \"missing\","] #[doc = " \"valid\","] #[doc = " \"sum\","] #[doc = " \"product\","] #[doc = " \"mean\","] #[doc = " \"average\","] #[doc = " \"variance\","] #[doc = " \"variancep\","] #[doc = " \"stdev\","] #[doc = " \"stdevp\","] #[doc = " \"stderr\","] #[doc = " \"distinct\","] #[doc = " \"ci0\","] #[doc = " \"ci1\","] #[doc = " \"median\","] #[doc = " \"q1\","] #[doc = " \"q3\","] #[doc = " \"min\","] #[doc = " \"max\","] #[doc = " \"argmin\","] #[doc = " \"argmax\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AggregateTransformOpsVariant0Item { Variant0(AggregateTransformOpsVariant0ItemVariant0), Variant1(SignalRef), } impl From<&AggregateTransformOpsVariant0Item> for AggregateTransformOpsVariant0Item { fn from(value: &AggregateTransformOpsVariant0Item) -> Self { value.clone() } } impl From for AggregateTransformOpsVariant0Item { fn from(value: AggregateTransformOpsVariant0ItemVariant0) -> Self { Self::Variant0(value) } } impl From for AggregateTransformOpsVariant0Item { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "AggregateTransformOpsVariant0ItemVariant0"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"enum\": ["] #[doc = " \"values\","] #[doc = " \"count\","] #[doc = " \"__count__\","] #[doc = " \"missing\","] #[doc = " \"valid\","] #[doc = " \"sum\","] #[doc = " \"product\","] #[doc = " \"mean\","] #[doc = " \"average\","] #[doc = " \"variance\","] #[doc = " \"variancep\","] #[doc = " \"stdev\","] #[doc = " \"stdevp\","] #[doc = " \"stderr\","] #[doc = " \"distinct\","] #[doc = " \"ci0\","] #[doc = " \"ci1\","] #[doc = " \"median\","] #[doc = " \"q1\","] #[doc = " \"q3\","] #[doc = " \"min\","] #[doc = " \"max\","] #[doc = " \"argmin\","] #[doc = " \"argmax\""] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] pub enum AggregateTransformOpsVariant0ItemVariant0 { #[serde(rename = "values")] Values, #[serde(rename = "count")] Count, #[serde(rename = "__count__")] Count, #[serde(rename = "missing")] Missing, #[serde(rename = "valid")] Valid, #[serde(rename = "sum")] Sum, #[serde(rename = "product")] Product, #[serde(rename = "mean")] Mean, #[serde(rename = "average")] Average, #[serde(rename = "variance")] Variance, #[serde(rename = "variancep")] Variancep, #[serde(rename = "stdev")] Stdev, #[serde(rename = "stdevp")] Stdevp, #[serde(rename = "stderr")] Stderr, #[serde(rename = "distinct")] Distinct, #[serde(rename = "ci0")] Ci0, #[serde(rename = "ci1")] Ci1, #[serde(rename = "median")] Median, #[serde(rename = "q1")] Q1, #[serde(rename = "q3")] Q3, #[serde(rename = "min")] Min, #[serde(rename = "max")] Max, #[serde(rename = "argmin")] Argmin, #[serde(rename = "argmax")] Argmax, } impl From<&AggregateTransformOpsVariant0ItemVariant0> for AggregateTransformOpsVariant0ItemVariant0 { fn from(value: &AggregateTransformOpsVariant0ItemVariant0) -> Self { value.clone() } } impl ::std::fmt::Display for AggregateTransformOpsVariant0ItemVariant0 { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match *self { Self::Values => write!(f, "values"), Self::Count => write!(f, "count"), Self::Count => write!(f, "__count__"), Self::Missing => write!(f, "missing"), Self::Valid => write!(f, "valid"), Self::Sum => write!(f, "sum"), Self::Product => write!(f, "product"), Self::Mean => write!(f, "mean"), Self::Average => write!(f, "average"), Self::Variance => write!(f, "variance"), Self::Variancep => write!(f, "variancep"), Self::Stdev => write!(f, "stdev"), Self::Stdevp => write!(f, "stdevp"), Self::Stderr => write!(f, "stderr"), Self::Distinct => write!(f, "distinct"), Self::Ci0 => write!(f, "ci0"), Self::Ci1 => write!(f, "ci1"), Self::Median => write!(f, "median"), Self::Q1 => write!(f, "q1"), Self::Q3 => write!(f, "q3"), Self::Min => write!(f, "min"), Self::Max => write!(f, "max"), Self::Argmin => write!(f, "argmin"), Self::Argmax => write!(f, "argmax"), } } } impl std::str::FromStr for AggregateTransformOpsVariant0ItemVariant0 { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { match value { "values" => Ok(Self::Values), "count" => Ok(Self::Count), "__count__" => Ok(Self::Count), "missing" => Ok(Self::Missing), "valid" => Ok(Self::Valid), "sum" => Ok(Self::Sum), "product" => Ok(Self::Product), "mean" => Ok(Self::Mean), "average" => Ok(Self::Average), "variance" => Ok(Self::Variance), "variancep" => Ok(Self::Variancep), "stdev" => Ok(Self::Stdev), "stdevp" => Ok(Self::Stdevp), "stderr" => Ok(Self::Stderr), "distinct" => Ok(Self::Distinct), "ci0" => Ok(Self::Ci0), "ci1" => Ok(Self::Ci1), "median" => Ok(Self::Median), "q1" => Ok(Self::Q1), "q3" => Ok(Self::Q3), "min" => Ok(Self::Min), "max" => Ok(Self::Max), "argmin" => Ok(Self::Argmin), "argmax" => Ok(Self::Argmax), _ => Err("invalid value".into()), } } } impl std::convert::TryFrom<&str> for AggregateTransformOpsVariant0ItemVariant0 { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for AggregateTransformOpsVariant0ItemVariant0 { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for AggregateTransformOpsVariant0ItemVariant0 { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } #[doc = "AggregateTransformType"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"enum\": ["] #[doc = " \"aggregate\""] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] pub enum AggregateTransformType { #[serde(rename = "aggregate")] Aggregate, } impl From<&AggregateTransformType> for AggregateTransformType { fn from(value: &AggregateTransformType) -> Self { value.clone() } } impl ::std::fmt::Display for AggregateTransformType { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match *self { Self::Aggregate => write!(f, "aggregate"), } } } impl std::str::FromStr for AggregateTransformType { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { match value { "aggregate" => Ok(Self::Aggregate), _ => Err("invalid value".into()), } } } impl std::convert::TryFrom<&str> for AggregateTransformType { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for AggregateTransformType { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for AggregateTransformType { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } #[doc = "AlignValue"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/rule\""] #[doc = " },"] #[doc = " {"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/stringModifiers\""] #[doc = " },"] #[doc = " {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"enum\": ["] #[doc = " \"left\","] #[doc = " \"right\","] #[doc = " \"center\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/stringModifiers\""] #[doc = " },"] #[doc = " {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"enum\": ["] #[doc = " \"left\","] #[doc = " \"right\","] #[doc = " \"center\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AlignValue { Variant0(Vec), Variant1(AlignValueVariant1), } impl From<&AlignValue> for AlignValue { fn from(value: &AlignValue) -> Self { value.clone() } } impl From> for AlignValue { fn from(value: Vec) -> Self { Self::Variant0(value) } } impl From for AlignValue { fn from(value: AlignValueVariant1) -> Self { Self::Variant1(value) } } #[doc = "AlignValueVariant0Item"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/rule\""] #[doc = " },"] #[doc = " {"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/stringModifiers\""] #[doc = " },"] #[doc = " {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"enum\": ["] #[doc = " \"left\","] #[doc = " \"right\","] #[doc = " \"center\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AlignValueVariant0Item { Variant0(AlignValueVariant0ItemVariant0), Variant1(AlignValueVariant0ItemVariant1), Variant2(AlignValueVariant0ItemVariant2), Variant3 { offset: ::serde_json::Value, #[serde(default, skip_serializing_if = "Option::is_none")] test: Option, }, } impl From<&AlignValueVariant0Item> for AlignValueVariant0Item { fn from(value: &AlignValueVariant0Item) -> Self { value.clone() } } impl From for AlignValueVariant0Item { fn from(value: AlignValueVariant0ItemVariant0) -> Self { Self::Variant0(value) } } impl From for AlignValueVariant0Item { fn from(value: AlignValueVariant0ItemVariant1) -> Self { Self::Variant1(value) } } impl From for AlignValueVariant0Item { fn from(value: AlignValueVariant0ItemVariant2) -> Self { Self::Variant2(value) } } #[doc = "AlignValueVariant0ItemVariant0"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"scale\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " },"] #[doc = " \"test\": {"] #[doc = " \"type\": \"string\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"enum\": ["] #[doc = " \"left\","] #[doc = " \"right\","] #[doc = " \"center\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AlignValueVariant0ItemVariant0 { Variant0 { #[serde(default, skip_serializing_if = "Option::is_none")] scale: Option, signal: String, #[serde(default, skip_serializing_if = "Option::is_none")] test: Option, }, Variant1 { #[serde(default, skip_serializing_if = "Option::is_none")] scale: Option, #[serde(default, skip_serializing_if = "Option::is_none")] test: Option, value: AlignValueVariant0ItemVariant0Variant1Value, }, Variant2 { field: Field, #[serde(default, skip_serializing_if = "Option::is_none")] scale: Option, #[serde(default, skip_serializing_if = "Option::is_none")] test: Option, }, Variant3 { range: AlignValueVariant0ItemVariant0Variant3Range, #[serde(default, skip_serializing_if = "Option::is_none")] scale: Option, #[serde(default, skip_serializing_if = "Option::is_none")] test: Option, }, } impl From<&AlignValueVariant0ItemVariant0> for AlignValueVariant0ItemVariant0 { fn from(value: &AlignValueVariant0ItemVariant0) -> Self { value.clone() } } #[doc = "AlignValueVariant0ItemVariant0Variant1Value"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"enum\": ["] #[doc = " \"left\","] #[doc = " \"right\","] #[doc = " \"center\""] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] pub enum AlignValueVariant0ItemVariant0Variant1Value { #[serde(rename = "left")] Left, #[serde(rename = "right")] Right, #[serde(rename = "center")] Center, } impl From<&AlignValueVariant0ItemVariant0Variant1Value> for AlignValueVariant0ItemVariant0Variant1Value { fn from(value: &AlignValueVariant0ItemVariant0Variant1Value) -> Self { value.clone() } } impl ::std::fmt::Display for AlignValueVariant0ItemVariant0Variant1Value { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match *self { Self::Left => write!(f, "left"), Self::Right => write!(f, "right"), Self::Center => write!(f, "center"), } } } impl std::str::FromStr for AlignValueVariant0ItemVariant0Variant1Value { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { match value { "left" => Ok(Self::Left), "right" => Ok(Self::Right), "center" => Ok(Self::Center), _ => Err("invalid value".into()), } } } impl std::convert::TryFrom<&str> for AlignValueVariant0ItemVariant0Variant1Value { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for AlignValueVariant0ItemVariant0Variant1Value { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for AlignValueVariant0ItemVariant0Variant1Value { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } #[doc = "AlignValueVariant0ItemVariant0Variant3Range"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AlignValueVariant0ItemVariant0Variant3Range { Variant0(f64), Variant1(bool), } impl From<&AlignValueVariant0ItemVariant0Variant3Range> for AlignValueVariant0ItemVariant0Variant3Range { fn from(value: &AlignValueVariant0ItemVariant0Variant3Range) -> Self { value.clone() } } impl std::str::FromStr for AlignValueVariant0ItemVariant0Variant3Range { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { if let Ok(v) = value.parse() { Ok(Self::Variant0(v)) } else if let Ok(v) = value.parse() { Ok(Self::Variant1(v)) } else { Err("string conversion failed for all variants".into()) } } } impl std::convert::TryFrom<&str> for AlignValueVariant0ItemVariant0Variant3Range { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for AlignValueVariant0ItemVariant0Variant3Range { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for AlignValueVariant0ItemVariant0Variant3Range { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } impl ::std::fmt::Display for AlignValueVariant0ItemVariant0Variant3Range { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match self { Self::Variant0(x) => x.fmt(f), Self::Variant1(x) => x.fmt(f), } } } impl From for AlignValueVariant0ItemVariant0Variant3Range { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for AlignValueVariant0ItemVariant0Variant3Range { fn from(value: bool) -> Self { Self::Variant1(value) } } #[doc = "AlignValueVariant0ItemVariant1"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"scale\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " },"] #[doc = " \"test\": {"] #[doc = " \"type\": \"string\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"enum\": ["] #[doc = " \"left\","] #[doc = " \"right\","] #[doc = " \"center\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] #[serde(deny_unknown_fields)] pub enum AlignValueVariant0ItemVariant1 {} impl From<&AlignValueVariant0ItemVariant1> for AlignValueVariant0ItemVariant1 { fn from(value: &AlignValueVariant0ItemVariant1) -> Self { value.clone() } } #[doc = "AlignValueVariant0ItemVariant2"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"scale\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " },"] #[doc = " \"test\": {"] #[doc = " \"type\": \"string\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"enum\": ["] #[doc = " \"left\","] #[doc = " \"right\","] #[doc = " \"center\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] #[serde(deny_unknown_fields)] pub enum AlignValueVariant0ItemVariant2 {} impl From<&AlignValueVariant0ItemVariant2> for AlignValueVariant0ItemVariant2 { fn from(value: &AlignValueVariant0ItemVariant2) -> Self { value.clone() } } #[doc = "AlignValueVariant1"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/stringModifiers\""] #[doc = " },"] #[doc = " {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"enum\": ["] #[doc = " \"left\","] #[doc = " \"right\","] #[doc = " \"center\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AlignValueVariant1 { Variant0(AlignValueVariant1Variant0), Variant1(AlignValueVariant1Variant1), Variant2(AlignValueVariant1Variant2), Variant3 { offset: ::serde_json::Value }, } impl From<&AlignValueVariant1> for AlignValueVariant1 { fn from(value: &AlignValueVariant1) -> Self { value.clone() } } impl From for AlignValueVariant1 { fn from(value: AlignValueVariant1Variant0) -> Self { Self::Variant0(value) } } impl From for AlignValueVariant1 { fn from(value: AlignValueVariant1Variant1) -> Self { Self::Variant1(value) } } impl From for AlignValueVariant1 { fn from(value: AlignValueVariant1Variant2) -> Self { Self::Variant2(value) } } #[doc = "AlignValueVariant1Variant0"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"scale\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"enum\": ["] #[doc = " \"left\","] #[doc = " \"right\","] #[doc = " \"center\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AlignValueVariant1Variant0 { Variant0 { #[serde(default, skip_serializing_if = "Option::is_none")] scale: Option, signal: String, }, Variant1 { #[serde(default, skip_serializing_if = "Option::is_none")] scale: Option, value: AlignValueVariant1Variant0Variant1Value, }, Variant2 { field: Field, #[serde(default, skip_serializing_if = "Option::is_none")] scale: Option, }, Variant3 { range: AlignValueVariant1Variant0Variant3Range, #[serde(default, skip_serializing_if = "Option::is_none")] scale: Option, }, } impl From<&AlignValueVariant1Variant0> for AlignValueVariant1Variant0 { fn from(value: &AlignValueVariant1Variant0) -> Self { value.clone() } } #[doc = "AlignValueVariant1Variant0Variant1Value"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"enum\": ["] #[doc = " \"left\","] #[doc = " \"right\","] #[doc = " \"center\""] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] pub enum AlignValueVariant1Variant0Variant1Value { #[serde(rename = "left")] Left, #[serde(rename = "right")] Right, #[serde(rename = "center")] Center, } impl From<&AlignValueVariant1Variant0Variant1Value> for AlignValueVariant1Variant0Variant1Value { fn from(value: &AlignValueVariant1Variant0Variant1Value) -> Self { value.clone() } } impl ::std::fmt::Display for AlignValueVariant1Variant0Variant1Value { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match *self { Self::Left => write!(f, "left"), Self::Right => write!(f, "right"), Self::Center => write!(f, "center"), } } } impl std::str::FromStr for AlignValueVariant1Variant0Variant1Value { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { match value { "left" => Ok(Self::Left), "right" => Ok(Self::Right), "center" => Ok(Self::Center), _ => Err("invalid value".into()), } } } impl std::convert::TryFrom<&str> for AlignValueVariant1Variant0Variant1Value { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for AlignValueVariant1Variant0Variant1Value { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for AlignValueVariant1Variant0Variant1Value { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } #[doc = "AlignValueVariant1Variant0Variant3Range"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AlignValueVariant1Variant0Variant3Range { Variant0(f64), Variant1(bool), } impl From<&AlignValueVariant1Variant0Variant3Range> for AlignValueVariant1Variant0Variant3Range { fn from(value: &AlignValueVariant1Variant0Variant3Range) -> Self { value.clone() } } impl std::str::FromStr for AlignValueVariant1Variant0Variant3Range { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { if let Ok(v) = value.parse() { Ok(Self::Variant0(v)) } else if let Ok(v) = value.parse() { Ok(Self::Variant1(v)) } else { Err("string conversion failed for all variants".into()) } } } impl std::convert::TryFrom<&str> for AlignValueVariant1Variant0Variant3Range { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for AlignValueVariant1Variant0Variant3Range { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for AlignValueVariant1Variant0Variant3Range { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } impl ::std::fmt::Display for AlignValueVariant1Variant0Variant3Range { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match self { Self::Variant0(x) => x.fmt(f), Self::Variant1(x) => x.fmt(f), } } } impl From for AlignValueVariant1Variant0Variant3Range { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for AlignValueVariant1Variant0Variant3Range { fn from(value: bool) -> Self { Self::Variant1(value) } } #[doc = "AlignValueVariant1Variant1"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"scale\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"enum\": ["] #[doc = " \"left\","] #[doc = " \"right\","] #[doc = " \"center\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] #[serde(deny_unknown_fields)] pub enum AlignValueVariant1Variant1 {} impl From<&AlignValueVariant1Variant1> for AlignValueVariant1Variant1 { fn from(value: &AlignValueVariant1Variant1) -> Self { value.clone() } } #[doc = "AlignValueVariant1Variant2"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"scale\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"enum\": ["] #[doc = " \"left\","] #[doc = " \"right\","] #[doc = " \"center\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] #[serde(deny_unknown_fields)] pub enum AlignValueVariant1Variant2 {} impl From<&AlignValueVariant1Variant2> for AlignValueVariant1Variant2 { fn from(value: &AlignValueVariant1Variant2) -> Self { value.clone() } } #[doc = "AnchorValue"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/rule\""] #[doc = " },"] #[doc = " {"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/stringModifiers\""] #[doc = " },"] #[doc = " {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"enum\": ["] #[doc = " \"start\","] #[doc = " \"middle\","] #[doc = " \"end\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/stringModifiers\""] #[doc = " },"] #[doc = " {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"enum\": ["] #[doc = " \"start\","] #[doc = " \"middle\","] #[doc = " \"end\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AnchorValue { Variant0(Vec), Variant1(AnchorValueVariant1), } impl From<&AnchorValue> for AnchorValue { fn from(value: &AnchorValue) -> Self { value.clone() } } impl From> for AnchorValue { fn from(value: Vec) -> Self { Self::Variant0(value) } } impl From for AnchorValue { fn from(value: AnchorValueVariant1) -> Self { Self::Variant1(value) } } #[doc = "AnchorValueVariant0Item"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/rule\""] #[doc = " },"] #[doc = " {"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/stringModifiers\""] #[doc = " },"] #[doc = " {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"enum\": ["] #[doc = " \"start\","] #[doc = " \"middle\","] #[doc = " \"end\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AnchorValueVariant0Item { Variant0(AnchorValueVariant0ItemVariant0), Variant1(AnchorValueVariant0ItemVariant1), Variant2(AnchorValueVariant0ItemVariant2), Variant3 { offset: ::serde_json::Value, #[serde(default, skip_serializing_if = "Option::is_none")] test: Option, }, } impl From<&AnchorValueVariant0Item> for AnchorValueVariant0Item { fn from(value: &AnchorValueVariant0Item) -> Self { value.clone() } } impl From for AnchorValueVariant0Item { fn from(value: AnchorValueVariant0ItemVariant0) -> Self { Self::Variant0(value) } } impl From for AnchorValueVariant0Item { fn from(value: AnchorValueVariant0ItemVariant1) -> Self { Self::Variant1(value) } } impl From for AnchorValueVariant0Item { fn from(value: AnchorValueVariant0ItemVariant2) -> Self { Self::Variant2(value) } } #[doc = "AnchorValueVariant0ItemVariant0"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"scale\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " },"] #[doc = " \"test\": {"] #[doc = " \"type\": \"string\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"enum\": ["] #[doc = " \"start\","] #[doc = " \"middle\","] #[doc = " \"end\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AnchorValueVariant0ItemVariant0 { Variant0 { #[serde(default, skip_serializing_if = "Option::is_none")] scale: Option, signal: String, #[serde(default, skip_serializing_if = "Option::is_none")] test: Option, }, Variant1 { #[serde(default, skip_serializing_if = "Option::is_none")] scale: Option, #[serde(default, skip_serializing_if = "Option::is_none")] test: Option, value: AnchorValueVariant0ItemVariant0Variant1Value, }, Variant2 { field: Field, #[serde(default, skip_serializing_if = "Option::is_none")] scale: Option, #[serde(default, skip_serializing_if = "Option::is_none")] test: Option, }, Variant3 { range: AnchorValueVariant0ItemVariant0Variant3Range, #[serde(default, skip_serializing_if = "Option::is_none")] scale: Option, #[serde(default, skip_serializing_if = "Option::is_none")] test: Option, }, } impl From<&AnchorValueVariant0ItemVariant0> for AnchorValueVariant0ItemVariant0 { fn from(value: &AnchorValueVariant0ItemVariant0) -> Self { value.clone() } } #[doc = "AnchorValueVariant0ItemVariant0Variant1Value"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"enum\": ["] #[doc = " \"start\","] #[doc = " \"middle\","] #[doc = " \"end\""] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] pub enum AnchorValueVariant0ItemVariant0Variant1Value { #[serde(rename = "start")] Start, #[serde(rename = "middle")] Middle, #[serde(rename = "end")] End, } impl From<&AnchorValueVariant0ItemVariant0Variant1Value> for AnchorValueVariant0ItemVariant0Variant1Value { fn from(value: &AnchorValueVariant0ItemVariant0Variant1Value) -> Self { value.clone() } } impl ::std::fmt::Display for AnchorValueVariant0ItemVariant0Variant1Value { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match *self { Self::Start => write!(f, "start"), Self::Middle => write!(f, "middle"), Self::End => write!(f, "end"), } } } impl std::str::FromStr for AnchorValueVariant0ItemVariant0Variant1Value { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { match value { "start" => Ok(Self::Start), "middle" => Ok(Self::Middle), "end" => Ok(Self::End), _ => Err("invalid value".into()), } } } impl std::convert::TryFrom<&str> for AnchorValueVariant0ItemVariant0Variant1Value { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for AnchorValueVariant0ItemVariant0Variant1Value { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for AnchorValueVariant0ItemVariant0Variant1Value { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } #[doc = "AnchorValueVariant0ItemVariant0Variant3Range"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AnchorValueVariant0ItemVariant0Variant3Range { Variant0(f64), Variant1(bool), } impl From<&AnchorValueVariant0ItemVariant0Variant3Range> for AnchorValueVariant0ItemVariant0Variant3Range { fn from(value: &AnchorValueVariant0ItemVariant0Variant3Range) -> Self { value.clone() } } impl std::str::FromStr for AnchorValueVariant0ItemVariant0Variant3Range { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { if let Ok(v) = value.parse() { Ok(Self::Variant0(v)) } else if let Ok(v) = value.parse() { Ok(Self::Variant1(v)) } else { Err("string conversion failed for all variants".into()) } } } impl std::convert::TryFrom<&str> for AnchorValueVariant0ItemVariant0Variant3Range { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for AnchorValueVariant0ItemVariant0Variant3Range { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for AnchorValueVariant0ItemVariant0Variant3Range { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } impl ::std::fmt::Display for AnchorValueVariant0ItemVariant0Variant3Range { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match self { Self::Variant0(x) => x.fmt(f), Self::Variant1(x) => x.fmt(f), } } } impl From for AnchorValueVariant0ItemVariant0Variant3Range { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for AnchorValueVariant0ItemVariant0Variant3Range { fn from(value: bool) -> Self { Self::Variant1(value) } } #[doc = "AnchorValueVariant0ItemVariant1"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"scale\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " },"] #[doc = " \"test\": {"] #[doc = " \"type\": \"string\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"enum\": ["] #[doc = " \"start\","] #[doc = " \"middle\","] #[doc = " \"end\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] #[serde(deny_unknown_fields)] pub enum AnchorValueVariant0ItemVariant1 {} impl From<&AnchorValueVariant0ItemVariant1> for AnchorValueVariant0ItemVariant1 { fn from(value: &AnchorValueVariant0ItemVariant1) -> Self { value.clone() } } #[doc = "AnchorValueVariant0ItemVariant2"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"scale\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " },"] #[doc = " \"test\": {"] #[doc = " \"type\": \"string\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"enum\": ["] #[doc = " \"start\","] #[doc = " \"middle\","] #[doc = " \"end\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] #[serde(deny_unknown_fields)] pub enum AnchorValueVariant0ItemVariant2 {} impl From<&AnchorValueVariant0ItemVariant2> for AnchorValueVariant0ItemVariant2 { fn from(value: &AnchorValueVariant0ItemVariant2) -> Self { value.clone() } } #[doc = "AnchorValueVariant1"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/stringModifiers\""] #[doc = " },"] #[doc = " {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"enum\": ["] #[doc = " \"start\","] #[doc = " \"middle\","] #[doc = " \"end\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AnchorValueVariant1 { Variant0(AnchorValueVariant1Variant0), Variant1(AnchorValueVariant1Variant1), Variant2(AnchorValueVariant1Variant2), Variant3 { offset: ::serde_json::Value }, } impl From<&AnchorValueVariant1> for AnchorValueVariant1 { fn from(value: &AnchorValueVariant1) -> Self { value.clone() } } impl From for AnchorValueVariant1 { fn from(value: AnchorValueVariant1Variant0) -> Self { Self::Variant0(value) } } impl From for AnchorValueVariant1 { fn from(value: AnchorValueVariant1Variant1) -> Self { Self::Variant1(value) } } impl From for AnchorValueVariant1 { fn from(value: AnchorValueVariant1Variant2) -> Self { Self::Variant2(value) } } #[doc = "AnchorValueVariant1Variant0"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"scale\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"enum\": ["] #[doc = " \"start\","] #[doc = " \"middle\","] #[doc = " \"end\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AnchorValueVariant1Variant0 { Variant0 { #[serde(default, skip_serializing_if = "Option::is_none")] scale: Option, signal: String, }, Variant1 { #[serde(default, skip_serializing_if = "Option::is_none")] scale: Option, value: AnchorValueVariant1Variant0Variant1Value, }, Variant2 { field: Field, #[serde(default, skip_serializing_if = "Option::is_none")] scale: Option, }, Variant3 { range: AnchorValueVariant1Variant0Variant3Range, #[serde(default, skip_serializing_if = "Option::is_none")] scale: Option, }, } impl From<&AnchorValueVariant1Variant0> for AnchorValueVariant1Variant0 { fn from(value: &AnchorValueVariant1Variant0) -> Self { value.clone() } } #[doc = "AnchorValueVariant1Variant0Variant1Value"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"enum\": ["] #[doc = " \"start\","] #[doc = " \"middle\","] #[doc = " \"end\""] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] pub enum AnchorValueVariant1Variant0Variant1Value { #[serde(rename = "start")] Start, #[serde(rename = "middle")] Middle, #[serde(rename = "end")] End, } impl From<&AnchorValueVariant1Variant0Variant1Value> for AnchorValueVariant1Variant0Variant1Value { fn from(value: &AnchorValueVariant1Variant0Variant1Value) -> Self { value.clone() } } impl ::std::fmt::Display for AnchorValueVariant1Variant0Variant1Value { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match *self { Self::Start => write!(f, "start"), Self::Middle => write!(f, "middle"), Self::End => write!(f, "end"), } } } impl std::str::FromStr for AnchorValueVariant1Variant0Variant1Value { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { match value { "start" => Ok(Self::Start), "middle" => Ok(Self::Middle), "end" => Ok(Self::End), _ => Err("invalid value".into()), } } } impl std::convert::TryFrom<&str> for AnchorValueVariant1Variant0Variant1Value { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for AnchorValueVariant1Variant0Variant1Value { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for AnchorValueVariant1Variant0Variant1Value { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } #[doc = "AnchorValueVariant1Variant0Variant3Range"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AnchorValueVariant1Variant0Variant3Range { Variant0(f64), Variant1(bool), } impl From<&AnchorValueVariant1Variant0Variant3Range> for AnchorValueVariant1Variant0Variant3Range { fn from(value: &AnchorValueVariant1Variant0Variant3Range) -> Self { value.clone() } } impl std::str::FromStr for AnchorValueVariant1Variant0Variant3Range { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { if let Ok(v) = value.parse() { Ok(Self::Variant0(v)) } else if let Ok(v) = value.parse() { Ok(Self::Variant1(v)) } else { Err("string conversion failed for all variants".into()) } } } impl std::convert::TryFrom<&str> for AnchorValueVariant1Variant0Variant3Range { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for AnchorValueVariant1Variant0Variant3Range { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for AnchorValueVariant1Variant0Variant3Range { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } impl ::std::fmt::Display for AnchorValueVariant1Variant0Variant3Range { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match self { Self::Variant0(x) => x.fmt(f), Self::Variant1(x) => x.fmt(f), } } } impl From for AnchorValueVariant1Variant0Variant3Range { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for AnchorValueVariant1Variant0Variant3Range { fn from(value: bool) -> Self { Self::Variant1(value) } } #[doc = "AnchorValueVariant1Variant1"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"scale\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"enum\": ["] #[doc = " \"start\","] #[doc = " \"middle\","] #[doc = " \"end\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] #[serde(deny_unknown_fields)] pub enum AnchorValueVariant1Variant1 {} impl From<&AnchorValueVariant1Variant1> for AnchorValueVariant1Variant1 { fn from(value: &AnchorValueVariant1Variant1) -> Self { value.clone() } } #[doc = "AnchorValueVariant1Variant2"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"scale\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"enum\": ["] #[doc = " \"start\","] #[doc = " \"middle\","] #[doc = " \"end\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] #[serde(deny_unknown_fields)] pub enum AnchorValueVariant1Variant2 {} impl From<&AnchorValueVariant1Variant2> for AnchorValueVariant1Variant2 { fn from(value: &AnchorValueVariant1Variant2) -> Self { value.clone() } } #[doc = "AnyValue"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/rule\""] #[doc = " },"] #[doc = " {"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/stringModifiers\""] #[doc = " },"] #[doc = " {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {}"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/stringModifiers\""] #[doc = " },"] #[doc = " {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {}"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AnyValue { Variant0(Vec), Variant1(AnyValueVariant1), } impl From<&AnyValue> for AnyValue { fn from(value: &AnyValue) -> Self { value.clone() } } impl From> for AnyValue { fn from(value: Vec) -> Self { Self::Variant0(value) } } impl From for AnyValue { fn from(value: AnyValueVariant1) -> Self { Self::Variant1(value) } } #[doc = "AnyValueVariant0Item"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/rule\""] #[doc = " },"] #[doc = " {"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/stringModifiers\""] #[doc = " },"] #[doc = " {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {}"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AnyValueVariant0Item { Variant0(AnyValueVariant0ItemVariant0), Variant1(AnyValueVariant0ItemVariant1), Variant2(AnyValueVariant0ItemVariant2), Variant3 { offset: ::serde_json::Value, #[serde(default, skip_serializing_if = "Option::is_none")] test: Option, }, } impl From<&AnyValueVariant0Item> for AnyValueVariant0Item { fn from(value: &AnyValueVariant0Item) -> Self { value.clone() } } impl From for AnyValueVariant0Item { fn from(value: AnyValueVariant0ItemVariant0) -> Self { Self::Variant0(value) } } impl From for AnyValueVariant0Item { fn from(value: AnyValueVariant0ItemVariant1) -> Self { Self::Variant1(value) } } impl From for AnyValueVariant0Item { fn from(value: AnyValueVariant0ItemVariant2) -> Self { Self::Variant2(value) } } #[doc = "AnyValueVariant0ItemVariant0"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"scale\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " },"] #[doc = " \"test\": {"] #[doc = " \"type\": \"string\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {}"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AnyValueVariant0ItemVariant0 { Variant0 { #[serde(default, skip_serializing_if = "Option::is_none")] scale: Option, signal: String, #[serde(default, skip_serializing_if = "Option::is_none")] test: Option, }, Variant1 { #[serde(default, skip_serializing_if = "Option::is_none")] scale: Option, #[serde(default, skip_serializing_if = "Option::is_none")] test: Option, value: ::serde_json::Value, }, Variant2 { field: Field, #[serde(default, skip_serializing_if = "Option::is_none")] scale: Option, #[serde(default, skip_serializing_if = "Option::is_none")] test: Option, }, Variant3 { range: AnyValueVariant0ItemVariant0Variant3Range, #[serde(default, skip_serializing_if = "Option::is_none")] scale: Option, #[serde(default, skip_serializing_if = "Option::is_none")] test: Option, }, } impl From<&AnyValueVariant0ItemVariant0> for AnyValueVariant0ItemVariant0 { fn from(value: &AnyValueVariant0ItemVariant0) -> Self { value.clone() } } #[doc = "AnyValueVariant0ItemVariant0Variant3Range"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AnyValueVariant0ItemVariant0Variant3Range { Variant0(f64), Variant1(bool), } impl From<&AnyValueVariant0ItemVariant0Variant3Range> for AnyValueVariant0ItemVariant0Variant3Range { fn from(value: &AnyValueVariant0ItemVariant0Variant3Range) -> Self { value.clone() } } impl std::str::FromStr for AnyValueVariant0ItemVariant0Variant3Range { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { if let Ok(v) = value.parse() { Ok(Self::Variant0(v)) } else if let Ok(v) = value.parse() { Ok(Self::Variant1(v)) } else { Err("string conversion failed for all variants".into()) } } } impl std::convert::TryFrom<&str> for AnyValueVariant0ItemVariant0Variant3Range { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for AnyValueVariant0ItemVariant0Variant3Range { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for AnyValueVariant0ItemVariant0Variant3Range { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } impl ::std::fmt::Display for AnyValueVariant0ItemVariant0Variant3Range { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match self { Self::Variant0(x) => x.fmt(f), Self::Variant1(x) => x.fmt(f), } } } impl From for AnyValueVariant0ItemVariant0Variant3Range { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for AnyValueVariant0ItemVariant0Variant3Range { fn from(value: bool) -> Self { Self::Variant1(value) } } #[doc = "AnyValueVariant0ItemVariant1"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"scale\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " },"] #[doc = " \"test\": {"] #[doc = " \"type\": \"string\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {}"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] #[serde(deny_unknown_fields)] pub enum AnyValueVariant0ItemVariant1 {} impl From<&AnyValueVariant0ItemVariant1> for AnyValueVariant0ItemVariant1 { fn from(value: &AnyValueVariant0ItemVariant1) -> Self { value.clone() } } #[doc = "AnyValueVariant0ItemVariant2"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"scale\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " },"] #[doc = " \"test\": {"] #[doc = " \"type\": \"string\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {}"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] #[serde(deny_unknown_fields)] pub enum AnyValueVariant0ItemVariant2 {} impl From<&AnyValueVariant0ItemVariant2> for AnyValueVariant0ItemVariant2 { fn from(value: &AnyValueVariant0ItemVariant2) -> Self { value.clone() } } #[doc = "AnyValueVariant1"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/stringModifiers\""] #[doc = " },"] #[doc = " {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {}"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AnyValueVariant1 { Variant0(AnyValueVariant1Variant0), Variant1(AnyValueVariant1Variant1), Variant2(AnyValueVariant1Variant2), Variant3 { offset: ::serde_json::Value }, } impl From<&AnyValueVariant1> for AnyValueVariant1 { fn from(value: &AnyValueVariant1) -> Self { value.clone() } } impl From for AnyValueVariant1 { fn from(value: AnyValueVariant1Variant0) -> Self { Self::Variant0(value) } } impl From for AnyValueVariant1 { fn from(value: AnyValueVariant1Variant1) -> Self { Self::Variant1(value) } } impl From for AnyValueVariant1 { fn from(value: AnyValueVariant1Variant2) -> Self { Self::Variant2(value) } } #[doc = "AnyValueVariant1Variant0"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"scale\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {}"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AnyValueVariant1Variant0 { Variant0 { #[serde(default, skip_serializing_if = "Option::is_none")] scale: Option, signal: String, }, Variant1 { #[serde(default, skip_serializing_if = "Option::is_none")] scale: Option, value: ::serde_json::Value, }, Variant2 { field: Field, #[serde(default, skip_serializing_if = "Option::is_none")] scale: Option, }, Variant3 { range: AnyValueVariant1Variant0Variant3Range, #[serde(default, skip_serializing_if = "Option::is_none")] scale: Option, }, } impl From<&AnyValueVariant1Variant0> for AnyValueVariant1Variant0 { fn from(value: &AnyValueVariant1Variant0) -> Self { value.clone() } } #[doc = "AnyValueVariant1Variant0Variant3Range"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AnyValueVariant1Variant0Variant3Range { Variant0(f64), Variant1(bool), } impl From<&AnyValueVariant1Variant0Variant3Range> for AnyValueVariant1Variant0Variant3Range { fn from(value: &AnyValueVariant1Variant0Variant3Range) -> Self { value.clone() } } impl std::str::FromStr for AnyValueVariant1Variant0Variant3Range { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { if let Ok(v) = value.parse() { Ok(Self::Variant0(v)) } else if let Ok(v) = value.parse() { Ok(Self::Variant1(v)) } else { Err("string conversion failed for all variants".into()) } } } impl std::convert::TryFrom<&str> for AnyValueVariant1Variant0Variant3Range { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for AnyValueVariant1Variant0Variant3Range { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for AnyValueVariant1Variant0Variant3Range { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } impl ::std::fmt::Display for AnyValueVariant1Variant0Variant3Range { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match self { Self::Variant0(x) => x.fmt(f), Self::Variant1(x) => x.fmt(f), } } } impl From for AnyValueVariant1Variant0Variant3Range { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for AnyValueVariant1Variant0Variant3Range { fn from(value: bool) -> Self { Self::Variant1(value) } } #[doc = "AnyValueVariant1Variant1"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"scale\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {}"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] #[serde(deny_unknown_fields)] pub enum AnyValueVariant1Variant1 {} impl From<&AnyValueVariant1Variant1> for AnyValueVariant1Variant1 { fn from(value: &AnyValueVariant1Variant1) -> Self { value.clone() } } #[doc = "AnyValueVariant1Variant2"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"scale\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {}"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] #[serde(deny_unknown_fields)] pub enum AnyValueVariant1Variant2 {} impl From<&AnyValueVariant1Variant2> for AnyValueVariant1Variant2 { fn from(value: &AnyValueVariant1Variant2) -> Self { value.clone() } } #[doc = "ArrayOrSignal"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"array\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum ArrayOrSignal { Variant0(Vec<::serde_json::Value>), Variant1(SignalRef), } impl From<&ArrayOrSignal> for ArrayOrSignal { fn from(value: &ArrayOrSignal) -> Self { value.clone() } } impl From> for ArrayOrSignal { fn from(value: Vec<::serde_json::Value>) -> Self { Self::Variant0(value) } } impl From for ArrayOrSignal { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "ArrayValue"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/rule\""] #[doc = " },"] #[doc = " {"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/stringModifiers\""] #[doc = " },"] #[doc = " {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"type\": \"array\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/stringModifiers\""] #[doc = " },"] #[doc = " {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"type\": \"array\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum ArrayValue { Variant0(Vec), Variant1(ArrayValueVariant1), } impl From<&ArrayValue> for ArrayValue { fn from(value: &ArrayValue) -> Self { value.clone() } } impl From> for ArrayValue { fn from(value: Vec) -> Self { Self::Variant0(value) } } impl From for ArrayValue { fn from(value: ArrayValueVariant1) -> Self { Self::Variant1(value) } } #[doc = "ArrayValueVariant0Item"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/rule\""] #[doc = " },"] #[doc = " {"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/stringModifiers\""] #[doc = " },"] #[doc = " {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"type\": \"array\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum ArrayValueVariant0Item { Variant0(ArrayValueVariant0ItemVariant0), Variant1(ArrayValueVariant0ItemVariant1), Variant2(ArrayValueVariant0ItemVariant2), Variant3 { offset: ::serde_json::Value, #[serde(default, skip_serializing_if = "Option::is_none")] test: Option, }, } impl From<&ArrayValueVariant0Item> for ArrayValueVariant0Item { fn from(value: &ArrayValueVariant0Item) -> Self { value.clone() } } impl From for ArrayValueVariant0Item { fn from(value: ArrayValueVariant0ItemVariant0) -> Self { Self::Variant0(value) } } impl From for ArrayValueVariant0Item { fn from(value: ArrayValueVariant0ItemVariant1) -> Self { Self::Variant1(value) } } impl From for ArrayValueVariant0Item { fn from(value: ArrayValueVariant0ItemVariant2) -> Self { Self::Variant2(value) } } #[doc = "ArrayValueVariant0ItemVariant0"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"scale\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " },"] #[doc = " \"test\": {"] #[doc = " \"type\": \"string\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"type\": \"array\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum ArrayValueVariant0ItemVariant0 { Variant0 { #[serde(default, skip_serializing_if = "Option::is_none")] scale: Option, signal: String, #[serde(default, skip_serializing_if = "Option::is_none")] test: Option, }, Variant1 { #[serde(default, skip_serializing_if = "Option::is_none")] scale: Option, #[serde(default, skip_serializing_if = "Option::is_none")] test: Option, value: Vec<::serde_json::Value>, }, Variant2 { field: Field, #[serde(default, skip_serializing_if = "Option::is_none")] scale: Option, #[serde(default, skip_serializing_if = "Option::is_none")] test: Option, }, Variant3 { range: ArrayValueVariant0ItemVariant0Variant3Range, #[serde(default, skip_serializing_if = "Option::is_none")] scale: Option, #[serde(default, skip_serializing_if = "Option::is_none")] test: Option, }, } impl From<&ArrayValueVariant0ItemVariant0> for ArrayValueVariant0ItemVariant0 { fn from(value: &ArrayValueVariant0ItemVariant0) -> Self { value.clone() } } #[doc = "ArrayValueVariant0ItemVariant0Variant3Range"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum ArrayValueVariant0ItemVariant0Variant3Range { Variant0(f64), Variant1(bool), } impl From<&ArrayValueVariant0ItemVariant0Variant3Range> for ArrayValueVariant0ItemVariant0Variant3Range { fn from(value: &ArrayValueVariant0ItemVariant0Variant3Range) -> Self { value.clone() } } impl std::str::FromStr for ArrayValueVariant0ItemVariant0Variant3Range { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { if let Ok(v) = value.parse() { Ok(Self::Variant0(v)) } else if let Ok(v) = value.parse() { Ok(Self::Variant1(v)) } else { Err("string conversion failed for all variants".into()) } } } impl std::convert::TryFrom<&str> for ArrayValueVariant0ItemVariant0Variant3Range { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for ArrayValueVariant0ItemVariant0Variant3Range { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for ArrayValueVariant0ItemVariant0Variant3Range { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } impl ::std::fmt::Display for ArrayValueVariant0ItemVariant0Variant3Range { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match self { Self::Variant0(x) => x.fmt(f), Self::Variant1(x) => x.fmt(f), } } } impl From for ArrayValueVariant0ItemVariant0Variant3Range { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for ArrayValueVariant0ItemVariant0Variant3Range { fn from(value: bool) -> Self { Self::Variant1(value) } } #[doc = "ArrayValueVariant0ItemVariant1"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"scale\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " },"] #[doc = " \"test\": {"] #[doc = " \"type\": \"string\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"type\": \"array\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] #[serde(deny_unknown_fields)] pub enum ArrayValueVariant0ItemVariant1 {} impl From<&ArrayValueVariant0ItemVariant1> for ArrayValueVariant0ItemVariant1 { fn from(value: &ArrayValueVariant0ItemVariant1) -> Self { value.clone() } } #[doc = "ArrayValueVariant0ItemVariant2"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"scale\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " },"] #[doc = " \"test\": {"] #[doc = " \"type\": \"string\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"type\": \"array\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] #[serde(deny_unknown_fields)] pub enum ArrayValueVariant0ItemVariant2 {} impl From<&ArrayValueVariant0ItemVariant2> for ArrayValueVariant0ItemVariant2 { fn from(value: &ArrayValueVariant0ItemVariant2) -> Self { value.clone() } } #[doc = "ArrayValueVariant1"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/stringModifiers\""] #[doc = " },"] #[doc = " {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"type\": \"array\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum ArrayValueVariant1 { Variant0(ArrayValueVariant1Variant0), Variant1(ArrayValueVariant1Variant1), Variant2(ArrayValueVariant1Variant2), Variant3 { offset: ::serde_json::Value }, } impl From<&ArrayValueVariant1> for ArrayValueVariant1 { fn from(value: &ArrayValueVariant1) -> Self { value.clone() } } impl From for ArrayValueVariant1 { fn from(value: ArrayValueVariant1Variant0) -> Self { Self::Variant0(value) } } impl From for ArrayValueVariant1 { fn from(value: ArrayValueVariant1Variant1) -> Self { Self::Variant1(value) } } impl From for ArrayValueVariant1 { fn from(value: ArrayValueVariant1Variant2) -> Self { Self::Variant2(value) } } #[doc = "ArrayValueVariant1Variant0"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"scale\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"type\": \"array\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum ArrayValueVariant1Variant0 { Variant0 { #[serde(default, skip_serializing_if = "Option::is_none")] scale: Option, signal: String, }, Variant1 { #[serde(default, skip_serializing_if = "Option::is_none")] scale: Option, value: Vec<::serde_json::Value>, }, Variant2 { field: Field, #[serde(default, skip_serializing_if = "Option::is_none")] scale: Option, }, Variant3 { range: ArrayValueVariant1Variant0Variant3Range, #[serde(default, skip_serializing_if = "Option::is_none")] scale: Option, }, } impl From<&ArrayValueVariant1Variant0> for ArrayValueVariant1Variant0 { fn from(value: &ArrayValueVariant1Variant0) -> Self { value.clone() } } #[doc = "ArrayValueVariant1Variant0Variant3Range"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum ArrayValueVariant1Variant0Variant3Range { Variant0(f64), Variant1(bool), } impl From<&ArrayValueVariant1Variant0Variant3Range> for ArrayValueVariant1Variant0Variant3Range { fn from(value: &ArrayValueVariant1Variant0Variant3Range) -> Self { value.clone() } } impl std::str::FromStr for ArrayValueVariant1Variant0Variant3Range { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { if let Ok(v) = value.parse() { Ok(Self::Variant0(v)) } else if let Ok(v) = value.parse() { Ok(Self::Variant1(v)) } else { Err("string conversion failed for all variants".into()) } } } impl std::convert::TryFrom<&str> for ArrayValueVariant1Variant0Variant3Range { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for ArrayValueVariant1Variant0Variant3Range { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for ArrayValueVariant1Variant0Variant3Range { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } impl ::std::fmt::Display for ArrayValueVariant1Variant0Variant3Range { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match self { Self::Variant0(x) => x.fmt(f), Self::Variant1(x) => x.fmt(f), } } } impl From for ArrayValueVariant1Variant0Variant3Range { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for ArrayValueVariant1Variant0Variant3Range { fn from(value: bool) -> Self { Self::Variant1(value) } } #[doc = "ArrayValueVariant1Variant1"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"scale\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"type\": \"array\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] #[serde(deny_unknown_fields)] pub enum ArrayValueVariant1Variant1 {} impl From<&ArrayValueVariant1Variant1> for ArrayValueVariant1Variant1 { fn from(value: &ArrayValueVariant1Variant1) -> Self { value.clone() } } #[doc = "ArrayValueVariant1Variant2"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"scale\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"type\": \"array\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] #[serde(deny_unknown_fields)] pub enum ArrayValueVariant1Variant2 {} impl From<&ArrayValueVariant1Variant2> for ArrayValueVariant1Variant2 { fn from(value: &ArrayValueVariant1Variant2) -> Self { value.clone() } } #[doc = "Autosize"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"default\": \"pad\","] #[doc = " \"enum\": ["] #[doc = " \"pad\","] #[doc = " \"fit\","] #[doc = " \"fit-x\","] #[doc = " \"fit-y\","] #[doc = " \"none\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"type\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"contains\": {"] #[doc = " \"enum\": ["] #[doc = " \"content\","] #[doc = " \"padding\""] #[doc = " ]"] #[doc = " },"] #[doc = " \"resize\": {"] #[doc = " \"type\": \"boolean\""] #[doc = " },"] #[doc = " \"type\": {"] #[doc = " \"default\": \"pad\","] #[doc = " \"enum\": ["] #[doc = " \"pad\","] #[doc = " \"fit\","] #[doc = " \"fit-x\","] #[doc = " \"fit-y\","] #[doc = " \"none\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged, deny_unknown_fields)] pub enum Autosize { Variant0(AutosizeVariant0), Variant1 { #[serde(default, skip_serializing_if = "Option::is_none")] contains: Option, #[serde(default, skip_serializing_if = "Option::is_none")] resize: Option, #[serde(rename = "type")] type_: AutosizeVariant1Type, }, Variant2(SignalRef), } impl From<&Autosize> for Autosize { fn from(value: &Autosize) -> Self { value.clone() } } impl From for Autosize { fn from(value: AutosizeVariant0) -> Self { Self::Variant0(value) } } impl From for Autosize { fn from(value: SignalRef) -> Self { Self::Variant2(value) } } #[doc = "AutosizeVariant0"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"default\": \"pad\","] #[doc = " \"enum\": ["] #[doc = " \"pad\","] #[doc = " \"fit\","] #[doc = " \"fit-x\","] #[doc = " \"fit-y\","] #[doc = " \"none\""] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] pub enum AutosizeVariant0 { #[serde(rename = "pad")] Pad, #[serde(rename = "fit")] Fit, #[serde(rename = "fit-x")] FitX, #[serde(rename = "fit-y")] FitY, #[serde(rename = "none")] None, } impl From<&AutosizeVariant0> for AutosizeVariant0 { fn from(value: &AutosizeVariant0) -> Self { value.clone() } } impl ::std::fmt::Display for AutosizeVariant0 { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match *self { Self::Pad => write!(f, "pad"), Self::Fit => write!(f, "fit"), Self::FitX => write!(f, "fit-x"), Self::FitY => write!(f, "fit-y"), Self::None => write!(f, "none"), } } } impl std::str::FromStr for AutosizeVariant0 { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { match value { "pad" => Ok(Self::Pad), "fit" => Ok(Self::Fit), "fit-x" => Ok(Self::FitX), "fit-y" => Ok(Self::FitY), "none" => Ok(Self::None), _ => Err("invalid value".into()), } } } impl std::convert::TryFrom<&str> for AutosizeVariant0 { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for AutosizeVariant0 { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for AutosizeVariant0 { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } #[doc = "AutosizeVariant1Contains"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"enum\": ["] #[doc = " \"content\","] #[doc = " \"padding\""] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] pub enum AutosizeVariant1Contains { #[serde(rename = "content")] Content, #[serde(rename = "padding")] Padding, } impl From<&AutosizeVariant1Contains> for AutosizeVariant1Contains { fn from(value: &AutosizeVariant1Contains) -> Self { value.clone() } } impl ::std::fmt::Display for AutosizeVariant1Contains { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match *self { Self::Content => write!(f, "content"), Self::Padding => write!(f, "padding"), } } } impl std::str::FromStr for AutosizeVariant1Contains { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { match value { "content" => Ok(Self::Content), "padding" => Ok(Self::Padding), _ => Err("invalid value".into()), } } } impl std::convert::TryFrom<&str> for AutosizeVariant1Contains { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for AutosizeVariant1Contains { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for AutosizeVariant1Contains { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } #[doc = "AutosizeVariant1Type"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"default\": \"pad\","] #[doc = " \"enum\": ["] #[doc = " \"pad\","] #[doc = " \"fit\","] #[doc = " \"fit-x\","] #[doc = " \"fit-y\","] #[doc = " \"none\""] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] pub enum AutosizeVariant1Type { #[serde(rename = "pad")] Pad, #[serde(rename = "fit")] Fit, #[serde(rename = "fit-x")] FitX, #[serde(rename = "fit-y")] FitY, #[serde(rename = "none")] None, } impl From<&AutosizeVariant1Type> for AutosizeVariant1Type { fn from(value: &AutosizeVariant1Type) -> Self { value.clone() } } impl ::std::fmt::Display for AutosizeVariant1Type { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match *self { Self::Pad => write!(f, "pad"), Self::Fit => write!(f, "fit"), Self::FitX => write!(f, "fit-x"), Self::FitY => write!(f, "fit-y"), Self::None => write!(f, "none"), } } } impl std::str::FromStr for AutosizeVariant1Type { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { match value { "pad" => Ok(Self::Pad), "fit" => Ok(Self::Fit), "fit-x" => Ok(Self::FitX), "fit-y" => Ok(Self::FitY), "none" => Ok(Self::None), _ => Err("invalid value".into()), } } } impl std::convert::TryFrom<&str> for AutosizeVariant1Type { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for AutosizeVariant1Type { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for AutosizeVariant1Type { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } impl Default for AutosizeVariant1Type { fn default() -> Self { AutosizeVariant1Type::Pad } } #[doc = "Axis"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"orient\","] #[doc = " \"scale\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"aria\": {"] #[doc = " \"type\": \"boolean\""] #[doc = " },"] #[doc = " \"bandPosition\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"description\": {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " \"domain\": {"] #[doc = " \"type\": \"boolean\""] #[doc = " },"] #[doc = " \"domainCap\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/stringValue\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"domainColor\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"null\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/colorValue\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"domainDash\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"type\": \"number\""] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/arrayValue\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"domainDashOffset\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"domainOpacity\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"domainWidth\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"encode\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"axis\": {"] #[doc = " \"$ref\": \"#/definitions/guideEncode\""] #[doc = " },"] #[doc = " \"domain\": {"] #[doc = " \"$ref\": \"#/definitions/guideEncode\""] #[doc = " },"] #[doc = " \"grid\": {"] #[doc = " \"$ref\": \"#/definitions/guideEncode\""] #[doc = " },"] #[doc = " \"labels\": {"] #[doc = " \"$ref\": \"#/definitions/guideEncode\""] #[doc = " },"] #[doc = " \"ticks\": {"] #[doc = " \"$ref\": \"#/definitions/guideEncode\""] #[doc = " },"] #[doc = " \"title\": {"] #[doc = " \"$ref\": \"#/definitions/guideEncode\""] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = " },"] #[doc = " \"format\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"date\": {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " \"day\": {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " \"hours\": {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " \"milliseconds\": {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " \"minutes\": {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " \"month\": {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " \"quarter\": {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " \"seconds\": {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " \"week\": {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " \"year\": {"] #[doc = " \"type\": \"string\""] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"formatType\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"number\","] #[doc = " \"time\","] #[doc = " \"utc\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"grid\": {"] #[doc = " \"type\": \"boolean\""] #[doc = " },"] #[doc = " \"gridCap\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/stringValue\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"gridColor\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"null\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/colorValue\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"gridDash\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"type\": \"number\""] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/arrayValue\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"gridDashOffset\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"gridOpacity\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"gridScale\": {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " \"gridWidth\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"labelAlign\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"left\","] #[doc = " \"right\","] #[doc = " \"center\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/alignValue\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"labelAngle\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"labelBaseline\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"top\","] #[doc = " \"middle\","] #[doc = " \"bottom\","] #[doc = " \"alphabetic\","] #[doc = " \"line-top\","] #[doc = " \"line-bottom\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/baselineValue\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"labelBound\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"labelColor\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"null\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/colorValue\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"labelFlush\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"labelFlushOffset\": {"] #[doc = " \"$ref\": \"#/definitions/numberOrSignal\""] #[doc = " },"] #[doc = " \"labelFont\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/stringValue\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"labelFontSize\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"labelFontStyle\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/stringValue\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"labelFontWeight\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " null,"] #[doc = " \"normal\","] #[doc = " \"bold\","] #[doc = " \"lighter\","] #[doc = " \"bolder\","] #[doc = " \"100\","] #[doc = " \"200\","] #[doc = " \"300\","] #[doc = " \"400\","] #[doc = " \"500\","] #[doc = " \"600\","] #[doc = " \"700\","] #[doc = " \"800\","] #[doc = " \"900\","] #[doc = " 100,"] #[doc = " 200,"] #[doc = " 300,"] #[doc = " 400,"] #[doc = " 500,"] #[doc = " 600,"] #[doc = " 700,"] #[doc = " 800,"] #[doc = " 900"] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/fontWeightValue\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"labelLimit\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"labelLineHeight\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"labelOffset\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"labelOpacity\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"labelOverlap\": {"] #[doc = " \"$ref\": \"#/definitions/labelOverlap\""] #[doc = " },"] #[doc = " \"labelPadding\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"labelSeparation\": {"] #[doc = " \"$ref\": \"#/definitions/numberOrSignal\""] #[doc = " },"] #[doc = " \"labels\": {"] #[doc = " \"type\": \"boolean\""] #[doc = " },"] #[doc = " \"maxExtent\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"minExtent\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"offset\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"orient\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"top\","] #[doc = " \"bottom\","] #[doc = " \"left\","] #[doc = " \"right\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"position\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"scale\": {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " \"tickBand\": {"] #[doc = " \"$ref\": \"#/definitions/tickBand\""] #[doc = " },"] #[doc = " \"tickCap\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/stringValue\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"tickColor\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"null\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/colorValue\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"tickCount\": {"] #[doc = " \"$ref\": \"#/definitions/tickCount\""] #[doc = " },"] #[doc = " \"tickDash\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"type\": \"number\""] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/arrayValue\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"tickDashOffset\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"tickExtra\": {"] #[doc = " \"$ref\": \"#/definitions/booleanOrSignal\""] #[doc = " },"] #[doc = " \"tickMinStep\": {"] #[doc = " \"$ref\": \"#/definitions/numberOrSignal\""] #[doc = " },"] #[doc = " \"tickOffset\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"tickOpacity\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"tickRound\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/booleanValue\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"tickSize\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"tickWidth\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"ticks\": {"] #[doc = " \"type\": \"boolean\""] #[doc = " },"] #[doc = " \"title\": {"] #[doc = " \"$ref\": \"#/definitions/textOrSignal\""] #[doc = " },"] #[doc = " \"titleAlign\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"left\","] #[doc = " \"right\","] #[doc = " \"center\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/alignValue\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"titleAnchor\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " null,"] #[doc = " \"start\","] #[doc = " \"middle\","] #[doc = " \"end\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/anchorValue\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"titleAngle\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"titleBaseline\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"top\","] #[doc = " \"middle\","] #[doc = " \"bottom\","] #[doc = " \"alphabetic\","] #[doc = " \"line-top\","] #[doc = " \"line-bottom\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/baselineValue\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"titleColor\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"null\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/colorValue\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"titleFont\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/stringValue\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"titleFontSize\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"titleFontStyle\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/stringValue\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"titleFontWeight\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " null,"] #[doc = " \"normal\","] #[doc = " \"bold\","] #[doc = " \"lighter\","] #[doc = " \"bolder\","] #[doc = " \"100\","] #[doc = " \"200\","] #[doc = " \"300\","] #[doc = " \"400\","] #[doc = " \"500\","] #[doc = " \"600\","] #[doc = " \"700\","] #[doc = " \"800\","] #[doc = " \"900\","] #[doc = " 100,"] #[doc = " 200,"] #[doc = " 300,"] #[doc = " 400,"] #[doc = " 500,"] #[doc = " 600,"] #[doc = " 700,"] #[doc = " 800,"] #[doc = " 900"] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/fontWeightValue\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"titleLimit\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"titleLineHeight\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"titleOpacity\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"titlePadding\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"titleX\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"titleY\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"translate\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"values\": {"] #[doc = " \"$ref\": \"#/definitions/arrayOrSignal\""] #[doc = " },"] #[doc = " \"zindex\": {"] #[doc = " \"type\": \"number\""] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(deny_unknown_fields)] pub struct Axis { #[serde(default, skip_serializing_if = "Option::is_none")] pub aria: Option, #[serde( rename = "bandPosition", default, skip_serializing_if = "Option::is_none" )] pub band_position: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub description: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub domain: Option, #[serde(rename = "domainCap", default, skip_serializing_if = "Option::is_none")] pub domain_cap: Option, #[serde( rename = "domainColor", default, skip_serializing_if = "Option::is_none" )] pub domain_color: Option, #[serde( rename = "domainDash", default, skip_serializing_if = "Option::is_none" )] pub domain_dash: Option, #[serde( rename = "domainDashOffset", default, skip_serializing_if = "Option::is_none" )] pub domain_dash_offset: Option, #[serde( rename = "domainOpacity", default, skip_serializing_if = "Option::is_none" )] pub domain_opacity: Option, #[serde( rename = "domainWidth", default, skip_serializing_if = "Option::is_none" )] pub domain_width: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub encode: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub format: Option, #[serde( rename = "formatType", default, skip_serializing_if = "Option::is_none" )] pub format_type: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub grid: Option, #[serde(rename = "gridCap", default, skip_serializing_if = "Option::is_none")] pub grid_cap: Option, #[serde(rename = "gridColor", default, skip_serializing_if = "Option::is_none")] pub grid_color: Option, #[serde(rename = "gridDash", default, skip_serializing_if = "Option::is_none")] pub grid_dash: Option, #[serde( rename = "gridDashOffset", default, skip_serializing_if = "Option::is_none" )] pub grid_dash_offset: Option, #[serde( rename = "gridOpacity", default, skip_serializing_if = "Option::is_none" )] pub grid_opacity: Option, #[serde(rename = "gridScale", default, skip_serializing_if = "Option::is_none")] pub grid_scale: Option, #[serde(rename = "gridWidth", default, skip_serializing_if = "Option::is_none")] pub grid_width: Option, #[serde( rename = "labelAlign", default, skip_serializing_if = "Option::is_none" )] pub label_align: Option, #[serde( rename = "labelAngle", default, skip_serializing_if = "Option::is_none" )] pub label_angle: Option, #[serde( rename = "labelBaseline", default, skip_serializing_if = "Option::is_none" )] pub label_baseline: Option, #[serde( rename = "labelBound", default, skip_serializing_if = "Option::is_none" )] pub label_bound: Option, #[serde( rename = "labelColor", default, skip_serializing_if = "Option::is_none" )] pub label_color: Option, #[serde( rename = "labelFlush", default, skip_serializing_if = "Option::is_none" )] pub label_flush: Option, #[serde( rename = "labelFlushOffset", default, skip_serializing_if = "Option::is_none" )] pub label_flush_offset: Option, #[serde(rename = "labelFont", default, skip_serializing_if = "Option::is_none")] pub label_font: Option, #[serde( rename = "labelFontSize", default, skip_serializing_if = "Option::is_none" )] pub label_font_size: Option, #[serde( rename = "labelFontStyle", default, skip_serializing_if = "Option::is_none" )] pub label_font_style: Option, #[serde( rename = "labelFontWeight", default, skip_serializing_if = "Option::is_none" )] pub label_font_weight: Option, #[serde( rename = "labelLimit", default, skip_serializing_if = "Option::is_none" )] pub label_limit: Option, #[serde( rename = "labelLineHeight", default, skip_serializing_if = "Option::is_none" )] pub label_line_height: Option, #[serde( rename = "labelOffset", default, skip_serializing_if = "Option::is_none" )] pub label_offset: Option, #[serde( rename = "labelOpacity", default, skip_serializing_if = "Option::is_none" )] pub label_opacity: Option, #[serde( rename = "labelOverlap", default, skip_serializing_if = "Option::is_none" )] pub label_overlap: Option, #[serde( rename = "labelPadding", default, skip_serializing_if = "Option::is_none" )] pub label_padding: Option, #[serde( rename = "labelSeparation", default, skip_serializing_if = "Option::is_none" )] pub label_separation: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub labels: Option, #[serde(rename = "maxExtent", default, skip_serializing_if = "Option::is_none")] pub max_extent: Option, #[serde(rename = "minExtent", default, skip_serializing_if = "Option::is_none")] pub min_extent: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub offset: Option, pub orient: AxisOrient, #[serde(default, skip_serializing_if = "Option::is_none")] pub position: Option, pub scale: String, #[serde(rename = "tickBand", default, skip_serializing_if = "Option::is_none")] pub tick_band: Option, #[serde(rename = "tickCap", default, skip_serializing_if = "Option::is_none")] pub tick_cap: Option, #[serde(rename = "tickColor", default, skip_serializing_if = "Option::is_none")] pub tick_color: Option, #[serde(rename = "tickCount", default, skip_serializing_if = "Option::is_none")] pub tick_count: Option, #[serde(rename = "tickDash", default, skip_serializing_if = "Option::is_none")] pub tick_dash: Option, #[serde( rename = "tickDashOffset", default, skip_serializing_if = "Option::is_none" )] pub tick_dash_offset: Option, #[serde(rename = "tickExtra", default, skip_serializing_if = "Option::is_none")] pub tick_extra: Option, #[serde( rename = "tickMinStep", default, skip_serializing_if = "Option::is_none" )] pub tick_min_step: Option, #[serde( rename = "tickOffset", default, skip_serializing_if = "Option::is_none" )] pub tick_offset: Option, #[serde( rename = "tickOpacity", default, skip_serializing_if = "Option::is_none" )] pub tick_opacity: Option, #[serde(rename = "tickRound", default, skip_serializing_if = "Option::is_none")] pub tick_round: Option, #[serde(rename = "tickSize", default, skip_serializing_if = "Option::is_none")] pub tick_size: Option, #[serde(rename = "tickWidth", default, skip_serializing_if = "Option::is_none")] pub tick_width: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub ticks: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub title: Option, #[serde( rename = "titleAlign", default, skip_serializing_if = "Option::is_none" )] pub title_align: Option, #[serde( rename = "titleAnchor", default, skip_serializing_if = "Option::is_none" )] pub title_anchor: Option, #[serde( rename = "titleAngle", default, skip_serializing_if = "Option::is_none" )] pub title_angle: Option, #[serde( rename = "titleBaseline", default, skip_serializing_if = "Option::is_none" )] pub title_baseline: Option, #[serde( rename = "titleColor", default, skip_serializing_if = "Option::is_none" )] pub title_color: Option, #[serde(rename = "titleFont", default, skip_serializing_if = "Option::is_none")] pub title_font: Option, #[serde( rename = "titleFontSize", default, skip_serializing_if = "Option::is_none" )] pub title_font_size: Option, #[serde( rename = "titleFontStyle", default, skip_serializing_if = "Option::is_none" )] pub title_font_style: Option, #[serde( rename = "titleFontWeight", default, skip_serializing_if = "Option::is_none" )] pub title_font_weight: Option, #[serde( rename = "titleLimit", default, skip_serializing_if = "Option::is_none" )] pub title_limit: Option, #[serde( rename = "titleLineHeight", default, skip_serializing_if = "Option::is_none" )] pub title_line_height: Option, #[serde( rename = "titleOpacity", default, skip_serializing_if = "Option::is_none" )] pub title_opacity: Option, #[serde( rename = "titlePadding", default, skip_serializing_if = "Option::is_none" )] pub title_padding: Option, #[serde(rename = "titleX", default, skip_serializing_if = "Option::is_none")] pub title_x: Option, #[serde(rename = "titleY", default, skip_serializing_if = "Option::is_none")] pub title_y: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub translate: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub values: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub zindex: Option, } impl From<&Axis> for Axis { fn from(value: &Axis) -> Self { value.clone() } } #[doc = "AxisBandPosition"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AxisBandPosition { Variant0(f64), Variant1(NumberValue), } impl From<&AxisBandPosition> for AxisBandPosition { fn from(value: &AxisBandPosition) -> Self { value.clone() } } impl From for AxisBandPosition { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for AxisBandPosition { fn from(value: NumberValue) -> Self { Self::Variant1(value) } } #[doc = "AxisDomainCap"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/stringValue\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AxisDomainCap { Variant0(String), Variant1(StringValue), } impl From<&AxisDomainCap> for AxisDomainCap { fn from(value: &AxisDomainCap) -> Self { value.clone() } } impl From for AxisDomainCap { fn from(value: StringValue) -> Self { Self::Variant1(value) } } #[doc = "AxisDomainColor"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"null\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/colorValue\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AxisDomainColor { Variant0, Variant1(String), Variant2(ColorValue), } impl From<&AxisDomainColor> for AxisDomainColor { fn from(value: &AxisDomainColor) -> Self { value.clone() } } impl From for AxisDomainColor { fn from(value: ColorValue) -> Self { Self::Variant2(value) } } #[doc = "AxisDomainDash"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"type\": \"number\""] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/arrayValue\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AxisDomainDash { Variant0(Vec), Variant1(ArrayValue), } impl From<&AxisDomainDash> for AxisDomainDash { fn from(value: &AxisDomainDash) -> Self { value.clone() } } impl From> for AxisDomainDash { fn from(value: Vec) -> Self { Self::Variant0(value) } } impl From for AxisDomainDash { fn from(value: ArrayValue) -> Self { Self::Variant1(value) } } #[doc = "AxisDomainDashOffset"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AxisDomainDashOffset { Variant0(f64), Variant1(NumberValue), } impl From<&AxisDomainDashOffset> for AxisDomainDashOffset { fn from(value: &AxisDomainDashOffset) -> Self { value.clone() } } impl From for AxisDomainDashOffset { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for AxisDomainDashOffset { fn from(value: NumberValue) -> Self { Self::Variant1(value) } } #[doc = "AxisDomainOpacity"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AxisDomainOpacity { Variant0(f64), Variant1(NumberValue), } impl From<&AxisDomainOpacity> for AxisDomainOpacity { fn from(value: &AxisDomainOpacity) -> Self { value.clone() } } impl From for AxisDomainOpacity { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for AxisDomainOpacity { fn from(value: NumberValue) -> Self { Self::Variant1(value) } } #[doc = "AxisDomainWidth"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AxisDomainWidth { Variant0(f64), Variant1(NumberValue), } impl From<&AxisDomainWidth> for AxisDomainWidth { fn from(value: &AxisDomainWidth) -> Self { value.clone() } } impl From for AxisDomainWidth { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for AxisDomainWidth { fn from(value: NumberValue) -> Self { Self::Variant1(value) } } #[doc = "AxisEncode"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"axis\": {"] #[doc = " \"$ref\": \"#/definitions/guideEncode\""] #[doc = " },"] #[doc = " \"domain\": {"] #[doc = " \"$ref\": \"#/definitions/guideEncode\""] #[doc = " },"] #[doc = " \"grid\": {"] #[doc = " \"$ref\": \"#/definitions/guideEncode\""] #[doc = " },"] #[doc = " \"labels\": {"] #[doc = " \"$ref\": \"#/definitions/guideEncode\""] #[doc = " },"] #[doc = " \"ticks\": {"] #[doc = " \"$ref\": \"#/definitions/guideEncode\""] #[doc = " },"] #[doc = " \"title\": {"] #[doc = " \"$ref\": \"#/definitions/guideEncode\""] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(deny_unknown_fields)] pub struct AxisEncode { #[serde(default, skip_serializing_if = "Option::is_none")] pub axis: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub domain: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub grid: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub labels: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub ticks: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub title: Option, } impl From<&AxisEncode> for AxisEncode { fn from(value: &AxisEncode) -> Self { value.clone() } } #[doc = "AxisFormat"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"date\": {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " \"day\": {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " \"hours\": {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " \"milliseconds\": {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " \"minutes\": {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " \"month\": {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " \"quarter\": {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " \"seconds\": {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " \"week\": {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " \"year\": {"] #[doc = " \"type\": \"string\""] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged, deny_unknown_fields)] pub enum AxisFormat { Variant0(String), Variant1 { #[serde(default, skip_serializing_if = "Option::is_none")] date: Option, #[serde(default, skip_serializing_if = "Option::is_none")] day: Option, #[serde(default, skip_serializing_if = "Option::is_none")] hours: Option, #[serde(default, skip_serializing_if = "Option::is_none")] milliseconds: Option, #[serde(default, skip_serializing_if = "Option::is_none")] minutes: Option, #[serde(default, skip_serializing_if = "Option::is_none")] month: Option, #[serde(default, skip_serializing_if = "Option::is_none")] quarter: Option, #[serde(default, skip_serializing_if = "Option::is_none")] seconds: Option, #[serde(default, skip_serializing_if = "Option::is_none")] week: Option, #[serde(default, skip_serializing_if = "Option::is_none")] year: Option, }, Variant2(SignalRef), } impl From<&AxisFormat> for AxisFormat { fn from(value: &AxisFormat) -> Self { value.clone() } } impl From for AxisFormat { fn from(value: SignalRef) -> Self { Self::Variant2(value) } } #[doc = "AxisFormatType"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"number\","] #[doc = " \"time\","] #[doc = " \"utc\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AxisFormatType { Variant0(AxisFormatTypeVariant0), Variant1(SignalRef), } impl From<&AxisFormatType> for AxisFormatType { fn from(value: &AxisFormatType) -> Self { value.clone() } } impl From for AxisFormatType { fn from(value: AxisFormatTypeVariant0) -> Self { Self::Variant0(value) } } impl From for AxisFormatType { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "AxisFormatTypeVariant0"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"enum\": ["] #[doc = " \"number\","] #[doc = " \"time\","] #[doc = " \"utc\""] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] pub enum AxisFormatTypeVariant0 { #[serde(rename = "number")] Number, #[serde(rename = "time")] Time, #[serde(rename = "utc")] Utc, } impl From<&AxisFormatTypeVariant0> for AxisFormatTypeVariant0 { fn from(value: &AxisFormatTypeVariant0) -> Self { value.clone() } } impl ::std::fmt::Display for AxisFormatTypeVariant0 { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match *self { Self::Number => write!(f, "number"), Self::Time => write!(f, "time"), Self::Utc => write!(f, "utc"), } } } impl std::str::FromStr for AxisFormatTypeVariant0 { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { match value { "number" => Ok(Self::Number), "time" => Ok(Self::Time), "utc" => Ok(Self::Utc), _ => Err("invalid value".into()), } } } impl std::convert::TryFrom<&str> for AxisFormatTypeVariant0 { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for AxisFormatTypeVariant0 { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for AxisFormatTypeVariant0 { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } #[doc = "AxisGridCap"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/stringValue\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AxisGridCap { Variant0(String), Variant1(StringValue), } impl From<&AxisGridCap> for AxisGridCap { fn from(value: &AxisGridCap) -> Self { value.clone() } } impl From for AxisGridCap { fn from(value: StringValue) -> Self { Self::Variant1(value) } } #[doc = "AxisGridColor"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"null\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/colorValue\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AxisGridColor { Variant0, Variant1(String), Variant2(ColorValue), } impl From<&AxisGridColor> for AxisGridColor { fn from(value: &AxisGridColor) -> Self { value.clone() } } impl From for AxisGridColor { fn from(value: ColorValue) -> Self { Self::Variant2(value) } } #[doc = "AxisGridDash"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"type\": \"number\""] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/arrayValue\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AxisGridDash { Variant0(Vec), Variant1(ArrayValue), } impl From<&AxisGridDash> for AxisGridDash { fn from(value: &AxisGridDash) -> Self { value.clone() } } impl From> for AxisGridDash { fn from(value: Vec) -> Self { Self::Variant0(value) } } impl From for AxisGridDash { fn from(value: ArrayValue) -> Self { Self::Variant1(value) } } #[doc = "AxisGridDashOffset"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AxisGridDashOffset { Variant0(f64), Variant1(NumberValue), } impl From<&AxisGridDashOffset> for AxisGridDashOffset { fn from(value: &AxisGridDashOffset) -> Self { value.clone() } } impl From for AxisGridDashOffset { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for AxisGridDashOffset { fn from(value: NumberValue) -> Self { Self::Variant1(value) } } #[doc = "AxisGridOpacity"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AxisGridOpacity { Variant0(f64), Variant1(NumberValue), } impl From<&AxisGridOpacity> for AxisGridOpacity { fn from(value: &AxisGridOpacity) -> Self { value.clone() } } impl From for AxisGridOpacity { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for AxisGridOpacity { fn from(value: NumberValue) -> Self { Self::Variant1(value) } } #[doc = "AxisGridWidth"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AxisGridWidth { Variant0(f64), Variant1(NumberValue), } impl From<&AxisGridWidth> for AxisGridWidth { fn from(value: &AxisGridWidth) -> Self { value.clone() } } impl From for AxisGridWidth { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for AxisGridWidth { fn from(value: NumberValue) -> Self { Self::Variant1(value) } } #[doc = "AxisLabelAlign"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"left\","] #[doc = " \"right\","] #[doc = " \"center\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/alignValue\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AxisLabelAlign { Variant0(AxisLabelAlignVariant0), Variant1(AlignValue), } impl From<&AxisLabelAlign> for AxisLabelAlign { fn from(value: &AxisLabelAlign) -> Self { value.clone() } } impl From for AxisLabelAlign { fn from(value: AxisLabelAlignVariant0) -> Self { Self::Variant0(value) } } impl From for AxisLabelAlign { fn from(value: AlignValue) -> Self { Self::Variant1(value) } } #[doc = "AxisLabelAlignVariant0"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"enum\": ["] #[doc = " \"left\","] #[doc = " \"right\","] #[doc = " \"center\""] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] pub enum AxisLabelAlignVariant0 { #[serde(rename = "left")] Left, #[serde(rename = "right")] Right, #[serde(rename = "center")] Center, } impl From<&AxisLabelAlignVariant0> for AxisLabelAlignVariant0 { fn from(value: &AxisLabelAlignVariant0) -> Self { value.clone() } } impl ::std::fmt::Display for AxisLabelAlignVariant0 { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match *self { Self::Left => write!(f, "left"), Self::Right => write!(f, "right"), Self::Center => write!(f, "center"), } } } impl std::str::FromStr for AxisLabelAlignVariant0 { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { match value { "left" => Ok(Self::Left), "right" => Ok(Self::Right), "center" => Ok(Self::Center), _ => Err("invalid value".into()), } } } impl std::convert::TryFrom<&str> for AxisLabelAlignVariant0 { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for AxisLabelAlignVariant0 { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for AxisLabelAlignVariant0 { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } #[doc = "AxisLabelAngle"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AxisLabelAngle { Variant0(f64), Variant1(NumberValue), } impl From<&AxisLabelAngle> for AxisLabelAngle { fn from(value: &AxisLabelAngle) -> Self { value.clone() } } impl From for AxisLabelAngle { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for AxisLabelAngle { fn from(value: NumberValue) -> Self { Self::Variant1(value) } } #[doc = "AxisLabelBaseline"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"top\","] #[doc = " \"middle\","] #[doc = " \"bottom\","] #[doc = " \"alphabetic\","] #[doc = " \"line-top\","] #[doc = " \"line-bottom\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/baselineValue\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AxisLabelBaseline { Variant0(AxisLabelBaselineVariant0), Variant1(BaselineValue), } impl From<&AxisLabelBaseline> for AxisLabelBaseline { fn from(value: &AxisLabelBaseline) -> Self { value.clone() } } impl From for AxisLabelBaseline { fn from(value: AxisLabelBaselineVariant0) -> Self { Self::Variant0(value) } } impl From for AxisLabelBaseline { fn from(value: BaselineValue) -> Self { Self::Variant1(value) } } #[doc = "AxisLabelBaselineVariant0"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"enum\": ["] #[doc = " \"top\","] #[doc = " \"middle\","] #[doc = " \"bottom\","] #[doc = " \"alphabetic\","] #[doc = " \"line-top\","] #[doc = " \"line-bottom\""] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] pub enum AxisLabelBaselineVariant0 { #[serde(rename = "top")] Top, #[serde(rename = "middle")] Middle, #[serde(rename = "bottom")] Bottom, #[serde(rename = "alphabetic")] Alphabetic, #[serde(rename = "line-top")] LineTop, #[serde(rename = "line-bottom")] LineBottom, } impl From<&AxisLabelBaselineVariant0> for AxisLabelBaselineVariant0 { fn from(value: &AxisLabelBaselineVariant0) -> Self { value.clone() } } impl ::std::fmt::Display for AxisLabelBaselineVariant0 { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match *self { Self::Top => write!(f, "top"), Self::Middle => write!(f, "middle"), Self::Bottom => write!(f, "bottom"), Self::Alphabetic => write!(f, "alphabetic"), Self::LineTop => write!(f, "line-top"), Self::LineBottom => write!(f, "line-bottom"), } } } impl std::str::FromStr for AxisLabelBaselineVariant0 { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { match value { "top" => Ok(Self::Top), "middle" => Ok(Self::Middle), "bottom" => Ok(Self::Bottom), "alphabetic" => Ok(Self::Alphabetic), "line-top" => Ok(Self::LineTop), "line-bottom" => Ok(Self::LineBottom), _ => Err("invalid value".into()), } } } impl std::convert::TryFrom<&str> for AxisLabelBaselineVariant0 { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for AxisLabelBaselineVariant0 { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for AxisLabelBaselineVariant0 { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } #[doc = "AxisLabelBound"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AxisLabelBound { Variant0(bool), Variant1(f64), Variant2(SignalRef), } impl From<&AxisLabelBound> for AxisLabelBound { fn from(value: &AxisLabelBound) -> Self { value.clone() } } impl From for AxisLabelBound { fn from(value: bool) -> Self { Self::Variant0(value) } } impl From for AxisLabelBound { fn from(value: f64) -> Self { Self::Variant1(value) } } impl From for AxisLabelBound { fn from(value: SignalRef) -> Self { Self::Variant2(value) } } #[doc = "AxisLabelColor"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"null\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/colorValue\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AxisLabelColor { Variant0, Variant1(String), Variant2(ColorValue), } impl From<&AxisLabelColor> for AxisLabelColor { fn from(value: &AxisLabelColor) -> Self { value.clone() } } impl From for AxisLabelColor { fn from(value: ColorValue) -> Self { Self::Variant2(value) } } #[doc = "AxisLabelFlush"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AxisLabelFlush { Variant0(bool), Variant1(f64), Variant2(SignalRef), } impl From<&AxisLabelFlush> for AxisLabelFlush { fn from(value: &AxisLabelFlush) -> Self { value.clone() } } impl From for AxisLabelFlush { fn from(value: bool) -> Self { Self::Variant0(value) } } impl From for AxisLabelFlush { fn from(value: f64) -> Self { Self::Variant1(value) } } impl From for AxisLabelFlush { fn from(value: SignalRef) -> Self { Self::Variant2(value) } } #[doc = "AxisLabelFont"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/stringValue\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AxisLabelFont { Variant0(String), Variant1(StringValue), } impl From<&AxisLabelFont> for AxisLabelFont { fn from(value: &AxisLabelFont) -> Self { value.clone() } } impl From for AxisLabelFont { fn from(value: StringValue) -> Self { Self::Variant1(value) } } #[doc = "AxisLabelFontSize"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AxisLabelFontSize { Variant0(f64), Variant1(NumberValue), } impl From<&AxisLabelFontSize> for AxisLabelFontSize { fn from(value: &AxisLabelFontSize) -> Self { value.clone() } } impl From for AxisLabelFontSize { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for AxisLabelFontSize { fn from(value: NumberValue) -> Self { Self::Variant1(value) } } #[doc = "AxisLabelFontStyle"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/stringValue\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AxisLabelFontStyle { Variant0(String), Variant1(StringValue), } impl From<&AxisLabelFontStyle> for AxisLabelFontStyle { fn from(value: &AxisLabelFontStyle) -> Self { value.clone() } } impl From for AxisLabelFontStyle { fn from(value: StringValue) -> Self { Self::Variant1(value) } } #[doc = "AxisLabelFontWeight"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " null,"] #[doc = " \"normal\","] #[doc = " \"bold\","] #[doc = " \"lighter\","] #[doc = " \"bolder\","] #[doc = " \"100\","] #[doc = " \"200\","] #[doc = " \"300\","] #[doc = " \"400\","] #[doc = " \"500\","] #[doc = " \"600\","] #[doc = " \"700\","] #[doc = " \"800\","] #[doc = " \"900\","] #[doc = " 100,"] #[doc = " 200,"] #[doc = " 300,"] #[doc = " 400,"] #[doc = " 500,"] #[doc = " 600,"] #[doc = " 700,"] #[doc = " 800,"] #[doc = " 900"] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/fontWeightValue\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AxisLabelFontWeight { Variant0(MyEnum), Variant1(FontWeightValue), } impl From<&AxisLabelFontWeight> for AxisLabelFontWeight { fn from(value: &AxisLabelFontWeight) -> Self { value.clone() } } impl From for AxisLabelFontWeight { fn from(value: MyEnum) -> Self { Self::Variant0(value) } } impl From for AxisLabelFontWeight { fn from(value: FontWeightValue) -> Self { Self::Variant1(value) } } #[doc = "AxisLabelLimit"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AxisLabelLimit { Variant0(f64), Variant1(NumberValue), } impl From<&AxisLabelLimit> for AxisLabelLimit { fn from(value: &AxisLabelLimit) -> Self { value.clone() } } impl From for AxisLabelLimit { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for AxisLabelLimit { fn from(value: NumberValue) -> Self { Self::Variant1(value) } } #[doc = "AxisLabelLineHeight"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AxisLabelLineHeight { Variant0(f64), Variant1(NumberValue), } impl From<&AxisLabelLineHeight> for AxisLabelLineHeight { fn from(value: &AxisLabelLineHeight) -> Self { value.clone() } } impl From for AxisLabelLineHeight { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for AxisLabelLineHeight { fn from(value: NumberValue) -> Self { Self::Variant1(value) } } #[doc = "AxisLabelOffset"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AxisLabelOffset { Variant0(f64), Variant1(NumberValue), } impl From<&AxisLabelOffset> for AxisLabelOffset { fn from(value: &AxisLabelOffset) -> Self { value.clone() } } impl From for AxisLabelOffset { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for AxisLabelOffset { fn from(value: NumberValue) -> Self { Self::Variant1(value) } } #[doc = "AxisLabelOpacity"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AxisLabelOpacity { Variant0(f64), Variant1(NumberValue), } impl From<&AxisLabelOpacity> for AxisLabelOpacity { fn from(value: &AxisLabelOpacity) -> Self { value.clone() } } impl From for AxisLabelOpacity { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for AxisLabelOpacity { fn from(value: NumberValue) -> Self { Self::Variant1(value) } } #[doc = "AxisLabelPadding"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AxisLabelPadding { Variant0(f64), Variant1(NumberValue), } impl From<&AxisLabelPadding> for AxisLabelPadding { fn from(value: &AxisLabelPadding) -> Self { value.clone() } } impl From for AxisLabelPadding { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for AxisLabelPadding { fn from(value: NumberValue) -> Self { Self::Variant1(value) } } #[doc = "AxisMaxExtent"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AxisMaxExtent { Variant0(f64), Variant1(NumberValue), } impl From<&AxisMaxExtent> for AxisMaxExtent { fn from(value: &AxisMaxExtent) -> Self { value.clone() } } impl From for AxisMaxExtent { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for AxisMaxExtent { fn from(value: NumberValue) -> Self { Self::Variant1(value) } } #[doc = "AxisMinExtent"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AxisMinExtent { Variant0(f64), Variant1(NumberValue), } impl From<&AxisMinExtent> for AxisMinExtent { fn from(value: &AxisMinExtent) -> Self { value.clone() } } impl From for AxisMinExtent { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for AxisMinExtent { fn from(value: NumberValue) -> Self { Self::Variant1(value) } } #[doc = "AxisOffset"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AxisOffset { Variant0(f64), Variant1(NumberValue), } impl From<&AxisOffset> for AxisOffset { fn from(value: &AxisOffset) -> Self { value.clone() } } impl From for AxisOffset { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for AxisOffset { fn from(value: NumberValue) -> Self { Self::Variant1(value) } } #[doc = "AxisOrient"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"top\","] #[doc = " \"bottom\","] #[doc = " \"left\","] #[doc = " \"right\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AxisOrient { Variant0(AxisOrientVariant0), Variant1(SignalRef), } impl From<&AxisOrient> for AxisOrient { fn from(value: &AxisOrient) -> Self { value.clone() } } impl From for AxisOrient { fn from(value: AxisOrientVariant0) -> Self { Self::Variant0(value) } } impl From for AxisOrient { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "AxisOrientVariant0"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"enum\": ["] #[doc = " \"top\","] #[doc = " \"bottom\","] #[doc = " \"left\","] #[doc = " \"right\""] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] pub enum AxisOrientVariant0 { #[serde(rename = "top")] Top, #[serde(rename = "bottom")] Bottom, #[serde(rename = "left")] Left, #[serde(rename = "right")] Right, } impl From<&AxisOrientVariant0> for AxisOrientVariant0 { fn from(value: &AxisOrientVariant0) -> Self { value.clone() } } impl ::std::fmt::Display for AxisOrientVariant0 { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match *self { Self::Top => write!(f, "top"), Self::Bottom => write!(f, "bottom"), Self::Left => write!(f, "left"), Self::Right => write!(f, "right"), } } } impl std::str::FromStr for AxisOrientVariant0 { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { match value { "top" => Ok(Self::Top), "bottom" => Ok(Self::Bottom), "left" => Ok(Self::Left), "right" => Ok(Self::Right), _ => Err("invalid value".into()), } } } impl std::convert::TryFrom<&str> for AxisOrientVariant0 { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for AxisOrientVariant0 { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for AxisOrientVariant0 { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } #[doc = "AxisPosition"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AxisPosition { Variant0(f64), Variant1(NumberValue), } impl From<&AxisPosition> for AxisPosition { fn from(value: &AxisPosition) -> Self { value.clone() } } impl From for AxisPosition { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for AxisPosition { fn from(value: NumberValue) -> Self { Self::Variant1(value) } } #[doc = "AxisTickCap"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/stringValue\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AxisTickCap { Variant0(String), Variant1(StringValue), } impl From<&AxisTickCap> for AxisTickCap { fn from(value: &AxisTickCap) -> Self { value.clone() } } impl From for AxisTickCap { fn from(value: StringValue) -> Self { Self::Variant1(value) } } #[doc = "AxisTickColor"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"null\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/colorValue\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AxisTickColor { Variant0, Variant1(String), Variant2(ColorValue), } impl From<&AxisTickColor> for AxisTickColor { fn from(value: &AxisTickColor) -> Self { value.clone() } } impl From for AxisTickColor { fn from(value: ColorValue) -> Self { Self::Variant2(value) } } #[doc = "AxisTickDash"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"type\": \"number\""] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/arrayValue\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AxisTickDash { Variant0(Vec), Variant1(ArrayValue), } impl From<&AxisTickDash> for AxisTickDash { fn from(value: &AxisTickDash) -> Self { value.clone() } } impl From> for AxisTickDash { fn from(value: Vec) -> Self { Self::Variant0(value) } } impl From for AxisTickDash { fn from(value: ArrayValue) -> Self { Self::Variant1(value) } } #[doc = "AxisTickDashOffset"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AxisTickDashOffset { Variant0(f64), Variant1(NumberValue), } impl From<&AxisTickDashOffset> for AxisTickDashOffset { fn from(value: &AxisTickDashOffset) -> Self { value.clone() } } impl From for AxisTickDashOffset { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for AxisTickDashOffset { fn from(value: NumberValue) -> Self { Self::Variant1(value) } } #[doc = "AxisTickOffset"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AxisTickOffset { Variant0(f64), Variant1(NumberValue), } impl From<&AxisTickOffset> for AxisTickOffset { fn from(value: &AxisTickOffset) -> Self { value.clone() } } impl From for AxisTickOffset { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for AxisTickOffset { fn from(value: NumberValue) -> Self { Self::Variant1(value) } } #[doc = "AxisTickOpacity"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AxisTickOpacity { Variant0(f64), Variant1(NumberValue), } impl From<&AxisTickOpacity> for AxisTickOpacity { fn from(value: &AxisTickOpacity) -> Self { value.clone() } } impl From for AxisTickOpacity { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for AxisTickOpacity { fn from(value: NumberValue) -> Self { Self::Variant1(value) } } #[doc = "AxisTickRound"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/booleanValue\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AxisTickRound { Variant0(bool), Variant1(BooleanValue), } impl From<&AxisTickRound> for AxisTickRound { fn from(value: &AxisTickRound) -> Self { value.clone() } } impl From for AxisTickRound { fn from(value: bool) -> Self { Self::Variant0(value) } } impl From for AxisTickRound { fn from(value: BooleanValue) -> Self { Self::Variant1(value) } } #[doc = "AxisTickSize"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AxisTickSize { Variant0(f64), Variant1(NumberValue), } impl From<&AxisTickSize> for AxisTickSize { fn from(value: &AxisTickSize) -> Self { value.clone() } } impl From for AxisTickSize { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for AxisTickSize { fn from(value: NumberValue) -> Self { Self::Variant1(value) } } #[doc = "AxisTickWidth"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AxisTickWidth { Variant0(f64), Variant1(NumberValue), } impl From<&AxisTickWidth> for AxisTickWidth { fn from(value: &AxisTickWidth) -> Self { value.clone() } } impl From for AxisTickWidth { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for AxisTickWidth { fn from(value: NumberValue) -> Self { Self::Variant1(value) } } #[doc = "AxisTitleAlign"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"left\","] #[doc = " \"right\","] #[doc = " \"center\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/alignValue\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AxisTitleAlign { Variant0(AxisTitleAlignVariant0), Variant1(AlignValue), } impl From<&AxisTitleAlign> for AxisTitleAlign { fn from(value: &AxisTitleAlign) -> Self { value.clone() } } impl From for AxisTitleAlign { fn from(value: AxisTitleAlignVariant0) -> Self { Self::Variant0(value) } } impl From for AxisTitleAlign { fn from(value: AlignValue) -> Self { Self::Variant1(value) } } #[doc = "AxisTitleAlignVariant0"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"enum\": ["] #[doc = " \"left\","] #[doc = " \"right\","] #[doc = " \"center\""] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] pub enum AxisTitleAlignVariant0 { #[serde(rename = "left")] Left, #[serde(rename = "right")] Right, #[serde(rename = "center")] Center, } impl From<&AxisTitleAlignVariant0> for AxisTitleAlignVariant0 { fn from(value: &AxisTitleAlignVariant0) -> Self { value.clone() } } impl ::std::fmt::Display for AxisTitleAlignVariant0 { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match *self { Self::Left => write!(f, "left"), Self::Right => write!(f, "right"), Self::Center => write!(f, "center"), } } } impl std::str::FromStr for AxisTitleAlignVariant0 { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { match value { "left" => Ok(Self::Left), "right" => Ok(Self::Right), "center" => Ok(Self::Center), _ => Err("invalid value".into()), } } } impl std::convert::TryFrom<&str> for AxisTitleAlignVariant0 { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for AxisTitleAlignVariant0 { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for AxisTitleAlignVariant0 { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } #[doc = "AxisTitleAnchor"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " null,"] #[doc = " \"start\","] #[doc = " \"middle\","] #[doc = " \"end\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/anchorValue\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AxisTitleAnchor { Variant0(Option), Variant1(AnchorValue), } impl From<&AxisTitleAnchor> for AxisTitleAnchor { fn from(value: &AxisTitleAnchor) -> Self { value.clone() } } impl From> for AxisTitleAnchor { fn from(value: Option) -> Self { Self::Variant0(value) } } impl From for AxisTitleAnchor { fn from(value: AnchorValue) -> Self { Self::Variant1(value) } } #[doc = "AxisTitleAnchorVariant0"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"enum\": ["] #[doc = " null,"] #[doc = " \"start\","] #[doc = " \"middle\","] #[doc = " \"end\""] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] pub enum AxisTitleAnchorVariant0 { #[serde(rename = "start")] Start, #[serde(rename = "middle")] Middle, #[serde(rename = "end")] End, } impl From<&AxisTitleAnchorVariant0> for AxisTitleAnchorVariant0 { fn from(value: &AxisTitleAnchorVariant0) -> Self { value.clone() } } impl ::std::fmt::Display for AxisTitleAnchorVariant0 { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match *self { Self::Start => write!(f, "start"), Self::Middle => write!(f, "middle"), Self::End => write!(f, "end"), } } } impl std::str::FromStr for AxisTitleAnchorVariant0 { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { match value { "start" => Ok(Self::Start), "middle" => Ok(Self::Middle), "end" => Ok(Self::End), _ => Err("invalid value".into()), } } } impl std::convert::TryFrom<&str> for AxisTitleAnchorVariant0 { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for AxisTitleAnchorVariant0 { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for AxisTitleAnchorVariant0 { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } #[doc = "AxisTitleAngle"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AxisTitleAngle { Variant0(f64), Variant1(NumberValue), } impl From<&AxisTitleAngle> for AxisTitleAngle { fn from(value: &AxisTitleAngle) -> Self { value.clone() } } impl From for AxisTitleAngle { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for AxisTitleAngle { fn from(value: NumberValue) -> Self { Self::Variant1(value) } } #[doc = "AxisTitleBaseline"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"top\","] #[doc = " \"middle\","] #[doc = " \"bottom\","] #[doc = " \"alphabetic\","] #[doc = " \"line-top\","] #[doc = " \"line-bottom\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/baselineValue\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AxisTitleBaseline { Variant0(AxisTitleBaselineVariant0), Variant1(BaselineValue), } impl From<&AxisTitleBaseline> for AxisTitleBaseline { fn from(value: &AxisTitleBaseline) -> Self { value.clone() } } impl From for AxisTitleBaseline { fn from(value: AxisTitleBaselineVariant0) -> Self { Self::Variant0(value) } } impl From for AxisTitleBaseline { fn from(value: BaselineValue) -> Self { Self::Variant1(value) } } #[doc = "AxisTitleBaselineVariant0"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"enum\": ["] #[doc = " \"top\","] #[doc = " \"middle\","] #[doc = " \"bottom\","] #[doc = " \"alphabetic\","] #[doc = " \"line-top\","] #[doc = " \"line-bottom\""] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] pub enum AxisTitleBaselineVariant0 { #[serde(rename = "top")] Top, #[serde(rename = "middle")] Middle, #[serde(rename = "bottom")] Bottom, #[serde(rename = "alphabetic")] Alphabetic, #[serde(rename = "line-top")] LineTop, #[serde(rename = "line-bottom")] LineBottom, } impl From<&AxisTitleBaselineVariant0> for AxisTitleBaselineVariant0 { fn from(value: &AxisTitleBaselineVariant0) -> Self { value.clone() } } impl ::std::fmt::Display for AxisTitleBaselineVariant0 { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match *self { Self::Top => write!(f, "top"), Self::Middle => write!(f, "middle"), Self::Bottom => write!(f, "bottom"), Self::Alphabetic => write!(f, "alphabetic"), Self::LineTop => write!(f, "line-top"), Self::LineBottom => write!(f, "line-bottom"), } } } impl std::str::FromStr for AxisTitleBaselineVariant0 { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { match value { "top" => Ok(Self::Top), "middle" => Ok(Self::Middle), "bottom" => Ok(Self::Bottom), "alphabetic" => Ok(Self::Alphabetic), "line-top" => Ok(Self::LineTop), "line-bottom" => Ok(Self::LineBottom), _ => Err("invalid value".into()), } } } impl std::convert::TryFrom<&str> for AxisTitleBaselineVariant0 { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for AxisTitleBaselineVariant0 { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for AxisTitleBaselineVariant0 { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } #[doc = "AxisTitleColor"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"null\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/colorValue\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AxisTitleColor { Variant0, Variant1(String), Variant2(ColorValue), } impl From<&AxisTitleColor> for AxisTitleColor { fn from(value: &AxisTitleColor) -> Self { value.clone() } } impl From for AxisTitleColor { fn from(value: ColorValue) -> Self { Self::Variant2(value) } } #[doc = "AxisTitleFont"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/stringValue\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AxisTitleFont { Variant0(String), Variant1(StringValue), } impl From<&AxisTitleFont> for AxisTitleFont { fn from(value: &AxisTitleFont) -> Self { value.clone() } } impl From for AxisTitleFont { fn from(value: StringValue) -> Self { Self::Variant1(value) } } #[doc = "AxisTitleFontSize"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AxisTitleFontSize { Variant0(f64), Variant1(NumberValue), } impl From<&AxisTitleFontSize> for AxisTitleFontSize { fn from(value: &AxisTitleFontSize) -> Self { value.clone() } } impl From for AxisTitleFontSize { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for AxisTitleFontSize { fn from(value: NumberValue) -> Self { Self::Variant1(value) } } #[doc = "AxisTitleFontStyle"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/stringValue\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AxisTitleFontStyle { Variant0(String), Variant1(StringValue), } impl From<&AxisTitleFontStyle> for AxisTitleFontStyle { fn from(value: &AxisTitleFontStyle) -> Self { value.clone() } } impl From for AxisTitleFontStyle { fn from(value: StringValue) -> Self { Self::Variant1(value) } } #[doc = "AxisTitleFontWeight"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " null,"] #[doc = " \"normal\","] #[doc = " \"bold\","] #[doc = " \"lighter\","] #[doc = " \"bolder\","] #[doc = " \"100\","] #[doc = " \"200\","] #[doc = " \"300\","] #[doc = " \"400\","] #[doc = " \"500\","] #[doc = " \"600\","] #[doc = " \"700\","] #[doc = " \"800\","] #[doc = " \"900\","] #[doc = " 100,"] #[doc = " 200,"] #[doc = " 300,"] #[doc = " 400,"] #[doc = " 500,"] #[doc = " 600,"] #[doc = " 700,"] #[doc = " 800,"] #[doc = " 900"] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/fontWeightValue\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AxisTitleFontWeight { Variant0(MyEnum), Variant1(FontWeightValue), } impl From<&AxisTitleFontWeight> for AxisTitleFontWeight { fn from(value: &AxisTitleFontWeight) -> Self { value.clone() } } impl From for AxisTitleFontWeight { fn from(value: MyEnum) -> Self { Self::Variant0(value) } } impl From for AxisTitleFontWeight { fn from(value: FontWeightValue) -> Self { Self::Variant1(value) } } #[doc = "AxisTitleLimit"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AxisTitleLimit { Variant0(f64), Variant1(NumberValue), } impl From<&AxisTitleLimit> for AxisTitleLimit { fn from(value: &AxisTitleLimit) -> Self { value.clone() } } impl From for AxisTitleLimit { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for AxisTitleLimit { fn from(value: NumberValue) -> Self { Self::Variant1(value) } } #[doc = "AxisTitleLineHeight"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AxisTitleLineHeight { Variant0(f64), Variant1(NumberValue), } impl From<&AxisTitleLineHeight> for AxisTitleLineHeight { fn from(value: &AxisTitleLineHeight) -> Self { value.clone() } } impl From for AxisTitleLineHeight { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for AxisTitleLineHeight { fn from(value: NumberValue) -> Self { Self::Variant1(value) } } #[doc = "AxisTitleOpacity"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AxisTitleOpacity { Variant0(f64), Variant1(NumberValue), } impl From<&AxisTitleOpacity> for AxisTitleOpacity { fn from(value: &AxisTitleOpacity) -> Self { value.clone() } } impl From for AxisTitleOpacity { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for AxisTitleOpacity { fn from(value: NumberValue) -> Self { Self::Variant1(value) } } #[doc = "AxisTitlePadding"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AxisTitlePadding { Variant0(f64), Variant1(NumberValue), } impl From<&AxisTitlePadding> for AxisTitlePadding { fn from(value: &AxisTitlePadding) -> Self { value.clone() } } impl From for AxisTitlePadding { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for AxisTitlePadding { fn from(value: NumberValue) -> Self { Self::Variant1(value) } } #[doc = "AxisTitleX"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AxisTitleX { Variant0(f64), Variant1(NumberValue), } impl From<&AxisTitleX> for AxisTitleX { fn from(value: &AxisTitleX) -> Self { value.clone() } } impl From for AxisTitleX { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for AxisTitleX { fn from(value: NumberValue) -> Self { Self::Variant1(value) } } #[doc = "AxisTitleY"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AxisTitleY { Variant0(f64), Variant1(NumberValue), } impl From<&AxisTitleY> for AxisTitleY { fn from(value: &AxisTitleY) -> Self { value.clone() } } impl From for AxisTitleY { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for AxisTitleY { fn from(value: NumberValue) -> Self { Self::Variant1(value) } } #[doc = "AxisTranslate"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum AxisTranslate { Variant0(f64), Variant1(NumberValue), } impl From<&AxisTranslate> for AxisTranslate { fn from(value: &AxisTranslate) -> Self { value.clone() } } impl From for AxisTranslate { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for AxisTranslate { fn from(value: NumberValue) -> Self { Self::Variant1(value) } } #[doc = "Background"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"$ref\": \"#/definitions/stringOrSignal\""] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] pub struct Background(pub StringOrSignal); impl ::std::ops::Deref for Background { type Target = StringOrSignal; fn deref(&self) -> &StringOrSignal { &self.0 } } impl From for StringOrSignal { fn from(value: Background) -> Self { value.0 } } impl From<&Background> for Background { fn from(value: &Background) -> Self { value.clone() } } impl From for Background { fn from(value: StringOrSignal) -> Self { Self(value) } } #[doc = "BaseColorValue"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/stringModifiers\""] #[doc = " },"] #[doc = " {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"null\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"$ref\": \"#/definitions/linearGradient\""] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"$ref\": \"#/definitions/radialGradient\""] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"gradient\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"count\": {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " \"gradient\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " },"] #[doc = " \"start\": {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " \"maxItems\": 2,"] #[doc = " \"minItems\": 2"] #[doc = " },"] #[doc = " \"stop\": {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " \"maxItems\": 2,"] #[doc = " \"minItems\": 2"] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"color\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"color\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/colorRGB\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/colorHSL\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/colorLAB\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/colorHCL\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged, deny_unknown_fields)] pub enum BaseColorValue { Variant0(BaseColorValueVariant0), Variant1 { value: LinearGradient, }, Variant2 { value: RadialGradient, }, Variant3 { #[serde(default, skip_serializing_if = "Option::is_none")] count: Option, gradient: Field, #[serde(default, skip_serializing_if = "Option::is_none")] start: Option<[f64; 2usize]>, #[serde(default, skip_serializing_if = "Option::is_none")] stop: Option<[f64; 2usize]>, }, Variant4 { color: BaseColorValueVariant4Color, }, } impl From<&BaseColorValue> for BaseColorValue { fn from(value: &BaseColorValue) -> Self { value.clone() } } impl From for BaseColorValue { fn from(value: BaseColorValueVariant0) -> Self { Self::Variant0(value) } } #[doc = "BaseColorValueVariant0"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/stringModifiers\""] #[doc = " },"] #[doc = " {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"null\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum BaseColorValueVariant0 { Variant0(BaseColorValueVariant0Variant0), Variant1(BaseColorValueVariant0Variant1), Variant2(BaseColorValueVariant0Variant2), Variant3 { offset: ::serde_json::Value }, } impl From<&BaseColorValueVariant0> for BaseColorValueVariant0 { fn from(value: &BaseColorValueVariant0) -> Self { value.clone() } } impl From for BaseColorValueVariant0 { fn from(value: BaseColorValueVariant0Variant0) -> Self { Self::Variant0(value) } } impl From for BaseColorValueVariant0 { fn from(value: BaseColorValueVariant0Variant1) -> Self { Self::Variant1(value) } } impl From for BaseColorValueVariant0 { fn from(value: BaseColorValueVariant0Variant2) -> Self { Self::Variant2(value) } } #[doc = "BaseColorValueVariant0Variant0"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"scale\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"null\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum BaseColorValueVariant0Variant0 { Variant0 { #[serde(default, skip_serializing_if = "Option::is_none")] scale: Option, signal: String, }, Variant1 { #[serde(default, skip_serializing_if = "Option::is_none")] scale: Option, value: Option, }, Variant2 { field: Field, #[serde(default, skip_serializing_if = "Option::is_none")] scale: Option, }, Variant3 { range: BaseColorValueVariant0Variant0Variant3Range, #[serde(default, skip_serializing_if = "Option::is_none")] scale: Option, }, } impl From<&BaseColorValueVariant0Variant0> for BaseColorValueVariant0Variant0 { fn from(value: &BaseColorValueVariant0Variant0) -> Self { value.clone() } } #[doc = "BaseColorValueVariant0Variant0Variant3Range"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum BaseColorValueVariant0Variant0Variant3Range { Variant0(f64), Variant1(bool), } impl From<&BaseColorValueVariant0Variant0Variant3Range> for BaseColorValueVariant0Variant0Variant3Range { fn from(value: &BaseColorValueVariant0Variant0Variant3Range) -> Self { value.clone() } } impl std::str::FromStr for BaseColorValueVariant0Variant0Variant3Range { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { if let Ok(v) = value.parse() { Ok(Self::Variant0(v)) } else if let Ok(v) = value.parse() { Ok(Self::Variant1(v)) } else { Err("string conversion failed for all variants".into()) } } } impl std::convert::TryFrom<&str> for BaseColorValueVariant0Variant0Variant3Range { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for BaseColorValueVariant0Variant0Variant3Range { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for BaseColorValueVariant0Variant0Variant3Range { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } impl ::std::fmt::Display for BaseColorValueVariant0Variant0Variant3Range { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match self { Self::Variant0(x) => x.fmt(f), Self::Variant1(x) => x.fmt(f), } } } impl From for BaseColorValueVariant0Variant0Variant3Range { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for BaseColorValueVariant0Variant0Variant3Range { fn from(value: bool) -> Self { Self::Variant1(value) } } #[doc = "BaseColorValueVariant0Variant1"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"scale\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"null\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] #[serde(deny_unknown_fields)] pub enum BaseColorValueVariant0Variant1 {} impl From<&BaseColorValueVariant0Variant1> for BaseColorValueVariant0Variant1 { fn from(value: &BaseColorValueVariant0Variant1) -> Self { value.clone() } } #[doc = "BaseColorValueVariant0Variant2"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"scale\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"null\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] #[serde(deny_unknown_fields)] pub enum BaseColorValueVariant0Variant2 {} impl From<&BaseColorValueVariant0Variant2> for BaseColorValueVariant0Variant2 { fn from(value: &BaseColorValueVariant0Variant2) -> Self { value.clone() } } #[doc = "BaseColorValueVariant4Color"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/colorRGB\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/colorHSL\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/colorLAB\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/colorHCL\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum BaseColorValueVariant4Color { Rgb(ColorRgb), Hsl(ColorHsl), Lab(ColorLab), Hcl(ColorHcl), } impl From<&BaseColorValueVariant4Color> for BaseColorValueVariant4Color { fn from(value: &BaseColorValueVariant4Color) -> Self { value.clone() } } impl From for BaseColorValueVariant4Color { fn from(value: ColorRgb) -> Self { Self::Rgb(value) } } impl From for BaseColorValueVariant4Color { fn from(value: ColorHsl) -> Self { Self::Hsl(value) } } impl From for BaseColorValueVariant4Color { fn from(value: ColorLab) -> Self { Self::Lab(value) } } impl From for BaseColorValueVariant4Color { fn from(value: ColorHcl) -> Self { Self::Hcl(value) } } #[doc = "BaselineValue"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/rule\""] #[doc = " },"] #[doc = " {"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/stringModifiers\""] #[doc = " },"] #[doc = " {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"enum\": ["] #[doc = " \"top\","] #[doc = " \"middle\","] #[doc = " \"bottom\","] #[doc = " \"alphabetic\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/stringModifiers\""] #[doc = " },"] #[doc = " {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"enum\": ["] #[doc = " \"top\","] #[doc = " \"middle\","] #[doc = " \"bottom\","] #[doc = " \"alphabetic\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum BaselineValue { Variant0(Vec), Variant1(BaselineValueVariant1), } impl From<&BaselineValue> for BaselineValue { fn from(value: &BaselineValue) -> Self { value.clone() } } impl From> for BaselineValue { fn from(value: Vec) -> Self { Self::Variant0(value) } } impl From for BaselineValue { fn from(value: BaselineValueVariant1) -> Self { Self::Variant1(value) } } #[doc = "BaselineValueVariant0Item"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/rule\""] #[doc = " },"] #[doc = " {"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/stringModifiers\""] #[doc = " },"] #[doc = " {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"enum\": ["] #[doc = " \"top\","] #[doc = " \"middle\","] #[doc = " \"bottom\","] #[doc = " \"alphabetic\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum BaselineValueVariant0Item { Variant0(BaselineValueVariant0ItemVariant0), Variant1(BaselineValueVariant0ItemVariant1), Variant2(BaselineValueVariant0ItemVariant2), Variant3 { offset: ::serde_json::Value, #[serde(default, skip_serializing_if = "Option::is_none")] test: Option, }, } impl From<&BaselineValueVariant0Item> for BaselineValueVariant0Item { fn from(value: &BaselineValueVariant0Item) -> Self { value.clone() } } impl From for BaselineValueVariant0Item { fn from(value: BaselineValueVariant0ItemVariant0) -> Self { Self::Variant0(value) } } impl From for BaselineValueVariant0Item { fn from(value: BaselineValueVariant0ItemVariant1) -> Self { Self::Variant1(value) } } impl From for BaselineValueVariant0Item { fn from(value: BaselineValueVariant0ItemVariant2) -> Self { Self::Variant2(value) } } #[doc = "BaselineValueVariant0ItemVariant0"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"scale\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " },"] #[doc = " \"test\": {"] #[doc = " \"type\": \"string\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"enum\": ["] #[doc = " \"top\","] #[doc = " \"middle\","] #[doc = " \"bottom\","] #[doc = " \"alphabetic\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum BaselineValueVariant0ItemVariant0 { Variant0 { #[serde(default, skip_serializing_if = "Option::is_none")] scale: Option, signal: String, #[serde(default, skip_serializing_if = "Option::is_none")] test: Option, }, Variant1 { #[serde(default, skip_serializing_if = "Option::is_none")] scale: Option, #[serde(default, skip_serializing_if = "Option::is_none")] test: Option, value: BaselineValueVariant0ItemVariant0Variant1Value, }, Variant2 { field: Field, #[serde(default, skip_serializing_if = "Option::is_none")] scale: Option, #[serde(default, skip_serializing_if = "Option::is_none")] test: Option, }, Variant3 { range: BaselineValueVariant0ItemVariant0Variant3Range, #[serde(default, skip_serializing_if = "Option::is_none")] scale: Option, #[serde(default, skip_serializing_if = "Option::is_none")] test: Option, }, } impl From<&BaselineValueVariant0ItemVariant0> for BaselineValueVariant0ItemVariant0 { fn from(value: &BaselineValueVariant0ItemVariant0) -> Self { value.clone() } } #[doc = "BaselineValueVariant0ItemVariant0Variant1Value"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"enum\": ["] #[doc = " \"top\","] #[doc = " \"middle\","] #[doc = " \"bottom\","] #[doc = " \"alphabetic\""] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] pub enum BaselineValueVariant0ItemVariant0Variant1Value { #[serde(rename = "top")] Top, #[serde(rename = "middle")] Middle, #[serde(rename = "bottom")] Bottom, #[serde(rename = "alphabetic")] Alphabetic, } impl From<&BaselineValueVariant0ItemVariant0Variant1Value> for BaselineValueVariant0ItemVariant0Variant1Value { fn from(value: &BaselineValueVariant0ItemVariant0Variant1Value) -> Self { value.clone() } } impl ::std::fmt::Display for BaselineValueVariant0ItemVariant0Variant1Value { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match *self { Self::Top => write!(f, "top"), Self::Middle => write!(f, "middle"), Self::Bottom => write!(f, "bottom"), Self::Alphabetic => write!(f, "alphabetic"), } } } impl std::str::FromStr for BaselineValueVariant0ItemVariant0Variant1Value { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { match value { "top" => Ok(Self::Top), "middle" => Ok(Self::Middle), "bottom" => Ok(Self::Bottom), "alphabetic" => Ok(Self::Alphabetic), _ => Err("invalid value".into()), } } } impl std::convert::TryFrom<&str> for BaselineValueVariant0ItemVariant0Variant1Value { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for BaselineValueVariant0ItemVariant0Variant1Value { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for BaselineValueVariant0ItemVariant0Variant1Value { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } #[doc = "BaselineValueVariant0ItemVariant0Variant3Range"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum BaselineValueVariant0ItemVariant0Variant3Range { Variant0(f64), Variant1(bool), } impl From<&BaselineValueVariant0ItemVariant0Variant3Range> for BaselineValueVariant0ItemVariant0Variant3Range { fn from(value: &BaselineValueVariant0ItemVariant0Variant3Range) -> Self { value.clone() } } impl std::str::FromStr for BaselineValueVariant0ItemVariant0Variant3Range { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { if let Ok(v) = value.parse() { Ok(Self::Variant0(v)) } else if let Ok(v) = value.parse() { Ok(Self::Variant1(v)) } else { Err("string conversion failed for all variants".into()) } } } impl std::convert::TryFrom<&str> for BaselineValueVariant0ItemVariant0Variant3Range { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for BaselineValueVariant0ItemVariant0Variant3Range { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for BaselineValueVariant0ItemVariant0Variant3Range { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } impl ::std::fmt::Display for BaselineValueVariant0ItemVariant0Variant3Range { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match self { Self::Variant0(x) => x.fmt(f), Self::Variant1(x) => x.fmt(f), } } } impl From for BaselineValueVariant0ItemVariant0Variant3Range { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for BaselineValueVariant0ItemVariant0Variant3Range { fn from(value: bool) -> Self { Self::Variant1(value) } } #[doc = "BaselineValueVariant0ItemVariant1"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"scale\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " },"] #[doc = " \"test\": {"] #[doc = " \"type\": \"string\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"enum\": ["] #[doc = " \"top\","] #[doc = " \"middle\","] #[doc = " \"bottom\","] #[doc = " \"alphabetic\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] #[serde(deny_unknown_fields)] pub enum BaselineValueVariant0ItemVariant1 {} impl From<&BaselineValueVariant0ItemVariant1> for BaselineValueVariant0ItemVariant1 { fn from(value: &BaselineValueVariant0ItemVariant1) -> Self { value.clone() } } #[doc = "BaselineValueVariant0ItemVariant2"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"scale\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " },"] #[doc = " \"test\": {"] #[doc = " \"type\": \"string\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"enum\": ["] #[doc = " \"top\","] #[doc = " \"middle\","] #[doc = " \"bottom\","] #[doc = " \"alphabetic\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] #[serde(deny_unknown_fields)] pub enum BaselineValueVariant0ItemVariant2 {} impl From<&BaselineValueVariant0ItemVariant2> for BaselineValueVariant0ItemVariant2 { fn from(value: &BaselineValueVariant0ItemVariant2) -> Self { value.clone() } } #[doc = "BaselineValueVariant1"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/stringModifiers\""] #[doc = " },"] #[doc = " {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"enum\": ["] #[doc = " \"top\","] #[doc = " \"middle\","] #[doc = " \"bottom\","] #[doc = " \"alphabetic\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum BaselineValueVariant1 { Variant0(BaselineValueVariant1Variant0), Variant1(BaselineValueVariant1Variant1), Variant2(BaselineValueVariant1Variant2), Variant3 { offset: ::serde_json::Value }, } impl From<&BaselineValueVariant1> for BaselineValueVariant1 { fn from(value: &BaselineValueVariant1) -> Self { value.clone() } } impl From for BaselineValueVariant1 { fn from(value: BaselineValueVariant1Variant0) -> Self { Self::Variant0(value) } } impl From for BaselineValueVariant1 { fn from(value: BaselineValueVariant1Variant1) -> Self { Self::Variant1(value) } } impl From for BaselineValueVariant1 { fn from(value: BaselineValueVariant1Variant2) -> Self { Self::Variant2(value) } } #[doc = "BaselineValueVariant1Variant0"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"scale\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"enum\": ["] #[doc = " \"top\","] #[doc = " \"middle\","] #[doc = " \"bottom\","] #[doc = " \"alphabetic\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum BaselineValueVariant1Variant0 { Variant0 { #[serde(default, skip_serializing_if = "Option::is_none")] scale: Option, signal: String, }, Variant1 { #[serde(default, skip_serializing_if = "Option::is_none")] scale: Option, value: BaselineValueVariant1Variant0Variant1Value, }, Variant2 { field: Field, #[serde(default, skip_serializing_if = "Option::is_none")] scale: Option, }, Variant3 { range: BaselineValueVariant1Variant0Variant3Range, #[serde(default, skip_serializing_if = "Option::is_none")] scale: Option, }, } impl From<&BaselineValueVariant1Variant0> for BaselineValueVariant1Variant0 { fn from(value: &BaselineValueVariant1Variant0) -> Self { value.clone() } } #[doc = "BaselineValueVariant1Variant0Variant1Value"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"enum\": ["] #[doc = " \"top\","] #[doc = " \"middle\","] #[doc = " \"bottom\","] #[doc = " \"alphabetic\""] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] pub enum BaselineValueVariant1Variant0Variant1Value { #[serde(rename = "top")] Top, #[serde(rename = "middle")] Middle, #[serde(rename = "bottom")] Bottom, #[serde(rename = "alphabetic")] Alphabetic, } impl From<&BaselineValueVariant1Variant0Variant1Value> for BaselineValueVariant1Variant0Variant1Value { fn from(value: &BaselineValueVariant1Variant0Variant1Value) -> Self { value.clone() } } impl ::std::fmt::Display for BaselineValueVariant1Variant0Variant1Value { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match *self { Self::Top => write!(f, "top"), Self::Middle => write!(f, "middle"), Self::Bottom => write!(f, "bottom"), Self::Alphabetic => write!(f, "alphabetic"), } } } impl std::str::FromStr for BaselineValueVariant1Variant0Variant1Value { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { match value { "top" => Ok(Self::Top), "middle" => Ok(Self::Middle), "bottom" => Ok(Self::Bottom), "alphabetic" => Ok(Self::Alphabetic), _ => Err("invalid value".into()), } } } impl std::convert::TryFrom<&str> for BaselineValueVariant1Variant0Variant1Value { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for BaselineValueVariant1Variant0Variant1Value { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for BaselineValueVariant1Variant0Variant1Value { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } #[doc = "BaselineValueVariant1Variant0Variant3Range"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum BaselineValueVariant1Variant0Variant3Range { Variant0(f64), Variant1(bool), } impl From<&BaselineValueVariant1Variant0Variant3Range> for BaselineValueVariant1Variant0Variant3Range { fn from(value: &BaselineValueVariant1Variant0Variant3Range) -> Self { value.clone() } } impl std::str::FromStr for BaselineValueVariant1Variant0Variant3Range { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { if let Ok(v) = value.parse() { Ok(Self::Variant0(v)) } else if let Ok(v) = value.parse() { Ok(Self::Variant1(v)) } else { Err("string conversion failed for all variants".into()) } } } impl std::convert::TryFrom<&str> for BaselineValueVariant1Variant0Variant3Range { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for BaselineValueVariant1Variant0Variant3Range { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for BaselineValueVariant1Variant0Variant3Range { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } impl ::std::fmt::Display for BaselineValueVariant1Variant0Variant3Range { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match self { Self::Variant0(x) => x.fmt(f), Self::Variant1(x) => x.fmt(f), } } } impl From for BaselineValueVariant1Variant0Variant3Range { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for BaselineValueVariant1Variant0Variant3Range { fn from(value: bool) -> Self { Self::Variant1(value) } } #[doc = "BaselineValueVariant1Variant1"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"scale\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"enum\": ["] #[doc = " \"top\","] #[doc = " \"middle\","] #[doc = " \"bottom\","] #[doc = " \"alphabetic\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] #[serde(deny_unknown_fields)] pub enum BaselineValueVariant1Variant1 {} impl From<&BaselineValueVariant1Variant1> for BaselineValueVariant1Variant1 { fn from(value: &BaselineValueVariant1Variant1) -> Self { value.clone() } } #[doc = "BaselineValueVariant1Variant2"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"scale\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"enum\": ["] #[doc = " \"top\","] #[doc = " \"middle\","] #[doc = " \"bottom\","] #[doc = " \"alphabetic\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] #[serde(deny_unknown_fields)] pub enum BaselineValueVariant1Variant2 {} impl From<&BaselineValueVariant1Variant2> for BaselineValueVariant1Variant2 { fn from(value: &BaselineValueVariant1Variant2) -> Self { value.clone() } } #[doc = "BinTransform"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"extent\","] #[doc = " \"field\","] #[doc = " \"type\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"anchor\": {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"as\": {"] #[doc = " \"default\": ["] #[doc = " \"bin0\","] #[doc = " \"bin1\""] #[doc = " ],"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"maxItems\": 2,"] #[doc = " \"minItems\": 2"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"base\": {"] #[doc = " \"default\": 10,"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"divide\": {"] #[doc = " \"default\": ["] #[doc = " 5,"] #[doc = " 2"] #[doc = " ],"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"extent\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"maxItems\": 2,"] #[doc = " \"minItems\": 2"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"field\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/scaleField\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/paramField\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/expr\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"interval\": {"] #[doc = " \"default\": true,"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"maxbins\": {"] #[doc = " \"default\": 20,"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"minstep\": {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"name\": {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"nice\": {"] #[doc = " \"default\": true,"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"signal\": {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " \"span\": {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"step\": {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"steps\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"type\": {"] #[doc = " \"enum\": ["] #[doc = " \"bin\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(deny_unknown_fields)] pub struct BinTransform { #[serde(default, skip_serializing_if = "Option::is_none")] pub anchor: Option, #[serde(rename = "as", default = "defaults::bin_transform_as")] pub as_: BinTransformAs, #[serde(default = "defaults::bin_transform_base")] pub base: BinTransformBase, #[serde(default = "defaults::bin_transform_divide")] pub divide: BinTransformDivide, pub extent: BinTransformExtent, pub field: BinTransformField, #[serde(default = "defaults::bin_transform_interval")] pub interval: BinTransformInterval, #[serde(default = "defaults::bin_transform_maxbins")] pub maxbins: BinTransformMaxbins, #[serde(default, skip_serializing_if = "Option::is_none")] pub minstep: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub name: Option, #[serde(default = "defaults::bin_transform_nice")] pub nice: BinTransformNice, #[serde(default, skip_serializing_if = "Option::is_none")] pub signal: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub span: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub step: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub steps: Option, #[serde(rename = "type")] pub type_: BinTransformType, } impl From<&BinTransform> for BinTransform { fn from(value: &BinTransform) -> Self { value.clone() } } #[doc = "BinTransformAnchor"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum BinTransformAnchor { Variant0(f64), Variant1(SignalRef), } impl From<&BinTransformAnchor> for BinTransformAnchor { fn from(value: &BinTransformAnchor) -> Self { value.clone() } } impl From for BinTransformAnchor { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for BinTransformAnchor { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "BinTransformAs"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"default\": ["] #[doc = " \"bin0\","] #[doc = " \"bin1\""] #[doc = " ],"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"maxItems\": 2,"] #[doc = " \"minItems\": 2"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum BinTransformAs { Variant0([BinTransformAsVariant0Item; 2usize]), Variant1(SignalRef), } impl From<&BinTransformAs> for BinTransformAs { fn from(value: &BinTransformAs) -> Self { value.clone() } } impl Default for BinTransformAs { fn default() -> Self { BinTransformAs::Variant0([ BinTransformAsVariant0Item::Variant0("bin0".to_string()), BinTransformAsVariant0Item::Variant0("bin1".to_string()), ]) } } impl From<[BinTransformAsVariant0Item; 2usize]> for BinTransformAs { fn from(value: [BinTransformAsVariant0Item; 2usize]) -> Self { Self::Variant0(value) } } impl From for BinTransformAs { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "BinTransformAsVariant0Item"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum BinTransformAsVariant0Item { Variant0(String), Variant1(SignalRef), } impl From<&BinTransformAsVariant0Item> for BinTransformAsVariant0Item { fn from(value: &BinTransformAsVariant0Item) -> Self { value.clone() } } impl From for BinTransformAsVariant0Item { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "BinTransformBase"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"default\": 10,"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum BinTransformBase { Variant0(f64), Variant1(SignalRef), } impl From<&BinTransformBase> for BinTransformBase { fn from(value: &BinTransformBase) -> Self { value.clone() } } impl Default for BinTransformBase { fn default() -> Self { BinTransformBase::Variant0(10_f64) } } impl From for BinTransformBase { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for BinTransformBase { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "BinTransformDivide"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"default\": ["] #[doc = " 5,"] #[doc = " 2"] #[doc = " ],"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum BinTransformDivide { Variant0(Vec), Variant1(SignalRef), } impl From<&BinTransformDivide> for BinTransformDivide { fn from(value: &BinTransformDivide) -> Self { value.clone() } } impl Default for BinTransformDivide { fn default() -> Self { BinTransformDivide::Variant0(vec![ BinTransformDivideVariant0Item::Variant0(5_f64), BinTransformDivideVariant0Item::Variant0(2_f64), ]) } } impl From> for BinTransformDivide { fn from(value: Vec) -> Self { Self::Variant0(value) } } impl From for BinTransformDivide { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "BinTransformDivideVariant0Item"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum BinTransformDivideVariant0Item { Variant0(f64), Variant1(SignalRef), } impl From<&BinTransformDivideVariant0Item> for BinTransformDivideVariant0Item { fn from(value: &BinTransformDivideVariant0Item) -> Self { value.clone() } } impl From for BinTransformDivideVariant0Item { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for BinTransformDivideVariant0Item { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "BinTransformExtent"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"maxItems\": 2,"] #[doc = " \"minItems\": 2"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum BinTransformExtent { Variant0([BinTransformExtentVariant0Item; 2usize]), Variant1(SignalRef), } impl From<&BinTransformExtent> for BinTransformExtent { fn from(value: &BinTransformExtent) -> Self { value.clone() } } impl From<[BinTransformExtentVariant0Item; 2usize]> for BinTransformExtent { fn from(value: [BinTransformExtentVariant0Item; 2usize]) -> Self { Self::Variant0(value) } } impl From for BinTransformExtent { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "BinTransformExtentVariant0Item"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum BinTransformExtentVariant0Item { Variant0(f64), Variant1(SignalRef), } impl From<&BinTransformExtentVariant0Item> for BinTransformExtentVariant0Item { fn from(value: &BinTransformExtentVariant0Item) -> Self { value.clone() } } impl From for BinTransformExtentVariant0Item { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for BinTransformExtentVariant0Item { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "BinTransformField"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/scaleField\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/paramField\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/expr\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum BinTransformField { ScaleField(ScaleField), ParamField(ParamField), Expr(Expr), } impl From<&BinTransformField> for BinTransformField { fn from(value: &BinTransformField) -> Self { value.clone() } } impl From for BinTransformField { fn from(value: ScaleField) -> Self { Self::ScaleField(value) } } impl From for BinTransformField { fn from(value: ParamField) -> Self { Self::ParamField(value) } } impl From for BinTransformField { fn from(value: Expr) -> Self { Self::Expr(value) } } #[doc = "BinTransformInterval"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"default\": true,"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum BinTransformInterval { Variant0(bool), Variant1(SignalRef), } impl From<&BinTransformInterval> for BinTransformInterval { fn from(value: &BinTransformInterval) -> Self { value.clone() } } impl Default for BinTransformInterval { fn default() -> Self { BinTransformInterval::Variant0(true) } } impl From for BinTransformInterval { fn from(value: bool) -> Self { Self::Variant0(value) } } impl From for BinTransformInterval { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "BinTransformMaxbins"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"default\": 20,"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum BinTransformMaxbins { Variant0(f64), Variant1(SignalRef), } impl From<&BinTransformMaxbins> for BinTransformMaxbins { fn from(value: &BinTransformMaxbins) -> Self { value.clone() } } impl Default for BinTransformMaxbins { fn default() -> Self { BinTransformMaxbins::Variant0(20_f64) } } impl From for BinTransformMaxbins { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for BinTransformMaxbins { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "BinTransformMinstep"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum BinTransformMinstep { Variant0(f64), Variant1(SignalRef), } impl From<&BinTransformMinstep> for BinTransformMinstep { fn from(value: &BinTransformMinstep) -> Self { value.clone() } } impl From for BinTransformMinstep { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for BinTransformMinstep { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "BinTransformName"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum BinTransformName { Variant0(String), Variant1(SignalRef), } impl From<&BinTransformName> for BinTransformName { fn from(value: &BinTransformName) -> Self { value.clone() } } impl From for BinTransformName { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "BinTransformNice"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"default\": true,"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum BinTransformNice { Variant0(bool), Variant1(SignalRef), } impl From<&BinTransformNice> for BinTransformNice { fn from(value: &BinTransformNice) -> Self { value.clone() } } impl Default for BinTransformNice { fn default() -> Self { BinTransformNice::Variant0(true) } } impl From for BinTransformNice { fn from(value: bool) -> Self { Self::Variant0(value) } } impl From for BinTransformNice { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "BinTransformSpan"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum BinTransformSpan { Variant0(f64), Variant1(SignalRef), } impl From<&BinTransformSpan> for BinTransformSpan { fn from(value: &BinTransformSpan) -> Self { value.clone() } } impl From for BinTransformSpan { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for BinTransformSpan { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "BinTransformStep"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum BinTransformStep { Variant0(f64), Variant1(SignalRef), } impl From<&BinTransformStep> for BinTransformStep { fn from(value: &BinTransformStep) -> Self { value.clone() } } impl From for BinTransformStep { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for BinTransformStep { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "BinTransformSteps"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum BinTransformSteps { Variant0(Vec), Variant1(SignalRef), } impl From<&BinTransformSteps> for BinTransformSteps { fn from(value: &BinTransformSteps) -> Self { value.clone() } } impl From> for BinTransformSteps { fn from(value: Vec) -> Self { Self::Variant0(value) } } impl From for BinTransformSteps { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "BinTransformStepsVariant0Item"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum BinTransformStepsVariant0Item { Variant0(f64), Variant1(SignalRef), } impl From<&BinTransformStepsVariant0Item> for BinTransformStepsVariant0Item { fn from(value: &BinTransformStepsVariant0Item) -> Self { value.clone() } } impl From for BinTransformStepsVariant0Item { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for BinTransformStepsVariant0Item { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "BinTransformType"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"enum\": ["] #[doc = " \"bin\""] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] pub enum BinTransformType { #[serde(rename = "bin")] Bin, } impl From<&BinTransformType> for BinTransformType { fn from(value: &BinTransformType) -> Self { value.clone() } } impl ::std::fmt::Display for BinTransformType { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match *self { Self::Bin => write!(f, "bin"), } } } impl std::str::FromStr for BinTransformType { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { match value { "bin" => Ok(Self::Bin), _ => Err("invalid value".into()), } } } impl std::convert::TryFrom<&str> for BinTransformType { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for BinTransformType { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for BinTransformType { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } #[doc = "Bind"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"input\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"debounce\": {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " \"element\": {"] #[doc = " \"$ref\": \"#/definitions/element\""] #[doc = " },"] #[doc = " \"input\": {"] #[doc = " \"enum\": ["] #[doc = " \"checkbox\""] #[doc = " ]"] #[doc = " },"] #[doc = " \"name\": {"] #[doc = " \"type\": \"string\""] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"input\","] #[doc = " \"options\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"debounce\": {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " \"element\": {"] #[doc = " \"$ref\": \"#/definitions/element\""] #[doc = " },"] #[doc = " \"input\": {"] #[doc = " \"enum\": ["] #[doc = " \"radio\","] #[doc = " \"select\""] #[doc = " ]"] #[doc = " },"] #[doc = " \"labels\": {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"type\": \"string\""] #[doc = " }"] #[doc = " },"] #[doc = " \"name\": {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " \"options\": {"] #[doc = " \"type\": \"array\""] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"input\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"debounce\": {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " \"element\": {"] #[doc = " \"$ref\": \"#/definitions/element\""] #[doc = " },"] #[doc = " \"input\": {"] #[doc = " \"enum\": ["] #[doc = " \"range\""] #[doc = " ]"] #[doc = " },"] #[doc = " \"max\": {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " \"min\": {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " \"name\": {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " \"step\": {"] #[doc = " \"type\": \"number\""] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"input\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"debounce\": {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " \"element\": {"] #[doc = " \"$ref\": \"#/definitions/element\""] #[doc = " },"] #[doc = " \"input\": {"] #[doc = " \"not\": {"] #[doc = " \"enum\": ["] #[doc = " \"checkbox\","] #[doc = " \"radio\","] #[doc = " \"range\","] #[doc = " \"select\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " \"name\": {"] #[doc = " \"type\": \"string\""] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": true"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"element\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"debounce\": {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " \"element\": {"] #[doc = " \"$ref\": \"#/definitions/element\""] #[doc = " },"] #[doc = " \"event\": {"] #[doc = " \"type\": \"string\""] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged, deny_unknown_fields)] pub enum Bind { Variant0 { #[serde(default, skip_serializing_if = "Option::is_none")] debounce: Option, #[serde(default, skip_serializing_if = "Option::is_none")] element: Option, input: BindVariant0Input, #[serde(default, skip_serializing_if = "Option::is_none")] name: Option, }, Variant1 { #[serde(default, skip_serializing_if = "Option::is_none")] debounce: Option, #[serde(default, skip_serializing_if = "Option::is_none")] element: Option, input: BindVariant1Input, #[serde(default, skip_serializing_if = "Vec::is_empty")] labels: Vec, #[serde(default, skip_serializing_if = "Option::is_none")] name: Option, options: Vec<::serde_json::Value>, }, Variant2 { #[serde(default, skip_serializing_if = "Option::is_none")] debounce: Option, #[serde(default, skip_serializing_if = "Option::is_none")] element: Option, input: BindVariant2Input, #[serde(default, skip_serializing_if = "Option::is_none")] max: Option, #[serde(default, skip_serializing_if = "Option::is_none")] min: Option, #[serde(default, skip_serializing_if = "Option::is_none")] name: Option, #[serde(default, skip_serializing_if = "Option::is_none")] step: Option, }, Variant3 { #[serde(default, skip_serializing_if = "Option::is_none")] debounce: Option, #[serde(default, skip_serializing_if = "Option::is_none")] element: Option, input: BindVariant3Input, #[serde(default, skip_serializing_if = "Option::is_none")] name: Option, }, Variant4 { #[serde(default, skip_serializing_if = "Option::is_none")] debounce: Option, element: Element, #[serde(default, skip_serializing_if = "Option::is_none")] event: Option, }, } impl From<&Bind> for Bind { fn from(value: &Bind) -> Self { value.clone() } } #[doc = "BindVariant0Input"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"enum\": ["] #[doc = " \"checkbox\""] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] pub enum BindVariant0Input { #[serde(rename = "checkbox")] Checkbox, } impl From<&BindVariant0Input> for BindVariant0Input { fn from(value: &BindVariant0Input) -> Self { value.clone() } } impl ::std::fmt::Display for BindVariant0Input { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match *self { Self::Checkbox => write!(f, "checkbox"), } } } impl std::str::FromStr for BindVariant0Input { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { match value { "checkbox" => Ok(Self::Checkbox), _ => Err("invalid value".into()), } } } impl std::convert::TryFrom<&str> for BindVariant0Input { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for BindVariant0Input { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for BindVariant0Input { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } #[doc = "BindVariant1Input"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"enum\": ["] #[doc = " \"radio\","] #[doc = " \"select\""] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] pub enum BindVariant1Input { #[serde(rename = "radio")] Radio, #[serde(rename = "select")] Select, } impl From<&BindVariant1Input> for BindVariant1Input { fn from(value: &BindVariant1Input) -> Self { value.clone() } } impl ::std::fmt::Display for BindVariant1Input { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match *self { Self::Radio => write!(f, "radio"), Self::Select => write!(f, "select"), } } } impl std::str::FromStr for BindVariant1Input { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { match value { "radio" => Ok(Self::Radio), "select" => Ok(Self::Select), _ => Err("invalid value".into()), } } } impl std::convert::TryFrom<&str> for BindVariant1Input { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for BindVariant1Input { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for BindVariant1Input { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } #[doc = "BindVariant2Input"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"enum\": ["] #[doc = " \"range\""] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] pub enum BindVariant2Input { #[serde(rename = "range")] Range, } impl From<&BindVariant2Input> for BindVariant2Input { fn from(value: &BindVariant2Input) -> Self { value.clone() } } impl ::std::fmt::Display for BindVariant2Input { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match *self { Self::Range => write!(f, "range"), } } } impl std::str::FromStr for BindVariant2Input { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { match value { "range" => Ok(Self::Range), _ => Err("invalid value".into()), } } } impl std::convert::TryFrom<&str> for BindVariant2Input { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for BindVariant2Input { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for BindVariant2Input { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } #[doc = "BindVariant3Input"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"not\": {"] #[doc = " \"enum\": ["] #[doc = " \"checkbox\","] #[doc = " \"radio\","] #[doc = " \"range\","] #[doc = " \"select\""] #[doc = " ]"] #[doc = " }"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Serialize, Clone, Debug, Eq, Hash, Ord, PartialEq, PartialOrd)] pub struct BindVariant3Input(String); impl ::std::ops::Deref for BindVariant3Input { type Target = String; fn deref(&self) -> &String { &self.0 } } impl From for String { fn from(value: BindVariant3Input) -> Self { value.0 } } impl From<&BindVariant3Input> for BindVariant3Input { fn from(value: &BindVariant3Input) -> Self { value.clone() } } impl std::convert::TryFrom for BindVariant3Input { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { if [ "checkbox".to_string(), "radio".to_string(), "range".to_string(), "select".to_string(), ] .contains(&value) { Err("invalid value".into()) } else { Ok(Self(value)) } } } impl<'de> ::serde::Deserialize<'de> for BindVariant3Input { fn deserialize(deserializer: D) -> Result where D: ::serde::Deserializer<'de>, { Self::try_from(::deserialize(deserializer)?) .map_err(|e| ::custom(e.to_string())) } } #[doc = "BlendValue"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/rule\""] #[doc = " },"] #[doc = " {"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/stringModifiers\""] #[doc = " },"] #[doc = " {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"enum\": ["] #[doc = " null,"] #[doc = " \"multiply\","] #[doc = " \"screen\","] #[doc = " \"overlay\","] #[doc = " \"darken\","] #[doc = " \"lighten\","] #[doc = " \"color-dodge\","] #[doc = " \"color-burn\","] #[doc = " \"hard-light\","] #[doc = " \"soft-light\","] #[doc = " \"difference\","] #[doc = " \"exclusion\","] #[doc = " \"hue\","] #[doc = " \"saturation\","] #[doc = " \"color\","] #[doc = " \"luminosity\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/stringModifiers\""] #[doc = " },"] #[doc = " {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"enum\": ["] #[doc = " null,"] #[doc = " \"multiply\","] #[doc = " \"screen\","] #[doc = " \"overlay\","] #[doc = " \"darken\","] #[doc = " \"lighten\","] #[doc = " \"color-dodge\","] #[doc = " \"color-burn\","] #[doc = " \"hard-light\","] #[doc = " \"soft-light\","] #[doc = " \"difference\","] #[doc = " \"exclusion\","] #[doc = " \"hue\","] #[doc = " \"saturation\","] #[doc = " \"color\","] #[doc = " \"luminosity\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum BlendValue { Variant0(Vec), Variant1(BlendValueVariant1), } impl From<&BlendValue> for BlendValue { fn from(value: &BlendValue) -> Self { value.clone() } } impl From> for BlendValue { fn from(value: Vec) -> Self { Self::Variant0(value) } } impl From for BlendValue { fn from(value: BlendValueVariant1) -> Self { Self::Variant1(value) } } #[doc = "BlendValueVariant0Item"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/rule\""] #[doc = " },"] #[doc = " {"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/stringModifiers\""] #[doc = " },"] #[doc = " {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"enum\": ["] #[doc = " null,"] #[doc = " \"multiply\","] #[doc = " \"screen\","] #[doc = " \"overlay\","] #[doc = " \"darken\","] #[doc = " \"lighten\","] #[doc = " \"color-dodge\","] #[doc = " \"color-burn\","] #[doc = " \"hard-light\","] #[doc = " \"soft-light\","] #[doc = " \"difference\","] #[doc = " \"exclusion\","] #[doc = " \"hue\","] #[doc = " \"saturation\","] #[doc = " \"color\","] #[doc = " \"luminosity\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum BlendValueVariant0Item { Variant0(BlendValueVariant0ItemVariant0), Variant1(BlendValueVariant0ItemVariant1), Variant2(BlendValueVariant0ItemVariant2), Variant3 { offset: ::serde_json::Value, #[serde(default, skip_serializing_if = "Option::is_none")] test: Option, }, } impl From<&BlendValueVariant0Item> for BlendValueVariant0Item { fn from(value: &BlendValueVariant0Item) -> Self { value.clone() } } impl From for BlendValueVariant0Item { fn from(value: BlendValueVariant0ItemVariant0) -> Self { Self::Variant0(value) } } impl From for BlendValueVariant0Item { fn from(value: BlendValueVariant0ItemVariant1) -> Self { Self::Variant1(value) } } impl From for BlendValueVariant0Item { fn from(value: BlendValueVariant0ItemVariant2) -> Self { Self::Variant2(value) } } #[doc = "BlendValueVariant0ItemVariant0"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"scale\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " },"] #[doc = " \"test\": {"] #[doc = " \"type\": \"string\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"enum\": ["] #[doc = " null,"] #[doc = " \"multiply\","] #[doc = " \"screen\","] #[doc = " \"overlay\","] #[doc = " \"darken\","] #[doc = " \"lighten\","] #[doc = " \"color-dodge\","] #[doc = " \"color-burn\","] #[doc = " \"hard-light\","] #[doc = " \"soft-light\","] #[doc = " \"difference\","] #[doc = " \"exclusion\","] #[doc = " \"hue\","] #[doc = " \"saturation\","] #[doc = " \"color\","] #[doc = " \"luminosity\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum BlendValueVariant0ItemVariant0 { Variant0 { #[serde(default, skip_serializing_if = "Option::is_none")] scale: Option, signal: String, #[serde(default, skip_serializing_if = "Option::is_none")] test: Option, }, Variant1 { #[serde(default, skip_serializing_if = "Option::is_none")] scale: Option, #[serde(default, skip_serializing_if = "Option::is_none")] test: Option, value: Option, }, Variant2 { field: Field, #[serde(default, skip_serializing_if = "Option::is_none")] scale: Option, #[serde(default, skip_serializing_if = "Option::is_none")] test: Option, }, Variant3 { range: BlendValueVariant0ItemVariant0Variant3Range, #[serde(default, skip_serializing_if = "Option::is_none")] scale: Option, #[serde(default, skip_serializing_if = "Option::is_none")] test: Option, }, } impl From<&BlendValueVariant0ItemVariant0> for BlendValueVariant0ItemVariant0 { fn from(value: &BlendValueVariant0ItemVariant0) -> Self { value.clone() } } #[doc = "BlendValueVariant0ItemVariant0Variant1Value"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"enum\": ["] #[doc = " null,"] #[doc = " \"multiply\","] #[doc = " \"screen\","] #[doc = " \"overlay\","] #[doc = " \"darken\","] #[doc = " \"lighten\","] #[doc = " \"color-dodge\","] #[doc = " \"color-burn\","] #[doc = " \"hard-light\","] #[doc = " \"soft-light\","] #[doc = " \"difference\","] #[doc = " \"exclusion\","] #[doc = " \"hue\","] #[doc = " \"saturation\","] #[doc = " \"color\","] #[doc = " \"luminosity\""] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] pub enum BlendValueVariant0ItemVariant0Variant1Value { #[serde(rename = "multiply")] Multiply, #[serde(rename = "screen")] Screen, #[serde(rename = "overlay")] Overlay, #[serde(rename = "darken")] Darken, #[serde(rename = "lighten")] Lighten, #[serde(rename = "color-dodge")] ColorDodge, #[serde(rename = "color-burn")] ColorBurn, #[serde(rename = "hard-light")] HardLight, #[serde(rename = "soft-light")] SoftLight, #[serde(rename = "difference")] Difference, #[serde(rename = "exclusion")] Exclusion, #[serde(rename = "hue")] Hue, #[serde(rename = "saturation")] Saturation, #[serde(rename = "color")] Color, #[serde(rename = "luminosity")] Luminosity, } impl From<&BlendValueVariant0ItemVariant0Variant1Value> for BlendValueVariant0ItemVariant0Variant1Value { fn from(value: &BlendValueVariant0ItemVariant0Variant1Value) -> Self { value.clone() } } impl ::std::fmt::Display for BlendValueVariant0ItemVariant0Variant1Value { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match *self { Self::Multiply => write!(f, "multiply"), Self::Screen => write!(f, "screen"), Self::Overlay => write!(f, "overlay"), Self::Darken => write!(f, "darken"), Self::Lighten => write!(f, "lighten"), Self::ColorDodge => write!(f, "color-dodge"), Self::ColorBurn => write!(f, "color-burn"), Self::HardLight => write!(f, "hard-light"), Self::SoftLight => write!(f, "soft-light"), Self::Difference => write!(f, "difference"), Self::Exclusion => write!(f, "exclusion"), Self::Hue => write!(f, "hue"), Self::Saturation => write!(f, "saturation"), Self::Color => write!(f, "color"), Self::Luminosity => write!(f, "luminosity"), } } } impl std::str::FromStr for BlendValueVariant0ItemVariant0Variant1Value { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { match value { "multiply" => Ok(Self::Multiply), "screen" => Ok(Self::Screen), "overlay" => Ok(Self::Overlay), "darken" => Ok(Self::Darken), "lighten" => Ok(Self::Lighten), "color-dodge" => Ok(Self::ColorDodge), "color-burn" => Ok(Self::ColorBurn), "hard-light" => Ok(Self::HardLight), "soft-light" => Ok(Self::SoftLight), "difference" => Ok(Self::Difference), "exclusion" => Ok(Self::Exclusion), "hue" => Ok(Self::Hue), "saturation" => Ok(Self::Saturation), "color" => Ok(Self::Color), "luminosity" => Ok(Self::Luminosity), _ => Err("invalid value".into()), } } } impl std::convert::TryFrom<&str> for BlendValueVariant0ItemVariant0Variant1Value { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for BlendValueVariant0ItemVariant0Variant1Value { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for BlendValueVariant0ItemVariant0Variant1Value { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } #[doc = "BlendValueVariant0ItemVariant0Variant3Range"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum BlendValueVariant0ItemVariant0Variant3Range { Variant0(f64), Variant1(bool), } impl From<&BlendValueVariant0ItemVariant0Variant3Range> for BlendValueVariant0ItemVariant0Variant3Range { fn from(value: &BlendValueVariant0ItemVariant0Variant3Range) -> Self { value.clone() } } impl std::str::FromStr for BlendValueVariant0ItemVariant0Variant3Range { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { if let Ok(v) = value.parse() { Ok(Self::Variant0(v)) } else if let Ok(v) = value.parse() { Ok(Self::Variant1(v)) } else { Err("string conversion failed for all variants".into()) } } } impl std::convert::TryFrom<&str> for BlendValueVariant0ItemVariant0Variant3Range { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for BlendValueVariant0ItemVariant0Variant3Range { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for BlendValueVariant0ItemVariant0Variant3Range { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } impl ::std::fmt::Display for BlendValueVariant0ItemVariant0Variant3Range { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match self { Self::Variant0(x) => x.fmt(f), Self::Variant1(x) => x.fmt(f), } } } impl From for BlendValueVariant0ItemVariant0Variant3Range { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for BlendValueVariant0ItemVariant0Variant3Range { fn from(value: bool) -> Self { Self::Variant1(value) } } #[doc = "BlendValueVariant0ItemVariant1"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"scale\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " },"] #[doc = " \"test\": {"] #[doc = " \"type\": \"string\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"enum\": ["] #[doc = " null,"] #[doc = " \"multiply\","] #[doc = " \"screen\","] #[doc = " \"overlay\","] #[doc = " \"darken\","] #[doc = " \"lighten\","] #[doc = " \"color-dodge\","] #[doc = " \"color-burn\","] #[doc = " \"hard-light\","] #[doc = " \"soft-light\","] #[doc = " \"difference\","] #[doc = " \"exclusion\","] #[doc = " \"hue\","] #[doc = " \"saturation\","] #[doc = " \"color\","] #[doc = " \"luminosity\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] #[serde(deny_unknown_fields)] pub enum BlendValueVariant0ItemVariant1 {} impl From<&BlendValueVariant0ItemVariant1> for BlendValueVariant0ItemVariant1 { fn from(value: &BlendValueVariant0ItemVariant1) -> Self { value.clone() } } #[doc = "BlendValueVariant0ItemVariant2"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"scale\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " },"] #[doc = " \"test\": {"] #[doc = " \"type\": \"string\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"enum\": ["] #[doc = " null,"] #[doc = " \"multiply\","] #[doc = " \"screen\","] #[doc = " \"overlay\","] #[doc = " \"darken\","] #[doc = " \"lighten\","] #[doc = " \"color-dodge\","] #[doc = " \"color-burn\","] #[doc = " \"hard-light\","] #[doc = " \"soft-light\","] #[doc = " \"difference\","] #[doc = " \"exclusion\","] #[doc = " \"hue\","] #[doc = " \"saturation\","] #[doc = " \"color\","] #[doc = " \"luminosity\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] #[serde(deny_unknown_fields)] pub enum BlendValueVariant0ItemVariant2 {} impl From<&BlendValueVariant0ItemVariant2> for BlendValueVariant0ItemVariant2 { fn from(value: &BlendValueVariant0ItemVariant2) -> Self { value.clone() } } #[doc = "BlendValueVariant1"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/stringModifiers\""] #[doc = " },"] #[doc = " {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"enum\": ["] #[doc = " null,"] #[doc = " \"multiply\","] #[doc = " \"screen\","] #[doc = " \"overlay\","] #[doc = " \"darken\","] #[doc = " \"lighten\","] #[doc = " \"color-dodge\","] #[doc = " \"color-burn\","] #[doc = " \"hard-light\","] #[doc = " \"soft-light\","] #[doc = " \"difference\","] #[doc = " \"exclusion\","] #[doc = " \"hue\","] #[doc = " \"saturation\","] #[doc = " \"color\","] #[doc = " \"luminosity\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum BlendValueVariant1 { Variant0(BlendValueVariant1Variant0), Variant1(BlendValueVariant1Variant1), Variant2(BlendValueVariant1Variant2), Variant3 { offset: ::serde_json::Value }, } impl From<&BlendValueVariant1> for BlendValueVariant1 { fn from(value: &BlendValueVariant1) -> Self { value.clone() } } impl From for BlendValueVariant1 { fn from(value: BlendValueVariant1Variant0) -> Self { Self::Variant0(value) } } impl From for BlendValueVariant1 { fn from(value: BlendValueVariant1Variant1) -> Self { Self::Variant1(value) } } impl From for BlendValueVariant1 { fn from(value: BlendValueVariant1Variant2) -> Self { Self::Variant2(value) } } #[doc = "BlendValueVariant1Variant0"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"scale\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"enum\": ["] #[doc = " null,"] #[doc = " \"multiply\","] #[doc = " \"screen\","] #[doc = " \"overlay\","] #[doc = " \"darken\","] #[doc = " \"lighten\","] #[doc = " \"color-dodge\","] #[doc = " \"color-burn\","] #[doc = " \"hard-light\","] #[doc = " \"soft-light\","] #[doc = " \"difference\","] #[doc = " \"exclusion\","] #[doc = " \"hue\","] #[doc = " \"saturation\","] #[doc = " \"color\","] #[doc = " \"luminosity\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum BlendValueVariant1Variant0 { Variant0 { #[serde(default, skip_serializing_if = "Option::is_none")] scale: Option, signal: String, }, Variant1 { #[serde(default, skip_serializing_if = "Option::is_none")] scale: Option, value: Option, }, Variant2 { field: Field, #[serde(default, skip_serializing_if = "Option::is_none")] scale: Option, }, Variant3 { range: BlendValueVariant1Variant0Variant3Range, #[serde(default, skip_serializing_if = "Option::is_none")] scale: Option, }, } impl From<&BlendValueVariant1Variant0> for BlendValueVariant1Variant0 { fn from(value: &BlendValueVariant1Variant0) -> Self { value.clone() } } #[doc = "BlendValueVariant1Variant0Variant1Value"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"enum\": ["] #[doc = " null,"] #[doc = " \"multiply\","] #[doc = " \"screen\","] #[doc = " \"overlay\","] #[doc = " \"darken\","] #[doc = " \"lighten\","] #[doc = " \"color-dodge\","] #[doc = " \"color-burn\","] #[doc = " \"hard-light\","] #[doc = " \"soft-light\","] #[doc = " \"difference\","] #[doc = " \"exclusion\","] #[doc = " \"hue\","] #[doc = " \"saturation\","] #[doc = " \"color\","] #[doc = " \"luminosity\""] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] pub enum BlendValueVariant1Variant0Variant1Value { #[serde(rename = "multiply")] Multiply, #[serde(rename = "screen")] Screen, #[serde(rename = "overlay")] Overlay, #[serde(rename = "darken")] Darken, #[serde(rename = "lighten")] Lighten, #[serde(rename = "color-dodge")] ColorDodge, #[serde(rename = "color-burn")] ColorBurn, #[serde(rename = "hard-light")] HardLight, #[serde(rename = "soft-light")] SoftLight, #[serde(rename = "difference")] Difference, #[serde(rename = "exclusion")] Exclusion, #[serde(rename = "hue")] Hue, #[serde(rename = "saturation")] Saturation, #[serde(rename = "color")] Color, #[serde(rename = "luminosity")] Luminosity, } impl From<&BlendValueVariant1Variant0Variant1Value> for BlendValueVariant1Variant0Variant1Value { fn from(value: &BlendValueVariant1Variant0Variant1Value) -> Self { value.clone() } } impl ::std::fmt::Display for BlendValueVariant1Variant0Variant1Value { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match *self { Self::Multiply => write!(f, "multiply"), Self::Screen => write!(f, "screen"), Self::Overlay => write!(f, "overlay"), Self::Darken => write!(f, "darken"), Self::Lighten => write!(f, "lighten"), Self::ColorDodge => write!(f, "color-dodge"), Self::ColorBurn => write!(f, "color-burn"), Self::HardLight => write!(f, "hard-light"), Self::SoftLight => write!(f, "soft-light"), Self::Difference => write!(f, "difference"), Self::Exclusion => write!(f, "exclusion"), Self::Hue => write!(f, "hue"), Self::Saturation => write!(f, "saturation"), Self::Color => write!(f, "color"), Self::Luminosity => write!(f, "luminosity"), } } } impl std::str::FromStr for BlendValueVariant1Variant0Variant1Value { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { match value { "multiply" => Ok(Self::Multiply), "screen" => Ok(Self::Screen), "overlay" => Ok(Self::Overlay), "darken" => Ok(Self::Darken), "lighten" => Ok(Self::Lighten), "color-dodge" => Ok(Self::ColorDodge), "color-burn" => Ok(Self::ColorBurn), "hard-light" => Ok(Self::HardLight), "soft-light" => Ok(Self::SoftLight), "difference" => Ok(Self::Difference), "exclusion" => Ok(Self::Exclusion), "hue" => Ok(Self::Hue), "saturation" => Ok(Self::Saturation), "color" => Ok(Self::Color), "luminosity" => Ok(Self::Luminosity), _ => Err("invalid value".into()), } } } impl std::convert::TryFrom<&str> for BlendValueVariant1Variant0Variant1Value { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for BlendValueVariant1Variant0Variant1Value { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for BlendValueVariant1Variant0Variant1Value { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } #[doc = "BlendValueVariant1Variant0Variant3Range"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum BlendValueVariant1Variant0Variant3Range { Variant0(f64), Variant1(bool), } impl From<&BlendValueVariant1Variant0Variant3Range> for BlendValueVariant1Variant0Variant3Range { fn from(value: &BlendValueVariant1Variant0Variant3Range) -> Self { value.clone() } } impl std::str::FromStr for BlendValueVariant1Variant0Variant3Range { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { if let Ok(v) = value.parse() { Ok(Self::Variant0(v)) } else if let Ok(v) = value.parse() { Ok(Self::Variant1(v)) } else { Err("string conversion failed for all variants".into()) } } } impl std::convert::TryFrom<&str> for BlendValueVariant1Variant0Variant3Range { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for BlendValueVariant1Variant0Variant3Range { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for BlendValueVariant1Variant0Variant3Range { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } impl ::std::fmt::Display for BlendValueVariant1Variant0Variant3Range { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match self { Self::Variant0(x) => x.fmt(f), Self::Variant1(x) => x.fmt(f), } } } impl From for BlendValueVariant1Variant0Variant3Range { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for BlendValueVariant1Variant0Variant3Range { fn from(value: bool) -> Self { Self::Variant1(value) } } #[doc = "BlendValueVariant1Variant1"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"scale\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"enum\": ["] #[doc = " null,"] #[doc = " \"multiply\","] #[doc = " \"screen\","] #[doc = " \"overlay\","] #[doc = " \"darken\","] #[doc = " \"lighten\","] #[doc = " \"color-dodge\","] #[doc = " \"color-burn\","] #[doc = " \"hard-light\","] #[doc = " \"soft-light\","] #[doc = " \"difference\","] #[doc = " \"exclusion\","] #[doc = " \"hue\","] #[doc = " \"saturation\","] #[doc = " \"color\","] #[doc = " \"luminosity\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] #[serde(deny_unknown_fields)] pub enum BlendValueVariant1Variant1 {} impl From<&BlendValueVariant1Variant1> for BlendValueVariant1Variant1 { fn from(value: &BlendValueVariant1Variant1) -> Self { value.clone() } } #[doc = "BlendValueVariant1Variant2"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"scale\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"enum\": ["] #[doc = " null,"] #[doc = " \"multiply\","] #[doc = " \"screen\","] #[doc = " \"overlay\","] #[doc = " \"darken\","] #[doc = " \"lighten\","] #[doc = " \"color-dodge\","] #[doc = " \"color-burn\","] #[doc = " \"hard-light\","] #[doc = " \"soft-light\","] #[doc = " \"difference\","] #[doc = " \"exclusion\","] #[doc = " \"hue\","] #[doc = " \"saturation\","] #[doc = " \"color\","] #[doc = " \"luminosity\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] #[serde(deny_unknown_fields)] pub enum BlendValueVariant1Variant2 {} impl From<&BlendValueVariant1Variant2> for BlendValueVariant1Variant2 { fn from(value: &BlendValueVariant1Variant2) -> Self { value.clone() } } #[doc = "BooleanOrSignal"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum BooleanOrSignal { Variant0(bool), Variant1(SignalRef), } impl From<&BooleanOrSignal> for BooleanOrSignal { fn from(value: &BooleanOrSignal) -> Self { value.clone() } } impl From for BooleanOrSignal { fn from(value: bool) -> Self { Self::Variant0(value) } } impl From for BooleanOrSignal { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "BooleanValue"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/rule\""] #[doc = " },"] #[doc = " {"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/stringModifiers\""] #[doc = " },"] #[doc = " {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/stringModifiers\""] #[doc = " },"] #[doc = " {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum BooleanValue { Variant0(Vec), Variant1(BooleanValueVariant1), } impl From<&BooleanValue> for BooleanValue { fn from(value: &BooleanValue) -> Self { value.clone() } } impl From> for BooleanValue { fn from(value: Vec) -> Self { Self::Variant0(value) } } impl From for BooleanValue { fn from(value: BooleanValueVariant1) -> Self { Self::Variant1(value) } } #[doc = "BooleanValueVariant0Item"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/rule\""] #[doc = " },"] #[doc = " {"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/stringModifiers\""] #[doc = " },"] #[doc = " {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum BooleanValueVariant0Item { Variant0(BooleanValueVariant0ItemVariant0), Variant1(BooleanValueVariant0ItemVariant1), Variant2(BooleanValueVariant0ItemVariant2), Variant3 { offset: ::serde_json::Value, #[serde(default, skip_serializing_if = "Option::is_none")] test: Option, }, } impl From<&BooleanValueVariant0Item> for BooleanValueVariant0Item { fn from(value: &BooleanValueVariant0Item) -> Self { value.clone() } } impl From for BooleanValueVariant0Item { fn from(value: BooleanValueVariant0ItemVariant0) -> Self { Self::Variant0(value) } } impl From for BooleanValueVariant0Item { fn from(value: BooleanValueVariant0ItemVariant1) -> Self { Self::Variant1(value) } } impl From for BooleanValueVariant0Item { fn from(value: BooleanValueVariant0ItemVariant2) -> Self { Self::Variant2(value) } } #[doc = "BooleanValueVariant0ItemVariant0"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"scale\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " },"] #[doc = " \"test\": {"] #[doc = " \"type\": \"string\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum BooleanValueVariant0ItemVariant0 { Variant0 { #[serde(default, skip_serializing_if = "Option::is_none")] scale: Option, signal: String, #[serde(default, skip_serializing_if = "Option::is_none")] test: Option, }, Variant1 { #[serde(default, skip_serializing_if = "Option::is_none")] scale: Option, #[serde(default, skip_serializing_if = "Option::is_none")] test: Option, value: bool, }, Variant2 { field: Field, #[serde(default, skip_serializing_if = "Option::is_none")] scale: Option, #[serde(default, skip_serializing_if = "Option::is_none")] test: Option, }, Variant3 { range: BooleanValueVariant0ItemVariant0Variant3Range, #[serde(default, skip_serializing_if = "Option::is_none")] scale: Option, #[serde(default, skip_serializing_if = "Option::is_none")] test: Option, }, } impl From<&BooleanValueVariant0ItemVariant0> for BooleanValueVariant0ItemVariant0 { fn from(value: &BooleanValueVariant0ItemVariant0) -> Self { value.clone() } } #[doc = "BooleanValueVariant0ItemVariant0Variant3Range"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum BooleanValueVariant0ItemVariant0Variant3Range { Variant0(f64), Variant1(bool), } impl From<&BooleanValueVariant0ItemVariant0Variant3Range> for BooleanValueVariant0ItemVariant0Variant3Range { fn from(value: &BooleanValueVariant0ItemVariant0Variant3Range) -> Self { value.clone() } } impl std::str::FromStr for BooleanValueVariant0ItemVariant0Variant3Range { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { if let Ok(v) = value.parse() { Ok(Self::Variant0(v)) } else if let Ok(v) = value.parse() { Ok(Self::Variant1(v)) } else { Err("string conversion failed for all variants".into()) } } } impl std::convert::TryFrom<&str> for BooleanValueVariant0ItemVariant0Variant3Range { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for BooleanValueVariant0ItemVariant0Variant3Range { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for BooleanValueVariant0ItemVariant0Variant3Range { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } impl ::std::fmt::Display for BooleanValueVariant0ItemVariant0Variant3Range { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match self { Self::Variant0(x) => x.fmt(f), Self::Variant1(x) => x.fmt(f), } } } impl From for BooleanValueVariant0ItemVariant0Variant3Range { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for BooleanValueVariant0ItemVariant0Variant3Range { fn from(value: bool) -> Self { Self::Variant1(value) } } #[doc = "BooleanValueVariant0ItemVariant1"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"scale\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " },"] #[doc = " \"test\": {"] #[doc = " \"type\": \"string\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] #[serde(deny_unknown_fields)] pub enum BooleanValueVariant0ItemVariant1 {} impl From<&BooleanValueVariant0ItemVariant1> for BooleanValueVariant0ItemVariant1 { fn from(value: &BooleanValueVariant0ItemVariant1) -> Self { value.clone() } } #[doc = "BooleanValueVariant0ItemVariant2"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"scale\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " },"] #[doc = " \"test\": {"] #[doc = " \"type\": \"string\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] #[serde(deny_unknown_fields)] pub enum BooleanValueVariant0ItemVariant2 {} impl From<&BooleanValueVariant0ItemVariant2> for BooleanValueVariant0ItemVariant2 { fn from(value: &BooleanValueVariant0ItemVariant2) -> Self { value.clone() } } #[doc = "BooleanValueVariant1"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/stringModifiers\""] #[doc = " },"] #[doc = " {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum BooleanValueVariant1 { Variant0(BooleanValueVariant1Variant0), Variant1(BooleanValueVariant1Variant1), Variant2(BooleanValueVariant1Variant2), Variant3 { offset: ::serde_json::Value }, } impl From<&BooleanValueVariant1> for BooleanValueVariant1 { fn from(value: &BooleanValueVariant1) -> Self { value.clone() } } impl From for BooleanValueVariant1 { fn from(value: BooleanValueVariant1Variant0) -> Self { Self::Variant0(value) } } impl From for BooleanValueVariant1 { fn from(value: BooleanValueVariant1Variant1) -> Self { Self::Variant1(value) } } impl From for BooleanValueVariant1 { fn from(value: BooleanValueVariant1Variant2) -> Self { Self::Variant2(value) } } #[doc = "BooleanValueVariant1Variant0"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"scale\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum BooleanValueVariant1Variant0 { Variant0 { #[serde(default, skip_serializing_if = "Option::is_none")] scale: Option, signal: String, }, Variant1 { #[serde(default, skip_serializing_if = "Option::is_none")] scale: Option, value: bool, }, Variant2 { field: Field, #[serde(default, skip_serializing_if = "Option::is_none")] scale: Option, }, Variant3 { range: BooleanValueVariant1Variant0Variant3Range, #[serde(default, skip_serializing_if = "Option::is_none")] scale: Option, }, } impl From<&BooleanValueVariant1Variant0> for BooleanValueVariant1Variant0 { fn from(value: &BooleanValueVariant1Variant0) -> Self { value.clone() } } #[doc = "BooleanValueVariant1Variant0Variant3Range"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum BooleanValueVariant1Variant0Variant3Range { Variant0(f64), Variant1(bool), } impl From<&BooleanValueVariant1Variant0Variant3Range> for BooleanValueVariant1Variant0Variant3Range { fn from(value: &BooleanValueVariant1Variant0Variant3Range) -> Self { value.clone() } } impl std::str::FromStr for BooleanValueVariant1Variant0Variant3Range { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { if let Ok(v) = value.parse() { Ok(Self::Variant0(v)) } else if let Ok(v) = value.parse() { Ok(Self::Variant1(v)) } else { Err("string conversion failed for all variants".into()) } } } impl std::convert::TryFrom<&str> for BooleanValueVariant1Variant0Variant3Range { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for BooleanValueVariant1Variant0Variant3Range { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for BooleanValueVariant1Variant0Variant3Range { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } impl ::std::fmt::Display for BooleanValueVariant1Variant0Variant3Range { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match self { Self::Variant0(x) => x.fmt(f), Self::Variant1(x) => x.fmt(f), } } } impl From for BooleanValueVariant1Variant0Variant3Range { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for BooleanValueVariant1Variant0Variant3Range { fn from(value: bool) -> Self { Self::Variant1(value) } } #[doc = "BooleanValueVariant1Variant1"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"scale\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] #[serde(deny_unknown_fields)] pub enum BooleanValueVariant1Variant1 {} impl From<&BooleanValueVariant1Variant1> for BooleanValueVariant1Variant1 { fn from(value: &BooleanValueVariant1Variant1) -> Self { value.clone() } } #[doc = "BooleanValueVariant1Variant2"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"scale\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] #[serde(deny_unknown_fields)] pub enum BooleanValueVariant1Variant2 {} impl From<&BooleanValueVariant1Variant2> for BooleanValueVariant1Variant2 { fn from(value: &BooleanValueVariant1Variant2) -> Self { value.clone() } } #[doc = "CollectTransform"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"type\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"signal\": {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " \"sort\": {"] #[doc = " \"$ref\": \"#/definitions/compare\""] #[doc = " },"] #[doc = " \"type\": {"] #[doc = " \"enum\": ["] #[doc = " \"collect\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(deny_unknown_fields)] pub struct CollectTransform { #[serde(default, skip_serializing_if = "Option::is_none")] pub signal: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub sort: Option, #[serde(rename = "type")] pub type_: CollectTransformType, } impl From<&CollectTransform> for CollectTransform { fn from(value: &CollectTransform) -> Self { value.clone() } } #[doc = "CollectTransformType"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"enum\": ["] #[doc = " \"collect\""] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] pub enum CollectTransformType { #[serde(rename = "collect")] Collect, } impl From<&CollectTransformType> for CollectTransformType { fn from(value: &CollectTransformType) -> Self { value.clone() } } impl ::std::fmt::Display for CollectTransformType { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match *self { Self::Collect => write!(f, "collect"), } } } impl std::str::FromStr for CollectTransformType { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { match value { "collect" => Ok(Self::Collect), _ => Err("invalid value".into()), } } } impl std::convert::TryFrom<&str> for CollectTransformType { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for CollectTransformType { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for CollectTransformType { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } #[doc = "ColorHcl"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"c\","] #[doc = " \"h\","] #[doc = " \"l\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"c\": {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " },"] #[doc = " \"h\": {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " },"] #[doc = " \"l\": {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " }"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] pub struct ColorHcl { pub c: NumberValue, pub h: NumberValue, pub l: NumberValue, } impl From<&ColorHcl> for ColorHcl { fn from(value: &ColorHcl) -> Self { value.clone() } } #[doc = "ColorHsl"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"h\","] #[doc = " \"l\","] #[doc = " \"s\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"h\": {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " },"] #[doc = " \"l\": {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " },"] #[doc = " \"s\": {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " }"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] pub struct ColorHsl { pub h: NumberValue, pub l: NumberValue, pub s: NumberValue, } impl From<&ColorHsl> for ColorHsl { fn from(value: &ColorHsl) -> Self { value.clone() } } #[doc = "ColorLab"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"a\","] #[doc = " \"b\","] #[doc = " \"l\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"a\": {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " },"] #[doc = " \"b\": {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " },"] #[doc = " \"l\": {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " }"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] pub struct ColorLab { pub a: NumberValue, pub b: NumberValue, pub l: NumberValue, } impl From<&ColorLab> for ColorLab { fn from(value: &ColorLab) -> Self { value.clone() } } #[doc = "ColorRgb"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"b\","] #[doc = " \"g\","] #[doc = " \"r\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"b\": {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " },"] #[doc = " \"g\": {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " },"] #[doc = " \"r\": {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " }"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] pub struct ColorRgb { pub b: NumberValue, pub g: NumberValue, pub r: NumberValue, } impl From<&ColorRgb> for ColorRgb { fn from(value: &ColorRgb) -> Self { value.clone() } } #[doc = "Compare"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/scaleField\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/expr\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"order\": {"] #[doc = " \"$ref\": \"#/definitions/sortOrder\""] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/scaleField\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/expr\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " \"order\": {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"$ref\": \"#/definitions/sortOrder\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged, deny_unknown_fields)] pub enum Compare { Variant0 { #[serde(default, skip_serializing_if = "Option::is_none")] field: Option, #[serde(default, skip_serializing_if = "Option::is_none")] order: Option, }, Variant1 { #[serde(default, skip_serializing_if = "Vec::is_empty")] field: Vec, #[serde(default, skip_serializing_if = "Vec::is_empty")] order: Vec, }, } impl From<&Compare> for Compare { fn from(value: &Compare) -> Self { value.clone() } } #[doc = "CompareVariant0Field"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/scaleField\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/expr\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum CompareVariant0Field { ScaleField(ScaleField), Expr(Expr), } impl From<&CompareVariant0Field> for CompareVariant0Field { fn from(value: &CompareVariant0Field) -> Self { value.clone() } } impl From for CompareVariant0Field { fn from(value: ScaleField) -> Self { Self::ScaleField(value) } } impl From for CompareVariant0Field { fn from(value: Expr) -> Self { Self::Expr(value) } } #[doc = "CompareVariant1FieldItem"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/scaleField\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/expr\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum CompareVariant1FieldItem { ScaleField(ScaleField), Expr(Expr), } impl From<&CompareVariant1FieldItem> for CompareVariant1FieldItem { fn from(value: &CompareVariant1FieldItem) -> Self { value.clone() } } impl From for CompareVariant1FieldItem { fn from(value: ScaleField) -> Self { Self::ScaleField(value) } } impl From for CompareVariant1FieldItem { fn from(value: Expr) -> Self { Self::Expr(value) } } #[doc = "ContourTransform"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"size\","] #[doc = " \"type\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"bandwidth\": {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"cellSize\": {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"count\": {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"nice\": {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"signal\": {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " \"size\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"maxItems\": 2,"] #[doc = " \"minItems\": 2"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"smooth\": {"] #[doc = " \"default\": true,"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"thresholds\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"type\": {"] #[doc = " \"enum\": ["] #[doc = " \"contour\""] #[doc = " ]"] #[doc = " },"] #[doc = " \"values\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"weight\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/scaleField\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/paramField\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/expr\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"x\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/scaleField\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/paramField\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/expr\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"y\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/scaleField\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/paramField\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/expr\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(deny_unknown_fields)] pub struct ContourTransform { #[serde(default, skip_serializing_if = "Option::is_none")] pub bandwidth: Option, #[serde(rename = "cellSize", default, skip_serializing_if = "Option::is_none")] pub cell_size: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub count: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub nice: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub signal: Option, pub size: ContourTransformSize, #[serde(default = "defaults::contour_transform_smooth")] pub smooth: ContourTransformSmooth, #[serde(default, skip_serializing_if = "Option::is_none")] pub thresholds: Option, #[serde(rename = "type")] pub type_: ContourTransformType, #[serde(default, skip_serializing_if = "Option::is_none")] pub values: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub weight: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub x: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub y: Option, } impl From<&ContourTransform> for ContourTransform { fn from(value: &ContourTransform) -> Self { value.clone() } } #[doc = "ContourTransformBandwidth"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum ContourTransformBandwidth { Variant0(f64), Variant1(SignalRef), } impl From<&ContourTransformBandwidth> for ContourTransformBandwidth { fn from(value: &ContourTransformBandwidth) -> Self { value.clone() } } impl From for ContourTransformBandwidth { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for ContourTransformBandwidth { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "ContourTransformCellSize"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum ContourTransformCellSize { Variant0(f64), Variant1(SignalRef), } impl From<&ContourTransformCellSize> for ContourTransformCellSize { fn from(value: &ContourTransformCellSize) -> Self { value.clone() } } impl From for ContourTransformCellSize { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for ContourTransformCellSize { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "ContourTransformCount"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum ContourTransformCount { Variant0(f64), Variant1(SignalRef), } impl From<&ContourTransformCount> for ContourTransformCount { fn from(value: &ContourTransformCount) -> Self { value.clone() } } impl From for ContourTransformCount { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for ContourTransformCount { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "ContourTransformNice"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum ContourTransformNice { Variant0(bool), Variant1(SignalRef), } impl From<&ContourTransformNice> for ContourTransformNice { fn from(value: &ContourTransformNice) -> Self { value.clone() } } impl From for ContourTransformNice { fn from(value: bool) -> Self { Self::Variant0(value) } } impl From for ContourTransformNice { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "ContourTransformSize"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"maxItems\": 2,"] #[doc = " \"minItems\": 2"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum ContourTransformSize { Variant0([ContourTransformSizeVariant0Item; 2usize]), Variant1(SignalRef), } impl From<&ContourTransformSize> for ContourTransformSize { fn from(value: &ContourTransformSize) -> Self { value.clone() } } impl From<[ContourTransformSizeVariant0Item; 2usize]> for ContourTransformSize { fn from(value: [ContourTransformSizeVariant0Item; 2usize]) -> Self { Self::Variant0(value) } } impl From for ContourTransformSize { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "ContourTransformSizeVariant0Item"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum ContourTransformSizeVariant0Item { Variant0(f64), Variant1(SignalRef), } impl From<&ContourTransformSizeVariant0Item> for ContourTransformSizeVariant0Item { fn from(value: &ContourTransformSizeVariant0Item) -> Self { value.clone() } } impl From for ContourTransformSizeVariant0Item { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for ContourTransformSizeVariant0Item { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "ContourTransformSmooth"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"default\": true,"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum ContourTransformSmooth { Variant0(bool), Variant1(SignalRef), } impl From<&ContourTransformSmooth> for ContourTransformSmooth { fn from(value: &ContourTransformSmooth) -> Self { value.clone() } } impl Default for ContourTransformSmooth { fn default() -> Self { ContourTransformSmooth::Variant0(true) } } impl From for ContourTransformSmooth { fn from(value: bool) -> Self { Self::Variant0(value) } } impl From for ContourTransformSmooth { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "ContourTransformThresholds"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum ContourTransformThresholds { Variant0(Vec), Variant1(SignalRef), } impl From<&ContourTransformThresholds> for ContourTransformThresholds { fn from(value: &ContourTransformThresholds) -> Self { value.clone() } } impl From> for ContourTransformThresholds { fn from(value: Vec) -> Self { Self::Variant0(value) } } impl From for ContourTransformThresholds { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "ContourTransformThresholdsVariant0Item"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum ContourTransformThresholdsVariant0Item { Variant0(f64), Variant1(SignalRef), } impl From<&ContourTransformThresholdsVariant0Item> for ContourTransformThresholdsVariant0Item { fn from(value: &ContourTransformThresholdsVariant0Item) -> Self { value.clone() } } impl From for ContourTransformThresholdsVariant0Item { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for ContourTransformThresholdsVariant0Item { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "ContourTransformType"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"enum\": ["] #[doc = " \"contour\""] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] pub enum ContourTransformType { #[serde(rename = "contour")] Contour, } impl From<&ContourTransformType> for ContourTransformType { fn from(value: &ContourTransformType) -> Self { value.clone() } } impl ::std::fmt::Display for ContourTransformType { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match *self { Self::Contour => write!(f, "contour"), } } } impl std::str::FromStr for ContourTransformType { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { match value { "contour" => Ok(Self::Contour), _ => Err("invalid value".into()), } } } impl std::convert::TryFrom<&str> for ContourTransformType { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for ContourTransformType { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for ContourTransformType { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } #[doc = "ContourTransformValues"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum ContourTransformValues { Variant0(Vec), Variant1(SignalRef), } impl From<&ContourTransformValues> for ContourTransformValues { fn from(value: &ContourTransformValues) -> Self { value.clone() } } impl From> for ContourTransformValues { fn from(value: Vec) -> Self { Self::Variant0(value) } } impl From for ContourTransformValues { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "ContourTransformValuesVariant0Item"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum ContourTransformValuesVariant0Item { Variant0(f64), Variant1(SignalRef), } impl From<&ContourTransformValuesVariant0Item> for ContourTransformValuesVariant0Item { fn from(value: &ContourTransformValuesVariant0Item) -> Self { value.clone() } } impl From for ContourTransformValuesVariant0Item { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for ContourTransformValuesVariant0Item { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "ContourTransformWeight"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/scaleField\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/paramField\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/expr\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum ContourTransformWeight { ScaleField(ScaleField), ParamField(ParamField), Expr(Expr), } impl From<&ContourTransformWeight> for ContourTransformWeight { fn from(value: &ContourTransformWeight) -> Self { value.clone() } } impl From for ContourTransformWeight { fn from(value: ScaleField) -> Self { Self::ScaleField(value) } } impl From for ContourTransformWeight { fn from(value: ParamField) -> Self { Self::ParamField(value) } } impl From for ContourTransformWeight { fn from(value: Expr) -> Self { Self::Expr(value) } } #[doc = "ContourTransformX"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/scaleField\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/paramField\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/expr\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum ContourTransformX { ScaleField(ScaleField), ParamField(ParamField), Expr(Expr), } impl From<&ContourTransformX> for ContourTransformX { fn from(value: &ContourTransformX) -> Self { value.clone() } } impl From for ContourTransformX { fn from(value: ScaleField) -> Self { Self::ScaleField(value) } } impl From for ContourTransformX { fn from(value: ParamField) -> Self { Self::ParamField(value) } } impl From for ContourTransformX { fn from(value: Expr) -> Self { Self::Expr(value) } } #[doc = "ContourTransformY"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/scaleField\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/paramField\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/expr\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum ContourTransformY { ScaleField(ScaleField), ParamField(ParamField), Expr(Expr), } impl From<&ContourTransformY> for ContourTransformY { fn from(value: &ContourTransformY) -> Self { value.clone() } } impl From for ContourTransformY { fn from(value: ScaleField) -> Self { Self::ScaleField(value) } } impl From for ContourTransformY { fn from(value: ParamField) -> Self { Self::ParamField(value) } } impl From for ContourTransformY { fn from(value: Expr) -> Self { Self::Expr(value) } } #[doc = "CountpatternTransform"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\","] #[doc = " \"type\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"as\": {"] #[doc = " \"default\": ["] #[doc = " \"text\","] #[doc = " \"count\""] #[doc = " ],"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"maxItems\": 2,"] #[doc = " \"minItems\": 2"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"case\": {"] #[doc = " \"default\": \"mixed\","] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"upper\","] #[doc = " \"lower\","] #[doc = " \"mixed\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"field\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/scaleField\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/paramField\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/expr\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"pattern\": {"] #[doc = " \"default\": \"[\\\\w\\\"]+\","] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"signal\": {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " \"stopwords\": {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"type\": {"] #[doc = " \"enum\": ["] #[doc = " \"countpattern\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(deny_unknown_fields)] pub struct CountpatternTransform { #[serde(rename = "as", default = "defaults::countpattern_transform_as")] pub as_: CountpatternTransformAs, #[serde(default = "defaults::countpattern_transform_case")] pub case: CountpatternTransformCase, pub field: CountpatternTransformField, #[serde(default = "defaults::countpattern_transform_pattern")] pub pattern: CountpatternTransformPattern, #[serde(default, skip_serializing_if = "Option::is_none")] pub signal: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub stopwords: Option, #[serde(rename = "type")] pub type_: CountpatternTransformType, } impl From<&CountpatternTransform> for CountpatternTransform { fn from(value: &CountpatternTransform) -> Self { value.clone() } } #[doc = "CountpatternTransformAs"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"default\": ["] #[doc = " \"text\","] #[doc = " \"count\""] #[doc = " ],"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"maxItems\": 2,"] #[doc = " \"minItems\": 2"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum CountpatternTransformAs { Variant0([CountpatternTransformAsVariant0Item; 2usize]), Variant1(SignalRef), } impl From<&CountpatternTransformAs> for CountpatternTransformAs { fn from(value: &CountpatternTransformAs) -> Self { value.clone() } } impl Default for CountpatternTransformAs { fn default() -> Self { CountpatternTransformAs::Variant0([ CountpatternTransformAsVariant0Item::Variant0("text".to_string()), CountpatternTransformAsVariant0Item::Variant0("count".to_string()), ]) } } impl From<[CountpatternTransformAsVariant0Item; 2usize]> for CountpatternTransformAs { fn from(value: [CountpatternTransformAsVariant0Item; 2usize]) -> Self { Self::Variant0(value) } } impl From for CountpatternTransformAs { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "CountpatternTransformAsVariant0Item"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum CountpatternTransformAsVariant0Item { Variant0(String), Variant1(SignalRef), } impl From<&CountpatternTransformAsVariant0Item> for CountpatternTransformAsVariant0Item { fn from(value: &CountpatternTransformAsVariant0Item) -> Self { value.clone() } } impl From for CountpatternTransformAsVariant0Item { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "CountpatternTransformCase"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"default\": \"mixed\","] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"upper\","] #[doc = " \"lower\","] #[doc = " \"mixed\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum CountpatternTransformCase { Variant0(CountpatternTransformCaseVariant0), Variant1(SignalRef), } impl From<&CountpatternTransformCase> for CountpatternTransformCase { fn from(value: &CountpatternTransformCase) -> Self { value.clone() } } impl Default for CountpatternTransformCase { fn default() -> Self { CountpatternTransformCase::Variant0(CountpatternTransformCaseVariant0::Mixed) } } impl From for CountpatternTransformCase { fn from(value: CountpatternTransformCaseVariant0) -> Self { Self::Variant0(value) } } impl From for CountpatternTransformCase { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "CountpatternTransformCaseVariant0"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"enum\": ["] #[doc = " \"upper\","] #[doc = " \"lower\","] #[doc = " \"mixed\""] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] pub enum CountpatternTransformCaseVariant0 { #[serde(rename = "upper")] Upper, #[serde(rename = "lower")] Lower, #[serde(rename = "mixed")] Mixed, } impl From<&CountpatternTransformCaseVariant0> for CountpatternTransformCaseVariant0 { fn from(value: &CountpatternTransformCaseVariant0) -> Self { value.clone() } } impl ::std::fmt::Display for CountpatternTransformCaseVariant0 { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match *self { Self::Upper => write!(f, "upper"), Self::Lower => write!(f, "lower"), Self::Mixed => write!(f, "mixed"), } } } impl std::str::FromStr for CountpatternTransformCaseVariant0 { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { match value { "upper" => Ok(Self::Upper), "lower" => Ok(Self::Lower), "mixed" => Ok(Self::Mixed), _ => Err("invalid value".into()), } } } impl std::convert::TryFrom<&str> for CountpatternTransformCaseVariant0 { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for CountpatternTransformCaseVariant0 { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for CountpatternTransformCaseVariant0 { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } #[doc = "CountpatternTransformField"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/scaleField\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/paramField\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/expr\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum CountpatternTransformField { ScaleField(ScaleField), ParamField(ParamField), Expr(Expr), } impl From<&CountpatternTransformField> for CountpatternTransformField { fn from(value: &CountpatternTransformField) -> Self { value.clone() } } impl From for CountpatternTransformField { fn from(value: ScaleField) -> Self { Self::ScaleField(value) } } impl From for CountpatternTransformField { fn from(value: ParamField) -> Self { Self::ParamField(value) } } impl From for CountpatternTransformField { fn from(value: Expr) -> Self { Self::Expr(value) } } #[doc = "CountpatternTransformPattern"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"default\": \"[\\\\w\\\"]+\","] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum CountpatternTransformPattern { Variant0(String), Variant1(SignalRef), } impl From<&CountpatternTransformPattern> for CountpatternTransformPattern { fn from(value: &CountpatternTransformPattern) -> Self { value.clone() } } impl Default for CountpatternTransformPattern { fn default() -> Self { CountpatternTransformPattern::Variant0("[\\w\"]+".to_string()) } } impl From for CountpatternTransformPattern { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "CountpatternTransformStopwords"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum CountpatternTransformStopwords { Variant0(String), Variant1(SignalRef), } impl From<&CountpatternTransformStopwords> for CountpatternTransformStopwords { fn from(value: &CountpatternTransformStopwords) -> Self { value.clone() } } impl From for CountpatternTransformStopwords { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "CountpatternTransformType"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"enum\": ["] #[doc = " \"countpattern\""] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] pub enum CountpatternTransformType { #[serde(rename = "countpattern")] Countpattern, } impl From<&CountpatternTransformType> for CountpatternTransformType { fn from(value: &CountpatternTransformType) -> Self { value.clone() } } impl ::std::fmt::Display for CountpatternTransformType { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match *self { Self::Countpattern => write!(f, "countpattern"), } } } impl std::str::FromStr for CountpatternTransformType { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { match value { "countpattern" => Ok(Self::Countpattern), _ => Err("invalid value".into()), } } } impl std::convert::TryFrom<&str> for CountpatternTransformType { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for CountpatternTransformType { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for CountpatternTransformType { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } #[doc = "CrossTransform"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"type\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"as\": {"] #[doc = " \"default\": ["] #[doc = " \"a\","] #[doc = " \"b\""] #[doc = " ],"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"maxItems\": 2,"] #[doc = " \"minItems\": 2"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"filter\": {"] #[doc = " \"$ref\": \"#/definitions/exprString\""] #[doc = " },"] #[doc = " \"signal\": {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " \"type\": {"] #[doc = " \"enum\": ["] #[doc = " \"cross\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(deny_unknown_fields)] pub struct CrossTransform { #[serde(rename = "as", default = "defaults::cross_transform_as")] pub as_: CrossTransformAs, #[serde(default, skip_serializing_if = "Option::is_none")] pub filter: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub signal: Option, #[serde(rename = "type")] pub type_: CrossTransformType, } impl From<&CrossTransform> for CrossTransform { fn from(value: &CrossTransform) -> Self { value.clone() } } #[doc = "CrossTransformAs"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"default\": ["] #[doc = " \"a\","] #[doc = " \"b\""] #[doc = " ],"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"maxItems\": 2,"] #[doc = " \"minItems\": 2"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum CrossTransformAs { Variant0([CrossTransformAsVariant0Item; 2usize]), Variant1(SignalRef), } impl From<&CrossTransformAs> for CrossTransformAs { fn from(value: &CrossTransformAs) -> Self { value.clone() } } impl Default for CrossTransformAs { fn default() -> Self { CrossTransformAs::Variant0([ CrossTransformAsVariant0Item::Variant0("a".to_string()), CrossTransformAsVariant0Item::Variant0("b".to_string()), ]) } } impl From<[CrossTransformAsVariant0Item; 2usize]> for CrossTransformAs { fn from(value: [CrossTransformAsVariant0Item; 2usize]) -> Self { Self::Variant0(value) } } impl From for CrossTransformAs { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "CrossTransformAsVariant0Item"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum CrossTransformAsVariant0Item { Variant0(String), Variant1(SignalRef), } impl From<&CrossTransformAsVariant0Item> for CrossTransformAsVariant0Item { fn from(value: &CrossTransformAsVariant0Item) -> Self { value.clone() } } impl From for CrossTransformAsVariant0Item { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "CrossTransformType"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"enum\": ["] #[doc = " \"cross\""] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] pub enum CrossTransformType { #[serde(rename = "cross")] Cross, } impl From<&CrossTransformType> for CrossTransformType { fn from(value: &CrossTransformType) -> Self { value.clone() } } impl ::std::fmt::Display for CrossTransformType { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match *self { Self::Cross => write!(f, "cross"), } } } impl std::str::FromStr for CrossTransformType { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { match value { "cross" => Ok(Self::Cross), _ => Err("invalid value".into()), } } } impl std::convert::TryFrom<&str> for CrossTransformType { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for CrossTransformType { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for CrossTransformType { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } #[doc = "CrossfilterTransform"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"fields\","] #[doc = " \"query\","] #[doc = " \"type\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"fields\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/scaleField\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/paramField\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/expr\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"query\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {}"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"signal\": {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " \"type\": {"] #[doc = " \"enum\": ["] #[doc = " \"crossfilter\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(deny_unknown_fields)] pub struct CrossfilterTransform { pub fields: CrossfilterTransformFields, pub query: CrossfilterTransformQuery, #[serde(default, skip_serializing_if = "Option::is_none")] pub signal: Option, #[serde(rename = "type")] pub type_: CrossfilterTransformType, } impl From<&CrossfilterTransform> for CrossfilterTransform { fn from(value: &CrossfilterTransform) -> Self { value.clone() } } #[doc = "CrossfilterTransformFields"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/scaleField\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/paramField\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/expr\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum CrossfilterTransformFields { Variant0(Vec), Variant1(SignalRef), } impl From<&CrossfilterTransformFields> for CrossfilterTransformFields { fn from(value: &CrossfilterTransformFields) -> Self { value.clone() } } impl From> for CrossfilterTransformFields { fn from(value: Vec) -> Self { Self::Variant0(value) } } impl From for CrossfilterTransformFields { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "CrossfilterTransformFieldsVariant0Item"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/scaleField\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/paramField\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/expr\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum CrossfilterTransformFieldsVariant0Item { ScaleField(ScaleField), ParamField(ParamField), Expr(Expr), } impl From<&CrossfilterTransformFieldsVariant0Item> for CrossfilterTransformFieldsVariant0Item { fn from(value: &CrossfilterTransformFieldsVariant0Item) -> Self { value.clone() } } impl From for CrossfilterTransformFieldsVariant0Item { fn from(value: ScaleField) -> Self { Self::ScaleField(value) } } impl From for CrossfilterTransformFieldsVariant0Item { fn from(value: ParamField) -> Self { Self::ParamField(value) } } impl From for CrossfilterTransformFieldsVariant0Item { fn from(value: Expr) -> Self { Self::Expr(value) } } #[doc = "CrossfilterTransformQuery"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {}"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum CrossfilterTransformQuery { Variant0(Vec<::serde_json::Value>), Variant1(SignalRef), } impl From<&CrossfilterTransformQuery> for CrossfilterTransformQuery { fn from(value: &CrossfilterTransformQuery) -> Self { value.clone() } } impl From> for CrossfilterTransformQuery { fn from(value: Vec<::serde_json::Value>) -> Self { Self::Variant0(value) } } impl From for CrossfilterTransformQuery { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "CrossfilterTransformType"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"enum\": ["] #[doc = " \"crossfilter\""] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] pub enum CrossfilterTransformType { #[serde(rename = "crossfilter")] Crossfilter, } impl From<&CrossfilterTransformType> for CrossfilterTransformType { fn from(value: &CrossfilterTransformType) -> Self { value.clone() } } impl ::std::fmt::Display for CrossfilterTransformType { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match *self { Self::Crossfilter => write!(f, "crossfilter"), } } } impl std::str::FromStr for CrossfilterTransformType { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { match value { "crossfilter" => Ok(Self::Crossfilter), _ => Err("invalid value".into()), } } } impl std::convert::TryFrom<&str> for CrossfilterTransformType { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for CrossfilterTransformType { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for CrossfilterTransformType { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } #[doc = "Data"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"name\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"name\": {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " \"on\": {"] #[doc = " \"$ref\": \"#/definitions/onTrigger\""] #[doc = " },"] #[doc = " \"transform\": {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"$ref\": \"#/definitions/transform\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"name\","] #[doc = " \"source\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"name\": {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " \"on\": {"] #[doc = " \"$ref\": \"#/definitions/onTrigger\""] #[doc = " },"] #[doc = " \"source\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " \"minItems\": 1"] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"transform\": {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"$ref\": \"#/definitions/transform\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"name\","] #[doc = " \"url\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"async\": {"] #[doc = " \"$ref\": \"#/definitions/booleanOrSignal\""] #[doc = " },"] #[doc = " \"format\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"parse\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"auto\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"additionalProperties\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"boolean\","] #[doc = " \"number\","] #[doc = " \"date\","] #[doc = " \"string\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"string\","] #[doc = " \"pattern\": \"^(date|utc):.*$\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"type\": {"] #[doc = " \"$ref\": \"#/definitions/stringOrSignal\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"copy\": {"] #[doc = " \"$ref\": \"#/definitions/booleanOrSignal\""] #[doc = " },"] #[doc = " \"parse\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"auto\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"additionalProperties\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"boolean\","] #[doc = " \"number\","] #[doc = " \"date\","] #[doc = " \"string\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"string\","] #[doc = " \"pattern\": \"^(date|utc):.*$\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"property\": {"] #[doc = " \"$ref\": \"#/definitions/stringOrSignal\""] #[doc = " },"] #[doc = " \"type\": {"] #[doc = " \"enum\": ["] #[doc = " \"json\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"type\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"header\": {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"type\": \"string\""] #[doc = " }"] #[doc = " },"] #[doc = " \"parse\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"auto\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"additionalProperties\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"boolean\","] #[doc = " \"number\","] #[doc = " \"date\","] #[doc = " \"string\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"string\","] #[doc = " \"pattern\": \"^(date|utc):.*$\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"type\": {"] #[doc = " \"enum\": ["] #[doc = " \"csv\","] #[doc = " \"tsv\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"delimiter\","] #[doc = " \"type\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"delimiter\": {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " \"header\": {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"type\": \"string\""] #[doc = " }"] #[doc = " },"] #[doc = " \"parse\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"auto\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"additionalProperties\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"boolean\","] #[doc = " \"number\","] #[doc = " \"date\","] #[doc = " \"string\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"string\","] #[doc = " \"pattern\": \"^(date|utc):.*$\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"type\": {"] #[doc = " \"enum\": ["] #[doc = " \"dsv\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = " },"] #[doc = " {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"feature\","] #[doc = " \"type\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"feature\": {"] #[doc = " \"$ref\": \"#/definitions/stringOrSignal\""] #[doc = " },"] #[doc = " \"property\": {"] #[doc = " \"$ref\": \"#/definitions/stringOrSignal\""] #[doc = " },"] #[doc = " \"type\": {"] #[doc = " \"enum\": ["] #[doc = " \"topojson\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"mesh\","] #[doc = " \"type\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"filter\": {"] #[doc = " \"enum\": ["] #[doc = " \"interior\","] #[doc = " \"exterior\","] #[doc = " null"] #[doc = " ]"] #[doc = " },"] #[doc = " \"mesh\": {"] #[doc = " \"$ref\": \"#/definitions/stringOrSignal\""] #[doc = " },"] #[doc = " \"property\": {"] #[doc = " \"$ref\": \"#/definitions/stringOrSignal\""] #[doc = " },"] #[doc = " \"type\": {"] #[doc = " \"enum\": ["] #[doc = " \"topojson\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"name\": {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " \"on\": {"] #[doc = " \"$ref\": \"#/definitions/onTrigger\""] #[doc = " },"] #[doc = " \"transform\": {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"$ref\": \"#/definitions/transform\""] #[doc = " }"] #[doc = " },"] #[doc = " \"url\": {"] #[doc = " \"$ref\": \"#/definitions/stringOrSignal\""] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"name\","] #[doc = " \"values\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"async\": {"] #[doc = " \"$ref\": \"#/definitions/booleanOrSignal\""] #[doc = " },"] #[doc = " \"format\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"parse\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"auto\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"additionalProperties\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"boolean\","] #[doc = " \"number\","] #[doc = " \"date\","] #[doc = " \"string\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"string\","] #[doc = " \"pattern\": \"^(date|utc):.*$\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"type\": {"] #[doc = " \"$ref\": \"#/definitions/stringOrSignal\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"copy\": {"] #[doc = " \"$ref\": \"#/definitions/booleanOrSignal\""] #[doc = " },"] #[doc = " \"parse\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"auto\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"additionalProperties\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"boolean\","] #[doc = " \"number\","] #[doc = " \"date\","] #[doc = " \"string\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"string\","] #[doc = " \"pattern\": \"^(date|utc):.*$\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"property\": {"] #[doc = " \"$ref\": \"#/definitions/stringOrSignal\""] #[doc = " },"] #[doc = " \"type\": {"] #[doc = " \"enum\": ["] #[doc = " \"json\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"type\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"header\": {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"type\": \"string\""] #[doc = " }"] #[doc = " },"] #[doc = " \"parse\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"auto\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"additionalProperties\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"boolean\","] #[doc = " \"number\","] #[doc = " \"date\","] #[doc = " \"string\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"string\","] #[doc = " \"pattern\": \"^(date|utc):.*$\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"type\": {"] #[doc = " \"enum\": ["] #[doc = " \"csv\","] #[doc = " \"tsv\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"delimiter\","] #[doc = " \"type\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"delimiter\": {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " \"header\": {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"type\": \"string\""] #[doc = " }"] #[doc = " },"] #[doc = " \"parse\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"auto\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"additionalProperties\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"boolean\","] #[doc = " \"number\","] #[doc = " \"date\","] #[doc = " \"string\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"string\","] #[doc = " \"pattern\": \"^(date|utc):.*$\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"type\": {"] #[doc = " \"enum\": ["] #[doc = " \"dsv\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = " },"] #[doc = " {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"feature\","] #[doc = " \"type\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"feature\": {"] #[doc = " \"$ref\": \"#/definitions/stringOrSignal\""] #[doc = " },"] #[doc = " \"property\": {"] #[doc = " \"$ref\": \"#/definitions/stringOrSignal\""] #[doc = " },"] #[doc = " \"type\": {"] #[doc = " \"enum\": ["] #[doc = " \"topojson\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"mesh\","] #[doc = " \"type\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"filter\": {"] #[doc = " \"enum\": ["] #[doc = " \"interior\","] #[doc = " \"exterior\","] #[doc = " null"] #[doc = " ]"] #[doc = " },"] #[doc = " \"mesh\": {"] #[doc = " \"$ref\": \"#/definitions/stringOrSignal\""] #[doc = " },"] #[doc = " \"property\": {"] #[doc = " \"$ref\": \"#/definitions/stringOrSignal\""] #[doc = " },"] #[doc = " \"type\": {"] #[doc = " \"enum\": ["] #[doc = " \"topojson\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"name\": {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " \"on\": {"] #[doc = " \"$ref\": \"#/definitions/onTrigger\""] #[doc = " },"] #[doc = " \"transform\": {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"$ref\": \"#/definitions/transform\""] #[doc = " }"] #[doc = " },"] #[doc = " \"values\": {"] #[doc = " \"oneOf\": ["] #[doc = " {},"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged, deny_unknown_fields)] pub enum Data { Variant0 { name: String, #[serde(default, skip_serializing_if = "Option::is_none")] on: Option, #[serde(default, skip_serializing_if = "Vec::is_empty")] transform: Vec, }, Variant1 { name: String, #[serde(default, skip_serializing_if = "Option::is_none")] on: Option, source: DataVariant1Source, #[serde(default, skip_serializing_if = "Vec::is_empty")] transform: Vec, }, Variant2 { #[serde(rename = "async", default, skip_serializing_if = "Option::is_none")] async_: Option, #[serde(default, skip_serializing_if = "Option::is_none")] format: Option, name: String, #[serde(default, skip_serializing_if = "Option::is_none")] on: Option, #[serde(default, skip_serializing_if = "Vec::is_empty")] transform: Vec, url: StringOrSignal, }, Variant3 { #[serde(rename = "async", default, skip_serializing_if = "Option::is_none")] async_: Option, #[serde(default, skip_serializing_if = "Option::is_none")] format: Option, name: String, #[serde(default, skip_serializing_if = "Option::is_none")] on: Option, #[serde(default, skip_serializing_if = "Vec::is_empty")] transform: Vec, values: DataVariant3Values, }, } impl From<&Data> for Data { fn from(value: &Data) -> Self { value.clone() } } #[doc = "DataVariant1Source"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " \"minItems\": 1"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum DataVariant1Source { Variant0(String), Variant1(Vec), } impl From<&DataVariant1Source> for DataVariant1Source { fn from(value: &DataVariant1Source) -> Self { value.clone() } } impl From> for DataVariant1Source { fn from(value: Vec) -> Self { Self::Variant1(value) } } #[doc = "DataVariant2Format"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"parse\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"auto\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"additionalProperties\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"boolean\","] #[doc = " \"number\","] #[doc = " \"date\","] #[doc = " \"string\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"string\","] #[doc = " \"pattern\": \"^(date|utc):.*$\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"type\": {"] #[doc = " \"$ref\": \"#/definitions/stringOrSignal\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"copy\": {"] #[doc = " \"$ref\": \"#/definitions/booleanOrSignal\""] #[doc = " },"] #[doc = " \"parse\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"auto\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"additionalProperties\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"boolean\","] #[doc = " \"number\","] #[doc = " \"date\","] #[doc = " \"string\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"string\","] #[doc = " \"pattern\": \"^(date|utc):.*$\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"property\": {"] #[doc = " \"$ref\": \"#/definitions/stringOrSignal\""] #[doc = " },"] #[doc = " \"type\": {"] #[doc = " \"enum\": ["] #[doc = " \"json\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"type\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"header\": {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"type\": \"string\""] #[doc = " }"] #[doc = " },"] #[doc = " \"parse\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"auto\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"additionalProperties\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"boolean\","] #[doc = " \"number\","] #[doc = " \"date\","] #[doc = " \"string\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"string\","] #[doc = " \"pattern\": \"^(date|utc):.*$\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"type\": {"] #[doc = " \"enum\": ["] #[doc = " \"csv\","] #[doc = " \"tsv\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"delimiter\","] #[doc = " \"type\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"delimiter\": {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " \"header\": {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"type\": \"string\""] #[doc = " }"] #[doc = " },"] #[doc = " \"parse\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"auto\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"additionalProperties\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"boolean\","] #[doc = " \"number\","] #[doc = " \"date\","] #[doc = " \"string\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"string\","] #[doc = " \"pattern\": \"^(date|utc):.*$\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"type\": {"] #[doc = " \"enum\": ["] #[doc = " \"dsv\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = " },"] #[doc = " {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"feature\","] #[doc = " \"type\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"feature\": {"] #[doc = " \"$ref\": \"#/definitions/stringOrSignal\""] #[doc = " },"] #[doc = " \"property\": {"] #[doc = " \"$ref\": \"#/definitions/stringOrSignal\""] #[doc = " },"] #[doc = " \"type\": {"] #[doc = " \"enum\": ["] #[doc = " \"topojson\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"mesh\","] #[doc = " \"type\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"filter\": {"] #[doc = " \"enum\": ["] #[doc = " \"interior\","] #[doc = " \"exterior\","] #[doc = " null"] #[doc = " ]"] #[doc = " },"] #[doc = " \"mesh\": {"] #[doc = " \"$ref\": \"#/definitions/stringOrSignal\""] #[doc = " },"] #[doc = " \"property\": {"] #[doc = " \"$ref\": \"#/definitions/stringOrSignal\""] #[doc = " },"] #[doc = " \"type\": {"] #[doc = " \"enum\": ["] #[doc = " \"topojson\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum DataVariant2Format { Variant0 { #[serde(flatten, default, skip_serializing_if = "Option::is_none")] subtype_0: Option, #[serde(flatten, default, skip_serializing_if = "Option::is_none")] subtype_1: Option, #[serde(flatten, default, skip_serializing_if = "Option::is_none")] subtype_2: Option, #[serde(flatten, default, skip_serializing_if = "Option::is_none")] subtype_3: Option, #[serde(flatten, default, skip_serializing_if = "Option::is_none")] subtype_4: Option, }, Variant1(SignalRef), } impl From<&DataVariant2Format> for DataVariant2Format { fn from(value: &DataVariant2Format) -> Self { value.clone() } } impl From for DataVariant2Format { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "DataVariant2FormatVariant0Subtype0"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"parse\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"auto\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"additionalProperties\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"boolean\","] #[doc = " \"number\","] #[doc = " \"date\","] #[doc = " \"string\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"string\","] #[doc = " \"pattern\": \"^(date|utc):.*$\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"type\": {"] #[doc = " \"$ref\": \"#/definitions/stringOrSignal\""] #[doc = " }"] #[doc = " }"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] pub struct DataVariant2FormatVariant0Subtype0 { #[serde(default, skip_serializing_if = "Option::is_none")] pub parse: Option, #[serde(rename = "type", default, skip_serializing_if = "Option::is_none")] pub type_: Option, } impl From<&DataVariant2FormatVariant0Subtype0> for DataVariant2FormatVariant0Subtype0 { fn from(value: &DataVariant2FormatVariant0Subtype0) -> Self { value.clone() } } #[doc = "DataVariant2FormatVariant0Subtype0Parse"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"auto\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"additionalProperties\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"boolean\","] #[doc = " \"number\","] #[doc = " \"date\","] #[doc = " \"string\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"string\","] #[doc = " \"pattern\": \"^(date|utc):.*$\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum DataVariant2FormatVariant0Subtype0Parse { Variant0(DataVariant2FormatVariant0Subtype0ParseVariant0), Variant1( ::std::collections::HashMap, ), Variant2(SignalRef), } impl From<&DataVariant2FormatVariant0Subtype0Parse> for DataVariant2FormatVariant0Subtype0Parse { fn from(value: &DataVariant2FormatVariant0Subtype0Parse) -> Self { value.clone() } } impl From for DataVariant2FormatVariant0Subtype0Parse { fn from(value: DataVariant2FormatVariant0Subtype0ParseVariant0) -> Self { Self::Variant0(value) } } impl From<::std::collections::HashMap> for DataVariant2FormatVariant0Subtype0Parse { fn from( value: ::std::collections::HashMap< String, DataVariant2FormatVariant0Subtype0ParseVariant1Value, >, ) -> Self { Self::Variant1(value) } } impl From for DataVariant2FormatVariant0Subtype0Parse { fn from(value: SignalRef) -> Self { Self::Variant2(value) } } #[doc = "DataVariant2FormatVariant0Subtype0ParseVariant0"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"enum\": ["] #[doc = " \"auto\""] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] pub enum DataVariant2FormatVariant0Subtype0ParseVariant0 { #[serde(rename = "auto")] Auto, } impl From<&DataVariant2FormatVariant0Subtype0ParseVariant0> for DataVariant2FormatVariant0Subtype0ParseVariant0 { fn from(value: &DataVariant2FormatVariant0Subtype0ParseVariant0) -> Self { value.clone() } } impl ::std::fmt::Display for DataVariant2FormatVariant0Subtype0ParseVariant0 { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match *self { Self::Auto => write!(f, "auto"), } } } impl std::str::FromStr for DataVariant2FormatVariant0Subtype0ParseVariant0 { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { match value { "auto" => Ok(Self::Auto), _ => Err("invalid value".into()), } } } impl std::convert::TryFrom<&str> for DataVariant2FormatVariant0Subtype0ParseVariant0 { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for DataVariant2FormatVariant0Subtype0ParseVariant0 { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for DataVariant2FormatVariant0Subtype0ParseVariant0 { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } #[doc = "DataVariant2FormatVariant0Subtype0ParseVariant1Value"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"boolean\","] #[doc = " \"number\","] #[doc = " \"date\","] #[doc = " \"string\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"string\","] #[doc = " \"pattern\": \"^(date|utc):.*$\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum DataVariant2FormatVariant0Subtype0ParseVariant1Value { Variant0(DataVariant2FormatVariant0Subtype0ParseVariant1ValueVariant0), Variant1(DataVariant2FormatVariant0Subtype0ParseVariant1ValueVariant1), } impl From<&DataVariant2FormatVariant0Subtype0ParseVariant1Value> for DataVariant2FormatVariant0Subtype0ParseVariant1Value { fn from(value: &DataVariant2FormatVariant0Subtype0ParseVariant1Value) -> Self { value.clone() } } impl std::str::FromStr for DataVariant2FormatVariant0Subtype0ParseVariant1Value { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { if let Ok(v) = value.parse() { Ok(Self::Variant0(v)) } else if let Ok(v) = value.parse() { Ok(Self::Variant1(v)) } else { Err("string conversion failed for all variants".into()) } } } impl std::convert::TryFrom<&str> for DataVariant2FormatVariant0Subtype0ParseVariant1Value { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for DataVariant2FormatVariant0Subtype0ParseVariant1Value { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for DataVariant2FormatVariant0Subtype0ParseVariant1Value { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } impl ::std::fmt::Display for DataVariant2FormatVariant0Subtype0ParseVariant1Value { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match self { Self::Variant0(x) => x.fmt(f), Self::Variant1(x) => x.fmt(f), } } } impl From for DataVariant2FormatVariant0Subtype0ParseVariant1Value { fn from(value: DataVariant2FormatVariant0Subtype0ParseVariant1ValueVariant0) -> Self { Self::Variant0(value) } } impl From for DataVariant2FormatVariant0Subtype0ParseVariant1Value { fn from(value: DataVariant2FormatVariant0Subtype0ParseVariant1ValueVariant1) -> Self { Self::Variant1(value) } } #[doc = "DataVariant2FormatVariant0Subtype0ParseVariant1ValueVariant0"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"enum\": ["] #[doc = " \"boolean\","] #[doc = " \"number\","] #[doc = " \"date\","] #[doc = " \"string\""] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] pub enum DataVariant2FormatVariant0Subtype0ParseVariant1ValueVariant0 { #[serde(rename = "boolean")] Boolean, #[serde(rename = "number")] Number, #[serde(rename = "date")] Date, #[serde(rename = "string")] String, } impl From<&DataVariant2FormatVariant0Subtype0ParseVariant1ValueVariant0> for DataVariant2FormatVariant0Subtype0ParseVariant1ValueVariant0 { fn from(value: &DataVariant2FormatVariant0Subtype0ParseVariant1ValueVariant0) -> Self { value.clone() } } impl ::std::fmt::Display for DataVariant2FormatVariant0Subtype0ParseVariant1ValueVariant0 { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match *self { Self::Boolean => write!(f, "boolean"), Self::Number => write!(f, "number"), Self::Date => write!(f, "date"), Self::String => write!(f, "string"), } } } impl std::str::FromStr for DataVariant2FormatVariant0Subtype0ParseVariant1ValueVariant0 { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { match value { "boolean" => Ok(Self::Boolean), "number" => Ok(Self::Number), "date" => Ok(Self::Date), "string" => Ok(Self::String), _ => Err("invalid value".into()), } } } impl std::convert::TryFrom<&str> for DataVariant2FormatVariant0Subtype0ParseVariant1ValueVariant0 { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for DataVariant2FormatVariant0Subtype0ParseVariant1ValueVariant0 { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for DataVariant2FormatVariant0Subtype0ParseVariant1ValueVariant0 { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } #[doc = "DataVariant2FormatVariant0Subtype0ParseVariant1ValueVariant1"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"type\": \"string\","] #[doc = " \"pattern\": \"^(date|utc):.*$\""] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Serialize, Clone, Debug, Eq, Hash, Ord, PartialEq, PartialOrd)] pub struct DataVariant2FormatVariant0Subtype0ParseVariant1ValueVariant1(String); impl ::std::ops::Deref for DataVariant2FormatVariant0Subtype0ParseVariant1ValueVariant1 { type Target = String; fn deref(&self) -> &String { &self.0 } } impl From for String { fn from(value: DataVariant2FormatVariant0Subtype0ParseVariant1ValueVariant1) -> Self { value.0 } } impl From<&DataVariant2FormatVariant0Subtype0ParseVariant1ValueVariant1> for DataVariant2FormatVariant0Subtype0ParseVariant1ValueVariant1 { fn from(value: &DataVariant2FormatVariant0Subtype0ParseVariant1ValueVariant1) -> Self { value.clone() } } impl ::std::str::FromStr for DataVariant2FormatVariant0Subtype0ParseVariant1ValueVariant1 { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { if regress::Regex::new("^(date|utc):.*$") .unwrap() .find(value) .is_none() { return Err("doesn't match pattern \"^(date|utc):.*$\"".into()); } Ok(Self(value.to_string())) } } impl ::std::convert::TryFrom<&str> for DataVariant2FormatVariant0Subtype0ParseVariant1ValueVariant1 { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl ::std::convert::TryFrom<&String> for DataVariant2FormatVariant0Subtype0ParseVariant1ValueVariant1 { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl ::std::convert::TryFrom for DataVariant2FormatVariant0Subtype0ParseVariant1ValueVariant1 { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } impl<'de> ::serde::Deserialize<'de> for DataVariant2FormatVariant0Subtype0ParseVariant1ValueVariant1 { fn deserialize(deserializer: D) -> Result where D: ::serde::Deserializer<'de>, { String::deserialize(deserializer)? .parse() .map_err(|e: self::error::ConversionError| { ::custom(e.to_string()) }) } } #[doc = "DataVariant2FormatVariant0Subtype1"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"copy\": {"] #[doc = " \"$ref\": \"#/definitions/booleanOrSignal\""] #[doc = " },"] #[doc = " \"parse\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"auto\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"additionalProperties\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"boolean\","] #[doc = " \"number\","] #[doc = " \"date\","] #[doc = " \"string\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"string\","] #[doc = " \"pattern\": \"^(date|utc):.*$\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"property\": {"] #[doc = " \"$ref\": \"#/definitions/stringOrSignal\""] #[doc = " },"] #[doc = " \"type\": {"] #[doc = " \"enum\": ["] #[doc = " \"json\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(deny_unknown_fields)] pub struct DataVariant2FormatVariant0Subtype1 { #[serde(default, skip_serializing_if = "Option::is_none")] pub copy: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub parse: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub property: Option, #[serde(rename = "type", default, skip_serializing_if = "Option::is_none")] pub type_: Option, } impl From<&DataVariant2FormatVariant0Subtype1> for DataVariant2FormatVariant0Subtype1 { fn from(value: &DataVariant2FormatVariant0Subtype1) -> Self { value.clone() } } #[doc = "DataVariant2FormatVariant0Subtype1Parse"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"auto\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"additionalProperties\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"boolean\","] #[doc = " \"number\","] #[doc = " \"date\","] #[doc = " \"string\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"string\","] #[doc = " \"pattern\": \"^(date|utc):.*$\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum DataVariant2FormatVariant0Subtype1Parse { Variant0(DataVariant2FormatVariant0Subtype1ParseVariant0), Variant1( ::std::collections::HashMap, ), Variant2(SignalRef), } impl From<&DataVariant2FormatVariant0Subtype1Parse> for DataVariant2FormatVariant0Subtype1Parse { fn from(value: &DataVariant2FormatVariant0Subtype1Parse) -> Self { value.clone() } } impl From for DataVariant2FormatVariant0Subtype1Parse { fn from(value: DataVariant2FormatVariant0Subtype1ParseVariant0) -> Self { Self::Variant0(value) } } impl From<::std::collections::HashMap> for DataVariant2FormatVariant0Subtype1Parse { fn from( value: ::std::collections::HashMap< String, DataVariant2FormatVariant0Subtype1ParseVariant1Value, >, ) -> Self { Self::Variant1(value) } } impl From for DataVariant2FormatVariant0Subtype1Parse { fn from(value: SignalRef) -> Self { Self::Variant2(value) } } #[doc = "DataVariant2FormatVariant0Subtype1ParseVariant0"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"enum\": ["] #[doc = " \"auto\""] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] pub enum DataVariant2FormatVariant0Subtype1ParseVariant0 { #[serde(rename = "auto")] Auto, } impl From<&DataVariant2FormatVariant0Subtype1ParseVariant0> for DataVariant2FormatVariant0Subtype1ParseVariant0 { fn from(value: &DataVariant2FormatVariant0Subtype1ParseVariant0) -> Self { value.clone() } } impl ::std::fmt::Display for DataVariant2FormatVariant0Subtype1ParseVariant0 { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match *self { Self::Auto => write!(f, "auto"), } } } impl std::str::FromStr for DataVariant2FormatVariant0Subtype1ParseVariant0 { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { match value { "auto" => Ok(Self::Auto), _ => Err("invalid value".into()), } } } impl std::convert::TryFrom<&str> for DataVariant2FormatVariant0Subtype1ParseVariant0 { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for DataVariant2FormatVariant0Subtype1ParseVariant0 { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for DataVariant2FormatVariant0Subtype1ParseVariant0 { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } #[doc = "DataVariant2FormatVariant0Subtype1ParseVariant1Value"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"boolean\","] #[doc = " \"number\","] #[doc = " \"date\","] #[doc = " \"string\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"string\","] #[doc = " \"pattern\": \"^(date|utc):.*$\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum DataVariant2FormatVariant0Subtype1ParseVariant1Value { Variant0(DataVariant2FormatVariant0Subtype1ParseVariant1ValueVariant0), Variant1(DataVariant2FormatVariant0Subtype1ParseVariant1ValueVariant1), } impl From<&DataVariant2FormatVariant0Subtype1ParseVariant1Value> for DataVariant2FormatVariant0Subtype1ParseVariant1Value { fn from(value: &DataVariant2FormatVariant0Subtype1ParseVariant1Value) -> Self { value.clone() } } impl std::str::FromStr for DataVariant2FormatVariant0Subtype1ParseVariant1Value { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { if let Ok(v) = value.parse() { Ok(Self::Variant0(v)) } else if let Ok(v) = value.parse() { Ok(Self::Variant1(v)) } else { Err("string conversion failed for all variants".into()) } } } impl std::convert::TryFrom<&str> for DataVariant2FormatVariant0Subtype1ParseVariant1Value { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for DataVariant2FormatVariant0Subtype1ParseVariant1Value { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for DataVariant2FormatVariant0Subtype1ParseVariant1Value { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } impl ::std::fmt::Display for DataVariant2FormatVariant0Subtype1ParseVariant1Value { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match self { Self::Variant0(x) => x.fmt(f), Self::Variant1(x) => x.fmt(f), } } } impl From for DataVariant2FormatVariant0Subtype1ParseVariant1Value { fn from(value: DataVariant2FormatVariant0Subtype1ParseVariant1ValueVariant0) -> Self { Self::Variant0(value) } } impl From for DataVariant2FormatVariant0Subtype1ParseVariant1Value { fn from(value: DataVariant2FormatVariant0Subtype1ParseVariant1ValueVariant1) -> Self { Self::Variant1(value) } } #[doc = "DataVariant2FormatVariant0Subtype1ParseVariant1ValueVariant0"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"enum\": ["] #[doc = " \"boolean\","] #[doc = " \"number\","] #[doc = " \"date\","] #[doc = " \"string\""] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] pub enum DataVariant2FormatVariant0Subtype1ParseVariant1ValueVariant0 { #[serde(rename = "boolean")] Boolean, #[serde(rename = "number")] Number, #[serde(rename = "date")] Date, #[serde(rename = "string")] String, } impl From<&DataVariant2FormatVariant0Subtype1ParseVariant1ValueVariant0> for DataVariant2FormatVariant0Subtype1ParseVariant1ValueVariant0 { fn from(value: &DataVariant2FormatVariant0Subtype1ParseVariant1ValueVariant0) -> Self { value.clone() } } impl ::std::fmt::Display for DataVariant2FormatVariant0Subtype1ParseVariant1ValueVariant0 { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match *self { Self::Boolean => write!(f, "boolean"), Self::Number => write!(f, "number"), Self::Date => write!(f, "date"), Self::String => write!(f, "string"), } } } impl std::str::FromStr for DataVariant2FormatVariant0Subtype1ParseVariant1ValueVariant0 { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { match value { "boolean" => Ok(Self::Boolean), "number" => Ok(Self::Number), "date" => Ok(Self::Date), "string" => Ok(Self::String), _ => Err("invalid value".into()), } } } impl std::convert::TryFrom<&str> for DataVariant2FormatVariant0Subtype1ParseVariant1ValueVariant0 { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for DataVariant2FormatVariant0Subtype1ParseVariant1ValueVariant0 { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for DataVariant2FormatVariant0Subtype1ParseVariant1ValueVariant0 { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } #[doc = "DataVariant2FormatVariant0Subtype1ParseVariant1ValueVariant1"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"type\": \"string\","] #[doc = " \"pattern\": \"^(date|utc):.*$\""] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Serialize, Clone, Debug, Eq, Hash, Ord, PartialEq, PartialOrd)] pub struct DataVariant2FormatVariant0Subtype1ParseVariant1ValueVariant1(String); impl ::std::ops::Deref for DataVariant2FormatVariant0Subtype1ParseVariant1ValueVariant1 { type Target = String; fn deref(&self) -> &String { &self.0 } } impl From for String { fn from(value: DataVariant2FormatVariant0Subtype1ParseVariant1ValueVariant1) -> Self { value.0 } } impl From<&DataVariant2FormatVariant0Subtype1ParseVariant1ValueVariant1> for DataVariant2FormatVariant0Subtype1ParseVariant1ValueVariant1 { fn from(value: &DataVariant2FormatVariant0Subtype1ParseVariant1ValueVariant1) -> Self { value.clone() } } impl ::std::str::FromStr for DataVariant2FormatVariant0Subtype1ParseVariant1ValueVariant1 { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { if regress::Regex::new("^(date|utc):.*$") .unwrap() .find(value) .is_none() { return Err("doesn't match pattern \"^(date|utc):.*$\"".into()); } Ok(Self(value.to_string())) } } impl ::std::convert::TryFrom<&str> for DataVariant2FormatVariant0Subtype1ParseVariant1ValueVariant1 { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl ::std::convert::TryFrom<&String> for DataVariant2FormatVariant0Subtype1ParseVariant1ValueVariant1 { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl ::std::convert::TryFrom for DataVariant2FormatVariant0Subtype1ParseVariant1ValueVariant1 { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } impl<'de> ::serde::Deserialize<'de> for DataVariant2FormatVariant0Subtype1ParseVariant1ValueVariant1 { fn deserialize(deserializer: D) -> Result where D: ::serde::Deserializer<'de>, { String::deserialize(deserializer)? .parse() .map_err(|e: self::error::ConversionError| { ::custom(e.to_string()) }) } } #[doc = "DataVariant2FormatVariant0Subtype1Type"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"enum\": ["] #[doc = " \"json\""] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] pub enum DataVariant2FormatVariant0Subtype1Type { #[serde(rename = "json")] Json, } impl From<&DataVariant2FormatVariant0Subtype1Type> for DataVariant2FormatVariant0Subtype1Type { fn from(value: &DataVariant2FormatVariant0Subtype1Type) -> Self { value.clone() } } impl ::std::fmt::Display for DataVariant2FormatVariant0Subtype1Type { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match *self { Self::Json => write!(f, "json"), } } } impl std::str::FromStr for DataVariant2FormatVariant0Subtype1Type { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { match value { "json" => Ok(Self::Json), _ => Err("invalid value".into()), } } } impl std::convert::TryFrom<&str> for DataVariant2FormatVariant0Subtype1Type { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for DataVariant2FormatVariant0Subtype1Type { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for DataVariant2FormatVariant0Subtype1Type { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } #[doc = "DataVariant2FormatVariant0Subtype2"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"type\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"header\": {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"type\": \"string\""] #[doc = " }"] #[doc = " },"] #[doc = " \"parse\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"auto\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"additionalProperties\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"boolean\","] #[doc = " \"number\","] #[doc = " \"date\","] #[doc = " \"string\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"string\","] #[doc = " \"pattern\": \"^(date|utc):.*$\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"type\": {"] #[doc = " \"enum\": ["] #[doc = " \"csv\","] #[doc = " \"tsv\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(deny_unknown_fields)] pub struct DataVariant2FormatVariant0Subtype2 { #[serde(default, skip_serializing_if = "Vec::is_empty")] pub header: Vec, #[serde(default, skip_serializing_if = "Option::is_none")] pub parse: Option, #[serde(rename = "type")] pub type_: DataVariant2FormatVariant0Subtype2Type, } impl From<&DataVariant2FormatVariant0Subtype2> for DataVariant2FormatVariant0Subtype2 { fn from(value: &DataVariant2FormatVariant0Subtype2) -> Self { value.clone() } } #[doc = "DataVariant2FormatVariant0Subtype2Parse"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"auto\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"additionalProperties\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"boolean\","] #[doc = " \"number\","] #[doc = " \"date\","] #[doc = " \"string\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"string\","] #[doc = " \"pattern\": \"^(date|utc):.*$\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum DataVariant2FormatVariant0Subtype2Parse { Variant0(DataVariant2FormatVariant0Subtype2ParseVariant0), Variant1( ::std::collections::HashMap, ), Variant2(SignalRef), } impl From<&DataVariant2FormatVariant0Subtype2Parse> for DataVariant2FormatVariant0Subtype2Parse { fn from(value: &DataVariant2FormatVariant0Subtype2Parse) -> Self { value.clone() } } impl From for DataVariant2FormatVariant0Subtype2Parse { fn from(value: DataVariant2FormatVariant0Subtype2ParseVariant0) -> Self { Self::Variant0(value) } } impl From<::std::collections::HashMap> for DataVariant2FormatVariant0Subtype2Parse { fn from( value: ::std::collections::HashMap< String, DataVariant2FormatVariant0Subtype2ParseVariant1Value, >, ) -> Self { Self::Variant1(value) } } impl From for DataVariant2FormatVariant0Subtype2Parse { fn from(value: SignalRef) -> Self { Self::Variant2(value) } } #[doc = "DataVariant2FormatVariant0Subtype2ParseVariant0"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"enum\": ["] #[doc = " \"auto\""] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] pub enum DataVariant2FormatVariant0Subtype2ParseVariant0 { #[serde(rename = "auto")] Auto, } impl From<&DataVariant2FormatVariant0Subtype2ParseVariant0> for DataVariant2FormatVariant0Subtype2ParseVariant0 { fn from(value: &DataVariant2FormatVariant0Subtype2ParseVariant0) -> Self { value.clone() } } impl ::std::fmt::Display for DataVariant2FormatVariant0Subtype2ParseVariant0 { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match *self { Self::Auto => write!(f, "auto"), } } } impl std::str::FromStr for DataVariant2FormatVariant0Subtype2ParseVariant0 { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { match value { "auto" => Ok(Self::Auto), _ => Err("invalid value".into()), } } } impl std::convert::TryFrom<&str> for DataVariant2FormatVariant0Subtype2ParseVariant0 { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for DataVariant2FormatVariant0Subtype2ParseVariant0 { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for DataVariant2FormatVariant0Subtype2ParseVariant0 { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } #[doc = "DataVariant2FormatVariant0Subtype2ParseVariant1Value"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"boolean\","] #[doc = " \"number\","] #[doc = " \"date\","] #[doc = " \"string\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"string\","] #[doc = " \"pattern\": \"^(date|utc):.*$\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum DataVariant2FormatVariant0Subtype2ParseVariant1Value { Variant0(DataVariant2FormatVariant0Subtype2ParseVariant1ValueVariant0), Variant1(DataVariant2FormatVariant0Subtype2ParseVariant1ValueVariant1), } impl From<&DataVariant2FormatVariant0Subtype2ParseVariant1Value> for DataVariant2FormatVariant0Subtype2ParseVariant1Value { fn from(value: &DataVariant2FormatVariant0Subtype2ParseVariant1Value) -> Self { value.clone() } } impl std::str::FromStr for DataVariant2FormatVariant0Subtype2ParseVariant1Value { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { if let Ok(v) = value.parse() { Ok(Self::Variant0(v)) } else if let Ok(v) = value.parse() { Ok(Self::Variant1(v)) } else { Err("string conversion failed for all variants".into()) } } } impl std::convert::TryFrom<&str> for DataVariant2FormatVariant0Subtype2ParseVariant1Value { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for DataVariant2FormatVariant0Subtype2ParseVariant1Value { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for DataVariant2FormatVariant0Subtype2ParseVariant1Value { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } impl ::std::fmt::Display for DataVariant2FormatVariant0Subtype2ParseVariant1Value { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match self { Self::Variant0(x) => x.fmt(f), Self::Variant1(x) => x.fmt(f), } } } impl From for DataVariant2FormatVariant0Subtype2ParseVariant1Value { fn from(value: DataVariant2FormatVariant0Subtype2ParseVariant1ValueVariant0) -> Self { Self::Variant0(value) } } impl From for DataVariant2FormatVariant0Subtype2ParseVariant1Value { fn from(value: DataVariant2FormatVariant0Subtype2ParseVariant1ValueVariant1) -> Self { Self::Variant1(value) } } #[doc = "DataVariant2FormatVariant0Subtype2ParseVariant1ValueVariant0"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"enum\": ["] #[doc = " \"boolean\","] #[doc = " \"number\","] #[doc = " \"date\","] #[doc = " \"string\""] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] pub enum DataVariant2FormatVariant0Subtype2ParseVariant1ValueVariant0 { #[serde(rename = "boolean")] Boolean, #[serde(rename = "number")] Number, #[serde(rename = "date")] Date, #[serde(rename = "string")] String, } impl From<&DataVariant2FormatVariant0Subtype2ParseVariant1ValueVariant0> for DataVariant2FormatVariant0Subtype2ParseVariant1ValueVariant0 { fn from(value: &DataVariant2FormatVariant0Subtype2ParseVariant1ValueVariant0) -> Self { value.clone() } } impl ::std::fmt::Display for DataVariant2FormatVariant0Subtype2ParseVariant1ValueVariant0 { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match *self { Self::Boolean => write!(f, "boolean"), Self::Number => write!(f, "number"), Self::Date => write!(f, "date"), Self::String => write!(f, "string"), } } } impl std::str::FromStr for DataVariant2FormatVariant0Subtype2ParseVariant1ValueVariant0 { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { match value { "boolean" => Ok(Self::Boolean), "number" => Ok(Self::Number), "date" => Ok(Self::Date), "string" => Ok(Self::String), _ => Err("invalid value".into()), } } } impl std::convert::TryFrom<&str> for DataVariant2FormatVariant0Subtype2ParseVariant1ValueVariant0 { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for DataVariant2FormatVariant0Subtype2ParseVariant1ValueVariant0 { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for DataVariant2FormatVariant0Subtype2ParseVariant1ValueVariant0 { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } #[doc = "DataVariant2FormatVariant0Subtype2ParseVariant1ValueVariant1"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"type\": \"string\","] #[doc = " \"pattern\": \"^(date|utc):.*$\""] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Serialize, Clone, Debug, Eq, Hash, Ord, PartialEq, PartialOrd)] pub struct DataVariant2FormatVariant0Subtype2ParseVariant1ValueVariant1(String); impl ::std::ops::Deref for DataVariant2FormatVariant0Subtype2ParseVariant1ValueVariant1 { type Target = String; fn deref(&self) -> &String { &self.0 } } impl From for String { fn from(value: DataVariant2FormatVariant0Subtype2ParseVariant1ValueVariant1) -> Self { value.0 } } impl From<&DataVariant2FormatVariant0Subtype2ParseVariant1ValueVariant1> for DataVariant2FormatVariant0Subtype2ParseVariant1ValueVariant1 { fn from(value: &DataVariant2FormatVariant0Subtype2ParseVariant1ValueVariant1) -> Self { value.clone() } } impl ::std::str::FromStr for DataVariant2FormatVariant0Subtype2ParseVariant1ValueVariant1 { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { if regress::Regex::new("^(date|utc):.*$") .unwrap() .find(value) .is_none() { return Err("doesn't match pattern \"^(date|utc):.*$\"".into()); } Ok(Self(value.to_string())) } } impl ::std::convert::TryFrom<&str> for DataVariant2FormatVariant0Subtype2ParseVariant1ValueVariant1 { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl ::std::convert::TryFrom<&String> for DataVariant2FormatVariant0Subtype2ParseVariant1ValueVariant1 { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl ::std::convert::TryFrom for DataVariant2FormatVariant0Subtype2ParseVariant1ValueVariant1 { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } impl<'de> ::serde::Deserialize<'de> for DataVariant2FormatVariant0Subtype2ParseVariant1ValueVariant1 { fn deserialize(deserializer: D) -> Result where D: ::serde::Deserializer<'de>, { String::deserialize(deserializer)? .parse() .map_err(|e: self::error::ConversionError| { ::custom(e.to_string()) }) } } #[doc = "DataVariant2FormatVariant0Subtype2Type"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"enum\": ["] #[doc = " \"csv\","] #[doc = " \"tsv\""] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] pub enum DataVariant2FormatVariant0Subtype2Type { #[serde(rename = "csv")] Csv, #[serde(rename = "tsv")] Tsv, } impl From<&DataVariant2FormatVariant0Subtype2Type> for DataVariant2FormatVariant0Subtype2Type { fn from(value: &DataVariant2FormatVariant0Subtype2Type) -> Self { value.clone() } } impl ::std::fmt::Display for DataVariant2FormatVariant0Subtype2Type { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match *self { Self::Csv => write!(f, "csv"), Self::Tsv => write!(f, "tsv"), } } } impl std::str::FromStr for DataVariant2FormatVariant0Subtype2Type { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { match value { "csv" => Ok(Self::Csv), "tsv" => Ok(Self::Tsv), _ => Err("invalid value".into()), } } } impl std::convert::TryFrom<&str> for DataVariant2FormatVariant0Subtype2Type { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for DataVariant2FormatVariant0Subtype2Type { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for DataVariant2FormatVariant0Subtype2Type { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } #[doc = "DataVariant2FormatVariant0Subtype3"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"delimiter\","] #[doc = " \"type\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"delimiter\": {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " \"header\": {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"type\": \"string\""] #[doc = " }"] #[doc = " },"] #[doc = " \"parse\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"auto\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"additionalProperties\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"boolean\","] #[doc = " \"number\","] #[doc = " \"date\","] #[doc = " \"string\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"string\","] #[doc = " \"pattern\": \"^(date|utc):.*$\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"type\": {"] #[doc = " \"enum\": ["] #[doc = " \"dsv\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(deny_unknown_fields)] pub struct DataVariant2FormatVariant0Subtype3 { pub delimiter: String, #[serde(default, skip_serializing_if = "Vec::is_empty")] pub header: Vec, #[serde(default, skip_serializing_if = "Option::is_none")] pub parse: Option, #[serde(rename = "type")] pub type_: DataVariant2FormatVariant0Subtype3Type, } impl From<&DataVariant2FormatVariant0Subtype3> for DataVariant2FormatVariant0Subtype3 { fn from(value: &DataVariant2FormatVariant0Subtype3) -> Self { value.clone() } } #[doc = "DataVariant2FormatVariant0Subtype3Parse"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"auto\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"additionalProperties\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"boolean\","] #[doc = " \"number\","] #[doc = " \"date\","] #[doc = " \"string\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"string\","] #[doc = " \"pattern\": \"^(date|utc):.*$\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum DataVariant2FormatVariant0Subtype3Parse { Variant0(DataVariant2FormatVariant0Subtype3ParseVariant0), Variant1( ::std::collections::HashMap, ), Variant2(SignalRef), } impl From<&DataVariant2FormatVariant0Subtype3Parse> for DataVariant2FormatVariant0Subtype3Parse { fn from(value: &DataVariant2FormatVariant0Subtype3Parse) -> Self { value.clone() } } impl From for DataVariant2FormatVariant0Subtype3Parse { fn from(value: DataVariant2FormatVariant0Subtype3ParseVariant0) -> Self { Self::Variant0(value) } } impl From<::std::collections::HashMap> for DataVariant2FormatVariant0Subtype3Parse { fn from( value: ::std::collections::HashMap< String, DataVariant2FormatVariant0Subtype3ParseVariant1Value, >, ) -> Self { Self::Variant1(value) } } impl From for DataVariant2FormatVariant0Subtype3Parse { fn from(value: SignalRef) -> Self { Self::Variant2(value) } } #[doc = "DataVariant2FormatVariant0Subtype3ParseVariant0"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"enum\": ["] #[doc = " \"auto\""] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] pub enum DataVariant2FormatVariant0Subtype3ParseVariant0 { #[serde(rename = "auto")] Auto, } impl From<&DataVariant2FormatVariant0Subtype3ParseVariant0> for DataVariant2FormatVariant0Subtype3ParseVariant0 { fn from(value: &DataVariant2FormatVariant0Subtype3ParseVariant0) -> Self { value.clone() } } impl ::std::fmt::Display for DataVariant2FormatVariant0Subtype3ParseVariant0 { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match *self { Self::Auto => write!(f, "auto"), } } } impl std::str::FromStr for DataVariant2FormatVariant0Subtype3ParseVariant0 { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { match value { "auto" => Ok(Self::Auto), _ => Err("invalid value".into()), } } } impl std::convert::TryFrom<&str> for DataVariant2FormatVariant0Subtype3ParseVariant0 { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for DataVariant2FormatVariant0Subtype3ParseVariant0 { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for DataVariant2FormatVariant0Subtype3ParseVariant0 { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } #[doc = "DataVariant2FormatVariant0Subtype3ParseVariant1Value"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"boolean\","] #[doc = " \"number\","] #[doc = " \"date\","] #[doc = " \"string\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"string\","] #[doc = " \"pattern\": \"^(date|utc):.*$\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum DataVariant2FormatVariant0Subtype3ParseVariant1Value { Variant0(DataVariant2FormatVariant0Subtype3ParseVariant1ValueVariant0), Variant1(DataVariant2FormatVariant0Subtype3ParseVariant1ValueVariant1), } impl From<&DataVariant2FormatVariant0Subtype3ParseVariant1Value> for DataVariant2FormatVariant0Subtype3ParseVariant1Value { fn from(value: &DataVariant2FormatVariant0Subtype3ParseVariant1Value) -> Self { value.clone() } } impl std::str::FromStr for DataVariant2FormatVariant0Subtype3ParseVariant1Value { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { if let Ok(v) = value.parse() { Ok(Self::Variant0(v)) } else if let Ok(v) = value.parse() { Ok(Self::Variant1(v)) } else { Err("string conversion failed for all variants".into()) } } } impl std::convert::TryFrom<&str> for DataVariant2FormatVariant0Subtype3ParseVariant1Value { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for DataVariant2FormatVariant0Subtype3ParseVariant1Value { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for DataVariant2FormatVariant0Subtype3ParseVariant1Value { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } impl ::std::fmt::Display for DataVariant2FormatVariant0Subtype3ParseVariant1Value { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match self { Self::Variant0(x) => x.fmt(f), Self::Variant1(x) => x.fmt(f), } } } impl From for DataVariant2FormatVariant0Subtype3ParseVariant1Value { fn from(value: DataVariant2FormatVariant0Subtype3ParseVariant1ValueVariant0) -> Self { Self::Variant0(value) } } impl From for DataVariant2FormatVariant0Subtype3ParseVariant1Value { fn from(value: DataVariant2FormatVariant0Subtype3ParseVariant1ValueVariant1) -> Self { Self::Variant1(value) } } #[doc = "DataVariant2FormatVariant0Subtype3ParseVariant1ValueVariant0"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"enum\": ["] #[doc = " \"boolean\","] #[doc = " \"number\","] #[doc = " \"date\","] #[doc = " \"string\""] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] pub enum DataVariant2FormatVariant0Subtype3ParseVariant1ValueVariant0 { #[serde(rename = "boolean")] Boolean, #[serde(rename = "number")] Number, #[serde(rename = "date")] Date, #[serde(rename = "string")] String, } impl From<&DataVariant2FormatVariant0Subtype3ParseVariant1ValueVariant0> for DataVariant2FormatVariant0Subtype3ParseVariant1ValueVariant0 { fn from(value: &DataVariant2FormatVariant0Subtype3ParseVariant1ValueVariant0) -> Self { value.clone() } } impl ::std::fmt::Display for DataVariant2FormatVariant0Subtype3ParseVariant1ValueVariant0 { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match *self { Self::Boolean => write!(f, "boolean"), Self::Number => write!(f, "number"), Self::Date => write!(f, "date"), Self::String => write!(f, "string"), } } } impl std::str::FromStr for DataVariant2FormatVariant0Subtype3ParseVariant1ValueVariant0 { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { match value { "boolean" => Ok(Self::Boolean), "number" => Ok(Self::Number), "date" => Ok(Self::Date), "string" => Ok(Self::String), _ => Err("invalid value".into()), } } } impl std::convert::TryFrom<&str> for DataVariant2FormatVariant0Subtype3ParseVariant1ValueVariant0 { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for DataVariant2FormatVariant0Subtype3ParseVariant1ValueVariant0 { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for DataVariant2FormatVariant0Subtype3ParseVariant1ValueVariant0 { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } #[doc = "DataVariant2FormatVariant0Subtype3ParseVariant1ValueVariant1"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"type\": \"string\","] #[doc = " \"pattern\": \"^(date|utc):.*$\""] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Serialize, Clone, Debug, Eq, Hash, Ord, PartialEq, PartialOrd)] pub struct DataVariant2FormatVariant0Subtype3ParseVariant1ValueVariant1(String); impl ::std::ops::Deref for DataVariant2FormatVariant0Subtype3ParseVariant1ValueVariant1 { type Target = String; fn deref(&self) -> &String { &self.0 } } impl From for String { fn from(value: DataVariant2FormatVariant0Subtype3ParseVariant1ValueVariant1) -> Self { value.0 } } impl From<&DataVariant2FormatVariant0Subtype3ParseVariant1ValueVariant1> for DataVariant2FormatVariant0Subtype3ParseVariant1ValueVariant1 { fn from(value: &DataVariant2FormatVariant0Subtype3ParseVariant1ValueVariant1) -> Self { value.clone() } } impl ::std::str::FromStr for DataVariant2FormatVariant0Subtype3ParseVariant1ValueVariant1 { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { if regress::Regex::new("^(date|utc):.*$") .unwrap() .find(value) .is_none() { return Err("doesn't match pattern \"^(date|utc):.*$\"".into()); } Ok(Self(value.to_string())) } } impl ::std::convert::TryFrom<&str> for DataVariant2FormatVariant0Subtype3ParseVariant1ValueVariant1 { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl ::std::convert::TryFrom<&String> for DataVariant2FormatVariant0Subtype3ParseVariant1ValueVariant1 { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl ::std::convert::TryFrom for DataVariant2FormatVariant0Subtype3ParseVariant1ValueVariant1 { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } impl<'de> ::serde::Deserialize<'de> for DataVariant2FormatVariant0Subtype3ParseVariant1ValueVariant1 { fn deserialize(deserializer: D) -> Result where D: ::serde::Deserializer<'de>, { String::deserialize(deserializer)? .parse() .map_err(|e: self::error::ConversionError| { ::custom(e.to_string()) }) } } #[doc = "DataVariant2FormatVariant0Subtype3Type"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"enum\": ["] #[doc = " \"dsv\""] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] pub enum DataVariant2FormatVariant0Subtype3Type { #[serde(rename = "dsv")] Dsv, } impl From<&DataVariant2FormatVariant0Subtype3Type> for DataVariant2FormatVariant0Subtype3Type { fn from(value: &DataVariant2FormatVariant0Subtype3Type) -> Self { value.clone() } } impl ::std::fmt::Display for DataVariant2FormatVariant0Subtype3Type { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match *self { Self::Dsv => write!(f, "dsv"), } } } impl std::str::FromStr for DataVariant2FormatVariant0Subtype3Type { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { match value { "dsv" => Ok(Self::Dsv), _ => Err("invalid value".into()), } } } impl std::convert::TryFrom<&str> for DataVariant2FormatVariant0Subtype3Type { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for DataVariant2FormatVariant0Subtype3Type { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for DataVariant2FormatVariant0Subtype3Type { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } #[doc = "DataVariant2FormatVariant0Subtype4"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"feature\","] #[doc = " \"type\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"feature\": {"] #[doc = " \"$ref\": \"#/definitions/stringOrSignal\""] #[doc = " },"] #[doc = " \"property\": {"] #[doc = " \"$ref\": \"#/definitions/stringOrSignal\""] #[doc = " },"] #[doc = " \"type\": {"] #[doc = " \"enum\": ["] #[doc = " \"topojson\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"mesh\","] #[doc = " \"type\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"filter\": {"] #[doc = " \"enum\": ["] #[doc = " \"interior\","] #[doc = " \"exterior\","] #[doc = " null"] #[doc = " ]"] #[doc = " },"] #[doc = " \"mesh\": {"] #[doc = " \"$ref\": \"#/definitions/stringOrSignal\""] #[doc = " },"] #[doc = " \"property\": {"] #[doc = " \"$ref\": \"#/definitions/stringOrSignal\""] #[doc = " },"] #[doc = " \"type\": {"] #[doc = " \"enum\": ["] #[doc = " \"topojson\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged, deny_unknown_fields)] pub enum DataVariant2FormatVariant0Subtype4 { Variant0 { feature: StringOrSignal, #[serde(default, skip_serializing_if = "Option::is_none")] property: Option, #[serde(rename = "type")] type_: DataVariant2FormatVariant0Subtype4Variant0Type, }, Variant1 { #[serde(default, skip_serializing_if = "Option::is_none")] filter: Option, mesh: StringOrSignal, #[serde(default, skip_serializing_if = "Option::is_none")] property: Option, #[serde(rename = "type")] type_: DataVariant2FormatVariant0Subtype4Variant1Type, }, } impl From<&DataVariant2FormatVariant0Subtype4> for DataVariant2FormatVariant0Subtype4 { fn from(value: &DataVariant2FormatVariant0Subtype4) -> Self { value.clone() } } #[doc = "DataVariant2FormatVariant0Subtype4Variant0Type"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"enum\": ["] #[doc = " \"topojson\""] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] pub enum DataVariant2FormatVariant0Subtype4Variant0Type { #[serde(rename = "topojson")] Topojson, } impl From<&DataVariant2FormatVariant0Subtype4Variant0Type> for DataVariant2FormatVariant0Subtype4Variant0Type { fn from(value: &DataVariant2FormatVariant0Subtype4Variant0Type) -> Self { value.clone() } } impl ::std::fmt::Display for DataVariant2FormatVariant0Subtype4Variant0Type { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match *self { Self::Topojson => write!(f, "topojson"), } } } impl std::str::FromStr for DataVariant2FormatVariant0Subtype4Variant0Type { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { match value { "topojson" => Ok(Self::Topojson), _ => Err("invalid value".into()), } } } impl std::convert::TryFrom<&str> for DataVariant2FormatVariant0Subtype4Variant0Type { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for DataVariant2FormatVariant0Subtype4Variant0Type { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for DataVariant2FormatVariant0Subtype4Variant0Type { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } #[doc = "DataVariant2FormatVariant0Subtype4Variant1Filter"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"enum\": ["] #[doc = " \"interior\","] #[doc = " \"exterior\","] #[doc = " null"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] pub enum DataVariant2FormatVariant0Subtype4Variant1Filter { #[serde(rename = "interior")] Interior, #[serde(rename = "exterior")] Exterior, } impl From<&DataVariant2FormatVariant0Subtype4Variant1Filter> for DataVariant2FormatVariant0Subtype4Variant1Filter { fn from(value: &DataVariant2FormatVariant0Subtype4Variant1Filter) -> Self { value.clone() } } impl ::std::fmt::Display for DataVariant2FormatVariant0Subtype4Variant1Filter { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match *self { Self::Interior => write!(f, "interior"), Self::Exterior => write!(f, "exterior"), } } } impl std::str::FromStr for DataVariant2FormatVariant0Subtype4Variant1Filter { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { match value { "interior" => Ok(Self::Interior), "exterior" => Ok(Self::Exterior), _ => Err("invalid value".into()), } } } impl std::convert::TryFrom<&str> for DataVariant2FormatVariant0Subtype4Variant1Filter { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for DataVariant2FormatVariant0Subtype4Variant1Filter { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for DataVariant2FormatVariant0Subtype4Variant1Filter { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } #[doc = "DataVariant2FormatVariant0Subtype4Variant1Type"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"enum\": ["] #[doc = " \"topojson\""] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] pub enum DataVariant2FormatVariant0Subtype4Variant1Type { #[serde(rename = "topojson")] Topojson, } impl From<&DataVariant2FormatVariant0Subtype4Variant1Type> for DataVariant2FormatVariant0Subtype4Variant1Type { fn from(value: &DataVariant2FormatVariant0Subtype4Variant1Type) -> Self { value.clone() } } impl ::std::fmt::Display for DataVariant2FormatVariant0Subtype4Variant1Type { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match *self { Self::Topojson => write!(f, "topojson"), } } } impl std::str::FromStr for DataVariant2FormatVariant0Subtype4Variant1Type { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { match value { "topojson" => Ok(Self::Topojson), _ => Err("invalid value".into()), } } } impl std::convert::TryFrom<&str> for DataVariant2FormatVariant0Subtype4Variant1Type { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for DataVariant2FormatVariant0Subtype4Variant1Type { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for DataVariant2FormatVariant0Subtype4Variant1Type { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } #[doc = "DataVariant3Format"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"parse\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"auto\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"additionalProperties\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"boolean\","] #[doc = " \"number\","] #[doc = " \"date\","] #[doc = " \"string\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"string\","] #[doc = " \"pattern\": \"^(date|utc):.*$\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"type\": {"] #[doc = " \"$ref\": \"#/definitions/stringOrSignal\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"copy\": {"] #[doc = " \"$ref\": \"#/definitions/booleanOrSignal\""] #[doc = " },"] #[doc = " \"parse\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"auto\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"additionalProperties\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"boolean\","] #[doc = " \"number\","] #[doc = " \"date\","] #[doc = " \"string\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"string\","] #[doc = " \"pattern\": \"^(date|utc):.*$\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"property\": {"] #[doc = " \"$ref\": \"#/definitions/stringOrSignal\""] #[doc = " },"] #[doc = " \"type\": {"] #[doc = " \"enum\": ["] #[doc = " \"json\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"type\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"header\": {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"type\": \"string\""] #[doc = " }"] #[doc = " },"] #[doc = " \"parse\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"auto\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"additionalProperties\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"boolean\","] #[doc = " \"number\","] #[doc = " \"date\","] #[doc = " \"string\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"string\","] #[doc = " \"pattern\": \"^(date|utc):.*$\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"type\": {"] #[doc = " \"enum\": ["] #[doc = " \"csv\","] #[doc = " \"tsv\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"delimiter\","] #[doc = " \"type\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"delimiter\": {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " \"header\": {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"type\": \"string\""] #[doc = " }"] #[doc = " },"] #[doc = " \"parse\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"auto\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"additionalProperties\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"boolean\","] #[doc = " \"number\","] #[doc = " \"date\","] #[doc = " \"string\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"string\","] #[doc = " \"pattern\": \"^(date|utc):.*$\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"type\": {"] #[doc = " \"enum\": ["] #[doc = " \"dsv\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = " },"] #[doc = " {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"feature\","] #[doc = " \"type\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"feature\": {"] #[doc = " \"$ref\": \"#/definitions/stringOrSignal\""] #[doc = " },"] #[doc = " \"property\": {"] #[doc = " \"$ref\": \"#/definitions/stringOrSignal\""] #[doc = " },"] #[doc = " \"type\": {"] #[doc = " \"enum\": ["] #[doc = " \"topojson\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"mesh\","] #[doc = " \"type\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"filter\": {"] #[doc = " \"enum\": ["] #[doc = " \"interior\","] #[doc = " \"exterior\","] #[doc = " null"] #[doc = " ]"] #[doc = " },"] #[doc = " \"mesh\": {"] #[doc = " \"$ref\": \"#/definitions/stringOrSignal\""] #[doc = " },"] #[doc = " \"property\": {"] #[doc = " \"$ref\": \"#/definitions/stringOrSignal\""] #[doc = " },"] #[doc = " \"type\": {"] #[doc = " \"enum\": ["] #[doc = " \"topojson\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum DataVariant3Format { Variant0 { #[serde(flatten, default, skip_serializing_if = "Option::is_none")] subtype_0: Option, #[serde(flatten, default, skip_serializing_if = "Option::is_none")] subtype_1: Option, #[serde(flatten, default, skip_serializing_if = "Option::is_none")] subtype_2: Option, #[serde(flatten, default, skip_serializing_if = "Option::is_none")] subtype_3: Option, #[serde(flatten, default, skip_serializing_if = "Option::is_none")] subtype_4: Option, }, Variant1(SignalRef), } impl From<&DataVariant3Format> for DataVariant3Format { fn from(value: &DataVariant3Format) -> Self { value.clone() } } impl From for DataVariant3Format { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "DataVariant3FormatVariant0Subtype0"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"parse\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"auto\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"additionalProperties\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"boolean\","] #[doc = " \"number\","] #[doc = " \"date\","] #[doc = " \"string\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"string\","] #[doc = " \"pattern\": \"^(date|utc):.*$\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"type\": {"] #[doc = " \"$ref\": \"#/definitions/stringOrSignal\""] #[doc = " }"] #[doc = " }"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] pub struct DataVariant3FormatVariant0Subtype0 { #[serde(default, skip_serializing_if = "Option::is_none")] pub parse: Option, #[serde(rename = "type", default, skip_serializing_if = "Option::is_none")] pub type_: Option, } impl From<&DataVariant3FormatVariant0Subtype0> for DataVariant3FormatVariant0Subtype0 { fn from(value: &DataVariant3FormatVariant0Subtype0) -> Self { value.clone() } } #[doc = "DataVariant3FormatVariant0Subtype0Parse"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"auto\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"additionalProperties\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"boolean\","] #[doc = " \"number\","] #[doc = " \"date\","] #[doc = " \"string\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"string\","] #[doc = " \"pattern\": \"^(date|utc):.*$\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum DataVariant3FormatVariant0Subtype0Parse { Variant0(DataVariant3FormatVariant0Subtype0ParseVariant0), Variant1( ::std::collections::HashMap, ), Variant2(SignalRef), } impl From<&DataVariant3FormatVariant0Subtype0Parse> for DataVariant3FormatVariant0Subtype0Parse { fn from(value: &DataVariant3FormatVariant0Subtype0Parse) -> Self { value.clone() } } impl From for DataVariant3FormatVariant0Subtype0Parse { fn from(value: DataVariant3FormatVariant0Subtype0ParseVariant0) -> Self { Self::Variant0(value) } } impl From<::std::collections::HashMap> for DataVariant3FormatVariant0Subtype0Parse { fn from( value: ::std::collections::HashMap< String, DataVariant3FormatVariant0Subtype0ParseVariant1Value, >, ) -> Self { Self::Variant1(value) } } impl From for DataVariant3FormatVariant0Subtype0Parse { fn from(value: SignalRef) -> Self { Self::Variant2(value) } } #[doc = "DataVariant3FormatVariant0Subtype0ParseVariant0"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"enum\": ["] #[doc = " \"auto\""] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] pub enum DataVariant3FormatVariant0Subtype0ParseVariant0 { #[serde(rename = "auto")] Auto, } impl From<&DataVariant3FormatVariant0Subtype0ParseVariant0> for DataVariant3FormatVariant0Subtype0ParseVariant0 { fn from(value: &DataVariant3FormatVariant0Subtype0ParseVariant0) -> Self { value.clone() } } impl ::std::fmt::Display for DataVariant3FormatVariant0Subtype0ParseVariant0 { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match *self { Self::Auto => write!(f, "auto"), } } } impl std::str::FromStr for DataVariant3FormatVariant0Subtype0ParseVariant0 { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { match value { "auto" => Ok(Self::Auto), _ => Err("invalid value".into()), } } } impl std::convert::TryFrom<&str> for DataVariant3FormatVariant0Subtype0ParseVariant0 { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for DataVariant3FormatVariant0Subtype0ParseVariant0 { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for DataVariant3FormatVariant0Subtype0ParseVariant0 { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } #[doc = "DataVariant3FormatVariant0Subtype0ParseVariant1Value"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"boolean\","] #[doc = " \"number\","] #[doc = " \"date\","] #[doc = " \"string\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"string\","] #[doc = " \"pattern\": \"^(date|utc):.*$\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum DataVariant3FormatVariant0Subtype0ParseVariant1Value { Variant0(DataVariant3FormatVariant0Subtype0ParseVariant1ValueVariant0), Variant1(DataVariant3FormatVariant0Subtype0ParseVariant1ValueVariant1), } impl From<&DataVariant3FormatVariant0Subtype0ParseVariant1Value> for DataVariant3FormatVariant0Subtype0ParseVariant1Value { fn from(value: &DataVariant3FormatVariant0Subtype0ParseVariant1Value) -> Self { value.clone() } } impl std::str::FromStr for DataVariant3FormatVariant0Subtype0ParseVariant1Value { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { if let Ok(v) = value.parse() { Ok(Self::Variant0(v)) } else if let Ok(v) = value.parse() { Ok(Self::Variant1(v)) } else { Err("string conversion failed for all variants".into()) } } } impl std::convert::TryFrom<&str> for DataVariant3FormatVariant0Subtype0ParseVariant1Value { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for DataVariant3FormatVariant0Subtype0ParseVariant1Value { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for DataVariant3FormatVariant0Subtype0ParseVariant1Value { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } impl ::std::fmt::Display for DataVariant3FormatVariant0Subtype0ParseVariant1Value { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match self { Self::Variant0(x) => x.fmt(f), Self::Variant1(x) => x.fmt(f), } } } impl From for DataVariant3FormatVariant0Subtype0ParseVariant1Value { fn from(value: DataVariant3FormatVariant0Subtype0ParseVariant1ValueVariant0) -> Self { Self::Variant0(value) } } impl From for DataVariant3FormatVariant0Subtype0ParseVariant1Value { fn from(value: DataVariant3FormatVariant0Subtype0ParseVariant1ValueVariant1) -> Self { Self::Variant1(value) } } #[doc = "DataVariant3FormatVariant0Subtype0ParseVariant1ValueVariant0"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"enum\": ["] #[doc = " \"boolean\","] #[doc = " \"number\","] #[doc = " \"date\","] #[doc = " \"string\""] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] pub enum DataVariant3FormatVariant0Subtype0ParseVariant1ValueVariant0 { #[serde(rename = "boolean")] Boolean, #[serde(rename = "number")] Number, #[serde(rename = "date")] Date, #[serde(rename = "string")] String, } impl From<&DataVariant3FormatVariant0Subtype0ParseVariant1ValueVariant0> for DataVariant3FormatVariant0Subtype0ParseVariant1ValueVariant0 { fn from(value: &DataVariant3FormatVariant0Subtype0ParseVariant1ValueVariant0) -> Self { value.clone() } } impl ::std::fmt::Display for DataVariant3FormatVariant0Subtype0ParseVariant1ValueVariant0 { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match *self { Self::Boolean => write!(f, "boolean"), Self::Number => write!(f, "number"), Self::Date => write!(f, "date"), Self::String => write!(f, "string"), } } } impl std::str::FromStr for DataVariant3FormatVariant0Subtype0ParseVariant1ValueVariant0 { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { match value { "boolean" => Ok(Self::Boolean), "number" => Ok(Self::Number), "date" => Ok(Self::Date), "string" => Ok(Self::String), _ => Err("invalid value".into()), } } } impl std::convert::TryFrom<&str> for DataVariant3FormatVariant0Subtype0ParseVariant1ValueVariant0 { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for DataVariant3FormatVariant0Subtype0ParseVariant1ValueVariant0 { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for DataVariant3FormatVariant0Subtype0ParseVariant1ValueVariant0 { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } #[doc = "DataVariant3FormatVariant0Subtype0ParseVariant1ValueVariant1"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"type\": \"string\","] #[doc = " \"pattern\": \"^(date|utc):.*$\""] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Serialize, Clone, Debug, Eq, Hash, Ord, PartialEq, PartialOrd)] pub struct DataVariant3FormatVariant0Subtype0ParseVariant1ValueVariant1(String); impl ::std::ops::Deref for DataVariant3FormatVariant0Subtype0ParseVariant1ValueVariant1 { type Target = String; fn deref(&self) -> &String { &self.0 } } impl From for String { fn from(value: DataVariant3FormatVariant0Subtype0ParseVariant1ValueVariant1) -> Self { value.0 } } impl From<&DataVariant3FormatVariant0Subtype0ParseVariant1ValueVariant1> for DataVariant3FormatVariant0Subtype0ParseVariant1ValueVariant1 { fn from(value: &DataVariant3FormatVariant0Subtype0ParseVariant1ValueVariant1) -> Self { value.clone() } } impl ::std::str::FromStr for DataVariant3FormatVariant0Subtype0ParseVariant1ValueVariant1 { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { if regress::Regex::new("^(date|utc):.*$") .unwrap() .find(value) .is_none() { return Err("doesn't match pattern \"^(date|utc):.*$\"".into()); } Ok(Self(value.to_string())) } } impl ::std::convert::TryFrom<&str> for DataVariant3FormatVariant0Subtype0ParseVariant1ValueVariant1 { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl ::std::convert::TryFrom<&String> for DataVariant3FormatVariant0Subtype0ParseVariant1ValueVariant1 { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl ::std::convert::TryFrom for DataVariant3FormatVariant0Subtype0ParseVariant1ValueVariant1 { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } impl<'de> ::serde::Deserialize<'de> for DataVariant3FormatVariant0Subtype0ParseVariant1ValueVariant1 { fn deserialize(deserializer: D) -> Result where D: ::serde::Deserializer<'de>, { String::deserialize(deserializer)? .parse() .map_err(|e: self::error::ConversionError| { ::custom(e.to_string()) }) } } #[doc = "DataVariant3FormatVariant0Subtype1"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"copy\": {"] #[doc = " \"$ref\": \"#/definitions/booleanOrSignal\""] #[doc = " },"] #[doc = " \"parse\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"auto\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"additionalProperties\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"boolean\","] #[doc = " \"number\","] #[doc = " \"date\","] #[doc = " \"string\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"string\","] #[doc = " \"pattern\": \"^(date|utc):.*$\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"property\": {"] #[doc = " \"$ref\": \"#/definitions/stringOrSignal\""] #[doc = " },"] #[doc = " \"type\": {"] #[doc = " \"enum\": ["] #[doc = " \"json\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(deny_unknown_fields)] pub struct DataVariant3FormatVariant0Subtype1 { #[serde(default, skip_serializing_if = "Option::is_none")] pub copy: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub parse: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub property: Option, #[serde(rename = "type", default, skip_serializing_if = "Option::is_none")] pub type_: Option, } impl From<&DataVariant3FormatVariant0Subtype1> for DataVariant3FormatVariant0Subtype1 { fn from(value: &DataVariant3FormatVariant0Subtype1) -> Self { value.clone() } } #[doc = "DataVariant3FormatVariant0Subtype1Parse"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"auto\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"additionalProperties\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"boolean\","] #[doc = " \"number\","] #[doc = " \"date\","] #[doc = " \"string\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"string\","] #[doc = " \"pattern\": \"^(date|utc):.*$\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum DataVariant3FormatVariant0Subtype1Parse { Variant0(DataVariant3FormatVariant0Subtype1ParseVariant0), Variant1( ::std::collections::HashMap, ), Variant2(SignalRef), } impl From<&DataVariant3FormatVariant0Subtype1Parse> for DataVariant3FormatVariant0Subtype1Parse { fn from(value: &DataVariant3FormatVariant0Subtype1Parse) -> Self { value.clone() } } impl From for DataVariant3FormatVariant0Subtype1Parse { fn from(value: DataVariant3FormatVariant0Subtype1ParseVariant0) -> Self { Self::Variant0(value) } } impl From<::std::collections::HashMap> for DataVariant3FormatVariant0Subtype1Parse { fn from( value: ::std::collections::HashMap< String, DataVariant3FormatVariant0Subtype1ParseVariant1Value, >, ) -> Self { Self::Variant1(value) } } impl From for DataVariant3FormatVariant0Subtype1Parse { fn from(value: SignalRef) -> Self { Self::Variant2(value) } } #[doc = "DataVariant3FormatVariant0Subtype1ParseVariant0"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"enum\": ["] #[doc = " \"auto\""] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] pub enum DataVariant3FormatVariant0Subtype1ParseVariant0 { #[serde(rename = "auto")] Auto, } impl From<&DataVariant3FormatVariant0Subtype1ParseVariant0> for DataVariant3FormatVariant0Subtype1ParseVariant0 { fn from(value: &DataVariant3FormatVariant0Subtype1ParseVariant0) -> Self { value.clone() } } impl ::std::fmt::Display for DataVariant3FormatVariant0Subtype1ParseVariant0 { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match *self { Self::Auto => write!(f, "auto"), } } } impl std::str::FromStr for DataVariant3FormatVariant0Subtype1ParseVariant0 { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { match value { "auto" => Ok(Self::Auto), _ => Err("invalid value".into()), } } } impl std::convert::TryFrom<&str> for DataVariant3FormatVariant0Subtype1ParseVariant0 { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for DataVariant3FormatVariant0Subtype1ParseVariant0 { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for DataVariant3FormatVariant0Subtype1ParseVariant0 { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } #[doc = "DataVariant3FormatVariant0Subtype1ParseVariant1Value"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"boolean\","] #[doc = " \"number\","] #[doc = " \"date\","] #[doc = " \"string\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"string\","] #[doc = " \"pattern\": \"^(date|utc):.*$\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum DataVariant3FormatVariant0Subtype1ParseVariant1Value { Variant0(DataVariant3FormatVariant0Subtype1ParseVariant1ValueVariant0), Variant1(DataVariant3FormatVariant0Subtype1ParseVariant1ValueVariant1), } impl From<&DataVariant3FormatVariant0Subtype1ParseVariant1Value> for DataVariant3FormatVariant0Subtype1ParseVariant1Value { fn from(value: &DataVariant3FormatVariant0Subtype1ParseVariant1Value) -> Self { value.clone() } } impl std::str::FromStr for DataVariant3FormatVariant0Subtype1ParseVariant1Value { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { if let Ok(v) = value.parse() { Ok(Self::Variant0(v)) } else if let Ok(v) = value.parse() { Ok(Self::Variant1(v)) } else { Err("string conversion failed for all variants".into()) } } } impl std::convert::TryFrom<&str> for DataVariant3FormatVariant0Subtype1ParseVariant1Value { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for DataVariant3FormatVariant0Subtype1ParseVariant1Value { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for DataVariant3FormatVariant0Subtype1ParseVariant1Value { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } impl ::std::fmt::Display for DataVariant3FormatVariant0Subtype1ParseVariant1Value { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match self { Self::Variant0(x) => x.fmt(f), Self::Variant1(x) => x.fmt(f), } } } impl From for DataVariant3FormatVariant0Subtype1ParseVariant1Value { fn from(value: DataVariant3FormatVariant0Subtype1ParseVariant1ValueVariant0) -> Self { Self::Variant0(value) } } impl From for DataVariant3FormatVariant0Subtype1ParseVariant1Value { fn from(value: DataVariant3FormatVariant0Subtype1ParseVariant1ValueVariant1) -> Self { Self::Variant1(value) } } #[doc = "DataVariant3FormatVariant0Subtype1ParseVariant1ValueVariant0"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"enum\": ["] #[doc = " \"boolean\","] #[doc = " \"number\","] #[doc = " \"date\","] #[doc = " \"string\""] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] pub enum DataVariant3FormatVariant0Subtype1ParseVariant1ValueVariant0 { #[serde(rename = "boolean")] Boolean, #[serde(rename = "number")] Number, #[serde(rename = "date")] Date, #[serde(rename = "string")] String, } impl From<&DataVariant3FormatVariant0Subtype1ParseVariant1ValueVariant0> for DataVariant3FormatVariant0Subtype1ParseVariant1ValueVariant0 { fn from(value: &DataVariant3FormatVariant0Subtype1ParseVariant1ValueVariant0) -> Self { value.clone() } } impl ::std::fmt::Display for DataVariant3FormatVariant0Subtype1ParseVariant1ValueVariant0 { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match *self { Self::Boolean => write!(f, "boolean"), Self::Number => write!(f, "number"), Self::Date => write!(f, "date"), Self::String => write!(f, "string"), } } } impl std::str::FromStr for DataVariant3FormatVariant0Subtype1ParseVariant1ValueVariant0 { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { match value { "boolean" => Ok(Self::Boolean), "number" => Ok(Self::Number), "date" => Ok(Self::Date), "string" => Ok(Self::String), _ => Err("invalid value".into()), } } } impl std::convert::TryFrom<&str> for DataVariant3FormatVariant0Subtype1ParseVariant1ValueVariant0 { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for DataVariant3FormatVariant0Subtype1ParseVariant1ValueVariant0 { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for DataVariant3FormatVariant0Subtype1ParseVariant1ValueVariant0 { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } #[doc = "DataVariant3FormatVariant0Subtype1ParseVariant1ValueVariant1"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"type\": \"string\","] #[doc = " \"pattern\": \"^(date|utc):.*$\""] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Serialize, Clone, Debug, Eq, Hash, Ord, PartialEq, PartialOrd)] pub struct DataVariant3FormatVariant0Subtype1ParseVariant1ValueVariant1(String); impl ::std::ops::Deref for DataVariant3FormatVariant0Subtype1ParseVariant1ValueVariant1 { type Target = String; fn deref(&self) -> &String { &self.0 } } impl From for String { fn from(value: DataVariant3FormatVariant0Subtype1ParseVariant1ValueVariant1) -> Self { value.0 } } impl From<&DataVariant3FormatVariant0Subtype1ParseVariant1ValueVariant1> for DataVariant3FormatVariant0Subtype1ParseVariant1ValueVariant1 { fn from(value: &DataVariant3FormatVariant0Subtype1ParseVariant1ValueVariant1) -> Self { value.clone() } } impl ::std::str::FromStr for DataVariant3FormatVariant0Subtype1ParseVariant1ValueVariant1 { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { if regress::Regex::new("^(date|utc):.*$") .unwrap() .find(value) .is_none() { return Err("doesn't match pattern \"^(date|utc):.*$\"".into()); } Ok(Self(value.to_string())) } } impl ::std::convert::TryFrom<&str> for DataVariant3FormatVariant0Subtype1ParseVariant1ValueVariant1 { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl ::std::convert::TryFrom<&String> for DataVariant3FormatVariant0Subtype1ParseVariant1ValueVariant1 { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl ::std::convert::TryFrom for DataVariant3FormatVariant0Subtype1ParseVariant1ValueVariant1 { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } impl<'de> ::serde::Deserialize<'de> for DataVariant3FormatVariant0Subtype1ParseVariant1ValueVariant1 { fn deserialize(deserializer: D) -> Result where D: ::serde::Deserializer<'de>, { String::deserialize(deserializer)? .parse() .map_err(|e: self::error::ConversionError| { ::custom(e.to_string()) }) } } #[doc = "DataVariant3FormatVariant0Subtype1Type"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"enum\": ["] #[doc = " \"json\""] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] pub enum DataVariant3FormatVariant0Subtype1Type { #[serde(rename = "json")] Json, } impl From<&DataVariant3FormatVariant0Subtype1Type> for DataVariant3FormatVariant0Subtype1Type { fn from(value: &DataVariant3FormatVariant0Subtype1Type) -> Self { value.clone() } } impl ::std::fmt::Display for DataVariant3FormatVariant0Subtype1Type { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match *self { Self::Json => write!(f, "json"), } } } impl std::str::FromStr for DataVariant3FormatVariant0Subtype1Type { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { match value { "json" => Ok(Self::Json), _ => Err("invalid value".into()), } } } impl std::convert::TryFrom<&str> for DataVariant3FormatVariant0Subtype1Type { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for DataVariant3FormatVariant0Subtype1Type { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for DataVariant3FormatVariant0Subtype1Type { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } #[doc = "DataVariant3FormatVariant0Subtype2"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"type\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"header\": {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"type\": \"string\""] #[doc = " }"] #[doc = " },"] #[doc = " \"parse\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"auto\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"additionalProperties\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"boolean\","] #[doc = " \"number\","] #[doc = " \"date\","] #[doc = " \"string\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"string\","] #[doc = " \"pattern\": \"^(date|utc):.*$\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"type\": {"] #[doc = " \"enum\": ["] #[doc = " \"csv\","] #[doc = " \"tsv\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(deny_unknown_fields)] pub struct DataVariant3FormatVariant0Subtype2 { #[serde(default, skip_serializing_if = "Vec::is_empty")] pub header: Vec, #[serde(default, skip_serializing_if = "Option::is_none")] pub parse: Option, #[serde(rename = "type")] pub type_: DataVariant3FormatVariant0Subtype2Type, } impl From<&DataVariant3FormatVariant0Subtype2> for DataVariant3FormatVariant0Subtype2 { fn from(value: &DataVariant3FormatVariant0Subtype2) -> Self { value.clone() } } #[doc = "DataVariant3FormatVariant0Subtype2Parse"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"auto\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"additionalProperties\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"boolean\","] #[doc = " \"number\","] #[doc = " \"date\","] #[doc = " \"string\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"string\","] #[doc = " \"pattern\": \"^(date|utc):.*$\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum DataVariant3FormatVariant0Subtype2Parse { Variant0(DataVariant3FormatVariant0Subtype2ParseVariant0), Variant1( ::std::collections::HashMap, ), Variant2(SignalRef), } impl From<&DataVariant3FormatVariant0Subtype2Parse> for DataVariant3FormatVariant0Subtype2Parse { fn from(value: &DataVariant3FormatVariant0Subtype2Parse) -> Self { value.clone() } } impl From for DataVariant3FormatVariant0Subtype2Parse { fn from(value: DataVariant3FormatVariant0Subtype2ParseVariant0) -> Self { Self::Variant0(value) } } impl From<::std::collections::HashMap> for DataVariant3FormatVariant0Subtype2Parse { fn from( value: ::std::collections::HashMap< String, DataVariant3FormatVariant0Subtype2ParseVariant1Value, >, ) -> Self { Self::Variant1(value) } } impl From for DataVariant3FormatVariant0Subtype2Parse { fn from(value: SignalRef) -> Self { Self::Variant2(value) } } #[doc = "DataVariant3FormatVariant0Subtype2ParseVariant0"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"enum\": ["] #[doc = " \"auto\""] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] pub enum DataVariant3FormatVariant0Subtype2ParseVariant0 { #[serde(rename = "auto")] Auto, } impl From<&DataVariant3FormatVariant0Subtype2ParseVariant0> for DataVariant3FormatVariant0Subtype2ParseVariant0 { fn from(value: &DataVariant3FormatVariant0Subtype2ParseVariant0) -> Self { value.clone() } } impl ::std::fmt::Display for DataVariant3FormatVariant0Subtype2ParseVariant0 { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match *self { Self::Auto => write!(f, "auto"), } } } impl std::str::FromStr for DataVariant3FormatVariant0Subtype2ParseVariant0 { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { match value { "auto" => Ok(Self::Auto), _ => Err("invalid value".into()), } } } impl std::convert::TryFrom<&str> for DataVariant3FormatVariant0Subtype2ParseVariant0 { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for DataVariant3FormatVariant0Subtype2ParseVariant0 { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for DataVariant3FormatVariant0Subtype2ParseVariant0 { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } #[doc = "DataVariant3FormatVariant0Subtype2ParseVariant1Value"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"boolean\","] #[doc = " \"number\","] #[doc = " \"date\","] #[doc = " \"string\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"string\","] #[doc = " \"pattern\": \"^(date|utc):.*$\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum DataVariant3FormatVariant0Subtype2ParseVariant1Value { Variant0(DataVariant3FormatVariant0Subtype2ParseVariant1ValueVariant0), Variant1(DataVariant3FormatVariant0Subtype2ParseVariant1ValueVariant1), } impl From<&DataVariant3FormatVariant0Subtype2ParseVariant1Value> for DataVariant3FormatVariant0Subtype2ParseVariant1Value { fn from(value: &DataVariant3FormatVariant0Subtype2ParseVariant1Value) -> Self { value.clone() } } impl std::str::FromStr for DataVariant3FormatVariant0Subtype2ParseVariant1Value { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { if let Ok(v) = value.parse() { Ok(Self::Variant0(v)) } else if let Ok(v) = value.parse() { Ok(Self::Variant1(v)) } else { Err("string conversion failed for all variants".into()) } } } impl std::convert::TryFrom<&str> for DataVariant3FormatVariant0Subtype2ParseVariant1Value { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for DataVariant3FormatVariant0Subtype2ParseVariant1Value { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for DataVariant3FormatVariant0Subtype2ParseVariant1Value { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } impl ::std::fmt::Display for DataVariant3FormatVariant0Subtype2ParseVariant1Value { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match self { Self::Variant0(x) => x.fmt(f), Self::Variant1(x) => x.fmt(f), } } } impl From for DataVariant3FormatVariant0Subtype2ParseVariant1Value { fn from(value: DataVariant3FormatVariant0Subtype2ParseVariant1ValueVariant0) -> Self { Self::Variant0(value) } } impl From for DataVariant3FormatVariant0Subtype2ParseVariant1Value { fn from(value: DataVariant3FormatVariant0Subtype2ParseVariant1ValueVariant1) -> Self { Self::Variant1(value) } } #[doc = "DataVariant3FormatVariant0Subtype2ParseVariant1ValueVariant0"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"enum\": ["] #[doc = " \"boolean\","] #[doc = " \"number\","] #[doc = " \"date\","] #[doc = " \"string\""] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] pub enum DataVariant3FormatVariant0Subtype2ParseVariant1ValueVariant0 { #[serde(rename = "boolean")] Boolean, #[serde(rename = "number")] Number, #[serde(rename = "date")] Date, #[serde(rename = "string")] String, } impl From<&DataVariant3FormatVariant0Subtype2ParseVariant1ValueVariant0> for DataVariant3FormatVariant0Subtype2ParseVariant1ValueVariant0 { fn from(value: &DataVariant3FormatVariant0Subtype2ParseVariant1ValueVariant0) -> Self { value.clone() } } impl ::std::fmt::Display for DataVariant3FormatVariant0Subtype2ParseVariant1ValueVariant0 { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match *self { Self::Boolean => write!(f, "boolean"), Self::Number => write!(f, "number"), Self::Date => write!(f, "date"), Self::String => write!(f, "string"), } } } impl std::str::FromStr for DataVariant3FormatVariant0Subtype2ParseVariant1ValueVariant0 { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { match value { "boolean" => Ok(Self::Boolean), "number" => Ok(Self::Number), "date" => Ok(Self::Date), "string" => Ok(Self::String), _ => Err("invalid value".into()), } } } impl std::convert::TryFrom<&str> for DataVariant3FormatVariant0Subtype2ParseVariant1ValueVariant0 { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for DataVariant3FormatVariant0Subtype2ParseVariant1ValueVariant0 { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for DataVariant3FormatVariant0Subtype2ParseVariant1ValueVariant0 { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } #[doc = "DataVariant3FormatVariant0Subtype2ParseVariant1ValueVariant1"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"type\": \"string\","] #[doc = " \"pattern\": \"^(date|utc):.*$\""] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Serialize, Clone, Debug, Eq, Hash, Ord, PartialEq, PartialOrd)] pub struct DataVariant3FormatVariant0Subtype2ParseVariant1ValueVariant1(String); impl ::std::ops::Deref for DataVariant3FormatVariant0Subtype2ParseVariant1ValueVariant1 { type Target = String; fn deref(&self) -> &String { &self.0 } } impl From for String { fn from(value: DataVariant3FormatVariant0Subtype2ParseVariant1ValueVariant1) -> Self { value.0 } } impl From<&DataVariant3FormatVariant0Subtype2ParseVariant1ValueVariant1> for DataVariant3FormatVariant0Subtype2ParseVariant1ValueVariant1 { fn from(value: &DataVariant3FormatVariant0Subtype2ParseVariant1ValueVariant1) -> Self { value.clone() } } impl ::std::str::FromStr for DataVariant3FormatVariant0Subtype2ParseVariant1ValueVariant1 { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { if regress::Regex::new("^(date|utc):.*$") .unwrap() .find(value) .is_none() { return Err("doesn't match pattern \"^(date|utc):.*$\"".into()); } Ok(Self(value.to_string())) } } impl ::std::convert::TryFrom<&str> for DataVariant3FormatVariant0Subtype2ParseVariant1ValueVariant1 { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl ::std::convert::TryFrom<&String> for DataVariant3FormatVariant0Subtype2ParseVariant1ValueVariant1 { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl ::std::convert::TryFrom for DataVariant3FormatVariant0Subtype2ParseVariant1ValueVariant1 { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } impl<'de> ::serde::Deserialize<'de> for DataVariant3FormatVariant0Subtype2ParseVariant1ValueVariant1 { fn deserialize(deserializer: D) -> Result where D: ::serde::Deserializer<'de>, { String::deserialize(deserializer)? .parse() .map_err(|e: self::error::ConversionError| { ::custom(e.to_string()) }) } } #[doc = "DataVariant3FormatVariant0Subtype2Type"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"enum\": ["] #[doc = " \"csv\","] #[doc = " \"tsv\""] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] pub enum DataVariant3FormatVariant0Subtype2Type { #[serde(rename = "csv")] Csv, #[serde(rename = "tsv")] Tsv, } impl From<&DataVariant3FormatVariant0Subtype2Type> for DataVariant3FormatVariant0Subtype2Type { fn from(value: &DataVariant3FormatVariant0Subtype2Type) -> Self { value.clone() } } impl ::std::fmt::Display for DataVariant3FormatVariant0Subtype2Type { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match *self { Self::Csv => write!(f, "csv"), Self::Tsv => write!(f, "tsv"), } } } impl std::str::FromStr for DataVariant3FormatVariant0Subtype2Type { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { match value { "csv" => Ok(Self::Csv), "tsv" => Ok(Self::Tsv), _ => Err("invalid value".into()), } } } impl std::convert::TryFrom<&str> for DataVariant3FormatVariant0Subtype2Type { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for DataVariant3FormatVariant0Subtype2Type { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for DataVariant3FormatVariant0Subtype2Type { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } #[doc = "DataVariant3FormatVariant0Subtype3"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"delimiter\","] #[doc = " \"type\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"delimiter\": {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " \"header\": {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"type\": \"string\""] #[doc = " }"] #[doc = " },"] #[doc = " \"parse\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"auto\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"additionalProperties\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"boolean\","] #[doc = " \"number\","] #[doc = " \"date\","] #[doc = " \"string\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"string\","] #[doc = " \"pattern\": \"^(date|utc):.*$\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"type\": {"] #[doc = " \"enum\": ["] #[doc = " \"dsv\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(deny_unknown_fields)] pub struct DataVariant3FormatVariant0Subtype3 { pub delimiter: String, #[serde(default, skip_serializing_if = "Vec::is_empty")] pub header: Vec, #[serde(default, skip_serializing_if = "Option::is_none")] pub parse: Option, #[serde(rename = "type")] pub type_: DataVariant3FormatVariant0Subtype3Type, } impl From<&DataVariant3FormatVariant0Subtype3> for DataVariant3FormatVariant0Subtype3 { fn from(value: &DataVariant3FormatVariant0Subtype3) -> Self { value.clone() } } #[doc = "DataVariant3FormatVariant0Subtype3Parse"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"auto\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"additionalProperties\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"boolean\","] #[doc = " \"number\","] #[doc = " \"date\","] #[doc = " \"string\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"string\","] #[doc = " \"pattern\": \"^(date|utc):.*$\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum DataVariant3FormatVariant0Subtype3Parse { Variant0(DataVariant3FormatVariant0Subtype3ParseVariant0), Variant1( ::std::collections::HashMap, ), Variant2(SignalRef), } impl From<&DataVariant3FormatVariant0Subtype3Parse> for DataVariant3FormatVariant0Subtype3Parse { fn from(value: &DataVariant3FormatVariant0Subtype3Parse) -> Self { value.clone() } } impl From for DataVariant3FormatVariant0Subtype3Parse { fn from(value: DataVariant3FormatVariant0Subtype3ParseVariant0) -> Self { Self::Variant0(value) } } impl From<::std::collections::HashMap> for DataVariant3FormatVariant0Subtype3Parse { fn from( value: ::std::collections::HashMap< String, DataVariant3FormatVariant0Subtype3ParseVariant1Value, >, ) -> Self { Self::Variant1(value) } } impl From for DataVariant3FormatVariant0Subtype3Parse { fn from(value: SignalRef) -> Self { Self::Variant2(value) } } #[doc = "DataVariant3FormatVariant0Subtype3ParseVariant0"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"enum\": ["] #[doc = " \"auto\""] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] pub enum DataVariant3FormatVariant0Subtype3ParseVariant0 { #[serde(rename = "auto")] Auto, } impl From<&DataVariant3FormatVariant0Subtype3ParseVariant0> for DataVariant3FormatVariant0Subtype3ParseVariant0 { fn from(value: &DataVariant3FormatVariant0Subtype3ParseVariant0) -> Self { value.clone() } } impl ::std::fmt::Display for DataVariant3FormatVariant0Subtype3ParseVariant0 { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match *self { Self::Auto => write!(f, "auto"), } } } impl std::str::FromStr for DataVariant3FormatVariant0Subtype3ParseVariant0 { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { match value { "auto" => Ok(Self::Auto), _ => Err("invalid value".into()), } } } impl std::convert::TryFrom<&str> for DataVariant3FormatVariant0Subtype3ParseVariant0 { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for DataVariant3FormatVariant0Subtype3ParseVariant0 { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for DataVariant3FormatVariant0Subtype3ParseVariant0 { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } #[doc = "DataVariant3FormatVariant0Subtype3ParseVariant1Value"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"enum\": ["] #[doc = " \"boolean\","] #[doc = " \"number\","] #[doc = " \"date\","] #[doc = " \"string\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"string\","] #[doc = " \"pattern\": \"^(date|utc):.*$\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum DataVariant3FormatVariant0Subtype3ParseVariant1Value { Variant0(DataVariant3FormatVariant0Subtype3ParseVariant1ValueVariant0), Variant1(DataVariant3FormatVariant0Subtype3ParseVariant1ValueVariant1), } impl From<&DataVariant3FormatVariant0Subtype3ParseVariant1Value> for DataVariant3FormatVariant0Subtype3ParseVariant1Value { fn from(value: &DataVariant3FormatVariant0Subtype3ParseVariant1Value) -> Self { value.clone() } } impl std::str::FromStr for DataVariant3FormatVariant0Subtype3ParseVariant1Value { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { if let Ok(v) = value.parse() { Ok(Self::Variant0(v)) } else if let Ok(v) = value.parse() { Ok(Self::Variant1(v)) } else { Err("string conversion failed for all variants".into()) } } } impl std::convert::TryFrom<&str> for DataVariant3FormatVariant0Subtype3ParseVariant1Value { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for DataVariant3FormatVariant0Subtype3ParseVariant1Value { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for DataVariant3FormatVariant0Subtype3ParseVariant1Value { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } impl ::std::fmt::Display for DataVariant3FormatVariant0Subtype3ParseVariant1Value { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match self { Self::Variant0(x) => x.fmt(f), Self::Variant1(x) => x.fmt(f), } } } impl From for DataVariant3FormatVariant0Subtype3ParseVariant1Value { fn from(value: DataVariant3FormatVariant0Subtype3ParseVariant1ValueVariant0) -> Self { Self::Variant0(value) } } impl From for DataVariant3FormatVariant0Subtype3ParseVariant1Value { fn from(value: DataVariant3FormatVariant0Subtype3ParseVariant1ValueVariant1) -> Self { Self::Variant1(value) } } #[doc = "DataVariant3FormatVariant0Subtype3ParseVariant1ValueVariant0"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"enum\": ["] #[doc = " \"boolean\","] #[doc = " \"number\","] #[doc = " \"date\","] #[doc = " \"string\""] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] pub enum DataVariant3FormatVariant0Subtype3ParseVariant1ValueVariant0 { #[serde(rename = "boolean")] Boolean, #[serde(rename = "number")] Number, #[serde(rename = "date")] Date, #[serde(rename = "string")] String, } impl From<&DataVariant3FormatVariant0Subtype3ParseVariant1ValueVariant0> for DataVariant3FormatVariant0Subtype3ParseVariant1ValueVariant0 { fn from(value: &DataVariant3FormatVariant0Subtype3ParseVariant1ValueVariant0) -> Self { value.clone() } } impl ::std::fmt::Display for DataVariant3FormatVariant0Subtype3ParseVariant1ValueVariant0 { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match *self { Self::Boolean => write!(f, "boolean"), Self::Number => write!(f, "number"), Self::Date => write!(f, "date"), Self::String => write!(f, "string"), } } } impl std::str::FromStr for DataVariant3FormatVariant0Subtype3ParseVariant1ValueVariant0 { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { match value { "boolean" => Ok(Self::Boolean), "number" => Ok(Self::Number), "date" => Ok(Self::Date), "string" => Ok(Self::String), _ => Err("invalid value".into()), } } } impl std::convert::TryFrom<&str> for DataVariant3FormatVariant0Subtype3ParseVariant1ValueVariant0 { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for DataVariant3FormatVariant0Subtype3ParseVariant1ValueVariant0 { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for DataVariant3FormatVariant0Subtype3ParseVariant1ValueVariant0 { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } #[doc = "DataVariant3FormatVariant0Subtype3ParseVariant1ValueVariant1"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"type\": \"string\","] #[doc = " \"pattern\": \"^(date|utc):.*$\""] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Serialize, Clone, Debug, Eq, Hash, Ord, PartialEq, PartialOrd)] pub struct DataVariant3FormatVariant0Subtype3ParseVariant1ValueVariant1(String); impl ::std::ops::Deref for DataVariant3FormatVariant0Subtype3ParseVariant1ValueVariant1 { type Target = String; fn deref(&self) -> &String { &self.0 } } impl From for String { fn from(value: DataVariant3FormatVariant0Subtype3ParseVariant1ValueVariant1) -> Self { value.0 } } impl From<&DataVariant3FormatVariant0Subtype3ParseVariant1ValueVariant1> for DataVariant3FormatVariant0Subtype3ParseVariant1ValueVariant1 { fn from(value: &DataVariant3FormatVariant0Subtype3ParseVariant1ValueVariant1) -> Self { value.clone() } } impl ::std::str::FromStr for DataVariant3FormatVariant0Subtype3ParseVariant1ValueVariant1 { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { if regress::Regex::new("^(date|utc):.*$") .unwrap() .find(value) .is_none() { return Err("doesn't match pattern \"^(date|utc):.*$\"".into()); } Ok(Self(value.to_string())) } } impl ::std::convert::TryFrom<&str> for DataVariant3FormatVariant0Subtype3ParseVariant1ValueVariant1 { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl ::std::convert::TryFrom<&String> for DataVariant3FormatVariant0Subtype3ParseVariant1ValueVariant1 { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl ::std::convert::TryFrom for DataVariant3FormatVariant0Subtype3ParseVariant1ValueVariant1 { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } impl<'de> ::serde::Deserialize<'de> for DataVariant3FormatVariant0Subtype3ParseVariant1ValueVariant1 { fn deserialize(deserializer: D) -> Result where D: ::serde::Deserializer<'de>, { String::deserialize(deserializer)? .parse() .map_err(|e: self::error::ConversionError| { ::custom(e.to_string()) }) } } #[doc = "DataVariant3FormatVariant0Subtype3Type"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"enum\": ["] #[doc = " \"dsv\""] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] pub enum DataVariant3FormatVariant0Subtype3Type { #[serde(rename = "dsv")] Dsv, } impl From<&DataVariant3FormatVariant0Subtype3Type> for DataVariant3FormatVariant0Subtype3Type { fn from(value: &DataVariant3FormatVariant0Subtype3Type) -> Self { value.clone() } } impl ::std::fmt::Display for DataVariant3FormatVariant0Subtype3Type { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match *self { Self::Dsv => write!(f, "dsv"), } } } impl std::str::FromStr for DataVariant3FormatVariant0Subtype3Type { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { match value { "dsv" => Ok(Self::Dsv), _ => Err("invalid value".into()), } } } impl std::convert::TryFrom<&str> for DataVariant3FormatVariant0Subtype3Type { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for DataVariant3FormatVariant0Subtype3Type { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for DataVariant3FormatVariant0Subtype3Type { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } #[doc = "DataVariant3FormatVariant0Subtype4"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"feature\","] #[doc = " \"type\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"feature\": {"] #[doc = " \"$ref\": \"#/definitions/stringOrSignal\""] #[doc = " },"] #[doc = " \"property\": {"] #[doc = " \"$ref\": \"#/definitions/stringOrSignal\""] #[doc = " },"] #[doc = " \"type\": {"] #[doc = " \"enum\": ["] #[doc = " \"topojson\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"mesh\","] #[doc = " \"type\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"filter\": {"] #[doc = " \"enum\": ["] #[doc = " \"interior\","] #[doc = " \"exterior\","] #[doc = " null"] #[doc = " ]"] #[doc = " },"] #[doc = " \"mesh\": {"] #[doc = " \"$ref\": \"#/definitions/stringOrSignal\""] #[doc = " },"] #[doc = " \"property\": {"] #[doc = " \"$ref\": \"#/definitions/stringOrSignal\""] #[doc = " },"] #[doc = " \"type\": {"] #[doc = " \"enum\": ["] #[doc = " \"topojson\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged, deny_unknown_fields)] pub enum DataVariant3FormatVariant0Subtype4 { Variant0 { feature: StringOrSignal, #[serde(default, skip_serializing_if = "Option::is_none")] property: Option, #[serde(rename = "type")] type_: DataVariant3FormatVariant0Subtype4Variant0Type, }, Variant1 { #[serde(default, skip_serializing_if = "Option::is_none")] filter: Option, mesh: StringOrSignal, #[serde(default, skip_serializing_if = "Option::is_none")] property: Option, #[serde(rename = "type")] type_: DataVariant3FormatVariant0Subtype4Variant1Type, }, } impl From<&DataVariant3FormatVariant0Subtype4> for DataVariant3FormatVariant0Subtype4 { fn from(value: &DataVariant3FormatVariant0Subtype4) -> Self { value.clone() } } #[doc = "DataVariant3FormatVariant0Subtype4Variant0Type"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"enum\": ["] #[doc = " \"topojson\""] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] pub enum DataVariant3FormatVariant0Subtype4Variant0Type { #[serde(rename = "topojson")] Topojson, } impl From<&DataVariant3FormatVariant0Subtype4Variant0Type> for DataVariant3FormatVariant0Subtype4Variant0Type { fn from(value: &DataVariant3FormatVariant0Subtype4Variant0Type) -> Self { value.clone() } } impl ::std::fmt::Display for DataVariant3FormatVariant0Subtype4Variant0Type { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match *self { Self::Topojson => write!(f, "topojson"), } } } impl std::str::FromStr for DataVariant3FormatVariant0Subtype4Variant0Type { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { match value { "topojson" => Ok(Self::Topojson), _ => Err("invalid value".into()), } } } impl std::convert::TryFrom<&str> for DataVariant3FormatVariant0Subtype4Variant0Type { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for DataVariant3FormatVariant0Subtype4Variant0Type { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for DataVariant3FormatVariant0Subtype4Variant0Type { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } #[doc = "DataVariant3FormatVariant0Subtype4Variant1Filter"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"enum\": ["] #[doc = " \"interior\","] #[doc = " \"exterior\","] #[doc = " null"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] pub enum DataVariant3FormatVariant0Subtype4Variant1Filter { #[serde(rename = "interior")] Interior, #[serde(rename = "exterior")] Exterior, } impl From<&DataVariant3FormatVariant0Subtype4Variant1Filter> for DataVariant3FormatVariant0Subtype4Variant1Filter { fn from(value: &DataVariant3FormatVariant0Subtype4Variant1Filter) -> Self { value.clone() } } impl ::std::fmt::Display for DataVariant3FormatVariant0Subtype4Variant1Filter { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match *self { Self::Interior => write!(f, "interior"), Self::Exterior => write!(f, "exterior"), } } } impl std::str::FromStr for DataVariant3FormatVariant0Subtype4Variant1Filter { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { match value { "interior" => Ok(Self::Interior), "exterior" => Ok(Self::Exterior), _ => Err("invalid value".into()), } } } impl std::convert::TryFrom<&str> for DataVariant3FormatVariant0Subtype4Variant1Filter { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for DataVariant3FormatVariant0Subtype4Variant1Filter { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for DataVariant3FormatVariant0Subtype4Variant1Filter { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } #[doc = "DataVariant3FormatVariant0Subtype4Variant1Type"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"enum\": ["] #[doc = " \"topojson\""] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] pub enum DataVariant3FormatVariant0Subtype4Variant1Type { #[serde(rename = "topojson")] Topojson, } impl From<&DataVariant3FormatVariant0Subtype4Variant1Type> for DataVariant3FormatVariant0Subtype4Variant1Type { fn from(value: &DataVariant3FormatVariant0Subtype4Variant1Type) -> Self { value.clone() } } impl ::std::fmt::Display for DataVariant3FormatVariant0Subtype4Variant1Type { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match *self { Self::Topojson => write!(f, "topojson"), } } } impl std::str::FromStr for DataVariant3FormatVariant0Subtype4Variant1Type { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { match value { "topojson" => Ok(Self::Topojson), _ => Err("invalid value".into()), } } } impl std::convert::TryFrom<&str> for DataVariant3FormatVariant0Subtype4Variant1Type { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for DataVariant3FormatVariant0Subtype4Variant1Type { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for DataVariant3FormatVariant0Subtype4Variant1Type { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } #[doc = "DataVariant3Values"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {},"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum DataVariant3Values { Variant0(::serde_json::Value), Variant1(SignalRef), } impl From<&DataVariant3Values> for DataVariant3Values { fn from(value: &DataVariant3Values) -> Self { value.clone() } } impl From<::serde_json::Value> for DataVariant3Values { fn from(value: ::serde_json::Value) -> Self { Self::Variant0(value) } } impl From for DataVariant3Values { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "DensityTransform"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"type\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"as\": {"] #[doc = " \"default\": ["] #[doc = " \"value\","] #[doc = " \"density\""] #[doc = " ],"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"distribution\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"function\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"function\": {"] #[doc = " \"enum\": ["] #[doc = " \"normal\""] #[doc = " ]"] #[doc = " },"] #[doc = " \"mean\": {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"stdev\": {"] #[doc = " \"default\": 1,"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"function\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"function\": {"] #[doc = " \"enum\": ["] #[doc = " \"lognormal\""] #[doc = " ]"] #[doc = " },"] #[doc = " \"mean\": {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"stdev\": {"] #[doc = " \"default\": 1,"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"function\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"function\": {"] #[doc = " \"enum\": ["] #[doc = " \"uniform\""] #[doc = " ]"] #[doc = " },"] #[doc = " \"max\": {"] #[doc = " \"default\": 1,"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"min\": {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\","] #[doc = " \"function\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"bandwidth\": {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"field\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/scaleField\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/paramField\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/expr\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"from\": {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " \"function\": {"] #[doc = " \"enum\": ["] #[doc = " \"kde\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"function\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"distributions\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {}"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"function\": {"] #[doc = " \"enum\": ["] #[doc = " \"mixture\""] #[doc = " ]"] #[doc = " },"] #[doc = " \"weights\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"extent\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"maxItems\": 2,"] #[doc = " \"minItems\": 2"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"maxsteps\": {"] #[doc = " \"default\": 200,"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"method\": {"] #[doc = " \"default\": \"pdf\","] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"minsteps\": {"] #[doc = " \"default\": 25,"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"signal\": {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " \"steps\": {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"type\": {"] #[doc = " \"enum\": ["] #[doc = " \"density\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(deny_unknown_fields)] pub struct DensityTransform { #[serde(rename = "as", default = "defaults::density_transform_as")] pub as_: DensityTransformAs, #[serde(default, skip_serializing_if = "Option::is_none")] pub distribution: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub extent: Option, #[serde(default = "defaults::density_transform_maxsteps")] pub maxsteps: DensityTransformMaxsteps, #[serde(default = "defaults::density_transform_method")] pub method: DensityTransformMethod, #[serde(default = "defaults::density_transform_minsteps")] pub minsteps: DensityTransformMinsteps, #[serde(default, skip_serializing_if = "Option::is_none")] pub signal: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub steps: Option, #[serde(rename = "type")] pub type_: DensityTransformType, } impl From<&DensityTransform> for DensityTransform { fn from(value: &DensityTransform) -> Self { value.clone() } } #[doc = "DensityTransformAs"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"default\": ["] #[doc = " \"value\","] #[doc = " \"density\""] #[doc = " ],"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum DensityTransformAs { Variant0(Vec), Variant1(SignalRef), } impl From<&DensityTransformAs> for DensityTransformAs { fn from(value: &DensityTransformAs) -> Self { value.clone() } } impl Default for DensityTransformAs { fn default() -> Self { DensityTransformAs::Variant0(vec![ DensityTransformAsVariant0Item::Variant0("value".to_string()), DensityTransformAsVariant0Item::Variant0("density".to_string()), ]) } } impl From> for DensityTransformAs { fn from(value: Vec) -> Self { Self::Variant0(value) } } impl From for DensityTransformAs { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "DensityTransformAsVariant0Item"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum DensityTransformAsVariant0Item { Variant0(String), Variant1(SignalRef), } impl From<&DensityTransformAsVariant0Item> for DensityTransformAsVariant0Item { fn from(value: &DensityTransformAsVariant0Item) -> Self { value.clone() } } impl From for DensityTransformAsVariant0Item { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "DensityTransformDistribution"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"function\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"function\": {"] #[doc = " \"enum\": ["] #[doc = " \"normal\""] #[doc = " ]"] #[doc = " },"] #[doc = " \"mean\": {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"stdev\": {"] #[doc = " \"default\": 1,"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"function\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"function\": {"] #[doc = " \"enum\": ["] #[doc = " \"lognormal\""] #[doc = " ]"] #[doc = " },"] #[doc = " \"mean\": {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"stdev\": {"] #[doc = " \"default\": 1,"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"function\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"function\": {"] #[doc = " \"enum\": ["] #[doc = " \"uniform\""] #[doc = " ]"] #[doc = " },"] #[doc = " \"max\": {"] #[doc = " \"default\": 1,"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"min\": {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\","] #[doc = " \"function\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"bandwidth\": {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"field\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/scaleField\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/paramField\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/expr\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"from\": {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " \"function\": {"] #[doc = " \"enum\": ["] #[doc = " \"kde\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"function\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"distributions\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {}"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"function\": {"] #[doc = " \"enum\": ["] #[doc = " \"mixture\""] #[doc = " ]"] #[doc = " },"] #[doc = " \"weights\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(tag = "function", deny_unknown_fields)] pub enum DensityTransformDistribution { #[serde(rename = "normal")] Normal { #[serde(default, skip_serializing_if = "Option::is_none")] mean: Option, #[serde(default = "defaults::density_transform_distribution_normal_stdev")] stdev: DensityTransformDistributionStdev, }, #[serde(rename = "lognormal")] Lognormal { #[serde(default, skip_serializing_if = "Option::is_none")] mean: Option, #[serde(default = "defaults::density_transform_distribution_lognormal_stdev")] stdev: DensityTransformDistributionStdev, }, #[serde(rename = "uniform")] Uniform { #[serde(default = "defaults::density_transform_distribution_uniform_max")] max: DensityTransformDistributionMax, #[serde(default, skip_serializing_if = "Option::is_none")] min: Option, }, #[serde(rename = "kde")] Kde { #[serde(default, skip_serializing_if = "Option::is_none")] bandwidth: Option, field: DensityTransformDistributionField, #[serde(default, skip_serializing_if = "Option::is_none")] from: Option, }, #[serde(rename = "mixture")] Mixture { #[serde(default, skip_serializing_if = "Option::is_none")] distributions: Option, #[serde(default, skip_serializing_if = "Option::is_none")] weights: Option, }, } impl From<&DensityTransformDistribution> for DensityTransformDistribution { fn from(value: &DensityTransformDistribution) -> Self { value.clone() } } #[doc = "DensityTransformDistributionBandwidth"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum DensityTransformDistributionBandwidth { Variant0(f64), Variant1(SignalRef), } impl From<&DensityTransformDistributionBandwidth> for DensityTransformDistributionBandwidth { fn from(value: &DensityTransformDistributionBandwidth) -> Self { value.clone() } } impl From for DensityTransformDistributionBandwidth { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for DensityTransformDistributionBandwidth { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "DensityTransformDistributionDistributions"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {}"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum DensityTransformDistributionDistributions { Variant0(Vec<::serde_json::Value>), Variant1(SignalRef), } impl From<&DensityTransformDistributionDistributions> for DensityTransformDistributionDistributions { fn from(value: &DensityTransformDistributionDistributions) -> Self { value.clone() } } impl From> for DensityTransformDistributionDistributions { fn from(value: Vec<::serde_json::Value>) -> Self { Self::Variant0(value) } } impl From for DensityTransformDistributionDistributions { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "DensityTransformDistributionField"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/scaleField\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/paramField\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/expr\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum DensityTransformDistributionField { ScaleField(ScaleField), ParamField(ParamField), Expr(Expr), } impl From<&DensityTransformDistributionField> for DensityTransformDistributionField { fn from(value: &DensityTransformDistributionField) -> Self { value.clone() } } impl From for DensityTransformDistributionField { fn from(value: ScaleField) -> Self { Self::ScaleField(value) } } impl From for DensityTransformDistributionField { fn from(value: ParamField) -> Self { Self::ParamField(value) } } impl From for DensityTransformDistributionField { fn from(value: Expr) -> Self { Self::Expr(value) } } #[doc = "DensityTransformDistributionMax"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"default\": 1,"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum DensityTransformDistributionMax { Variant0(f64), Variant1(SignalRef), } impl From<&DensityTransformDistributionMax> for DensityTransformDistributionMax { fn from(value: &DensityTransformDistributionMax) -> Self { value.clone() } } impl Default for DensityTransformDistributionMax { fn default() -> Self { DensityTransformDistributionMax::Variant0(1_f64) } } impl From for DensityTransformDistributionMax { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for DensityTransformDistributionMax { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "DensityTransformDistributionMean"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum DensityTransformDistributionMean { Variant0(f64), Variant1(SignalRef), } impl From<&DensityTransformDistributionMean> for DensityTransformDistributionMean { fn from(value: &DensityTransformDistributionMean) -> Self { value.clone() } } impl From for DensityTransformDistributionMean { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for DensityTransformDistributionMean { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "DensityTransformDistributionMin"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum DensityTransformDistributionMin { Variant0(f64), Variant1(SignalRef), } impl From<&DensityTransformDistributionMin> for DensityTransformDistributionMin { fn from(value: &DensityTransformDistributionMin) -> Self { value.clone() } } impl From for DensityTransformDistributionMin { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for DensityTransformDistributionMin { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "DensityTransformDistributionStdev"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"default\": 1,"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum DensityTransformDistributionStdev { Variant0(f64), Variant1(SignalRef), } impl From<&DensityTransformDistributionStdev> for DensityTransformDistributionStdev { fn from(value: &DensityTransformDistributionStdev) -> Self { value.clone() } } impl Default for DensityTransformDistributionStdev { fn default() -> Self { DensityTransformDistributionStdev::Variant0(1_f64) } } impl From for DensityTransformDistributionStdev { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for DensityTransformDistributionStdev { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "DensityTransformDistributionWeights"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum DensityTransformDistributionWeights { Variant0(Vec), Variant1(SignalRef), } impl From<&DensityTransformDistributionWeights> for DensityTransformDistributionWeights { fn from(value: &DensityTransformDistributionWeights) -> Self { value.clone() } } impl From> for DensityTransformDistributionWeights { fn from(value: Vec) -> Self { Self::Variant0(value) } } impl From for DensityTransformDistributionWeights { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "DensityTransformDistributionWeightsVariant0Item"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum DensityTransformDistributionWeightsVariant0Item { Variant0(f64), Variant1(SignalRef), } impl From<&DensityTransformDistributionWeightsVariant0Item> for DensityTransformDistributionWeightsVariant0Item { fn from(value: &DensityTransformDistributionWeightsVariant0Item) -> Self { value.clone() } } impl From for DensityTransformDistributionWeightsVariant0Item { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for DensityTransformDistributionWeightsVariant0Item { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "DensityTransformExtent"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"maxItems\": 2,"] #[doc = " \"minItems\": 2"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum DensityTransformExtent { Variant0([DensityTransformExtentVariant0Item; 2usize]), Variant1(SignalRef), } impl From<&DensityTransformExtent> for DensityTransformExtent { fn from(value: &DensityTransformExtent) -> Self { value.clone() } } impl From<[DensityTransformExtentVariant0Item; 2usize]> for DensityTransformExtent { fn from(value: [DensityTransformExtentVariant0Item; 2usize]) -> Self { Self::Variant0(value) } } impl From for DensityTransformExtent { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "DensityTransformExtentVariant0Item"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum DensityTransformExtentVariant0Item { Variant0(f64), Variant1(SignalRef), } impl From<&DensityTransformExtentVariant0Item> for DensityTransformExtentVariant0Item { fn from(value: &DensityTransformExtentVariant0Item) -> Self { value.clone() } } impl From for DensityTransformExtentVariant0Item { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for DensityTransformExtentVariant0Item { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "DensityTransformMaxsteps"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"default\": 200,"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum DensityTransformMaxsteps { Variant0(f64), Variant1(SignalRef), } impl From<&DensityTransformMaxsteps> for DensityTransformMaxsteps { fn from(value: &DensityTransformMaxsteps) -> Self { value.clone() } } impl Default for DensityTransformMaxsteps { fn default() -> Self { DensityTransformMaxsteps::Variant0(200_f64) } } impl From for DensityTransformMaxsteps { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for DensityTransformMaxsteps { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "DensityTransformMethod"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"default\": \"pdf\","] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum DensityTransformMethod { Variant0(String), Variant1(SignalRef), } impl From<&DensityTransformMethod> for DensityTransformMethod { fn from(value: &DensityTransformMethod) -> Self { value.clone() } } impl Default for DensityTransformMethod { fn default() -> Self { DensityTransformMethod::Variant0("pdf".to_string()) } } impl From for DensityTransformMethod { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "DensityTransformMinsteps"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"default\": 25,"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum DensityTransformMinsteps { Variant0(f64), Variant1(SignalRef), } impl From<&DensityTransformMinsteps> for DensityTransformMinsteps { fn from(value: &DensityTransformMinsteps) -> Self { value.clone() } } impl Default for DensityTransformMinsteps { fn default() -> Self { DensityTransformMinsteps::Variant0(25_f64) } } impl From for DensityTransformMinsteps { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for DensityTransformMinsteps { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "DensityTransformSteps"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum DensityTransformSteps { Variant0(f64), Variant1(SignalRef), } impl From<&DensityTransformSteps> for DensityTransformSteps { fn from(value: &DensityTransformSteps) -> Self { value.clone() } } impl From for DensityTransformSteps { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for DensityTransformSteps { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "DensityTransformType"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"enum\": ["] #[doc = " \"density\""] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] pub enum DensityTransformType { #[serde(rename = "density")] Density, } impl From<&DensityTransformType> for DensityTransformType { fn from(value: &DensityTransformType) -> Self { value.clone() } } impl ::std::fmt::Display for DensityTransformType { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match *self { Self::Density => write!(f, "density"), } } } impl std::str::FromStr for DensityTransformType { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { match value { "density" => Ok(Self::Density), _ => Err("invalid value".into()), } } } impl std::convert::TryFrom<&str> for DensityTransformType { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for DensityTransformType { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for DensityTransformType { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } #[doc = "DirectionValue"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/rule\""] #[doc = " },"] #[doc = " {"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/stringModifiers\""] #[doc = " },"] #[doc = " {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"enum\": ["] #[doc = " \"horizontal\","] #[doc = " \"vertical\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/stringModifiers\""] #[doc = " },"] #[doc = " {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"enum\": ["] #[doc = " \"horizontal\","] #[doc = " \"vertical\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum DirectionValue { Variant0(Vec), Variant1(DirectionValueVariant1), } impl From<&DirectionValue> for DirectionValue { fn from(value: &DirectionValue) -> Self { value.clone() } } impl From> for DirectionValue { fn from(value: Vec) -> Self { Self::Variant0(value) } } impl From for DirectionValue { fn from(value: DirectionValueVariant1) -> Self { Self::Variant1(value) } } #[doc = "DirectionValueVariant0Item"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/rule\""] #[doc = " },"] #[doc = " {"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/stringModifiers\""] #[doc = " },"] #[doc = " {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"enum\": ["] #[doc = " \"horizontal\","] #[doc = " \"vertical\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum DirectionValueVariant0Item { Variant0(DirectionValueVariant0ItemVariant0), Variant1(DirectionValueVariant0ItemVariant1), Variant2(DirectionValueVariant0ItemVariant2), Variant3 { offset: ::serde_json::Value, #[serde(default, skip_serializing_if = "Option::is_none")] test: Option, }, } impl From<&DirectionValueVariant0Item> for DirectionValueVariant0Item { fn from(value: &DirectionValueVariant0Item) -> Self { value.clone() } } impl From for DirectionValueVariant0Item { fn from(value: DirectionValueVariant0ItemVariant0) -> Self { Self::Variant0(value) } } impl From for DirectionValueVariant0Item { fn from(value: DirectionValueVariant0ItemVariant1) -> Self { Self::Variant1(value) } } impl From for DirectionValueVariant0Item { fn from(value: DirectionValueVariant0ItemVariant2) -> Self { Self::Variant2(value) } } #[doc = "DirectionValueVariant0ItemVariant0"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"scale\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " },"] #[doc = " \"test\": {"] #[doc = " \"type\": \"string\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"enum\": ["] #[doc = " \"horizontal\","] #[doc = " \"vertical\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum DirectionValueVariant0ItemVariant0 { Variant0 { #[serde(default, skip_serializing_if = "Option::is_none")] scale: Option, signal: String, #[serde(default, skip_serializing_if = "Option::is_none")] test: Option, }, Variant1 { #[serde(default, skip_serializing_if = "Option::is_none")] scale: Option, #[serde(default, skip_serializing_if = "Option::is_none")] test: Option, value: DirectionValueVariant0ItemVariant0Variant1Value, }, Variant2 { field: Field, #[serde(default, skip_serializing_if = "Option::is_none")] scale: Option, #[serde(default, skip_serializing_if = "Option::is_none")] test: Option, }, Variant3 { range: DirectionValueVariant0ItemVariant0Variant3Range, #[serde(default, skip_serializing_if = "Option::is_none")] scale: Option, #[serde(default, skip_serializing_if = "Option::is_none")] test: Option, }, } impl From<&DirectionValueVariant0ItemVariant0> for DirectionValueVariant0ItemVariant0 { fn from(value: &DirectionValueVariant0ItemVariant0) -> Self { value.clone() } } #[doc = "DirectionValueVariant0ItemVariant0Variant1Value"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"enum\": ["] #[doc = " \"horizontal\","] #[doc = " \"vertical\""] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] pub enum DirectionValueVariant0ItemVariant0Variant1Value { #[serde(rename = "horizontal")] Horizontal, #[serde(rename = "vertical")] Vertical, } impl From<&DirectionValueVariant0ItemVariant0Variant1Value> for DirectionValueVariant0ItemVariant0Variant1Value { fn from(value: &DirectionValueVariant0ItemVariant0Variant1Value) -> Self { value.clone() } } impl ::std::fmt::Display for DirectionValueVariant0ItemVariant0Variant1Value { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match *self { Self::Horizontal => write!(f, "horizontal"), Self::Vertical => write!(f, "vertical"), } } } impl std::str::FromStr for DirectionValueVariant0ItemVariant0Variant1Value { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { match value { "horizontal" => Ok(Self::Horizontal), "vertical" => Ok(Self::Vertical), _ => Err("invalid value".into()), } } } impl std::convert::TryFrom<&str> for DirectionValueVariant0ItemVariant0Variant1Value { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for DirectionValueVariant0ItemVariant0Variant1Value { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for DirectionValueVariant0ItemVariant0Variant1Value { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } #[doc = "DirectionValueVariant0ItemVariant0Variant3Range"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum DirectionValueVariant0ItemVariant0Variant3Range { Variant0(f64), Variant1(bool), } impl From<&DirectionValueVariant0ItemVariant0Variant3Range> for DirectionValueVariant0ItemVariant0Variant3Range { fn from(value: &DirectionValueVariant0ItemVariant0Variant3Range) -> Self { value.clone() } } impl std::str::FromStr for DirectionValueVariant0ItemVariant0Variant3Range { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { if let Ok(v) = value.parse() { Ok(Self::Variant0(v)) } else if let Ok(v) = value.parse() { Ok(Self::Variant1(v)) } else { Err("string conversion failed for all variants".into()) } } } impl std::convert::TryFrom<&str> for DirectionValueVariant0ItemVariant0Variant3Range { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for DirectionValueVariant0ItemVariant0Variant3Range { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for DirectionValueVariant0ItemVariant0Variant3Range { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } impl ::std::fmt::Display for DirectionValueVariant0ItemVariant0Variant3Range { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match self { Self::Variant0(x) => x.fmt(f), Self::Variant1(x) => x.fmt(f), } } } impl From for DirectionValueVariant0ItemVariant0Variant3Range { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for DirectionValueVariant0ItemVariant0Variant3Range { fn from(value: bool) -> Self { Self::Variant1(value) } } #[doc = "DirectionValueVariant0ItemVariant1"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"scale\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " },"] #[doc = " \"test\": {"] #[doc = " \"type\": \"string\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"enum\": ["] #[doc = " \"horizontal\","] #[doc = " \"vertical\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] #[serde(deny_unknown_fields)] pub enum DirectionValueVariant0ItemVariant1 {} impl From<&DirectionValueVariant0ItemVariant1> for DirectionValueVariant0ItemVariant1 { fn from(value: &DirectionValueVariant0ItemVariant1) -> Self { value.clone() } } #[doc = "DirectionValueVariant0ItemVariant2"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"scale\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " },"] #[doc = " \"test\": {"] #[doc = " \"type\": \"string\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"enum\": ["] #[doc = " \"horizontal\","] #[doc = " \"vertical\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] #[serde(deny_unknown_fields)] pub enum DirectionValueVariant0ItemVariant2 {} impl From<&DirectionValueVariant0ItemVariant2> for DirectionValueVariant0ItemVariant2 { fn from(value: &DirectionValueVariant0ItemVariant2) -> Self { value.clone() } } #[doc = "DirectionValueVariant1"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/stringModifiers\""] #[doc = " },"] #[doc = " {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"enum\": ["] #[doc = " \"horizontal\","] #[doc = " \"vertical\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum DirectionValueVariant1 { Variant0(DirectionValueVariant1Variant0), Variant1(DirectionValueVariant1Variant1), Variant2(DirectionValueVariant1Variant2), Variant3 { offset: ::serde_json::Value }, } impl From<&DirectionValueVariant1> for DirectionValueVariant1 { fn from(value: &DirectionValueVariant1) -> Self { value.clone() } } impl From for DirectionValueVariant1 { fn from(value: DirectionValueVariant1Variant0) -> Self { Self::Variant0(value) } } impl From for DirectionValueVariant1 { fn from(value: DirectionValueVariant1Variant1) -> Self { Self::Variant1(value) } } impl From for DirectionValueVariant1 { fn from(value: DirectionValueVariant1Variant2) -> Self { Self::Variant2(value) } } #[doc = "DirectionValueVariant1Variant0"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"scale\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"enum\": ["] #[doc = " \"horizontal\","] #[doc = " \"vertical\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum DirectionValueVariant1Variant0 { Variant0 { #[serde(default, skip_serializing_if = "Option::is_none")] scale: Option, signal: String, }, Variant1 { #[serde(default, skip_serializing_if = "Option::is_none")] scale: Option, value: DirectionValueVariant1Variant0Variant1Value, }, Variant2 { field: Field, #[serde(default, skip_serializing_if = "Option::is_none")] scale: Option, }, Variant3 { range: DirectionValueVariant1Variant0Variant3Range, #[serde(default, skip_serializing_if = "Option::is_none")] scale: Option, }, } impl From<&DirectionValueVariant1Variant0> for DirectionValueVariant1Variant0 { fn from(value: &DirectionValueVariant1Variant0) -> Self { value.clone() } } #[doc = "DirectionValueVariant1Variant0Variant1Value"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"enum\": ["] #[doc = " \"horizontal\","] #[doc = " \"vertical\""] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] pub enum DirectionValueVariant1Variant0Variant1Value { #[serde(rename = "horizontal")] Horizontal, #[serde(rename = "vertical")] Vertical, } impl From<&DirectionValueVariant1Variant0Variant1Value> for DirectionValueVariant1Variant0Variant1Value { fn from(value: &DirectionValueVariant1Variant0Variant1Value) -> Self { value.clone() } } impl ::std::fmt::Display for DirectionValueVariant1Variant0Variant1Value { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match *self { Self::Horizontal => write!(f, "horizontal"), Self::Vertical => write!(f, "vertical"), } } } impl std::str::FromStr for DirectionValueVariant1Variant0Variant1Value { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { match value { "horizontal" => Ok(Self::Horizontal), "vertical" => Ok(Self::Vertical), _ => Err("invalid value".into()), } } } impl std::convert::TryFrom<&str> for DirectionValueVariant1Variant0Variant1Value { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for DirectionValueVariant1Variant0Variant1Value { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for DirectionValueVariant1Variant0Variant1Value { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } #[doc = "DirectionValueVariant1Variant0Variant3Range"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum DirectionValueVariant1Variant0Variant3Range { Variant0(f64), Variant1(bool), } impl From<&DirectionValueVariant1Variant0Variant3Range> for DirectionValueVariant1Variant0Variant3Range { fn from(value: &DirectionValueVariant1Variant0Variant3Range) -> Self { value.clone() } } impl std::str::FromStr for DirectionValueVariant1Variant0Variant3Range { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { if let Ok(v) = value.parse() { Ok(Self::Variant0(v)) } else if let Ok(v) = value.parse() { Ok(Self::Variant1(v)) } else { Err("string conversion failed for all variants".into()) } } } impl std::convert::TryFrom<&str> for DirectionValueVariant1Variant0Variant3Range { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for DirectionValueVariant1Variant0Variant3Range { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for DirectionValueVariant1Variant0Variant3Range { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } impl ::std::fmt::Display for DirectionValueVariant1Variant0Variant3Range { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match self { Self::Variant0(x) => x.fmt(f), Self::Variant1(x) => x.fmt(f), } } } impl From for DirectionValueVariant1Variant0Variant3Range { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for DirectionValueVariant1Variant0Variant3Range { fn from(value: bool) -> Self { Self::Variant1(value) } } #[doc = "DirectionValueVariant1Variant1"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"scale\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"enum\": ["] #[doc = " \"horizontal\","] #[doc = " \"vertical\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] #[serde(deny_unknown_fields)] pub enum DirectionValueVariant1Variant1 {} impl From<&DirectionValueVariant1Variant1> for DirectionValueVariant1Variant1 { fn from(value: &DirectionValueVariant1Variant1) -> Self { value.clone() } } #[doc = "DirectionValueVariant1Variant2"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"scale\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"band\","] #[doc = " \"scale\""] #[doc = " ]"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"value\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"value\": {"] #[doc = " \"enum\": ["] #[doc = " \"horizontal\","] #[doc = " \"vertical\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"field\": {"] #[doc = " \"$ref\": \"#/definitions/field\""] #[doc = " }"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"range\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"range\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"scale\","] #[doc = " \"value\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"not\": {"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"offset\""] #[doc = " ]"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] #[serde(deny_unknown_fields)] pub enum DirectionValueVariant1Variant2 {} impl From<&DirectionValueVariant1Variant2> for DirectionValueVariant1Variant2 { fn from(value: &DirectionValueVariant1Variant2) -> Self { value.clone() } } #[doc = "DotbinTransform"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"type\": \"object\","] #[doc = " \"required\": ["] #[doc = " \"field\","] #[doc = " \"type\""] #[doc = " ],"] #[doc = " \"properties\": {"] #[doc = " \"as\": {"] #[doc = " \"default\": \"bin\","] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"field\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/scaleField\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/paramField\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/expr\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"groupby\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/scaleField\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/paramField\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/expr\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"signal\": {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " \"smooth\": {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"step\": {"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = " },"] #[doc = " \"type\": {"] #[doc = " \"enum\": ["] #[doc = " \"dotbin\""] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(deny_unknown_fields)] pub struct DotbinTransform { #[serde(rename = "as", default = "defaults::dotbin_transform_as")] pub as_: DotbinTransformAs, pub field: DotbinTransformField, #[serde(default, skip_serializing_if = "Option::is_none")] pub groupby: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub signal: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub smooth: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub step: Option, #[serde(rename = "type")] pub type_: DotbinTransformType, } impl From<&DotbinTransform> for DotbinTransform { fn from(value: &DotbinTransform) -> Self { value.clone() } } #[doc = "DotbinTransformAs"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"default\": \"bin\","] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum DotbinTransformAs { Variant0(String), Variant1(SignalRef), } impl From<&DotbinTransformAs> for DotbinTransformAs { fn from(value: &DotbinTransformAs) -> Self { value.clone() } } impl Default for DotbinTransformAs { fn default() -> Self { DotbinTransformAs::Variant0("bin".to_string()) } } impl From for DotbinTransformAs { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "DotbinTransformField"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/scaleField\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/paramField\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/expr\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum DotbinTransformField { ScaleField(ScaleField), ParamField(ParamField), Expr(Expr), } impl From<&DotbinTransformField> for DotbinTransformField { fn from(value: &DotbinTransformField) -> Self { value.clone() } } impl From for DotbinTransformField { fn from(value: ScaleField) -> Self { Self::ScaleField(value) } } impl From for DotbinTransformField { fn from(value: ParamField) -> Self { Self::ParamField(value) } } impl From for DotbinTransformField { fn from(value: Expr) -> Self { Self::Expr(value) } } #[doc = "DotbinTransformGroupby"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"type\": \"array\","] #[doc = " \"items\": {"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/scaleField\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/paramField\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/expr\""] #[doc = " }"] #[doc = " ]"] #[doc = " }"] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum DotbinTransformGroupby { Variant0(Vec), Variant1(SignalRef), } impl From<&DotbinTransformGroupby> for DotbinTransformGroupby { fn from(value: &DotbinTransformGroupby) -> Self { value.clone() } } impl From> for DotbinTransformGroupby { fn from(value: Vec) -> Self { Self::Variant0(value) } } impl From for DotbinTransformGroupby { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "DotbinTransformGroupbyVariant0Item"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"oneOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/scaleField\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/paramField\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/expr\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum DotbinTransformGroupbyVariant0Item { ScaleField(ScaleField), ParamField(ParamField), Expr(Expr), } impl From<&DotbinTransformGroupbyVariant0Item> for DotbinTransformGroupbyVariant0Item { fn from(value: &DotbinTransformGroupbyVariant0Item) -> Self { value.clone() } } impl From for DotbinTransformGroupbyVariant0Item { fn from(value: ScaleField) -> Self { Self::ScaleField(value) } } impl From for DotbinTransformGroupbyVariant0Item { fn from(value: ParamField) -> Self { Self::ParamField(value) } } impl From for DotbinTransformGroupbyVariant0Item { fn from(value: Expr) -> Self { Self::Expr(value) } } #[doc = "DotbinTransformSmooth"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"boolean\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum DotbinTransformSmooth { Variant0(bool), Variant1(SignalRef), } impl From<&DotbinTransformSmooth> for DotbinTransformSmooth { fn from(value: &DotbinTransformSmooth) -> Self { value.clone() } } impl From for DotbinTransformSmooth { fn from(value: bool) -> Self { Self::Variant0(value) } } impl From for DotbinTransformSmooth { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "DotbinTransformStep"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"anyOf\": ["] #[doc = " {"] #[doc = " \"type\": \"number\""] #[doc = " },"] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/signalRef\""] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] #[serde(untagged)] pub enum DotbinTransformStep { Variant0(f64), Variant1(SignalRef), } impl From<&DotbinTransformStep> for DotbinTransformStep { fn from(value: &DotbinTransformStep) -> Self { value.clone() } } impl From for DotbinTransformStep { fn from(value: f64) -> Self { Self::Variant0(value) } } impl From for DotbinTransformStep { fn from(value: SignalRef) -> Self { Self::Variant1(value) } } #[doc = "DotbinTransformType"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"enum\": ["] #[doc = " \"dotbin\""] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] pub enum DotbinTransformType { #[serde(rename = "dotbin")] Dotbin, } impl From<&DotbinTransformType> for DotbinTransformType { fn from(value: &DotbinTransformType) -> Self { value.clone() } } impl ::std::fmt::Display for DotbinTransformType { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { match *self { Self::Dotbin => write!(f, "dotbin"), } } } impl std::str::FromStr for DotbinTransformType { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { match value { "dotbin" => Ok(Self::Dotbin), _ => Err("invalid value".into()), } } } impl std::convert::TryFrom<&str> for DotbinTransformType { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl std::convert::TryFrom<&String> for DotbinTransformType { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl std::convert::TryFrom for DotbinTransformType { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } #[doc = "Element"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"type\": \"string\""] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive( :: serde :: Deserialize, :: serde :: Serialize, Clone, Debug, Eq, Hash, Ord, PartialEq, PartialOrd, )] pub struct Element(pub String); impl ::std::ops::Deref for Element { type Target = String; fn deref(&self) -> &String { &self.0 } } impl From for String { fn from(value: Element) -> Self { value.0 } } impl From<&Element> for Element { fn from(value: &Element) -> Self { value.clone() } } impl From for Element { fn from(value: String) -> Self { Self(value) } } impl std::str::FromStr for Element { type Err = std::convert::Infallible; fn from_str(value: &str) -> Result { Ok(Self(value.to_string())) } } impl ::std::fmt::Display for Element { fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result { self.0.fmt(f) } } #[doc = "Encode"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"type\": \"object\","] #[doc = " \"patternProperties\": {"] #[doc = " \"^.+$\": {"] #[doc = " \"$ref\": \"#/definitions/encodeEntry\""] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": false"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] pub struct Encode(pub ::std::collections::HashMap); impl ::std::ops::Deref for Encode { type Target = ::std::collections::HashMap; fn deref(&self) -> &::std::collections::HashMap { &self.0 } } impl From for ::std::collections::HashMap { fn from(value: Encode) -> Self { value.0 } } impl From<&Encode> for Encode { fn from(value: &Encode) -> Self { value.clone() } } impl From<::std::collections::HashMap> for Encode { fn from(value: ::std::collections::HashMap) -> Self { Self(value) } } #[doc = "EncodeEntry"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"type\": \"object\","] #[doc = " \"properties\": {"] #[doc = " \"align\": {"] #[doc = " \"$ref\": \"#/definitions/alignValue\""] #[doc = " },"] #[doc = " \"angle\": {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " },"] #[doc = " \"aria\": {"] #[doc = " \"$ref\": \"#/definitions/booleanValue\""] #[doc = " },"] #[doc = " \"ariaRole\": {"] #[doc = " \"$ref\": \"#/definitions/stringValue\""] #[doc = " },"] #[doc = " \"ariaRoleDescription\": {"] #[doc = " \"$ref\": \"#/definitions/stringValue\""] #[doc = " },"] #[doc = " \"aspect\": {"] #[doc = " \"$ref\": \"#/definitions/booleanValue\""] #[doc = " },"] #[doc = " \"baseline\": {"] #[doc = " \"$ref\": \"#/definitions/baselineValue\""] #[doc = " },"] #[doc = " \"blend\": {"] #[doc = " \"$ref\": \"#/definitions/blendValue\""] #[doc = " },"] #[doc = " \"clip\": {"] #[doc = " \"$ref\": \"#/definitions/booleanValue\""] #[doc = " },"] #[doc = " \"cornerRadius\": {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " },"] #[doc = " \"cornerRadiusBottomLeft\": {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " },"] #[doc = " \"cornerRadiusBottomRight\": {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " },"] #[doc = " \"cornerRadiusTopLeft\": {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " },"] #[doc = " \"cornerRadiusTopRight\": {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " },"] #[doc = " \"cursor\": {"] #[doc = " \"$ref\": \"#/definitions/stringValue\""] #[doc = " },"] #[doc = " \"defined\": {"] #[doc = " \"$ref\": \"#/definitions/booleanValue\""] #[doc = " },"] #[doc = " \"description\": {"] #[doc = " \"$ref\": \"#/definitions/stringValue\""] #[doc = " },"] #[doc = " \"dir\": {"] #[doc = " \"$ref\": \"#/definitions/stringValue\""] #[doc = " },"] #[doc = " \"dx\": {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " },"] #[doc = " \"dy\": {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " },"] #[doc = " \"ellipsis\": {"] #[doc = " \"$ref\": \"#/definitions/stringValue\""] #[doc = " },"] #[doc = " \"endAngle\": {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " },"] #[doc = " \"fill\": {"] #[doc = " \"$ref\": \"#/definitions/colorValue\""] #[doc = " },"] #[doc = " \"fillOpacity\": {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " },"] #[doc = " \"font\": {"] #[doc = " \"$ref\": \"#/definitions/stringValue\""] #[doc = " },"] #[doc = " \"fontSize\": {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " },"] #[doc = " \"fontStyle\": {"] #[doc = " \"$ref\": \"#/definitions/stringValue\""] #[doc = " },"] #[doc = " \"fontWeight\": {"] #[doc = " \"$ref\": \"#/definitions/fontWeightValue\""] #[doc = " },"] #[doc = " \"height\": {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " },"] #[doc = " \"innerRadius\": {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " },"] #[doc = " \"interpolate\": {"] #[doc = " \"$ref\": \"#/definitions/stringValue\""] #[doc = " },"] #[doc = " \"limit\": {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " },"] #[doc = " \"lineBreak\": {"] #[doc = " \"$ref\": \"#/definitions/stringValue\""] #[doc = " },"] #[doc = " \"lineHeight\": {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " },"] #[doc = " \"opacity\": {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " },"] #[doc = " \"orient\": {"] #[doc = " \"$ref\": \"#/definitions/directionValue\""] #[doc = " },"] #[doc = " \"outerRadius\": {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " },"] #[doc = " \"padAngle\": {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " },"] #[doc = " \"path\": {"] #[doc = " \"$ref\": \"#/definitions/stringValue\""] #[doc = " },"] #[doc = " \"radius\": {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " },"] #[doc = " \"scaleX\": {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " },"] #[doc = " \"scaleY\": {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " },"] #[doc = " \"shape\": {"] #[doc = " \"$ref\": \"#/definitions/stringValue\""] #[doc = " },"] #[doc = " \"size\": {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " },"] #[doc = " \"smooth\": {"] #[doc = " \"$ref\": \"#/definitions/booleanValue\""] #[doc = " },"] #[doc = " \"startAngle\": {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " },"] #[doc = " \"stroke\": {"] #[doc = " \"$ref\": \"#/definitions/colorValue\""] #[doc = " },"] #[doc = " \"strokeCap\": {"] #[doc = " \"$ref\": \"#/definitions/strokeCapValue\""] #[doc = " },"] #[doc = " \"strokeDash\": {"] #[doc = " \"$ref\": \"#/definitions/arrayValue\""] #[doc = " },"] #[doc = " \"strokeDashOffset\": {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " },"] #[doc = " \"strokeForeground\": {"] #[doc = " \"$ref\": \"#/definitions/booleanValue\""] #[doc = " },"] #[doc = " \"strokeJoin\": {"] #[doc = " \"$ref\": \"#/definitions/strokeJoinValue\""] #[doc = " },"] #[doc = " \"strokeMiterLimit\": {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " },"] #[doc = " \"strokeOffset\": {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " },"] #[doc = " \"strokeOpacity\": {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " },"] #[doc = " \"strokeWidth\": {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " },"] #[doc = " \"tension\": {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " },"] #[doc = " \"text\": {"] #[doc = " \"$ref\": \"#/definitions/textValue\""] #[doc = " },"] #[doc = " \"theta\": {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " },"] #[doc = " \"tooltip\": {"] #[doc = " \"$ref\": \"#/definitions/anyValue\""] #[doc = " },"] #[doc = " \"url\": {"] #[doc = " \"$ref\": \"#/definitions/stringValue\""] #[doc = " },"] #[doc = " \"width\": {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " },"] #[doc = " \"x\": {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " },"] #[doc = " \"x2\": {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " },"] #[doc = " \"xc\": {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " },"] #[doc = " \"y\": {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " },"] #[doc = " \"y2\": {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " },"] #[doc = " \"yc\": {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " },"] #[doc = " \"zindex\": {"] #[doc = " \"$ref\": \"#/definitions/numberValue\""] #[doc = " }"] #[doc = " },"] #[doc = " \"additionalProperties\": true"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] pub struct EncodeEntry { #[serde(default, skip_serializing_if = "Option::is_none")] pub align: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub angle: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub aria: Option, #[serde(rename = "ariaRole", default, skip_serializing_if = "Option::is_none")] pub aria_role: Option, #[serde( rename = "ariaRoleDescription", default, skip_serializing_if = "Option::is_none" )] pub aria_role_description: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub aspect: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub baseline: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub blend: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub clip: Option, #[serde( rename = "cornerRadius", default, skip_serializing_if = "Option::is_none" )] pub corner_radius: Option, #[serde( rename = "cornerRadiusBottomLeft", default, skip_serializing_if = "Option::is_none" )] pub corner_radius_bottom_left: Option, #[serde( rename = "cornerRadiusBottomRight", default, skip_serializing_if = "Option::is_none" )] pub corner_radius_bottom_right: Option, #[serde( rename = "cornerRadiusTopLeft", default, skip_serializing_if = "Option::is_none" )] pub corner_radius_top_left: Option, #[serde( rename = "cornerRadiusTopRight", default, skip_serializing_if = "Option::is_none" )] pub corner_radius_top_right: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub cursor: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub defined: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub description: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub dir: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub dx: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub dy: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub ellipsis: Option, #[serde(rename = "endAngle", default, skip_serializing_if = "Option::is_none")] pub end_angle: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub fill: Option, #[serde( rename = "fillOpacity", default, skip_serializing_if = "Option::is_none" )] pub fill_opacity: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub font: Option, #[serde(rename = "fontSize", default, skip_serializing_if = "Option::is_none")] pub font_size: Option, #[serde(rename = "fontStyle", default, skip_serializing_if = "Option::is_none")] pub font_style: Option, #[serde( rename = "fontWeight", default, skip_serializing_if = "Option::is_none" )] pub font_weight: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub height: Option, #[serde( rename = "innerRadius", default, skip_serializing_if = "Option::is_none" )] pub inner_radius: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub interpolate: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub limit: Option, #[serde(rename = "lineBreak", default, skip_serializing_if = "Option::is_none")] pub line_break: Option, #[serde( rename = "lineHeight", default, skip_serializing_if = "Option::is_none" )] pub line_height: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub opacity: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub orient: Option, #[serde( rename = "outerRadius", default, skip_serializing_if = "Option::is_none" )] pub outer_radius: Option, #[serde(rename = "padAngle", default, skip_serializing_if = "Option::is_none")] pub pad_angle: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub path: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub radius: Option, #[serde(rename = "scaleX", default, skip_serializing_if = "Option::is_none")] pub scale_x: Option, #[serde(rename = "scaleY", default, skip_serializing_if = "Option::is_none")] pub scale_y: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub shape: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub size: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub smooth: Option, #[serde( rename = "startAngle", default, skip_serializing_if = "Option::is_none" )] pub start_angle: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub stroke: Option, #[serde(rename = "strokeCap", default, skip_serializing_if = "Option::is_none")] pub stroke_cap: Option, #[serde( rename = "strokeDash", default, skip_serializing_if = "Option::is_none" )] pub stroke_dash: Option, #[serde( rename = "strokeDashOffset", default, skip_serializing_if = "Option::is_none" )] pub stroke_dash_offset: Option, #[serde( rename = "strokeForeground", default, skip_serializing_if = "Option::is_none" )] pub stroke_foreground: Option, #[serde( rename = "strokeJoin", default, skip_serializing_if = "Option::is_none" )] pub stroke_join: Option, #[serde( rename = "strokeMiterLimit", default, skip_serializing_if = "Option::is_none" )] pub stroke_miter_limit: Option, #[serde( rename = "strokeOffset", default, skip_serializing_if = "Option::is_none" )] pub stroke_offset: Option, #[serde( rename = "strokeOpacity", default, skip_serializing_if = "Option::is_none" )] pub stroke_opacity: Option, #[serde( rename = "strokeWidth", default, skip_serializing_if = "Option::is_none" )] pub stroke_width: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub tension: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub text: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub theta: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub tooltip: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub url: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub width: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub x: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub x2: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub xc: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub y: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub y2: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub yc: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub zindex: Option, } impl From<&EncodeEntry> for EncodeEntry { fn from(value: &EncodeEntry) -> Self { value.clone() } } #[doc = "EncodeKey"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"type\": \"string\","] #[doc = " \"pattern\": \"^.+$\""] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Serialize, Clone, Debug, Eq, Hash, Ord, PartialEq, PartialOrd)] pub struct EncodeKey(String); impl ::std::ops::Deref for EncodeKey { type Target = String; fn deref(&self) -> &String { &self.0 } } impl From for String { fn from(value: EncodeKey) -> Self { value.0 } } impl From<&EncodeKey> for EncodeKey { fn from(value: &EncodeKey) -> Self { value.clone() } } impl ::std::str::FromStr for EncodeKey { type Err = self::error::ConversionError; fn from_str(value: &str) -> Result { if regress::Regex::new("^.+$").unwrap().find(value).is_none() { return Err("doesn't match pattern \"^.+$\"".into()); } Ok(Self(value.to_string())) } } impl ::std::convert::TryFrom<&str> for EncodeKey { type Error = self::error::ConversionError; fn try_from(value: &str) -> Result { value.parse() } } impl ::std::convert::TryFrom<&String> for EncodeKey { type Error = self::error::ConversionError; fn try_from(value: &String) -> Result { value.parse() } } impl ::std::convert::TryFrom for EncodeKey { type Error = self::error::ConversionError; fn try_from(value: String) -> Result { value.parse() } } impl<'de> ::serde::Deserialize<'de> for EncodeKey { fn deserialize(deserializer: D) -> Result where D: ::serde::Deserializer<'de>, { String::deserialize(deserializer)? .parse() .map_err(|e: self::error::ConversionError| { ::custom(e.to_string()) }) } } #[doc = "Everything"] #[doc = r""] #[doc = r"
JSON schema"] #[doc = r""] #[doc = r" ```json"] #[doc = "{"] #[doc = " \"title\": \"Everything\","] #[doc = " \"type\": \"object\","] #[doc = " \"allOf\": ["] #[doc = " {"] #[doc = " \"$ref\": \"#/definitions/scope\""] #[doc = " },"] #[doc = " {"] #[doc = " \"properties\": {"] #[doc = " \"$schema\": {"] #[doc = " \"type\": \"string\","] #[doc = " \"format\": \"uri\""] #[doc = " },"] #[doc = " \"autosize\": {"] #[doc = " \"$ref\": \"#/definitions/autosize\""] #[doc = " },"] #[doc = " \"background\": {"] #[doc = " \"$ref\": \"#/definitions/background\""] #[doc = " },"] #[doc = " \"config\": {"] #[doc = " \"type\": \"object\""] #[doc = " },"] #[doc = " \"description\": {"] #[doc = " \"type\": \"string\""] #[doc = " },"] #[doc = " \"height\": {"] #[doc = " \"$ref\": \"#/definitions/numberOrSignal\""] #[doc = " },"] #[doc = " \"padding\": {"] #[doc = " \"$ref\": \"#/definitions/padding\""] #[doc = " },"] #[doc = " \"style\": {"] #[doc = " \"$ref\": \"#/definitions/style\""] #[doc = " },"] #[doc = " \"width\": {"] #[doc = " \"$ref\": \"#/definitions/numberOrSignal\""] #[doc = " }"] #[doc = " }"] #[doc = " }"] #[doc = " ]"] #[doc = "}"] #[doc = r" ```"] #[doc = r"
"] #[derive(:: serde :: Deserialize, :: serde :: Serialize, Clone, Debug)] pub struct Everything { #[serde(default, skip_serializing_if = "Option::is_none")] pub autosize: Option, #[serde(default, skip_serializing_if = "Vec::is_empty")] pub axes: Vec, #[serde(default, skip_serializing_if = "Option::is_none")] pub background: Option, #[serde(default, skip_serializing_if = "::serde_json::Map::is_empty")] pub config: ::serde_json::Map, #[serde(default, skip_serializing_if = "Vec::is_empty")] pub data: Vec, #[serde(default, skip_serializing_if = "Option::is_none")] pub description: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub encode: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub height: Option, #[serde(default, skip_serializing_if = "Option::is_none")] pub layout: Option, #[serde(default, skip_serializing_if = "Vec::is_empty")] pub legends: Vec, #[serde(default, skip_serializing_if = "Vec::is_empty")] pub marks: Vec, #[serde(default, skip_serializing_if = "Option::is_none")] pub padding: Option, #[serde(default, skip_serializing_if = "Vec::is_empty")] pub projections: Vec, #[serde(default, skip_serializing_if = "Vec::is_empty")] pub scales: Vec, #[serde(rename = "$schema", default, skip_serializing_if = "Option::is_none")] pub schema: Option, #[serde(default, skip_serializing_if = "Vec::is_empty")] pub signals: Vec, #[serde(default, skip_serializing_if = "Option::is_none")] pub style: Option