impl serde::Serialize for DataTypeIdentifier {
    #[allow(deprecated)]
    fn serialize<S>(&self, serializer: S) -> std::result::Result<S::Ok, S::Error>
    where
        S: serde::Serializer,
    {
        use serde::ser::SerializeStruct;
        let mut len = 0;
        if self.r#type.is_some() {
            len += 1;
        }
        let mut struct_ser = serializer.serialize_struct("shared.DataTypeIdentifier", len)?;
        if let Some(v) = self.r#type.as_ref() {
            match v {
                data_type_identifier::Type::DataTypeIdentifier(v) => {
                    struct_ser.serialize_field("dataTypeIdentifier", v)?;
                }
                data_type_identifier::Type::GenericType(v) => {
                    struct_ser.serialize_field("genericType", v)?;
                }
                data_type_identifier::Type::GenericKey(v) => {
                    struct_ser.serialize_field("genericKey", v)?;
                }
            }
        }
        struct_ser.end()
    }
}
impl<'de> serde::Deserialize<'de> for DataTypeIdentifier {
    #[allow(deprecated)]
    fn deserialize<D>(deserializer: D) -> std::result::Result<Self, D::Error>
    where
        D: serde::Deserializer<'de>,
    {
        const FIELDS: &[&str] = &[
            "data_type_identifier",
            "dataTypeIdentifier",
            "generic_type",
            "genericType",
            "generic_key",
            "genericKey",
        ];

        #[allow(clippy::enum_variant_names)]
        enum GeneratedField {
            DataTypeIdentifier,
            GenericType,
            GenericKey,
        }
        impl<'de> serde::Deserialize<'de> for GeneratedField {
            fn deserialize<D>(deserializer: D) -> std::result::Result<GeneratedField, D::Error>
            where
                D: serde::Deserializer<'de>,
            {
                struct GeneratedVisitor;

                impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
                    type Value = GeneratedField;

                    fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                        write!(formatter, "expected one of: {:?}", &FIELDS)
                    }

                    #[allow(unused_variables)]
                    fn visit_str<E>(self, value: &str) -> std::result::Result<GeneratedField, E>
                    where
                        E: serde::de::Error,
                    {
                        match value {
                            "dataTypeIdentifier" | "data_type_identifier" => Ok(GeneratedField::DataTypeIdentifier),
                            "genericType" | "generic_type" => Ok(GeneratedField::GenericType),
                            "genericKey" | "generic_key" => Ok(GeneratedField::GenericKey),
                            _ => Err(serde::de::Error::unknown_field(value, FIELDS)),
                        }
                    }
                }
                deserializer.deserialize_identifier(GeneratedVisitor)
            }
        }
        struct GeneratedVisitor;
        impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
            type Value = DataTypeIdentifier;

            fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                formatter.write_str("struct shared.DataTypeIdentifier")
            }

            fn visit_map<V>(self, mut map_: V) -> std::result::Result<DataTypeIdentifier, V::Error>
                where
                    V: serde::de::MapAccess<'de>,
            {
                let mut r#type__ = None;
                while let Some(k) = map_.next_key()? {
                    match k {
                        GeneratedField::DataTypeIdentifier => {
                            if r#type__.is_some() {
                                return Err(serde::de::Error::duplicate_field("dataTypeIdentifier"));
                            }
                            r#type__ = map_.next_value::<::std::option::Option<_>>()?.map(data_type_identifier::Type::DataTypeIdentifier);
                        }
                        GeneratedField::GenericType => {
                            if r#type__.is_some() {
                                return Err(serde::de::Error::duplicate_field("genericType"));
                            }
                            r#type__ = map_.next_value::<::std::option::Option<_>>()?.map(data_type_identifier::Type::GenericType)
;
                        }
                        GeneratedField::GenericKey => {
                            if r#type__.is_some() {
                                return Err(serde::de::Error::duplicate_field("genericKey"));
                            }
                            r#type__ = map_.next_value::<::std::option::Option<_>>()?.map(data_type_identifier::Type::GenericKey);
                        }
                    }
                }
                Ok(DataTypeIdentifier {
                    r#type: r#type__,
                })
            }
        }
        deserializer.deserialize_struct("shared.DataTypeIdentifier", FIELDS, GeneratedVisitor)
    }
}
impl serde::Serialize for DataTypeItemOfCollectionRuleConfig {
    #[allow(deprecated)]
    fn serialize<S>(&self, serializer: S) -> std::result::Result<S::Ok, S::Error>
    where
        S: serde::Serializer,
    {
        use serde::ser::SerializeStruct;
        let mut len = 0;
        if !self.items.is_empty() {
            len += 1;
        }
        let mut struct_ser = serializer.serialize_struct("shared.DataTypeItemOfCollectionRuleConfig", len)?;
        if !self.items.is_empty() {
            struct_ser.serialize_field("items", &self.items)?;
        }
        struct_ser.end()
    }
}
impl<'de> serde::Deserialize<'de> for DataTypeItemOfCollectionRuleConfig {
    #[allow(deprecated)]
    fn deserialize<D>(deserializer: D) -> std::result::Result<Self, D::Error>
    where
        D: serde::Deserializer<'de>,
    {
        const FIELDS: &[&str] = &[
            "items",
        ];

        #[allow(clippy::enum_variant_names)]
        enum GeneratedField {
            Items,
        }
        impl<'de> serde::Deserialize<'de> for GeneratedField {
            fn deserialize<D>(deserializer: D) -> std::result::Result<GeneratedField, D::Error>
            where
                D: serde::Deserializer<'de>,
            {
                struct GeneratedVisitor;

                impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
                    type Value = GeneratedField;

                    fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                        write!(formatter, "expected one of: {:?}", &FIELDS)
                    }

                    #[allow(unused_variables)]
                    fn visit_str<E>(self, value: &str) -> std::result::Result<GeneratedField, E>
                    where
                        E: serde::de::Error,
                    {
                        match value {
                            "items" => Ok(GeneratedField::Items),
                            _ => Err(serde::de::Error::unknown_field(value, FIELDS)),
                        }
                    }
                }
                deserializer.deserialize_identifier(GeneratedVisitor)
            }
        }
        struct GeneratedVisitor;
        impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
            type Value = DataTypeItemOfCollectionRuleConfig;

            fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                formatter.write_str("struct shared.DataTypeItemOfCollectionRuleConfig")
            }

            fn visit_map<V>(self, mut map_: V) -> std::result::Result<DataTypeItemOfCollectionRuleConfig, V::Error>
                where
                    V: serde::de::MapAccess<'de>,
            {
                let mut items__ = None;
                while let Some(k) = map_.next_key()? {
                    match k {
                        GeneratedField::Items => {
                            if items__.is_some() {
                                return Err(serde::de::Error::duplicate_field("items"));
                            }
                            items__ = Some(map_.next_value()?);
                        }
                    }
                }
                Ok(DataTypeItemOfCollectionRuleConfig {
                    items: items__.unwrap_or_default(),
                })
            }
        }
        deserializer.deserialize_struct("shared.DataTypeItemOfCollectionRuleConfig", FIELDS, GeneratedVisitor)
    }
}
impl serde::Serialize for DataTypeNumberRangeRuleConfig {
    #[allow(deprecated)]
    fn serialize<S>(&self, serializer: S) -> std::result::Result<S::Ok, S::Error>
    where
        S: serde::Serializer,
    {
        use serde::ser::SerializeStruct;
        let mut len = 0;
        if self.from != 0 {
            len += 1;
        }
        if self.to != 0 {
            len += 1;
        }
        if self.steps.is_some() {
            len += 1;
        }
        let mut struct_ser = serializer.serialize_struct("shared.DataTypeNumberRangeRuleConfig", len)?;
        if self.from != 0 {
            #[allow(clippy::needless_borrow)]
            #[allow(clippy::needless_borrows_for_generic_args)]
            struct_ser.serialize_field("from", ToString::to_string(&self.from).as_str())?;
        }
        if self.to != 0 {
            #[allow(clippy::needless_borrow)]
            #[allow(clippy::needless_borrows_for_generic_args)]
            struct_ser.serialize_field("to", ToString::to_string(&self.to).as_str())?;
        }
        if let Some(v) = self.steps.as_ref() {
            #[allow(clippy::needless_borrow)]
            #[allow(clippy::needless_borrows_for_generic_args)]
            struct_ser.serialize_field("steps", ToString::to_string(&v).as_str())?;
        }
        struct_ser.end()
    }
}
impl<'de> serde::Deserialize<'de> for DataTypeNumberRangeRuleConfig {
    #[allow(deprecated)]
    fn deserialize<D>(deserializer: D) -> std::result::Result<Self, D::Error>
    where
        D: serde::Deserializer<'de>,
    {
        const FIELDS: &[&str] = &[
            "from",
            "to",
            "steps",
        ];

        #[allow(clippy::enum_variant_names)]
        enum GeneratedField {
            From,
            To,
            Steps,
        }
        impl<'de> serde::Deserialize<'de> for GeneratedField {
            fn deserialize<D>(deserializer: D) -> std::result::Result<GeneratedField, D::Error>
            where
                D: serde::Deserializer<'de>,
            {
                struct GeneratedVisitor;

                impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
                    type Value = GeneratedField;

                    fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                        write!(formatter, "expected one of: {:?}", &FIELDS)
                    }

                    #[allow(unused_variables)]
                    fn visit_str<E>(self, value: &str) -> std::result::Result<GeneratedField, E>
                    where
                        E: serde::de::Error,
                    {
                        match value {
                            "from" => Ok(GeneratedField::From),
                            "to" => Ok(GeneratedField::To),
                            "steps" => Ok(GeneratedField::Steps),
                            _ => Err(serde::de::Error::unknown_field(value, FIELDS)),
                        }
                    }
                }
                deserializer.deserialize_identifier(GeneratedVisitor)
            }
        }
        struct GeneratedVisitor;
        impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
            type Value = DataTypeNumberRangeRuleConfig;

            fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                formatter.write_str("struct shared.DataTypeNumberRangeRuleConfig")
            }

            fn visit_map<V>(self, mut map_: V) -> std::result::Result<DataTypeNumberRangeRuleConfig, V::Error>
                where
                    V: serde::de::MapAccess<'de>,
            {
                let mut from__ = None;
                let mut to__ = None;
                let mut steps__ = None;
                while let Some(k) = map_.next_key()? {
                    match k {
                        GeneratedField::From => {
                            if from__.is_some() {
                                return Err(serde::de::Error::duplicate_field("from"));
                            }
                            from__ = 
                                Some(map_.next_value::<::pbjson::private::NumberDeserialize<_>>()?.0)
                            ;
                        }
                        GeneratedField::To => {
                            if to__.is_some() {
                                return Err(serde::de::Error::duplicate_field("to"));
                            }
                            to__ = 
                                Some(map_.next_value::<::pbjson::private::NumberDeserialize<_>>()?.0)
                            ;
                        }
                        GeneratedField::Steps => {
                            if steps__.is_some() {
                                return Err(serde::de::Error::duplicate_field("steps"));
                            }
                            steps__ = 
                                map_.next_value::<::std::option::Option<::pbjson::private::NumberDeserialize<_>>>()?.map(|x| x.0)
                            ;
                        }
                    }
                }
                Ok(DataTypeNumberRangeRuleConfig {
                    from: from__.unwrap_or_default(),
                    to: to__.unwrap_or_default(),
                    steps: steps__,
                })
            }
        }
        deserializer.deserialize_struct("shared.DataTypeNumberRangeRuleConfig", FIELDS, GeneratedVisitor)
    }
}
impl serde::Serialize for DataTypeRegexRuleConfig {
    #[allow(deprecated)]
    fn serialize<S>(&self, serializer: S) -> std::result::Result<S::Ok, S::Error>
    where
        S: serde::Serializer,
    {
        use serde::ser::SerializeStruct;
        let mut len = 0;
        if !self.pattern.is_empty() {
            len += 1;
        }
        let mut struct_ser = serializer.serialize_struct("shared.DataTypeRegexRuleConfig", len)?;
        if !self.pattern.is_empty() {
            struct_ser.serialize_field("pattern", &self.pattern)?;
        }
        struct_ser.end()
    }
}
impl<'de> serde::Deserialize<'de> for DataTypeRegexRuleConfig {
    #[allow(deprecated)]
    fn deserialize<D>(deserializer: D) -> std::result::Result<Self, D::Error>
    where
        D: serde::Deserializer<'de>,
    {
        const FIELDS: &[&str] = &[
            "pattern",
        ];

        #[allow(clippy::enum_variant_names)]
        enum GeneratedField {
            Pattern,
        }
        impl<'de> serde::Deserialize<'de> for GeneratedField {
            fn deserialize<D>(deserializer: D) -> std::result::Result<GeneratedField, D::Error>
            where
                D: serde::Deserializer<'de>,
            {
                struct GeneratedVisitor;

                impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
                    type Value = GeneratedField;

                    fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                        write!(formatter, "expected one of: {:?}", &FIELDS)
                    }

                    #[allow(unused_variables)]
                    fn visit_str<E>(self, value: &str) -> std::result::Result<GeneratedField, E>
                    where
                        E: serde::de::Error,
                    {
                        match value {
                            "pattern" => Ok(GeneratedField::Pattern),
                            _ => Err(serde::de::Error::unknown_field(value, FIELDS)),
                        }
                    }
                }
                deserializer.deserialize_identifier(GeneratedVisitor)
            }
        }
        struct GeneratedVisitor;
        impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
            type Value = DataTypeRegexRuleConfig;

            fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                formatter.write_str("struct shared.DataTypeRegexRuleConfig")
            }

            fn visit_map<V>(self, mut map_: V) -> std::result::Result<DataTypeRegexRuleConfig, V::Error>
                where
                    V: serde::de::MapAccess<'de>,
            {
                let mut pattern__ = None;
                while let Some(k) = map_.next_key()? {
                    match k {
                        GeneratedField::Pattern => {
                            if pattern__.is_some() {
                                return Err(serde::de::Error::duplicate_field("pattern"));
                            }
                            pattern__ = Some(map_.next_value()?);
                        }
                    }
                }
                Ok(DataTypeRegexRuleConfig {
                    pattern: pattern__.unwrap_or_default(),
                })
            }
        }
        deserializer.deserialize_struct("shared.DataTypeRegexRuleConfig", FIELDS, GeneratedVisitor)
    }
}
impl serde::Serialize for DefinitionDataType {
    #[allow(deprecated)]
    fn serialize<S>(&self, serializer: S) -> std::result::Result<S::Ok, S::Error>
    where
        S: serde::Serializer,
    {
        use serde::ser::SerializeStruct;
        let mut len = 0;
        if self.variant != 0 {
            len += 1;
        }
        if !self.identifier.is_empty() {
            len += 1;
        }
        if !self.name.is_empty() {
            len += 1;
        }
        if !self.display_message.is_empty() {
            len += 1;
        }
        if !self.alias.is_empty() {
            len += 1;
        }
        if !self.rules.is_empty() {
            len += 1;
        }
        if !self.generic_keys.is_empty() {
            len += 1;
        }
        if !self.version.is_empty() {
            len += 1;
        }
        let mut struct_ser = serializer.serialize_struct("shared.DefinitionDataType", len)?;
        if self.variant != 0 {
            let v = definition_data_type::Variant::try_from(self.variant)
                .map_err(|_| serde::ser::Error::custom(format!("Invalid variant {}", self.variant)))?;
            struct_ser.serialize_field("variant", &v)?;
        }
        if !self.identifier.is_empty() {
            struct_ser.serialize_field("identifier", &self.identifier)?;
        }
        if !self.name.is_empty() {
            struct_ser.serialize_field("name", &self.name)?;
        }
        if !self.display_message.is_empty() {
            struct_ser.serialize_field("displayMessage", &self.display_message)?;
        }
        if !self.alias.is_empty() {
            struct_ser.serialize_field("alias", &self.alias)?;
        }
        if !self.rules.is_empty() {
            struct_ser.serialize_field("rules", &self.rules)?;
        }
        if !self.generic_keys.is_empty() {
            struct_ser.serialize_field("genericKeys", &self.generic_keys)?;
        }
        if !self.version.is_empty() {
            struct_ser.serialize_field("version", &self.version)?;
        }
        struct_ser.end()
    }
}
impl<'de> serde::Deserialize<'de> for DefinitionDataType {
    #[allow(deprecated)]
    fn deserialize<D>(deserializer: D) -> std::result::Result<Self, D::Error>
    where
        D: serde::Deserializer<'de>,
    {
        const FIELDS: &[&str] = &[
            "variant",
            "identifier",
            "name",
            "display_message",
            "displayMessage",
            "alias",
            "rules",
            "generic_keys",
            "genericKeys",
            "version",
        ];

        #[allow(clippy::enum_variant_names)]
        enum GeneratedField {
            Variant,
            Identifier,
            Name,
            DisplayMessage,
            Alias,
            Rules,
            GenericKeys,
            Version,
        }
        impl<'de> serde::Deserialize<'de> for GeneratedField {
            fn deserialize<D>(deserializer: D) -> std::result::Result<GeneratedField, D::Error>
            where
                D: serde::Deserializer<'de>,
            {
                struct GeneratedVisitor;

                impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
                    type Value = GeneratedField;

                    fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                        write!(formatter, "expected one of: {:?}", &FIELDS)
                    }

                    #[allow(unused_variables)]
                    fn visit_str<E>(self, value: &str) -> std::result::Result<GeneratedField, E>
                    where
                        E: serde::de::Error,
                    {
                        match value {
                            "variant" => Ok(GeneratedField::Variant),
                            "identifier" => Ok(GeneratedField::Identifier),
                            "name" => Ok(GeneratedField::Name),
                            "displayMessage" | "display_message" => Ok(GeneratedField::DisplayMessage),
                            "alias" => Ok(GeneratedField::Alias),
                            "rules" => Ok(GeneratedField::Rules),
                            "genericKeys" | "generic_keys" => Ok(GeneratedField::GenericKeys),
                            "version" => Ok(GeneratedField::Version),
                            _ => Err(serde::de::Error::unknown_field(value, FIELDS)),
                        }
                    }
                }
                deserializer.deserialize_identifier(GeneratedVisitor)
            }
        }
        struct GeneratedVisitor;
        impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
            type Value = DefinitionDataType;

            fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                formatter.write_str("struct shared.DefinitionDataType")
            }

            fn visit_map<V>(self, mut map_: V) -> std::result::Result<DefinitionDataType, V::Error>
                where
                    V: serde::de::MapAccess<'de>,
            {
                let mut variant__ = None;
                let mut identifier__ = None;
                let mut name__ = None;
                let mut display_message__ = None;
                let mut alias__ = None;
                let mut rules__ = None;
                let mut generic_keys__ = None;
                let mut version__ = None;
                while let Some(k) = map_.next_key()? {
                    match k {
                        GeneratedField::Variant => {
                            if variant__.is_some() {
                                return Err(serde::de::Error::duplicate_field("variant"));
                            }
                            variant__ = Some(map_.next_value::<definition_data_type::Variant>()? as i32);
                        }
                        GeneratedField::Identifier => {
                            if identifier__.is_some() {
                                return Err(serde::de::Error::duplicate_field("identifier"));
                            }
                            identifier__ = Some(map_.next_value()?);
                        }
                        GeneratedField::Name => {
                            if name__.is_some() {
                                return Err(serde::de::Error::duplicate_field("name"));
                            }
                            name__ = Some(map_.next_value()?);
                        }
                        GeneratedField::DisplayMessage => {
                            if display_message__.is_some() {
                                return Err(serde::de::Error::duplicate_field("displayMessage"));
                            }
                            display_message__ = Some(map_.next_value()?);
                        }
                        GeneratedField::Alias => {
                            if alias__.is_some() {
                                return Err(serde::de::Error::duplicate_field("alias"));
                            }
                            alias__ = Some(map_.next_value()?);
                        }
                        GeneratedField::Rules => {
                            if rules__.is_some() {
                                return Err(serde::de::Error::duplicate_field("rules"));
                            }
                            rules__ = Some(map_.next_value()?);
                        }
                        GeneratedField::GenericKeys => {
                            if generic_keys__.is_some() {
                                return Err(serde::de::Error::duplicate_field("genericKeys"));
                            }
                            generic_keys__ = Some(map_.next_value()?);
                        }
                        GeneratedField::Version => {
                            if version__.is_some() {
                                return Err(serde::de::Error::duplicate_field("version"));
                            }
                            version__ = Some(map_.next_value()?);
                        }
                    }
                }
                Ok(DefinitionDataType {
                    variant: variant__.unwrap_or_default(),
                    identifier: identifier__.unwrap_or_default(),
                    name: name__.unwrap_or_default(),
                    display_message: display_message__.unwrap_or_default(),
                    alias: alias__.unwrap_or_default(),
                    rules: rules__.unwrap_or_default(),
                    generic_keys: generic_keys__.unwrap_or_default(),
                    version: version__.unwrap_or_default(),
                })
            }
        }
        deserializer.deserialize_struct("shared.DefinitionDataType", FIELDS, GeneratedVisitor)
    }
}
impl serde::Serialize for definition_data_type::Variant {
    #[allow(deprecated)]
    fn serialize<S>(&self, serializer: S) -> std::result::Result<S::Ok, S::Error>
    where
        S: serde::Serializer,
    {
        let variant = match self {
            Self::Unknown => "UNKNOWN",
            Self::Primitive => "PRIMITIVE",
            Self::Type => "TYPE",
            Self::Object => "OBJECT",
            Self::Datatype => "DATATYPE",
            Self::Array => "ARRAY",
            Self::Error => "ERROR",
            Self::Node => "NODE",
        };
        serializer.serialize_str(variant)
    }
}
impl<'de> serde::Deserialize<'de> for definition_data_type::Variant {
    #[allow(deprecated)]
    fn deserialize<D>(deserializer: D) -> std::result::Result<Self, D::Error>
    where
        D: serde::Deserializer<'de>,
    {
        const FIELDS: &[&str] = &[
            "UNKNOWN",
            "PRIMITIVE",
            "TYPE",
            "OBJECT",
            "DATATYPE",
            "ARRAY",
            "ERROR",
            "NODE",
        ];

        struct GeneratedVisitor;

        impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
            type Value = definition_data_type::Variant;

            fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                write!(formatter, "expected one of: {:?}", &FIELDS)
            }

            fn visit_i64<E>(self, v: i64) -> std::result::Result<Self::Value, E>
            where
                E: serde::de::Error,
            {
                i32::try_from(v)
                    .ok()
                    .and_then(|x| x.try_into().ok())
                    .ok_or_else(|| {
                        serde::de::Error::invalid_value(serde::de::Unexpected::Signed(v), &self)
                    })
            }

            fn visit_u64<E>(self, v: u64) -> std::result::Result<Self::Value, E>
            where
                E: serde::de::Error,
            {
                i32::try_from(v)
                    .ok()
                    .and_then(|x| x.try_into().ok())
                    .ok_or_else(|| {
                        serde::de::Error::invalid_value(serde::de::Unexpected::Unsigned(v), &self)
                    })
            }

            fn visit_str<E>(self, value: &str) -> std::result::Result<Self::Value, E>
            where
                E: serde::de::Error,
            {
                match value {
                    "UNKNOWN" => Ok(definition_data_type::Variant::Unknown),
                    "PRIMITIVE" => Ok(definition_data_type::Variant::Primitive),
                    "TYPE" => Ok(definition_data_type::Variant::Type),
                    "OBJECT" => Ok(definition_data_type::Variant::Object),
                    "DATATYPE" => Ok(definition_data_type::Variant::Datatype),
                    "ARRAY" => Ok(definition_data_type::Variant::Array),
                    "ERROR" => Ok(definition_data_type::Variant::Error),
                    "NODE" => Ok(definition_data_type::Variant::Node),
                    _ => Err(serde::de::Error::unknown_variant(value, FIELDS)),
                }
            }
        }
        deserializer.deserialize_any(GeneratedVisitor)
    }
}
impl serde::Serialize for DefinitionDataTypeContainsKeyRuleConfig {
    #[allow(deprecated)]
    fn serialize<S>(&self, serializer: S) -> std::result::Result<S::Ok, S::Error>
    where
        S: serde::Serializer,
    {
        use serde::ser::SerializeStruct;
        let mut len = 0;
        if !self.key.is_empty() {
            len += 1;
        }
        if self.data_type_identifier.is_some() {
            len += 1;
        }
        let mut struct_ser = serializer.serialize_struct("shared.DefinitionDataTypeContainsKeyRuleConfig", len)?;
        if !self.key.is_empty() {
            struct_ser.serialize_field("key", &self.key)?;
        }
        if let Some(v) = self.data_type_identifier.as_ref() {
            struct_ser.serialize_field("dataTypeIdentifier", v)?;
        }
        struct_ser.end()
    }
}
impl<'de> serde::Deserialize<'de> for DefinitionDataTypeContainsKeyRuleConfig {
    #[allow(deprecated)]
    fn deserialize<D>(deserializer: D) -> std::result::Result<Self, D::Error>
    where
        D: serde::Deserializer<'de>,
    {
        const FIELDS: &[&str] = &[
            "key",
            "data_type_identifier",
            "dataTypeIdentifier",
        ];

        #[allow(clippy::enum_variant_names)]
        enum GeneratedField {
            Key,
            DataTypeIdentifier,
        }
        impl<'de> serde::Deserialize<'de> for GeneratedField {
            fn deserialize<D>(deserializer: D) -> std::result::Result<GeneratedField, D::Error>
            where
                D: serde::Deserializer<'de>,
            {
                struct GeneratedVisitor;

                impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
                    type Value = GeneratedField;

                    fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                        write!(formatter, "expected one of: {:?}", &FIELDS)
                    }

                    #[allow(unused_variables)]
                    fn visit_str<E>(self, value: &str) -> std::result::Result<GeneratedField, E>
                    where
                        E: serde::de::Error,
                    {
                        match value {
                            "key" => Ok(GeneratedField::Key),
                            "dataTypeIdentifier" | "data_type_identifier" => Ok(GeneratedField::DataTypeIdentifier),
                            _ => Err(serde::de::Error::unknown_field(value, FIELDS)),
                        }
                    }
                }
                deserializer.deserialize_identifier(GeneratedVisitor)
            }
        }
        struct GeneratedVisitor;
        impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
            type Value = DefinitionDataTypeContainsKeyRuleConfig;

            fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                formatter.write_str("struct shared.DefinitionDataTypeContainsKeyRuleConfig")
            }

            fn visit_map<V>(self, mut map_: V) -> std::result::Result<DefinitionDataTypeContainsKeyRuleConfig, V::Error>
                where
                    V: serde::de::MapAccess<'de>,
            {
                let mut key__ = None;
                let mut data_type_identifier__ = None;
                while let Some(k) = map_.next_key()? {
                    match k {
                        GeneratedField::Key => {
                            if key__.is_some() {
                                return Err(serde::de::Error::duplicate_field("key"));
                            }
                            key__ = Some(map_.next_value()?);
                        }
                        GeneratedField::DataTypeIdentifier => {
                            if data_type_identifier__.is_some() {
                                return Err(serde::de::Error::duplicate_field("dataTypeIdentifier"));
                            }
                            data_type_identifier__ = map_.next_value()?;
                        }
                    }
                }
                Ok(DefinitionDataTypeContainsKeyRuleConfig {
                    key: key__.unwrap_or_default(),
                    data_type_identifier: data_type_identifier__,
                })
            }
        }
        deserializer.deserialize_struct("shared.DefinitionDataTypeContainsKeyRuleConfig", FIELDS, GeneratedVisitor)
    }
}
impl serde::Serialize for DefinitionDataTypeContainsTypeRuleConfig {
    #[allow(deprecated)]
    fn serialize<S>(&self, serializer: S) -> std::result::Result<S::Ok, S::Error>
    where
        S: serde::Serializer,
    {
        use serde::ser::SerializeStruct;
        let mut len = 0;
        if self.data_type_identifier.is_some() {
            len += 1;
        }
        let mut struct_ser = serializer.serialize_struct("shared.DefinitionDataTypeContainsTypeRuleConfig", len)?;
        if let Some(v) = self.data_type_identifier.as_ref() {
            struct_ser.serialize_field("dataTypeIdentifier", v)?;
        }
        struct_ser.end()
    }
}
impl<'de> serde::Deserialize<'de> for DefinitionDataTypeContainsTypeRuleConfig {
    #[allow(deprecated)]
    fn deserialize<D>(deserializer: D) -> std::result::Result<Self, D::Error>
    where
        D: serde::Deserializer<'de>,
    {
        const FIELDS: &[&str] = &[
            "data_type_identifier",
            "dataTypeIdentifier",
        ];

        #[allow(clippy::enum_variant_names)]
        enum GeneratedField {
            DataTypeIdentifier,
        }
        impl<'de> serde::Deserialize<'de> for GeneratedField {
            fn deserialize<D>(deserializer: D) -> std::result::Result<GeneratedField, D::Error>
            where
                D: serde::Deserializer<'de>,
            {
                struct GeneratedVisitor;

                impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
                    type Value = GeneratedField;

                    fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                        write!(formatter, "expected one of: {:?}", &FIELDS)
                    }

                    #[allow(unused_variables)]
                    fn visit_str<E>(self, value: &str) -> std::result::Result<GeneratedField, E>
                    where
                        E: serde::de::Error,
                    {
                        match value {
                            "dataTypeIdentifier" | "data_type_identifier" => Ok(GeneratedField::DataTypeIdentifier),
                            _ => Err(serde::de::Error::unknown_field(value, FIELDS)),
                        }
                    }
                }
                deserializer.deserialize_identifier(GeneratedVisitor)
            }
        }
        struct GeneratedVisitor;
        impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
            type Value = DefinitionDataTypeContainsTypeRuleConfig;

            fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                formatter.write_str("struct shared.DefinitionDataTypeContainsTypeRuleConfig")
            }

            fn visit_map<V>(self, mut map_: V) -> std::result::Result<DefinitionDataTypeContainsTypeRuleConfig, V::Error>
                where
                    V: serde::de::MapAccess<'de>,
            {
                let mut data_type_identifier__ = None;
                while let Some(k) = map_.next_key()? {
                    match k {
                        GeneratedField::DataTypeIdentifier => {
                            if data_type_identifier__.is_some() {
                                return Err(serde::de::Error::duplicate_field("dataTypeIdentifier"));
                            }
                            data_type_identifier__ = map_.next_value()?;
                        }
                    }
                }
                Ok(DefinitionDataTypeContainsTypeRuleConfig {
                    data_type_identifier: data_type_identifier__,
                })
            }
        }
        deserializer.deserialize_struct("shared.DefinitionDataTypeContainsTypeRuleConfig", FIELDS, GeneratedVisitor)
    }
}
impl serde::Serialize for DefinitionDataTypeInputTypesRuleConfig {
    #[allow(deprecated)]
    fn serialize<S>(&self, serializer: S) -> std::result::Result<S::Ok, S::Error>
    where
        S: serde::Serializer,
    {
        use serde::ser::SerializeStruct;
        let mut len = 0;
        if !self.input_types.is_empty() {
            len += 1;
        }
        let mut struct_ser = serializer.serialize_struct("shared.DefinitionDataTypeInputTypesRuleConfig", len)?;
        if !self.input_types.is_empty() {
            struct_ser.serialize_field("inputTypes", &self.input_types)?;
        }
        struct_ser.end()
    }
}
impl<'de> serde::Deserialize<'de> for DefinitionDataTypeInputTypesRuleConfig {
    #[allow(deprecated)]
    fn deserialize<D>(deserializer: D) -> std::result::Result<Self, D::Error>
    where
        D: serde::Deserializer<'de>,
    {
        const FIELDS: &[&str] = &[
            "input_types",
            "inputTypes",
        ];

        #[allow(clippy::enum_variant_names)]
        enum GeneratedField {
            InputTypes,
        }
        impl<'de> serde::Deserialize<'de> for GeneratedField {
            fn deserialize<D>(deserializer: D) -> std::result::Result<GeneratedField, D::Error>
            where
                D: serde::Deserializer<'de>,
            {
                struct GeneratedVisitor;

                impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
                    type Value = GeneratedField;

                    fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                        write!(formatter, "expected one of: {:?}", &FIELDS)
                    }

                    #[allow(unused_variables)]
                    fn visit_str<E>(self, value: &str) -> std::result::Result<GeneratedField, E>
                    where
                        E: serde::de::Error,
                    {
                        match value {
                            "inputTypes" | "input_types" => Ok(GeneratedField::InputTypes),
                            _ => Err(serde::de::Error::unknown_field(value, FIELDS)),
                        }
                    }
                }
                deserializer.deserialize_identifier(GeneratedVisitor)
            }
        }
        struct GeneratedVisitor;
        impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
            type Value = DefinitionDataTypeInputTypesRuleConfig;

            fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                formatter.write_str("struct shared.DefinitionDataTypeInputTypesRuleConfig")
            }

            fn visit_map<V>(self, mut map_: V) -> std::result::Result<DefinitionDataTypeInputTypesRuleConfig, V::Error>
                where
                    V: serde::de::MapAccess<'de>,
            {
                let mut input_types__ = None;
                while let Some(k) = map_.next_key()? {
                    match k {
                        GeneratedField::InputTypes => {
                            if input_types__.is_some() {
                                return Err(serde::de::Error::duplicate_field("inputTypes"));
                            }
                            input_types__ = Some(map_.next_value()?);
                        }
                    }
                }
                Ok(DefinitionDataTypeInputTypesRuleConfig {
                    input_types: input_types__.unwrap_or_default(),
                })
            }
        }
        deserializer.deserialize_struct("shared.DefinitionDataTypeInputTypesRuleConfig", FIELDS, GeneratedVisitor)
    }
}
impl serde::Serialize for definition_data_type_input_types_rule_config::DataTypeInputType {
    #[allow(deprecated)]
    fn serialize<S>(&self, serializer: S) -> std::result::Result<S::Ok, S::Error>
    where
        S: serde::Serializer,
    {
        use serde::ser::SerializeStruct;
        let mut len = 0;
        if self.data_type_identifier.is_some() {
            len += 1;
        }
        if !self.input_identifier.is_empty() {
            len += 1;
        }
        let mut struct_ser = serializer.serialize_struct("shared.DefinitionDataTypeInputTypesRuleConfig.DataTypeInputType", len)?;
        if let Some(v) = self.data_type_identifier.as_ref() {
            struct_ser.serialize_field("dataTypeIdentifier", v)?;
        }
        if !self.input_identifier.is_empty() {
            struct_ser.serialize_field("inputIdentifier", &self.input_identifier)?;
        }
        struct_ser.end()
    }
}
impl<'de> serde::Deserialize<'de> for definition_data_type_input_types_rule_config::DataTypeInputType {
    #[allow(deprecated)]
    fn deserialize<D>(deserializer: D) -> std::result::Result<Self, D::Error>
    where
        D: serde::Deserializer<'de>,
    {
        const FIELDS: &[&str] = &[
            "data_type_identifier",
            "dataTypeIdentifier",
            "input_identifier",
            "inputIdentifier",
        ];

        #[allow(clippy::enum_variant_names)]
        enum GeneratedField {
            DataTypeIdentifier,
            InputIdentifier,
        }
        impl<'de> serde::Deserialize<'de> for GeneratedField {
            fn deserialize<D>(deserializer: D) -> std::result::Result<GeneratedField, D::Error>
            where
                D: serde::Deserializer<'de>,
            {
                struct GeneratedVisitor;

                impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
                    type Value = GeneratedField;

                    fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                        write!(formatter, "expected one of: {:?}", &FIELDS)
                    }

                    #[allow(unused_variables)]
                    fn visit_str<E>(self, value: &str) -> std::result::Result<GeneratedField, E>
                    where
                        E: serde::de::Error,
                    {
                        match value {
                            "dataTypeIdentifier" | "data_type_identifier" => Ok(GeneratedField::DataTypeIdentifier),
                            "inputIdentifier" | "input_identifier" => Ok(GeneratedField::InputIdentifier),
                            _ => Err(serde::de::Error::unknown_field(value, FIELDS)),
                        }
                    }
                }
                deserializer.deserialize_identifier(GeneratedVisitor)
            }
        }
        struct GeneratedVisitor;
        impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
            type Value = definition_data_type_input_types_rule_config::DataTypeInputType;

            fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                formatter.write_str("struct shared.DefinitionDataTypeInputTypesRuleConfig.DataTypeInputType")
            }

            fn visit_map<V>(self, mut map_: V) -> std::result::Result<definition_data_type_input_types_rule_config::DataTypeInputType, V::Error>
                where
                    V: serde::de::MapAccess<'de>,
            {
                let mut data_type_identifier__ = None;
                let mut input_identifier__ = None;
                while let Some(k) = map_.next_key()? {
                    match k {
                        GeneratedField::DataTypeIdentifier => {
                            if data_type_identifier__.is_some() {
                                return Err(serde::de::Error::duplicate_field("dataTypeIdentifier"));
                            }
                            data_type_identifier__ = map_.next_value()?;
                        }
                        GeneratedField::InputIdentifier => {
                            if input_identifier__.is_some() {
                                return Err(serde::de::Error::duplicate_field("inputIdentifier"));
                            }
                            input_identifier__ = Some(map_.next_value()?);
                        }
                    }
                }
                Ok(definition_data_type_input_types_rule_config::DataTypeInputType {
                    data_type_identifier: data_type_identifier__,
                    input_identifier: input_identifier__.unwrap_or_default(),
                })
            }
        }
        deserializer.deserialize_struct("shared.DefinitionDataTypeInputTypesRuleConfig.DataTypeInputType", FIELDS, GeneratedVisitor)
    }
}
impl serde::Serialize for DefinitionDataTypeParentTypeRuleConfig {
    #[allow(deprecated)]
    fn serialize<S>(&self, serializer: S) -> std::result::Result<S::Ok, S::Error>
    where
        S: serde::Serializer,
    {
        use serde::ser::SerializeStruct;
        let mut len = 0;
        if self.parent_type.is_some() {
            len += 1;
        }
        let mut struct_ser = serializer.serialize_struct("shared.DefinitionDataTypeParentTypeRuleConfig", len)?;
        if let Some(v) = self.parent_type.as_ref() {
            struct_ser.serialize_field("parentType", v)?;
        }
        struct_ser.end()
    }
}
impl<'de> serde::Deserialize<'de> for DefinitionDataTypeParentTypeRuleConfig {
    #[allow(deprecated)]
    fn deserialize<D>(deserializer: D) -> std::result::Result<Self, D::Error>
    where
        D: serde::Deserializer<'de>,
    {
        const FIELDS: &[&str] = &[
            "parent_type",
            "parentType",
        ];

        #[allow(clippy::enum_variant_names)]
        enum GeneratedField {
            ParentType,
        }
        impl<'de> serde::Deserialize<'de> for GeneratedField {
            fn deserialize<D>(deserializer: D) -> std::result::Result<GeneratedField, D::Error>
            where
                D: serde::Deserializer<'de>,
            {
                struct GeneratedVisitor;

                impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
                    type Value = GeneratedField;

                    fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                        write!(formatter, "expected one of: {:?}", &FIELDS)
                    }

                    #[allow(unused_variables)]
                    fn visit_str<E>(self, value: &str) -> std::result::Result<GeneratedField, E>
                    where
                        E: serde::de::Error,
                    {
                        match value {
                            "parentType" | "parent_type" => Ok(GeneratedField::ParentType),
                            _ => Err(serde::de::Error::unknown_field(value, FIELDS)),
                        }
                    }
                }
                deserializer.deserialize_identifier(GeneratedVisitor)
            }
        }
        struct GeneratedVisitor;
        impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
            type Value = DefinitionDataTypeParentTypeRuleConfig;

            fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                formatter.write_str("struct shared.DefinitionDataTypeParentTypeRuleConfig")
            }

            fn visit_map<V>(self, mut map_: V) -> std::result::Result<DefinitionDataTypeParentTypeRuleConfig, V::Error>
                where
                    V: serde::de::MapAccess<'de>,
            {
                let mut parent_type__ = None;
                while let Some(k) = map_.next_key()? {
                    match k {
                        GeneratedField::ParentType => {
                            if parent_type__.is_some() {
                                return Err(serde::de::Error::duplicate_field("parentType"));
                            }
                            parent_type__ = map_.next_value()?;
                        }
                    }
                }
                Ok(DefinitionDataTypeParentTypeRuleConfig {
                    parent_type: parent_type__,
                })
            }
        }
        deserializer.deserialize_struct("shared.DefinitionDataTypeParentTypeRuleConfig", FIELDS, GeneratedVisitor)
    }
}
impl serde::Serialize for DefinitionDataTypeReturnTypeRuleConfig {
    #[allow(deprecated)]
    fn serialize<S>(&self, serializer: S) -> std::result::Result<S::Ok, S::Error>
    where
        S: serde::Serializer,
    {
        use serde::ser::SerializeStruct;
        let mut len = 0;
        if self.data_type_identifier.is_some() {
            len += 1;
        }
        let mut struct_ser = serializer.serialize_struct("shared.DefinitionDataTypeReturnTypeRuleConfig", len)?;
        if let Some(v) = self.data_type_identifier.as_ref() {
            struct_ser.serialize_field("dataTypeIdentifier", v)?;
        }
        struct_ser.end()
    }
}
impl<'de> serde::Deserialize<'de> for DefinitionDataTypeReturnTypeRuleConfig {
    #[allow(deprecated)]
    fn deserialize<D>(deserializer: D) -> std::result::Result<Self, D::Error>
    where
        D: serde::Deserializer<'de>,
    {
        const FIELDS: &[&str] = &[
            "data_type_identifier",
            "dataTypeIdentifier",
        ];

        #[allow(clippy::enum_variant_names)]
        enum GeneratedField {
            DataTypeIdentifier,
        }
        impl<'de> serde::Deserialize<'de> for GeneratedField {
            fn deserialize<D>(deserializer: D) -> std::result::Result<GeneratedField, D::Error>
            where
                D: serde::Deserializer<'de>,
            {
                struct GeneratedVisitor;

                impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
                    type Value = GeneratedField;

                    fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                        write!(formatter, "expected one of: {:?}", &FIELDS)
                    }

                    #[allow(unused_variables)]
                    fn visit_str<E>(self, value: &str) -> std::result::Result<GeneratedField, E>
                    where
                        E: serde::de::Error,
                    {
                        match value {
                            "dataTypeIdentifier" | "data_type_identifier" => Ok(GeneratedField::DataTypeIdentifier),
                            _ => Err(serde::de::Error::unknown_field(value, FIELDS)),
                        }
                    }
                }
                deserializer.deserialize_identifier(GeneratedVisitor)
            }
        }
        struct GeneratedVisitor;
        impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
            type Value = DefinitionDataTypeReturnTypeRuleConfig;

            fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                formatter.write_str("struct shared.DefinitionDataTypeReturnTypeRuleConfig")
            }

            fn visit_map<V>(self, mut map_: V) -> std::result::Result<DefinitionDataTypeReturnTypeRuleConfig, V::Error>
                where
                    V: serde::de::MapAccess<'de>,
            {
                let mut data_type_identifier__ = None;
                while let Some(k) = map_.next_key()? {
                    match k {
                        GeneratedField::DataTypeIdentifier => {
                            if data_type_identifier__.is_some() {
                                return Err(serde::de::Error::duplicate_field("dataTypeIdentifier"));
                            }
                            data_type_identifier__ = map_.next_value()?;
                        }
                    }
                }
                Ok(DefinitionDataTypeReturnTypeRuleConfig {
                    data_type_identifier: data_type_identifier__,
                })
            }
        }
        deserializer.deserialize_struct("shared.DefinitionDataTypeReturnTypeRuleConfig", FIELDS, GeneratedVisitor)
    }
}
impl serde::Serialize for DefinitionDataTypeRule {
    #[allow(deprecated)]
    fn serialize<S>(&self, serializer: S) -> std::result::Result<S::Ok, S::Error>
    where
        S: serde::Serializer,
    {
        use serde::ser::SerializeStruct;
        let mut len = 0;
        if self.config.is_some() {
            len += 1;
        }
        let mut struct_ser = serializer.serialize_struct("shared.DefinitionDataTypeRule", len)?;
        if let Some(v) = self.config.as_ref() {
            match v {
                definition_data_type_rule::Config::ContainsKey(v) => {
                    struct_ser.serialize_field("containsKey", v)?;
                }
                definition_data_type_rule::Config::ContainsType(v) => {
                    struct_ser.serialize_field("containsType", v)?;
                }
                definition_data_type_rule::Config::ItemOfCollection(v) => {
                    struct_ser.serialize_field("itemOfCollection", v)?;
                }
                definition_data_type_rule::Config::NumberRange(v) => {
                    struct_ser.serialize_field("numberRange", v)?;
                }
                definition_data_type_rule::Config::Regex(v) => {
                    struct_ser.serialize_field("regex", v)?;
                }
                definition_data_type_rule::Config::InputTypes(v) => {
                    struct_ser.serialize_field("inputTypes", v)?;
                }
                definition_data_type_rule::Config::ReturnType(v) => {
                    struct_ser.serialize_field("returnType", v)?;
                }
                definition_data_type_rule::Config::ParentType(v) => {
                    struct_ser.serialize_field("parentType", v)?;
                }
            }
        }
        struct_ser.end()
    }
}
impl<'de> serde::Deserialize<'de> for DefinitionDataTypeRule {
    #[allow(deprecated)]
    fn deserialize<D>(deserializer: D) -> std::result::Result<Self, D::Error>
    where
        D: serde::Deserializer<'de>,
    {
        const FIELDS: &[&str] = &[
            "contains_key",
            "containsKey",
            "contains_type",
            "containsType",
            "item_of_collection",
            "itemOfCollection",
            "number_range",
            "numberRange",
            "regex",
            "input_types",
            "inputTypes",
            "return_type",
            "returnType",
            "parent_type",
            "parentType",
        ];

        #[allow(clippy::enum_variant_names)]
        enum GeneratedField {
            ContainsKey,
            ContainsType,
            ItemOfCollection,
            NumberRange,
            Regex,
            InputTypes,
            ReturnType,
            ParentType,
        }
        impl<'de> serde::Deserialize<'de> for GeneratedField {
            fn deserialize<D>(deserializer: D) -> std::result::Result<GeneratedField, D::Error>
            where
                D: serde::Deserializer<'de>,
            {
                struct GeneratedVisitor;

                impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
                    type Value = GeneratedField;

                    fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                        write!(formatter, "expected one of: {:?}", &FIELDS)
                    }

                    #[allow(unused_variables)]
                    fn visit_str<E>(self, value: &str) -> std::result::Result<GeneratedField, E>
                    where
                        E: serde::de::Error,
                    {
                        match value {
                            "containsKey" | "contains_key" => Ok(GeneratedField::ContainsKey),
                            "containsType" | "contains_type" => Ok(GeneratedField::ContainsType),
                            "itemOfCollection" | "item_of_collection" => Ok(GeneratedField::ItemOfCollection),
                            "numberRange" | "number_range" => Ok(GeneratedField::NumberRange),
                            "regex" => Ok(GeneratedField::Regex),
                            "inputTypes" | "input_types" => Ok(GeneratedField::InputTypes),
                            "returnType" | "return_type" => Ok(GeneratedField::ReturnType),
                            "parentType" | "parent_type" => Ok(GeneratedField::ParentType),
                            _ => Err(serde::de::Error::unknown_field(value, FIELDS)),
                        }
                    }
                }
                deserializer.deserialize_identifier(GeneratedVisitor)
            }
        }
        struct GeneratedVisitor;
        impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
            type Value = DefinitionDataTypeRule;

            fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                formatter.write_str("struct shared.DefinitionDataTypeRule")
            }

            fn visit_map<V>(self, mut map_: V) -> std::result::Result<DefinitionDataTypeRule, V::Error>
                where
                    V: serde::de::MapAccess<'de>,
            {
                let mut config__ = None;
                while let Some(k) = map_.next_key()? {
                    match k {
                        GeneratedField::ContainsKey => {
                            if config__.is_some() {
                                return Err(serde::de::Error::duplicate_field("containsKey"));
                            }
                            config__ = map_.next_value::<::std::option::Option<_>>()?.map(definition_data_type_rule::Config::ContainsKey)
;
                        }
                        GeneratedField::ContainsType => {
                            if config__.is_some() {
                                return Err(serde::de::Error::duplicate_field("containsType"));
                            }
                            config__ = map_.next_value::<::std::option::Option<_>>()?.map(definition_data_type_rule::Config::ContainsType)
;
                        }
                        GeneratedField::ItemOfCollection => {
                            if config__.is_some() {
                                return Err(serde::de::Error::duplicate_field("itemOfCollection"));
                            }
                            config__ = map_.next_value::<::std::option::Option<_>>()?.map(definition_data_type_rule::Config::ItemOfCollection)
;
                        }
                        GeneratedField::NumberRange => {
                            if config__.is_some() {
                                return Err(serde::de::Error::duplicate_field("numberRange"));
                            }
                            config__ = map_.next_value::<::std::option::Option<_>>()?.map(definition_data_type_rule::Config::NumberRange)
;
                        }
                        GeneratedField::Regex => {
                            if config__.is_some() {
                                return Err(serde::de::Error::duplicate_field("regex"));
                            }
                            config__ = map_.next_value::<::std::option::Option<_>>()?.map(definition_data_type_rule::Config::Regex)
;
                        }
                        GeneratedField::InputTypes => {
                            if config__.is_some() {
                                return Err(serde::de::Error::duplicate_field("inputTypes"));
                            }
                            config__ = map_.next_value::<::std::option::Option<_>>()?.map(definition_data_type_rule::Config::InputTypes)
;
                        }
                        GeneratedField::ReturnType => {
                            if config__.is_some() {
                                return Err(serde::de::Error::duplicate_field("returnType"));
                            }
                            config__ = map_.next_value::<::std::option::Option<_>>()?.map(definition_data_type_rule::Config::ReturnType)
;
                        }
                        GeneratedField::ParentType => {
                            if config__.is_some() {
                                return Err(serde::de::Error::duplicate_field("parentType"));
                            }
                            config__ = map_.next_value::<::std::option::Option<_>>()?.map(definition_data_type_rule::Config::ParentType)
;
                        }
                    }
                }
                Ok(DefinitionDataTypeRule {
                    config: config__,
                })
            }
        }
        deserializer.deserialize_struct("shared.DefinitionDataTypeRule", FIELDS, GeneratedVisitor)
    }
}
impl serde::Serialize for EventDefinition {
    #[allow(deprecated)]
    fn serialize<S>(&self, serializer: S) -> std::result::Result<S::Ok, S::Error>
    where
        S: serde::Serializer,
    {
        use serde::ser::SerializeStruct;
        let mut len = 0;
        if !self.settings.is_empty() {
            len += 1;
        }
        if self.input_type.is_some() {
            len += 1;
        }
        if self.editable {
            len += 1;
        }
        let mut struct_ser = serializer.serialize_struct("shared.EventDefinition", len)?;
        if !self.settings.is_empty() {
            struct_ser.serialize_field("settings", &self.settings)?;
        }
        if let Some(v) = self.input_type.as_ref() {
            struct_ser.serialize_field("inputType", v)?;
        }
        if self.editable {
            struct_ser.serialize_field("editable", &self.editable)?;
        }
        struct_ser.end()
    }
}
impl<'de> serde::Deserialize<'de> for EventDefinition {
    #[allow(deprecated)]
    fn deserialize<D>(deserializer: D) -> std::result::Result<Self, D::Error>
    where
        D: serde::Deserializer<'de>,
    {
        const FIELDS: &[&str] = &[
            "settings",
            "input_type",
            "inputType",
            "editable",
        ];

        #[allow(clippy::enum_variant_names)]
        enum GeneratedField {
            Settings,
            InputType,
            Editable,
        }
        impl<'de> serde::Deserialize<'de> for GeneratedField {
            fn deserialize<D>(deserializer: D) -> std::result::Result<GeneratedField, D::Error>
            where
                D: serde::Deserializer<'de>,
            {
                struct GeneratedVisitor;

                impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
                    type Value = GeneratedField;

                    fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                        write!(formatter, "expected one of: {:?}", &FIELDS)
                    }

                    #[allow(unused_variables)]
                    fn visit_str<E>(self, value: &str) -> std::result::Result<GeneratedField, E>
                    where
                        E: serde::de::Error,
                    {
                        match value {
                            "settings" => Ok(GeneratedField::Settings),
                            "inputType" | "input_type" => Ok(GeneratedField::InputType),
                            "editable" => Ok(GeneratedField::Editable),
                            _ => Err(serde::de::Error::unknown_field(value, FIELDS)),
                        }
                    }
                }
                deserializer.deserialize_identifier(GeneratedVisitor)
            }
        }
        struct GeneratedVisitor;
        impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
            type Value = EventDefinition;

            fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                formatter.write_str("struct shared.EventDefinition")
            }

            fn visit_map<V>(self, mut map_: V) -> std::result::Result<EventDefinition, V::Error>
                where
                    V: serde::de::MapAccess<'de>,
            {
                let mut settings__ = None;
                let mut input_type__ = None;
                let mut editable__ = None;
                while let Some(k) = map_.next_key()? {
                    match k {
                        GeneratedField::Settings => {
                            if settings__.is_some() {
                                return Err(serde::de::Error::duplicate_field("settings"));
                            }
                            settings__ = Some(map_.next_value()?);
                        }
                        GeneratedField::InputType => {
                            if input_type__.is_some() {
                                return Err(serde::de::Error::duplicate_field("inputType"));
                            }
                            input_type__ = map_.next_value()?;
                        }
                        GeneratedField::Editable => {
                            if editable__.is_some() {
                                return Err(serde::de::Error::duplicate_field("editable"));
                            }
                            editable__ = Some(map_.next_value()?);
                        }
                    }
                }
                Ok(EventDefinition {
                    settings: settings__.unwrap_or_default(),
                    input_type: input_type__,
                    editable: editable__.unwrap_or_default(),
                })
            }
        }
        deserializer.deserialize_struct("shared.EventDefinition", FIELDS, GeneratedVisitor)
    }
}
impl serde::Serialize for EventDefinitionSettings {
    #[allow(deprecated)]
    fn serialize<S>(&self, serializer: S) -> std::result::Result<S::Ok, S::Error>
    where
        S: serde::Serializer,
    {
        use serde::ser::SerializeStruct;
        let mut len = 0;
        if !self.name.is_empty() {
            len += 1;
        }
        if self.unique {
            len += 1;
        }
        if !self.description.is_empty() {
            len += 1;
        }
        if self.r#type.is_some() {
            len += 1;
        }
        if self.default_value.is_some() {
            len += 1;
        }
        let mut struct_ser = serializer.serialize_struct("shared.EventDefinitionSettings", len)?;
        if !self.name.is_empty() {
            struct_ser.serialize_field("name", &self.name)?;
        }
        if self.unique {
            struct_ser.serialize_field("unique", &self.unique)?;
        }
        if !self.description.is_empty() {
            struct_ser.serialize_field("description", &self.description)?;
        }
        if let Some(v) = self.r#type.as_ref() {
            struct_ser.serialize_field("type", v)?;
        }
        if let Some(v) = self.default_value.as_ref() {
            struct_ser.serialize_field("defaultValue", v)?;
        }
        struct_ser.end()
    }
}
impl<'de> serde::Deserialize<'de> for EventDefinitionSettings {
    #[allow(deprecated)]
    fn deserialize<D>(deserializer: D) -> std::result::Result<Self, D::Error>
    where
        D: serde::Deserializer<'de>,
    {
        const FIELDS: &[&str] = &[
            "name",
            "unique",
            "description",
            "type",
            "default_value",
            "defaultValue",
        ];

        #[allow(clippy::enum_variant_names)]
        enum GeneratedField {
            Name,
            Unique,
            Description,
            Type,
            DefaultValue,
        }
        impl<'de> serde::Deserialize<'de> for GeneratedField {
            fn deserialize<D>(deserializer: D) -> std::result::Result<GeneratedField, D::Error>
            where
                D: serde::Deserializer<'de>,
            {
                struct GeneratedVisitor;

                impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
                    type Value = GeneratedField;

                    fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                        write!(formatter, "expected one of: {:?}", &FIELDS)
                    }

                    #[allow(unused_variables)]
                    fn visit_str<E>(self, value: &str) -> std::result::Result<GeneratedField, E>
                    where
                        E: serde::de::Error,
                    {
                        match value {
                            "name" => Ok(GeneratedField::Name),
                            "unique" => Ok(GeneratedField::Unique),
                            "description" => Ok(GeneratedField::Description),
                            "type" => Ok(GeneratedField::Type),
                            "defaultValue" | "default_value" => Ok(GeneratedField::DefaultValue),
                            _ => Err(serde::de::Error::unknown_field(value, FIELDS)),
                        }
                    }
                }
                deserializer.deserialize_identifier(GeneratedVisitor)
            }
        }
        struct GeneratedVisitor;
        impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
            type Value = EventDefinitionSettings;

            fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                formatter.write_str("struct shared.EventDefinitionSettings")
            }

            fn visit_map<V>(self, mut map_: V) -> std::result::Result<EventDefinitionSettings, V::Error>
                where
                    V: serde::de::MapAccess<'de>,
            {
                let mut name__ = None;
                let mut unique__ = None;
                let mut description__ = None;
                let mut r#type__ = None;
                let mut default_value__ = None;
                while let Some(k) = map_.next_key()? {
                    match k {
                        GeneratedField::Name => {
                            if name__.is_some() {
                                return Err(serde::de::Error::duplicate_field("name"));
                            }
                            name__ = Some(map_.next_value()?);
                        }
                        GeneratedField::Unique => {
                            if unique__.is_some() {
                                return Err(serde::de::Error::duplicate_field("unique"));
                            }
                            unique__ = Some(map_.next_value()?);
                        }
                        GeneratedField::Description => {
                            if description__.is_some() {
                                return Err(serde::de::Error::duplicate_field("description"));
                            }
                            description__ = Some(map_.next_value()?);
                        }
                        GeneratedField::Type => {
                            if r#type__.is_some() {
                                return Err(serde::de::Error::duplicate_field("type"));
                            }
                            r#type__ = map_.next_value()?;
                        }
                        GeneratedField::DefaultValue => {
                            if default_value__.is_some() {
                                return Err(serde::de::Error::duplicate_field("defaultValue"));
                            }
                            default_value__ = map_.next_value()?;
                        }
                    }
                }
                Ok(EventDefinitionSettings {
                    name: name__.unwrap_or_default(),
                    unique: unique__.unwrap_or_default(),
                    description: description__.unwrap_or_default(),
                    r#type: r#type__,
                    default_value: default_value__,
                })
            }
        }
        deserializer.deserialize_struct("shared.EventDefinitionSettings", FIELDS, GeneratedVisitor)
    }
}
impl serde::Serialize for EventType {
    #[allow(deprecated)]
    fn serialize<S>(&self, serializer: S) -> std::result::Result<S::Ok, S::Error>
    where
        S: serde::Serializer,
    {
        use serde::ser::SerializeStruct;
        let mut len = 0;
        if !self.name.is_empty() {
            len += 1;
        }
        if self.definition.is_some() {
            len += 1;
        }
        let mut struct_ser = serializer.serialize_struct("shared.EventType", len)?;
        if !self.name.is_empty() {
            struct_ser.serialize_field("name", &self.name)?;
        }
        if let Some(v) = self.definition.as_ref() {
            struct_ser.serialize_field("definition", v)?;
        }
        struct_ser.end()
    }
}
impl<'de> serde::Deserialize<'de> for EventType {
    #[allow(deprecated)]
    fn deserialize<D>(deserializer: D) -> std::result::Result<Self, D::Error>
    where
        D: serde::Deserializer<'de>,
    {
        const FIELDS: &[&str] = &[
            "name",
            "definition",
        ];

        #[allow(clippy::enum_variant_names)]
        enum GeneratedField {
            Name,
            Definition,
        }
        impl<'de> serde::Deserialize<'de> for GeneratedField {
            fn deserialize<D>(deserializer: D) -> std::result::Result<GeneratedField, D::Error>
            where
                D: serde::Deserializer<'de>,
            {
                struct GeneratedVisitor;

                impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
                    type Value = GeneratedField;

                    fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                        write!(formatter, "expected one of: {:?}", &FIELDS)
                    }

                    #[allow(unused_variables)]
                    fn visit_str<E>(self, value: &str) -> std::result::Result<GeneratedField, E>
                    where
                        E: serde::de::Error,
                    {
                        match value {
                            "name" => Ok(GeneratedField::Name),
                            "definition" => Ok(GeneratedField::Definition),
                            _ => Err(serde::de::Error::unknown_field(value, FIELDS)),
                        }
                    }
                }
                deserializer.deserialize_identifier(GeneratedVisitor)
            }
        }
        struct GeneratedVisitor;
        impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
            type Value = EventType;

            fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                formatter.write_str("struct shared.EventType")
            }

            fn visit_map<V>(self, mut map_: V) -> std::result::Result<EventType, V::Error>
                where
                    V: serde::de::MapAccess<'de>,
            {
                let mut name__ = None;
                let mut definition__ = None;
                while let Some(k) = map_.next_key()? {
                    match k {
                        GeneratedField::Name => {
                            if name__.is_some() {
                                return Err(serde::de::Error::duplicate_field("name"));
                            }
                            name__ = Some(map_.next_value()?);
                        }
                        GeneratedField::Definition => {
                            if definition__.is_some() {
                                return Err(serde::de::Error::duplicate_field("definition"));
                            }
                            definition__ = map_.next_value()?;
                        }
                    }
                }
                Ok(EventType {
                    name: name__.unwrap_or_default(),
                    definition: definition__,
                })
            }
        }
        deserializer.deserialize_struct("shared.EventType", FIELDS, GeneratedVisitor)
    }
}
impl serde::Serialize for ExecutionDataType {
    #[allow(deprecated)]
    fn serialize<S>(&self, serializer: S) -> std::result::Result<S::Ok, S::Error>
    where
        S: serde::Serializer,
    {
        use serde::ser::SerializeStruct;
        let mut len = 0;
        if !self.identifier.is_empty() {
            len += 1;
        }
        if !self.rules.is_empty() {
            len += 1;
        }
        let mut struct_ser = serializer.serialize_struct("shared.ExecutionDataType", len)?;
        if !self.identifier.is_empty() {
            struct_ser.serialize_field("identifier", &self.identifier)?;
        }
        if !self.rules.is_empty() {
            struct_ser.serialize_field("rules", &self.rules)?;
        }
        struct_ser.end()
    }
}
impl<'de> serde::Deserialize<'de> for ExecutionDataType {
    #[allow(deprecated)]
    fn deserialize<D>(deserializer: D) -> std::result::Result<Self, D::Error>
    where
        D: serde::Deserializer<'de>,
    {
        const FIELDS: &[&str] = &[
            "identifier",
            "rules",
        ];

        #[allow(clippy::enum_variant_names)]
        enum GeneratedField {
            Identifier,
            Rules,
        }
        impl<'de> serde::Deserialize<'de> for GeneratedField {
            fn deserialize<D>(deserializer: D) -> std::result::Result<GeneratedField, D::Error>
            where
                D: serde::Deserializer<'de>,
            {
                struct GeneratedVisitor;

                impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
                    type Value = GeneratedField;

                    fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                        write!(formatter, "expected one of: {:?}", &FIELDS)
                    }

                    #[allow(unused_variables)]
                    fn visit_str<E>(self, value: &str) -> std::result::Result<GeneratedField, E>
                    where
                        E: serde::de::Error,
                    {
                        match value {
                            "identifier" => Ok(GeneratedField::Identifier),
                            "rules" => Ok(GeneratedField::Rules),
                            _ => Err(serde::de::Error::unknown_field(value, FIELDS)),
                        }
                    }
                }
                deserializer.deserialize_identifier(GeneratedVisitor)
            }
        }
        struct GeneratedVisitor;
        impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
            type Value = ExecutionDataType;

            fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                formatter.write_str("struct shared.ExecutionDataType")
            }

            fn visit_map<V>(self, mut map_: V) -> std::result::Result<ExecutionDataType, V::Error>
                where
                    V: serde::de::MapAccess<'de>,
            {
                let mut identifier__ = None;
                let mut rules__ = None;
                while let Some(k) = map_.next_key()? {
                    match k {
                        GeneratedField::Identifier => {
                            if identifier__.is_some() {
                                return Err(serde::de::Error::duplicate_field("identifier"));
                            }
                            identifier__ = Some(map_.next_value()?);
                        }
                        GeneratedField::Rules => {
                            if rules__.is_some() {
                                return Err(serde::de::Error::duplicate_field("rules"));
                            }
                            rules__ = Some(map_.next_value()?);
                        }
                    }
                }
                Ok(ExecutionDataType {
                    identifier: identifier__.unwrap_or_default(),
                    rules: rules__.unwrap_or_default(),
                })
            }
        }
        deserializer.deserialize_struct("shared.ExecutionDataType", FIELDS, GeneratedVisitor)
    }
}
impl serde::Serialize for ExecutionDataTypeContainsKeyRuleConfig {
    #[allow(deprecated)]
    fn serialize<S>(&self, serializer: S) -> std::result::Result<S::Ok, S::Error>
    where
        S: serde::Serializer,
    {
        use serde::ser::SerializeStruct;
        let mut len = 0;
        if !self.key.is_empty() {
            len += 1;
        }
        if !self.data_type_identifier.is_empty() {
            len += 1;
        }
        let mut struct_ser = serializer.serialize_struct("shared.ExecutionDataTypeContainsKeyRuleConfig", len)?;
        if !self.key.is_empty() {
            struct_ser.serialize_field("key", &self.key)?;
        }
        if !self.data_type_identifier.is_empty() {
            struct_ser.serialize_field("dataTypeIdentifier", &self.data_type_identifier)?;
        }
        struct_ser.end()
    }
}
impl<'de> serde::Deserialize<'de> for ExecutionDataTypeContainsKeyRuleConfig {
    #[allow(deprecated)]
    fn deserialize<D>(deserializer: D) -> std::result::Result<Self, D::Error>
    where
        D: serde::Deserializer<'de>,
    {
        const FIELDS: &[&str] = &[
            "key",
            "data_type_identifier",
            "dataTypeIdentifier",
        ];

        #[allow(clippy::enum_variant_names)]
        enum GeneratedField {
            Key,
            DataTypeIdentifier,
        }
        impl<'de> serde::Deserialize<'de> for GeneratedField {
            fn deserialize<D>(deserializer: D) -> std::result::Result<GeneratedField, D::Error>
            where
                D: serde::Deserializer<'de>,
            {
                struct GeneratedVisitor;

                impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
                    type Value = GeneratedField;

                    fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                        write!(formatter, "expected one of: {:?}", &FIELDS)
                    }

                    #[allow(unused_variables)]
                    fn visit_str<E>(self, value: &str) -> std::result::Result<GeneratedField, E>
                    where
                        E: serde::de::Error,
                    {
                        match value {
                            "key" => Ok(GeneratedField::Key),
                            "dataTypeIdentifier" | "data_type_identifier" => Ok(GeneratedField::DataTypeIdentifier),
                            _ => Err(serde::de::Error::unknown_field(value, FIELDS)),
                        }
                    }
                }
                deserializer.deserialize_identifier(GeneratedVisitor)
            }
        }
        struct GeneratedVisitor;
        impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
            type Value = ExecutionDataTypeContainsKeyRuleConfig;

            fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                formatter.write_str("struct shared.ExecutionDataTypeContainsKeyRuleConfig")
            }

            fn visit_map<V>(self, mut map_: V) -> std::result::Result<ExecutionDataTypeContainsKeyRuleConfig, V::Error>
                where
                    V: serde::de::MapAccess<'de>,
            {
                let mut key__ = None;
                let mut data_type_identifier__ = None;
                while let Some(k) = map_.next_key()? {
                    match k {
                        GeneratedField::Key => {
                            if key__.is_some() {
                                return Err(serde::de::Error::duplicate_field("key"));
                            }
                            key__ = Some(map_.next_value()?);
                        }
                        GeneratedField::DataTypeIdentifier => {
                            if data_type_identifier__.is_some() {
                                return Err(serde::de::Error::duplicate_field("dataTypeIdentifier"));
                            }
                            data_type_identifier__ = Some(map_.next_value()?);
                        }
                    }
                }
                Ok(ExecutionDataTypeContainsKeyRuleConfig {
                    key: key__.unwrap_or_default(),
                    data_type_identifier: data_type_identifier__.unwrap_or_default(),
                })
            }
        }
        deserializer.deserialize_struct("shared.ExecutionDataTypeContainsKeyRuleConfig", FIELDS, GeneratedVisitor)
    }
}
impl serde::Serialize for ExecutionDataTypeContainsTypeRuleConfig {
    #[allow(deprecated)]
    fn serialize<S>(&self, serializer: S) -> std::result::Result<S::Ok, S::Error>
    where
        S: serde::Serializer,
    {
        use serde::ser::SerializeStruct;
        let mut len = 0;
        if !self.data_type_identifier.is_empty() {
            len += 1;
        }
        let mut struct_ser = serializer.serialize_struct("shared.ExecutionDataTypeContainsTypeRuleConfig", len)?;
        if !self.data_type_identifier.is_empty() {
            struct_ser.serialize_field("dataTypeIdentifier", &self.data_type_identifier)?;
        }
        struct_ser.end()
    }
}
impl<'de> serde::Deserialize<'de> for ExecutionDataTypeContainsTypeRuleConfig {
    #[allow(deprecated)]
    fn deserialize<D>(deserializer: D) -> std::result::Result<Self, D::Error>
    where
        D: serde::Deserializer<'de>,
    {
        const FIELDS: &[&str] = &[
            "data_type_identifier",
            "dataTypeIdentifier",
        ];

        #[allow(clippy::enum_variant_names)]
        enum GeneratedField {
            DataTypeIdentifier,
        }
        impl<'de> serde::Deserialize<'de> for GeneratedField {
            fn deserialize<D>(deserializer: D) -> std::result::Result<GeneratedField, D::Error>
            where
                D: serde::Deserializer<'de>,
            {
                struct GeneratedVisitor;

                impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
                    type Value = GeneratedField;

                    fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                        write!(formatter, "expected one of: {:?}", &FIELDS)
                    }

                    #[allow(unused_variables)]
                    fn visit_str<E>(self, value: &str) -> std::result::Result<GeneratedField, E>
                    where
                        E: serde::de::Error,
                    {
                        match value {
                            "dataTypeIdentifier" | "data_type_identifier" => Ok(GeneratedField::DataTypeIdentifier),
                            _ => Err(serde::de::Error::unknown_field(value, FIELDS)),
                        }
                    }
                }
                deserializer.deserialize_identifier(GeneratedVisitor)
            }
        }
        struct GeneratedVisitor;
        impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
            type Value = ExecutionDataTypeContainsTypeRuleConfig;

            fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                formatter.write_str("struct shared.ExecutionDataTypeContainsTypeRuleConfig")
            }

            fn visit_map<V>(self, mut map_: V) -> std::result::Result<ExecutionDataTypeContainsTypeRuleConfig, V::Error>
                where
                    V: serde::de::MapAccess<'de>,
            {
                let mut data_type_identifier__ = None;
                while let Some(k) = map_.next_key()? {
                    match k {
                        GeneratedField::DataTypeIdentifier => {
                            if data_type_identifier__.is_some() {
                                return Err(serde::de::Error::duplicate_field("dataTypeIdentifier"));
                            }
                            data_type_identifier__ = Some(map_.next_value()?);
                        }
                    }
                }
                Ok(ExecutionDataTypeContainsTypeRuleConfig {
                    data_type_identifier: data_type_identifier__.unwrap_or_default(),
                })
            }
        }
        deserializer.deserialize_struct("shared.ExecutionDataTypeContainsTypeRuleConfig", FIELDS, GeneratedVisitor)
    }
}
impl serde::Serialize for ExecutionDataTypeRule {
    #[allow(deprecated)]
    fn serialize<S>(&self, serializer: S) -> std::result::Result<S::Ok, S::Error>
    where
        S: serde::Serializer,
    {
        use serde::ser::SerializeStruct;
        let mut len = 0;
        if self.config.is_some() {
            len += 1;
        }
        let mut struct_ser = serializer.serialize_struct("shared.ExecutionDataTypeRule", len)?;
        if let Some(v) = self.config.as_ref() {
            match v {
                execution_data_type_rule::Config::ContainsKey(v) => {
                    struct_ser.serialize_field("containsKey", v)?;
                }
                execution_data_type_rule::Config::ContainsType(v) => {
                    struct_ser.serialize_field("containsType", v)?;
                }
                execution_data_type_rule::Config::ItemOfCollection(v) => {
                    struct_ser.serialize_field("itemOfCollection", v)?;
                }
                execution_data_type_rule::Config::NumberRange(v) => {
                    struct_ser.serialize_field("numberRange", v)?;
                }
                execution_data_type_rule::Config::Regex(v) => {
                    struct_ser.serialize_field("regex", v)?;
                }
            }
        }
        struct_ser.end()
    }
}
impl<'de> serde::Deserialize<'de> for ExecutionDataTypeRule {
    #[allow(deprecated)]
    fn deserialize<D>(deserializer: D) -> std::result::Result<Self, D::Error>
    where
        D: serde::Deserializer<'de>,
    {
        const FIELDS: &[&str] = &[
            "contains_key",
            "containsKey",
            "contains_type",
            "containsType",
            "item_of_collection",
            "itemOfCollection",
            "number_range",
            "numberRange",
            "regex",
        ];

        #[allow(clippy::enum_variant_names)]
        enum GeneratedField {
            ContainsKey,
            ContainsType,
            ItemOfCollection,
            NumberRange,
            Regex,
        }
        impl<'de> serde::Deserialize<'de> for GeneratedField {
            fn deserialize<D>(deserializer: D) -> std::result::Result<GeneratedField, D::Error>
            where
                D: serde::Deserializer<'de>,
            {
                struct GeneratedVisitor;

                impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
                    type Value = GeneratedField;

                    fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                        write!(formatter, "expected one of: {:?}", &FIELDS)
                    }

                    #[allow(unused_variables)]
                    fn visit_str<E>(self, value: &str) -> std::result::Result<GeneratedField, E>
                    where
                        E: serde::de::Error,
                    {
                        match value {
                            "containsKey" | "contains_key" => Ok(GeneratedField::ContainsKey),
                            "containsType" | "contains_type" => Ok(GeneratedField::ContainsType),
                            "itemOfCollection" | "item_of_collection" => Ok(GeneratedField::ItemOfCollection),
                            "numberRange" | "number_range" => Ok(GeneratedField::NumberRange),
                            "regex" => Ok(GeneratedField::Regex),
                            _ => Err(serde::de::Error::unknown_field(value, FIELDS)),
                        }
                    }
                }
                deserializer.deserialize_identifier(GeneratedVisitor)
            }
        }
        struct GeneratedVisitor;
        impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
            type Value = ExecutionDataTypeRule;

            fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                formatter.write_str("struct shared.ExecutionDataTypeRule")
            }

            fn visit_map<V>(self, mut map_: V) -> std::result::Result<ExecutionDataTypeRule, V::Error>
                where
                    V: serde::de::MapAccess<'de>,
            {
                let mut config__ = None;
                while let Some(k) = map_.next_key()? {
                    match k {
                        GeneratedField::ContainsKey => {
                            if config__.is_some() {
                                return Err(serde::de::Error::duplicate_field("containsKey"));
                            }
                            config__ = map_.next_value::<::std::option::Option<_>>()?.map(execution_data_type_rule::Config::ContainsKey)
;
                        }
                        GeneratedField::ContainsType => {
                            if config__.is_some() {
                                return Err(serde::de::Error::duplicate_field("containsType"));
                            }
                            config__ = map_.next_value::<::std::option::Option<_>>()?.map(execution_data_type_rule::Config::ContainsType)
;
                        }
                        GeneratedField::ItemOfCollection => {
                            if config__.is_some() {
                                return Err(serde::de::Error::duplicate_field("itemOfCollection"));
                            }
                            config__ = map_.next_value::<::std::option::Option<_>>()?.map(execution_data_type_rule::Config::ItemOfCollection)
;
                        }
                        GeneratedField::NumberRange => {
                            if config__.is_some() {
                                return Err(serde::de::Error::duplicate_field("numberRange"));
                            }
                            config__ = map_.next_value::<::std::option::Option<_>>()?.map(execution_data_type_rule::Config::NumberRange)
;
                        }
                        GeneratedField::Regex => {
                            if config__.is_some() {
                                return Err(serde::de::Error::duplicate_field("regex"));
                            }
                            config__ = map_.next_value::<::std::option::Option<_>>()?.map(execution_data_type_rule::Config::Regex)
;
                        }
                    }
                }
                Ok(ExecutionDataTypeRule {
                    config: config__,
                })
            }
        }
        deserializer.deserialize_struct("shared.ExecutionDataTypeRule", FIELDS, GeneratedVisitor)
    }
}
impl serde::Serialize for ExecutionFlow {
    #[allow(deprecated)]
    fn serialize<S>(&self, serializer: S) -> std::result::Result<S::Ok, S::Error>
    where
        S: serde::Serializer,
    {
        use serde::ser::SerializeStruct;
        let mut len = 0;
        if self.flow_id != 0 {
            len += 1;
        }
        if self.starting_node_id != 0 {
            len += 1;
        }
        if !self.node_functions.is_empty() {
            len += 1;
        }
        if self.input_value.is_some() {
            len += 1;
        }
        let mut struct_ser = serializer.serialize_struct("shared.ExecutionFlow", len)?;
        if self.flow_id != 0 {
            #[allow(clippy::needless_borrow)]
            #[allow(clippy::needless_borrows_for_generic_args)]
            struct_ser.serialize_field("flowId", ToString::to_string(&self.flow_id).as_str())?;
        }
        if self.starting_node_id != 0 {
            #[allow(clippy::needless_borrow)]
            #[allow(clippy::needless_borrows_for_generic_args)]
            struct_ser.serialize_field("startingNodeId", ToString::to_string(&self.starting_node_id).as_str())?;
        }
        if !self.node_functions.is_empty() {
            struct_ser.serialize_field("nodeFunctions", &self.node_functions)?;
        }
        if let Some(v) = self.input_value.as_ref() {
            struct_ser.serialize_field("inputValue", v)?;
        }
        struct_ser.end()
    }
}
impl<'de> serde::Deserialize<'de> for ExecutionFlow {
    #[allow(deprecated)]
    fn deserialize<D>(deserializer: D) -> std::result::Result<Self, D::Error>
    where
        D: serde::Deserializer<'de>,
    {
        const FIELDS: &[&str] = &[
            "flow_id",
            "flowId",
            "starting_node_id",
            "startingNodeId",
            "node_functions",
            "nodeFunctions",
            "input_value",
            "inputValue",
        ];

        #[allow(clippy::enum_variant_names)]
        enum GeneratedField {
            FlowId,
            StartingNodeId,
            NodeFunctions,
            InputValue,
        }
        impl<'de> serde::Deserialize<'de> for GeneratedField {
            fn deserialize<D>(deserializer: D) -> std::result::Result<GeneratedField, D::Error>
            where
                D: serde::Deserializer<'de>,
            {
                struct GeneratedVisitor;

                impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
                    type Value = GeneratedField;

                    fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                        write!(formatter, "expected one of: {:?}", &FIELDS)
                    }

                    #[allow(unused_variables)]
                    fn visit_str<E>(self, value: &str) -> std::result::Result<GeneratedField, E>
                    where
                        E: serde::de::Error,
                    {
                        match value {
                            "flowId" | "flow_id" => Ok(GeneratedField::FlowId),
                            "startingNodeId" | "starting_node_id" => Ok(GeneratedField::StartingNodeId),
                            "nodeFunctions" | "node_functions" => Ok(GeneratedField::NodeFunctions),
                            "inputValue" | "input_value" => Ok(GeneratedField::InputValue),
                            _ => Err(serde::de::Error::unknown_field(value, FIELDS)),
                        }
                    }
                }
                deserializer.deserialize_identifier(GeneratedVisitor)
            }
        }
        struct GeneratedVisitor;
        impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
            type Value = ExecutionFlow;

            fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                formatter.write_str("struct shared.ExecutionFlow")
            }

            fn visit_map<V>(self, mut map_: V) -> std::result::Result<ExecutionFlow, V::Error>
                where
                    V: serde::de::MapAccess<'de>,
            {
                let mut flow_id__ = None;
                let mut starting_node_id__ = None;
                let mut node_functions__ = None;
                let mut input_value__ = None;
                while let Some(k) = map_.next_key()? {
                    match k {
                        GeneratedField::FlowId => {
                            if flow_id__.is_some() {
                                return Err(serde::de::Error::duplicate_field("flowId"));
                            }
                            flow_id__ = 
                                Some(map_.next_value::<::pbjson::private::NumberDeserialize<_>>()?.0)
                            ;
                        }
                        GeneratedField::StartingNodeId => {
                            if starting_node_id__.is_some() {
                                return Err(serde::de::Error::duplicate_field("startingNodeId"));
                            }
                            starting_node_id__ = 
                                Some(map_.next_value::<::pbjson::private::NumberDeserialize<_>>()?.0)
                            ;
                        }
                        GeneratedField::NodeFunctions => {
                            if node_functions__.is_some() {
                                return Err(serde::de::Error::duplicate_field("nodeFunctions"));
                            }
                            node_functions__ = Some(map_.next_value()?);
                        }
                        GeneratedField::InputValue => {
                            if input_value__.is_some() {
                                return Err(serde::de::Error::duplicate_field("inputValue"));
                            }
                            input_value__ = map_.next_value()?;
                        }
                    }
                }
                Ok(ExecutionFlow {
                    flow_id: flow_id__.unwrap_or_default(),
                    starting_node_id: starting_node_id__.unwrap_or_default(),
                    node_functions: node_functions__.unwrap_or_default(),
                    input_value: input_value__,
                })
            }
        }
        deserializer.deserialize_struct("shared.ExecutionFlow", FIELDS, GeneratedVisitor)
    }
}
impl serde::Serialize for FlowSetting {
    #[allow(deprecated)]
    fn serialize<S>(&self, serializer: S) -> std::result::Result<S::Ok, S::Error>
    where
        S: serde::Serializer,
    {
        use serde::ser::SerializeStruct;
        let mut len = 0;
        if self.database_id != 0 {
            len += 1;
        }
        if !self.flow_setting_id.is_empty() {
            len += 1;
        }
        if self.object.is_some() {
            len += 1;
        }
        let mut struct_ser = serializer.serialize_struct("shared.FlowSetting", len)?;
        if self.database_id != 0 {
            #[allow(clippy::needless_borrow)]
            #[allow(clippy::needless_borrows_for_generic_args)]
            struct_ser.serialize_field("databaseId", ToString::to_string(&self.database_id).as_str())?;
        }
        if !self.flow_setting_id.is_empty() {
            struct_ser.serialize_field("flowSettingId", &self.flow_setting_id)?;
        }
        if let Some(v) = self.object.as_ref() {
            struct_ser.serialize_field("object", v)?;
        }
        struct_ser.end()
    }
}
impl<'de> serde::Deserialize<'de> for FlowSetting {
    #[allow(deprecated)]
    fn deserialize<D>(deserializer: D) -> std::result::Result<Self, D::Error>
    where
        D: serde::Deserializer<'de>,
    {
        const FIELDS: &[&str] = &[
            "database_id",
            "databaseId",
            "flow_setting_id",
            "flowSettingId",
            "object",
        ];

        #[allow(clippy::enum_variant_names)]
        enum GeneratedField {
            DatabaseId,
            FlowSettingId,
            Object,
        }
        impl<'de> serde::Deserialize<'de> for GeneratedField {
            fn deserialize<D>(deserializer: D) -> std::result::Result<GeneratedField, D::Error>
            where
                D: serde::Deserializer<'de>,
            {
                struct GeneratedVisitor;

                impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
                    type Value = GeneratedField;

                    fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                        write!(formatter, "expected one of: {:?}", &FIELDS)
                    }

                    #[allow(unused_variables)]
                    fn visit_str<E>(self, value: &str) -> std::result::Result<GeneratedField, E>
                    where
                        E: serde::de::Error,
                    {
                        match value {
                            "databaseId" | "database_id" => Ok(GeneratedField::DatabaseId),
                            "flowSettingId" | "flow_setting_id" => Ok(GeneratedField::FlowSettingId),
                            "object" => Ok(GeneratedField::Object),
                            _ => Err(serde::de::Error::unknown_field(value, FIELDS)),
                        }
                    }
                }
                deserializer.deserialize_identifier(GeneratedVisitor)
            }
        }
        struct GeneratedVisitor;
        impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
            type Value = FlowSetting;

            fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                formatter.write_str("struct shared.FlowSetting")
            }

            fn visit_map<V>(self, mut map_: V) -> std::result::Result<FlowSetting, V::Error>
                where
                    V: serde::de::MapAccess<'de>,
            {
                let mut database_id__ = None;
                let mut flow_setting_id__ = None;
                let mut object__ = None;
                while let Some(k) = map_.next_key()? {
                    match k {
                        GeneratedField::DatabaseId => {
                            if database_id__.is_some() {
                                return Err(serde::de::Error::duplicate_field("databaseId"));
                            }
                            database_id__ = 
                                Some(map_.next_value::<::pbjson::private::NumberDeserialize<_>>()?.0)
                            ;
                        }
                        GeneratedField::FlowSettingId => {
                            if flow_setting_id__.is_some() {
                                return Err(serde::de::Error::duplicate_field("flowSettingId"));
                            }
                            flow_setting_id__ = Some(map_.next_value()?);
                        }
                        GeneratedField::Object => {
                            if object__.is_some() {
                                return Err(serde::de::Error::duplicate_field("object"));
                            }
                            object__ = map_.next_value()?;
                        }
                    }
                }
                Ok(FlowSetting {
                    database_id: database_id__.unwrap_or_default(),
                    flow_setting_id: flow_setting_id__.unwrap_or_default(),
                    object: object__,
                })
            }
        }
        deserializer.deserialize_struct("shared.FlowSetting", FIELDS, GeneratedVisitor)
    }
}
impl serde::Serialize for FlowType {
    #[allow(deprecated)]
    fn serialize<S>(&self, serializer: S) -> std::result::Result<S::Ok, S::Error>
    where
        S: serde::Serializer,
    {
        use serde::ser::SerializeStruct;
        let mut len = 0;
        if !self.identifier.is_empty() {
            len += 1;
        }
        if !self.settings.is_empty() {
            len += 1;
        }
        if self.input_type_identifier.is_some() {
            len += 1;
        }
        if self.return_type_identifier.is_some() {
            len += 1;
        }
        if self.editable {
            len += 1;
        }
        if !self.name.is_empty() {
            len += 1;
        }
        if !self.description.is_empty() {
            len += 1;
        }
        if !self.documentation.is_empty() {
            len += 1;
        }
        if !self.display_message.is_empty() {
            len += 1;
        }
        if !self.alias.is_empty() {
            len += 1;
        }
        if !self.version.is_empty() {
            len += 1;
        }
        let mut struct_ser = serializer.serialize_struct("shared.FlowType", len)?;
        if !self.identifier.is_empty() {
            struct_ser.serialize_field("identifier", &self.identifier)?;
        }
        if !self.settings.is_empty() {
            struct_ser.serialize_field("settings", &self.settings)?;
        }
        if let Some(v) = self.input_type_identifier.as_ref() {
            struct_ser.serialize_field("inputTypeIdentifier", v)?;
        }
        if let Some(v) = self.return_type_identifier.as_ref() {
            struct_ser.serialize_field("returnTypeIdentifier", v)?;
        }
        if self.editable {
            struct_ser.serialize_field("editable", &self.editable)?;
        }
        if !self.name.is_empty() {
            struct_ser.serialize_field("name", &self.name)?;
        }
        if !self.description.is_empty() {
            struct_ser.serialize_field("description", &self.description)?;
        }
        if !self.documentation.is_empty() {
            struct_ser.serialize_field("documentation", &self.documentation)?;
        }
        if !self.display_message.is_empty() {
            struct_ser.serialize_field("displayMessage", &self.display_message)?;
        }
        if !self.alias.is_empty() {
            struct_ser.serialize_field("alias", &self.alias)?;
        }
        if !self.version.is_empty() {
            struct_ser.serialize_field("version", &self.version)?;
        }
        struct_ser.end()
    }
}
impl<'de> serde::Deserialize<'de> for FlowType {
    #[allow(deprecated)]
    fn deserialize<D>(deserializer: D) -> std::result::Result<Self, D::Error>
    where
        D: serde::Deserializer<'de>,
    {
        const FIELDS: &[&str] = &[
            "identifier",
            "settings",
            "input_type_identifier",
            "inputTypeIdentifier",
            "return_type_identifier",
            "returnTypeIdentifier",
            "editable",
            "name",
            "description",
            "documentation",
            "display_message",
            "displayMessage",
            "alias",
            "version",
        ];

        #[allow(clippy::enum_variant_names)]
        enum GeneratedField {
            Identifier,
            Settings,
            InputTypeIdentifier,
            ReturnTypeIdentifier,
            Editable,
            Name,
            Description,
            Documentation,
            DisplayMessage,
            Alias,
            Version,
        }
        impl<'de> serde::Deserialize<'de> for GeneratedField {
            fn deserialize<D>(deserializer: D) -> std::result::Result<GeneratedField, D::Error>
            where
                D: serde::Deserializer<'de>,
            {
                struct GeneratedVisitor;

                impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
                    type Value = GeneratedField;

                    fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                        write!(formatter, "expected one of: {:?}", &FIELDS)
                    }

                    #[allow(unused_variables)]
                    fn visit_str<E>(self, value: &str) -> std::result::Result<GeneratedField, E>
                    where
                        E: serde::de::Error,
                    {
                        match value {
                            "identifier" => Ok(GeneratedField::Identifier),
                            "settings" => Ok(GeneratedField::Settings),
                            "inputTypeIdentifier" | "input_type_identifier" => Ok(GeneratedField::InputTypeIdentifier),
                            "returnTypeIdentifier" | "return_type_identifier" => Ok(GeneratedField::ReturnTypeIdentifier),
                            "editable" => Ok(GeneratedField::Editable),
                            "name" => Ok(GeneratedField::Name),
                            "description" => Ok(GeneratedField::Description),
                            "documentation" => Ok(GeneratedField::Documentation),
                            "displayMessage" | "display_message" => Ok(GeneratedField::DisplayMessage),
                            "alias" => Ok(GeneratedField::Alias),
                            "version" => Ok(GeneratedField::Version),
                            _ => Err(serde::de::Error::unknown_field(value, FIELDS)),
                        }
                    }
                }
                deserializer.deserialize_identifier(GeneratedVisitor)
            }
        }
        struct GeneratedVisitor;
        impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
            type Value = FlowType;

            fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                formatter.write_str("struct shared.FlowType")
            }

            fn visit_map<V>(self, mut map_: V) -> std::result::Result<FlowType, V::Error>
                where
                    V: serde::de::MapAccess<'de>,
            {
                let mut identifier__ = None;
                let mut settings__ = None;
                let mut input_type_identifier__ = None;
                let mut return_type_identifier__ = None;
                let mut editable__ = None;
                let mut name__ = None;
                let mut description__ = None;
                let mut documentation__ = None;
                let mut display_message__ = None;
                let mut alias__ = None;
                let mut version__ = None;
                while let Some(k) = map_.next_key()? {
                    match k {
                        GeneratedField::Identifier => {
                            if identifier__.is_some() {
                                return Err(serde::de::Error::duplicate_field("identifier"));
                            }
                            identifier__ = Some(map_.next_value()?);
                        }
                        GeneratedField::Settings => {
                            if settings__.is_some() {
                                return Err(serde::de::Error::duplicate_field("settings"));
                            }
                            settings__ = Some(map_.next_value()?);
                        }
                        GeneratedField::InputTypeIdentifier => {
                            if input_type_identifier__.is_some() {
                                return Err(serde::de::Error::duplicate_field("inputTypeIdentifier"));
                            }
                            input_type_identifier__ = map_.next_value()?;
                        }
                        GeneratedField::ReturnTypeIdentifier => {
                            if return_type_identifier__.is_some() {
                                return Err(serde::de::Error::duplicate_field("returnTypeIdentifier"));
                            }
                            return_type_identifier__ = map_.next_value()?;
                        }
                        GeneratedField::Editable => {
                            if editable__.is_some() {
                                return Err(serde::de::Error::duplicate_field("editable"));
                            }
                            editable__ = Some(map_.next_value()?);
                        }
                        GeneratedField::Name => {
                            if name__.is_some() {
                                return Err(serde::de::Error::duplicate_field("name"));
                            }
                            name__ = Some(map_.next_value()?);
                        }
                        GeneratedField::Description => {
                            if description__.is_some() {
                                return Err(serde::de::Error::duplicate_field("description"));
                            }
                            description__ = Some(map_.next_value()?);
                        }
                        GeneratedField::Documentation => {
                            if documentation__.is_some() {
                                return Err(serde::de::Error::duplicate_field("documentation"));
                            }
                            documentation__ = Some(map_.next_value()?);
                        }
                        GeneratedField::DisplayMessage => {
                            if display_message__.is_some() {
                                return Err(serde::de::Error::duplicate_field("displayMessage"));
                            }
                            display_message__ = Some(map_.next_value()?);
                        }
                        GeneratedField::Alias => {
                            if alias__.is_some() {
                                return Err(serde::de::Error::duplicate_field("alias"));
                            }
                            alias__ = Some(map_.next_value()?);
                        }
                        GeneratedField::Version => {
                            if version__.is_some() {
                                return Err(serde::de::Error::duplicate_field("version"));
                            }
                            version__ = Some(map_.next_value()?);
                        }
                    }
                }
                Ok(FlowType {
                    identifier: identifier__.unwrap_or_default(),
                    settings: settings__.unwrap_or_default(),
                    input_type_identifier: input_type_identifier__,
                    return_type_identifier: return_type_identifier__,
                    editable: editable__.unwrap_or_default(),
                    name: name__.unwrap_or_default(),
                    description: description__.unwrap_or_default(),
                    documentation: documentation__.unwrap_or_default(),
                    display_message: display_message__.unwrap_or_default(),
                    alias: alias__.unwrap_or_default(),
                    version: version__.unwrap_or_default(),
                })
            }
        }
        deserializer.deserialize_struct("shared.FlowType", FIELDS, GeneratedVisitor)
    }
}
impl serde::Serialize for FlowTypeSetting {
    #[allow(deprecated)]
    fn serialize<S>(&self, serializer: S) -> std::result::Result<S::Ok, S::Error>
    where
        S: serde::Serializer,
    {
        use serde::ser::SerializeStruct;
        let mut len = 0;
        if !self.identifier.is_empty() {
            len += 1;
        }
        if self.unique {
            len += 1;
        }
        if !self.data_type_identifier.is_empty() {
            len += 1;
        }
        if self.default_value.is_some() {
            len += 1;
        }
        if !self.name.is_empty() {
            len += 1;
        }
        if !self.description.is_empty() {
            len += 1;
        }
        let mut struct_ser = serializer.serialize_struct("shared.FlowTypeSetting", len)?;
        if !self.identifier.is_empty() {
            struct_ser.serialize_field("identifier", &self.identifier)?;
        }
        if self.unique {
            struct_ser.serialize_field("unique", &self.unique)?;
        }
        if !self.data_type_identifier.is_empty() {
            struct_ser.serialize_field("dataTypeIdentifier", &self.data_type_identifier)?;
        }
        if let Some(v) = self.default_value.as_ref() {
            struct_ser.serialize_field("defaultValue", v)?;
        }
        if !self.name.is_empty() {
            struct_ser.serialize_field("name", &self.name)?;
        }
        if !self.description.is_empty() {
            struct_ser.serialize_field("description", &self.description)?;
        }
        struct_ser.end()
    }
}
impl<'de> serde::Deserialize<'de> for FlowTypeSetting {
    #[allow(deprecated)]
    fn deserialize<D>(deserializer: D) -> std::result::Result<Self, D::Error>
    where
        D: serde::Deserializer<'de>,
    {
        const FIELDS: &[&str] = &[
            "identifier",
            "unique",
            "data_type_identifier",
            "dataTypeIdentifier",
            "default_value",
            "defaultValue",
            "name",
            "description",
        ];

        #[allow(clippy::enum_variant_names)]
        enum GeneratedField {
            Identifier,
            Unique,
            DataTypeIdentifier,
            DefaultValue,
            Name,
            Description,
        }
        impl<'de> serde::Deserialize<'de> for GeneratedField {
            fn deserialize<D>(deserializer: D) -> std::result::Result<GeneratedField, D::Error>
            where
                D: serde::Deserializer<'de>,
            {
                struct GeneratedVisitor;

                impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
                    type Value = GeneratedField;

                    fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                        write!(formatter, "expected one of: {:?}", &FIELDS)
                    }

                    #[allow(unused_variables)]
                    fn visit_str<E>(self, value: &str) -> std::result::Result<GeneratedField, E>
                    where
                        E: serde::de::Error,
                    {
                        match value {
                            "identifier" => Ok(GeneratedField::Identifier),
                            "unique" => Ok(GeneratedField::Unique),
                            "dataTypeIdentifier" | "data_type_identifier" => Ok(GeneratedField::DataTypeIdentifier),
                            "defaultValue" | "default_value" => Ok(GeneratedField::DefaultValue),
                            "name" => Ok(GeneratedField::Name),
                            "description" => Ok(GeneratedField::Description),
                            _ => Err(serde::de::Error::unknown_field(value, FIELDS)),
                        }
                    }
                }
                deserializer.deserialize_identifier(GeneratedVisitor)
            }
        }
        struct GeneratedVisitor;
        impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
            type Value = FlowTypeSetting;

            fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                formatter.write_str("struct shared.FlowTypeSetting")
            }

            fn visit_map<V>(self, mut map_: V) -> std::result::Result<FlowTypeSetting, V::Error>
                where
                    V: serde::de::MapAccess<'de>,
            {
                let mut identifier__ = None;
                let mut unique__ = None;
                let mut data_type_identifier__ = None;
                let mut default_value__ = None;
                let mut name__ = None;
                let mut description__ = None;
                while let Some(k) = map_.next_key()? {
                    match k {
                        GeneratedField::Identifier => {
                            if identifier__.is_some() {
                                return Err(serde::de::Error::duplicate_field("identifier"));
                            }
                            identifier__ = Some(map_.next_value()?);
                        }
                        GeneratedField::Unique => {
                            if unique__.is_some() {
                                return Err(serde::de::Error::duplicate_field("unique"));
                            }
                            unique__ = Some(map_.next_value()?);
                        }
                        GeneratedField::DataTypeIdentifier => {
                            if data_type_identifier__.is_some() {
                                return Err(serde::de::Error::duplicate_field("dataTypeIdentifier"));
                            }
                            data_type_identifier__ = Some(map_.next_value()?);
                        }
                        GeneratedField::DefaultValue => {
                            if default_value__.is_some() {
                                return Err(serde::de::Error::duplicate_field("defaultValue"));
                            }
                            default_value__ = map_.next_value()?;
                        }
                        GeneratedField::Name => {
                            if name__.is_some() {
                                return Err(serde::de::Error::duplicate_field("name"));
                            }
                            name__ = Some(map_.next_value()?);
                        }
                        GeneratedField::Description => {
                            if description__.is_some() {
                                return Err(serde::de::Error::duplicate_field("description"));
                            }
                            description__ = Some(map_.next_value()?);
                        }
                    }
                }
                Ok(FlowTypeSetting {
                    identifier: identifier__.unwrap_or_default(),
                    unique: unique__.unwrap_or_default(),
                    data_type_identifier: data_type_identifier__.unwrap_or_default(),
                    default_value: default_value__,
                    name: name__.unwrap_or_default(),
                    description: description__.unwrap_or_default(),
                })
            }
        }
        deserializer.deserialize_struct("shared.FlowTypeSetting", FIELDS, GeneratedVisitor)
    }
}
impl serde::Serialize for Flows {
    #[allow(deprecated)]
    fn serialize<S>(&self, serializer: S) -> std::result::Result<S::Ok, S::Error>
    where
        S: serde::Serializer,
    {
        use serde::ser::SerializeStruct;
        let mut len = 0;
        if !self.flows.is_empty() {
            len += 1;
        }
        let mut struct_ser = serializer.serialize_struct("shared.Flows", len)?;
        if !self.flows.is_empty() {
            struct_ser.serialize_field("flows", &self.flows)?;
        }
        struct_ser.end()
    }
}
impl<'de> serde::Deserialize<'de> for Flows {
    #[allow(deprecated)]
    fn deserialize<D>(deserializer: D) -> std::result::Result<Self, D::Error>
    where
        D: serde::Deserializer<'de>,
    {
        const FIELDS: &[&str] = &[
            "flows",
        ];

        #[allow(clippy::enum_variant_names)]
        enum GeneratedField {
            Flows,
        }
        impl<'de> serde::Deserialize<'de> for GeneratedField {
            fn deserialize<D>(deserializer: D) -> std::result::Result<GeneratedField, D::Error>
            where
                D: serde::Deserializer<'de>,
            {
                struct GeneratedVisitor;

                impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
                    type Value = GeneratedField;

                    fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                        write!(formatter, "expected one of: {:?}", &FIELDS)
                    }

                    #[allow(unused_variables)]
                    fn visit_str<E>(self, value: &str) -> std::result::Result<GeneratedField, E>
                    where
                        E: serde::de::Error,
                    {
                        match value {
                            "flows" => Ok(GeneratedField::Flows),
                            _ => Err(serde::de::Error::unknown_field(value, FIELDS)),
                        }
                    }
                }
                deserializer.deserialize_identifier(GeneratedVisitor)
            }
        }
        struct GeneratedVisitor;
        impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
            type Value = Flows;

            fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                formatter.write_str("struct shared.Flows")
            }

            fn visit_map<V>(self, mut map_: V) -> std::result::Result<Flows, V::Error>
                where
                    V: serde::de::MapAccess<'de>,
            {
                let mut flows__ = None;
                while let Some(k) = map_.next_key()? {
                    match k {
                        GeneratedField::Flows => {
                            if flows__.is_some() {
                                return Err(serde::de::Error::duplicate_field("flows"));
                            }
                            flows__ = Some(map_.next_value()?);
                        }
                    }
                }
                Ok(Flows {
                    flows: flows__.unwrap_or_default(),
                })
            }
        }
        deserializer.deserialize_struct("shared.Flows", FIELDS, GeneratedVisitor)
    }
}
impl serde::Serialize for GenericMapper {
    #[allow(deprecated)]
    fn serialize<S>(&self, serializer: S) -> std::result::Result<S::Ok, S::Error>
    where
        S: serde::Serializer,
    {
        use serde::ser::SerializeStruct;
        let mut len = 0;
        if !self.source.is_empty() {
            len += 1;
        }
        if !self.target.is_empty() {
            len += 1;
        }
        if !self.generic_combinations.is_empty() {
            len += 1;
        }
        let mut struct_ser = serializer.serialize_struct("shared.GenericMapper", len)?;
        if !self.source.is_empty() {
            struct_ser.serialize_field("source", &self.source)?;
        }
        if !self.target.is_empty() {
            struct_ser.serialize_field("target", &self.target)?;
        }
        if !self.generic_combinations.is_empty() {
            let v = self.generic_combinations.iter().cloned().map(|v| {
                generic_mapper::GenericCombinationStrategy::try_from(v)
                    .map_err(|_| serde::ser::Error::custom(format!("Invalid variant {}", v)))
                }).collect::<std::result::Result<Vec<_>, _>>()?;
            struct_ser.serialize_field("genericCombinations", &v)?;
        }
        struct_ser.end()
    }
}
impl<'de> serde::Deserialize<'de> for GenericMapper {
    #[allow(deprecated)]
    fn deserialize<D>(deserializer: D) -> std::result::Result<Self, D::Error>
    where
        D: serde::Deserializer<'de>,
    {
        const FIELDS: &[&str] = &[
            "source",
            "target",
            "generic_combinations",
            "genericCombinations",
        ];

        #[allow(clippy::enum_variant_names)]
        enum GeneratedField {
            Source,
            Target,
            GenericCombinations,
        }
        impl<'de> serde::Deserialize<'de> for GeneratedField {
            fn deserialize<D>(deserializer: D) -> std::result::Result<GeneratedField, D::Error>
            where
                D: serde::Deserializer<'de>,
            {
                struct GeneratedVisitor;

                impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
                    type Value = GeneratedField;

                    fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                        write!(formatter, "expected one of: {:?}", &FIELDS)
                    }

                    #[allow(unused_variables)]
                    fn visit_str<E>(self, value: &str) -> std::result::Result<GeneratedField, E>
                    where
                        E: serde::de::Error,
                    {
                        match value {
                            "source" => Ok(GeneratedField::Source),
                            "target" => Ok(GeneratedField::Target),
                            "genericCombinations" | "generic_combinations" => Ok(GeneratedField::GenericCombinations),
                            _ => Err(serde::de::Error::unknown_field(value, FIELDS)),
                        }
                    }
                }
                deserializer.deserialize_identifier(GeneratedVisitor)
            }
        }
        struct GeneratedVisitor;
        impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
            type Value = GenericMapper;

            fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                formatter.write_str("struct shared.GenericMapper")
            }

            fn visit_map<V>(self, mut map_: V) -> std::result::Result<GenericMapper, V::Error>
                where
                    V: serde::de::MapAccess<'de>,
            {
                let mut source__ = None;
                let mut target__ = None;
                let mut generic_combinations__ = None;
                while let Some(k) = map_.next_key()? {
                    match k {
                        GeneratedField::Source => {
                            if source__.is_some() {
                                return Err(serde::de::Error::duplicate_field("source"));
                            }
                            source__ = Some(map_.next_value()?);
                        }
                        GeneratedField::Target => {
                            if target__.is_some() {
                                return Err(serde::de::Error::duplicate_field("target"));
                            }
                            target__ = Some(map_.next_value()?);
                        }
                        GeneratedField::GenericCombinations => {
                            if generic_combinations__.is_some() {
                                return Err(serde::de::Error::duplicate_field("genericCombinations"));
                            }
                            generic_combinations__ = Some(map_.next_value::<Vec<generic_mapper::GenericCombinationStrategy>>()?.into_iter().map(|x| x as i32).collect());
                        }
                    }
                }
                Ok(GenericMapper {
                    source: source__.unwrap_or_default(),
                    target: target__.unwrap_or_default(),
                    generic_combinations: generic_combinations__.unwrap_or_default(),
                })
            }
        }
        deserializer.deserialize_struct("shared.GenericMapper", FIELDS, GeneratedVisitor)
    }
}
impl serde::Serialize for generic_mapper::GenericCombinationStrategy {
    #[allow(deprecated)]
    fn serialize<S>(&self, serializer: S) -> std::result::Result<S::Ok, S::Error>
    where
        S: serde::Serializer,
    {
        let variant = match self {
            Self::Unknown => "UNKNOWN",
            Self::And => "AND",
            Self::Or => "OR",
        };
        serializer.serialize_str(variant)
    }
}
impl<'de> serde::Deserialize<'de> for generic_mapper::GenericCombinationStrategy {
    #[allow(deprecated)]
    fn deserialize<D>(deserializer: D) -> std::result::Result<Self, D::Error>
    where
        D: serde::Deserializer<'de>,
    {
        const FIELDS: &[&str] = &[
            "UNKNOWN",
            "AND",
            "OR",
        ];

        struct GeneratedVisitor;

        impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
            type Value = generic_mapper::GenericCombinationStrategy;

            fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                write!(formatter, "expected one of: {:?}", &FIELDS)
            }

            fn visit_i64<E>(self, v: i64) -> std::result::Result<Self::Value, E>
            where
                E: serde::de::Error,
            {
                i32::try_from(v)
                    .ok()
                    .and_then(|x| x.try_into().ok())
                    .ok_or_else(|| {
                        serde::de::Error::invalid_value(serde::de::Unexpected::Signed(v), &self)
                    })
            }

            fn visit_u64<E>(self, v: u64) -> std::result::Result<Self::Value, E>
            where
                E: serde::de::Error,
            {
                i32::try_from(v)
                    .ok()
                    .and_then(|x| x.try_into().ok())
                    .ok_or_else(|| {
                        serde::de::Error::invalid_value(serde::de::Unexpected::Unsigned(v), &self)
                    })
            }

            fn visit_str<E>(self, value: &str) -> std::result::Result<Self::Value, E>
            where
                E: serde::de::Error,
            {
                match value {
                    "UNKNOWN" => Ok(generic_mapper::GenericCombinationStrategy::Unknown),
                    "AND" => Ok(generic_mapper::GenericCombinationStrategy::And),
                    "OR" => Ok(generic_mapper::GenericCombinationStrategy::Or),
                    _ => Err(serde::de::Error::unknown_variant(value, FIELDS)),
                }
            }
        }
        deserializer.deserialize_any(GeneratedVisitor)
    }
}
impl serde::Serialize for GenericType {
    #[allow(deprecated)]
    fn serialize<S>(&self, serializer: S) -> std::result::Result<S::Ok, S::Error>
    where
        S: serde::Serializer,
    {
        use serde::ser::SerializeStruct;
        let mut len = 0;
        if !self.data_type_identifier.is_empty() {
            len += 1;
        }
        if !self.generic_mappers.is_empty() {
            len += 1;
        }
        let mut struct_ser = serializer.serialize_struct("shared.GenericType", len)?;
        if !self.data_type_identifier.is_empty() {
            struct_ser.serialize_field("dataTypeIdentifier", &self.data_type_identifier)?;
        }
        if !self.generic_mappers.is_empty() {
            struct_ser.serialize_field("genericMappers", &self.generic_mappers)?;
        }
        struct_ser.end()
    }
}
impl<'de> serde::Deserialize<'de> for GenericType {
    #[allow(deprecated)]
    fn deserialize<D>(deserializer: D) -> std::result::Result<Self, D::Error>
    where
        D: serde::Deserializer<'de>,
    {
        const FIELDS: &[&str] = &[
            "data_type_identifier",
            "dataTypeIdentifier",
            "generic_mappers",
            "genericMappers",
        ];

        #[allow(clippy::enum_variant_names)]
        enum GeneratedField {
            DataTypeIdentifier,
            GenericMappers,
        }
        impl<'de> serde::Deserialize<'de> for GeneratedField {
            fn deserialize<D>(deserializer: D) -> std::result::Result<GeneratedField, D::Error>
            where
                D: serde::Deserializer<'de>,
            {
                struct GeneratedVisitor;

                impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
                    type Value = GeneratedField;

                    fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                        write!(formatter, "expected one of: {:?}", &FIELDS)
                    }

                    #[allow(unused_variables)]
                    fn visit_str<E>(self, value: &str) -> std::result::Result<GeneratedField, E>
                    where
                        E: serde::de::Error,
                    {
                        match value {
                            "dataTypeIdentifier" | "data_type_identifier" => Ok(GeneratedField::DataTypeIdentifier),
                            "genericMappers" | "generic_mappers" => Ok(GeneratedField::GenericMappers),
                            _ => Err(serde::de::Error::unknown_field(value, FIELDS)),
                        }
                    }
                }
                deserializer.deserialize_identifier(GeneratedVisitor)
            }
        }
        struct GeneratedVisitor;
        impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
            type Value = GenericType;

            fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                formatter.write_str("struct shared.GenericType")
            }

            fn visit_map<V>(self, mut map_: V) -> std::result::Result<GenericType, V::Error>
                where
                    V: serde::de::MapAccess<'de>,
            {
                let mut data_type_identifier__ = None;
                let mut generic_mappers__ = None;
                while let Some(k) = map_.next_key()? {
                    match k {
                        GeneratedField::DataTypeIdentifier => {
                            if data_type_identifier__.is_some() {
                                return Err(serde::de::Error::duplicate_field("dataTypeIdentifier"));
                            }
                            data_type_identifier__ = Some(map_.next_value()?);
                        }
                        GeneratedField::GenericMappers => {
                            if generic_mappers__.is_some() {
                                return Err(serde::de::Error::duplicate_field("genericMappers"));
                            }
                            generic_mappers__ = Some(map_.next_value()?);
                        }
                    }
                }
                Ok(GenericType {
                    data_type_identifier: data_type_identifier__.unwrap_or_default(),
                    generic_mappers: generic_mappers__.unwrap_or_default(),
                })
            }
        }
        deserializer.deserialize_struct("shared.GenericType", FIELDS, GeneratedVisitor)
    }
}
impl serde::Serialize for ListValue {
    #[allow(deprecated)]
    fn serialize<S>(&self, serializer: S) -> std::result::Result<S::Ok, S::Error>
    where
        S: serde::Serializer,
    {
        use serde::ser::SerializeStruct;
        let mut len = 0;
        if !self.values.is_empty() {
            len += 1;
        }
        let mut struct_ser = serializer.serialize_struct("shared.ListValue", len)?;
        if !self.values.is_empty() {
            struct_ser.serialize_field("values", &self.values)?;
        }
        struct_ser.end()
    }
}
impl<'de> serde::Deserialize<'de> for ListValue {
    #[allow(deprecated)]
    fn deserialize<D>(deserializer: D) -> std::result::Result<Self, D::Error>
    where
        D: serde::Deserializer<'de>,
    {
        const FIELDS: &[&str] = &[
            "values",
        ];

        #[allow(clippy::enum_variant_names)]
        enum GeneratedField {
            Values,
        }
        impl<'de> serde::Deserialize<'de> for GeneratedField {
            fn deserialize<D>(deserializer: D) -> std::result::Result<GeneratedField, D::Error>
            where
                D: serde::Deserializer<'de>,
            {
                struct GeneratedVisitor;

                impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
                    type Value = GeneratedField;

                    fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                        write!(formatter, "expected one of: {:?}", &FIELDS)
                    }

                    #[allow(unused_variables)]
                    fn visit_str<E>(self, value: &str) -> std::result::Result<GeneratedField, E>
                    where
                        E: serde::de::Error,
                    {
                        match value {
                            "values" => Ok(GeneratedField::Values),
                            _ => Err(serde::de::Error::unknown_field(value, FIELDS)),
                        }
                    }
                }
                deserializer.deserialize_identifier(GeneratedVisitor)
            }
        }
        struct GeneratedVisitor;
        impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
            type Value = ListValue;

            fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                formatter.write_str("struct shared.ListValue")
            }

            fn visit_map<V>(self, mut map_: V) -> std::result::Result<ListValue, V::Error>
                where
                    V: serde::de::MapAccess<'de>,
            {
                let mut values__ = None;
                while let Some(k) = map_.next_key()? {
                    match k {
                        GeneratedField::Values => {
                            if values__.is_some() {
                                return Err(serde::de::Error::duplicate_field("values"));
                            }
                            values__ = Some(map_.next_value()?);
                        }
                    }
                }
                Ok(ListValue {
                    values: values__.unwrap_or_default(),
                })
            }
        }
        deserializer.deserialize_struct("shared.ListValue", FIELDS, GeneratedVisitor)
    }
}
impl serde::Serialize for NodeFunction {
    #[allow(deprecated)]
    fn serialize<S>(&self, serializer: S) -> std::result::Result<S::Ok, S::Error>
    where
        S: serde::Serializer,
    {
        use serde::ser::SerializeStruct;
        let mut len = 0;
        if self.database_id != 0 {
            len += 1;
        }
        if !self.runtime_function_id.is_empty() {
            len += 1;
        }
        if !self.parameters.is_empty() {
            len += 1;
        }
        if self.next_node_id.is_some() {
            len += 1;
        }
        let mut struct_ser = serializer.serialize_struct("shared.NodeFunction", len)?;
        if self.database_id != 0 {
            #[allow(clippy::needless_borrow)]
            #[allow(clippy::needless_borrows_for_generic_args)]
            struct_ser.serialize_field("databaseId", ToString::to_string(&self.database_id).as_str())?;
        }
        if !self.runtime_function_id.is_empty() {
            struct_ser.serialize_field("runtimeFunctionId", &self.runtime_function_id)?;
        }
        if !self.parameters.is_empty() {
            struct_ser.serialize_field("parameters", &self.parameters)?;
        }
        if let Some(v) = self.next_node_id.as_ref() {
            #[allow(clippy::needless_borrow)]
            #[allow(clippy::needless_borrows_for_generic_args)]
            struct_ser.serialize_field("nextNodeId", ToString::to_string(&v).as_str())?;
        }
        struct_ser.end()
    }
}
impl<'de> serde::Deserialize<'de> for NodeFunction {
    #[allow(deprecated)]
    fn deserialize<D>(deserializer: D) -> std::result::Result<Self, D::Error>
    where
        D: serde::Deserializer<'de>,
    {
        const FIELDS: &[&str] = &[
            "database_id",
            "databaseId",
            "runtime_function_id",
            "runtimeFunctionId",
            "parameters",
            "next_node_id",
            "nextNodeId",
        ];

        #[allow(clippy::enum_variant_names)]
        enum GeneratedField {
            DatabaseId,
            RuntimeFunctionId,
            Parameters,
            NextNodeId,
        }
        impl<'de> serde::Deserialize<'de> for GeneratedField {
            fn deserialize<D>(deserializer: D) -> std::result::Result<GeneratedField, D::Error>
            where
                D: serde::Deserializer<'de>,
            {
                struct GeneratedVisitor;

                impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
                    type Value = GeneratedField;

                    fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                        write!(formatter, "expected one of: {:?}", &FIELDS)
                    }

                    #[allow(unused_variables)]
                    fn visit_str<E>(self, value: &str) -> std::result::Result<GeneratedField, E>
                    where
                        E: serde::de::Error,
                    {
                        match value {
                            "databaseId" | "database_id" => Ok(GeneratedField::DatabaseId),
                            "runtimeFunctionId" | "runtime_function_id" => Ok(GeneratedField::RuntimeFunctionId),
                            "parameters" => Ok(GeneratedField::Parameters),
                            "nextNodeId" | "next_node_id" => Ok(GeneratedField::NextNodeId),
                            _ => Err(serde::de::Error::unknown_field(value, FIELDS)),
                        }
                    }
                }
                deserializer.deserialize_identifier(GeneratedVisitor)
            }
        }
        struct GeneratedVisitor;
        impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
            type Value = NodeFunction;

            fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                formatter.write_str("struct shared.NodeFunction")
            }

            fn visit_map<V>(self, mut map_: V) -> std::result::Result<NodeFunction, V::Error>
                where
                    V: serde::de::MapAccess<'de>,
            {
                let mut database_id__ = None;
                let mut runtime_function_id__ = None;
                let mut parameters__ = None;
                let mut next_node_id__ = None;
                while let Some(k) = map_.next_key()? {
                    match k {
                        GeneratedField::DatabaseId => {
                            if database_id__.is_some() {
                                return Err(serde::de::Error::duplicate_field("databaseId"));
                            }
                            database_id__ = 
                                Some(map_.next_value::<::pbjson::private::NumberDeserialize<_>>()?.0)
                            ;
                        }
                        GeneratedField::RuntimeFunctionId => {
                            if runtime_function_id__.is_some() {
                                return Err(serde::de::Error::duplicate_field("runtimeFunctionId"));
                            }
                            runtime_function_id__ = Some(map_.next_value()?);
                        }
                        GeneratedField::Parameters => {
                            if parameters__.is_some() {
                                return Err(serde::de::Error::duplicate_field("parameters"));
                            }
                            parameters__ = Some(map_.next_value()?);
                        }
                        GeneratedField::NextNodeId => {
                            if next_node_id__.is_some() {
                                return Err(serde::de::Error::duplicate_field("nextNodeId"));
                            }
                            next_node_id__ = 
                                map_.next_value::<::std::option::Option<::pbjson::private::NumberDeserialize<_>>>()?.map(|x| x.0)
                            ;
                        }
                    }
                }
                Ok(NodeFunction {
                    database_id: database_id__.unwrap_or_default(),
                    runtime_function_id: runtime_function_id__.unwrap_or_default(),
                    parameters: parameters__.unwrap_or_default(),
                    next_node_id: next_node_id__,
                })
            }
        }
        deserializer.deserialize_struct("shared.NodeFunction", FIELDS, GeneratedVisitor)
    }
}
impl serde::Serialize for NodeParameter {
    #[allow(deprecated)]
    fn serialize<S>(&self, serializer: S) -> std::result::Result<S::Ok, S::Error>
    where
        S: serde::Serializer,
    {
        use serde::ser::SerializeStruct;
        let mut len = 0;
        if self.database_id != 0 {
            len += 1;
        }
        if !self.runtime_parameter_id.is_empty() {
            len += 1;
        }
        if self.value.is_some() {
            len += 1;
        }
        let mut struct_ser = serializer.serialize_struct("shared.NodeParameter", len)?;
        if self.database_id != 0 {
            #[allow(clippy::needless_borrow)]
            #[allow(clippy::needless_borrows_for_generic_args)]
            struct_ser.serialize_field("databaseId", ToString::to_string(&self.database_id).as_str())?;
        }
        if !self.runtime_parameter_id.is_empty() {
            struct_ser.serialize_field("runtimeParameterId", &self.runtime_parameter_id)?;
        }
        if let Some(v) = self.value.as_ref() {
            struct_ser.serialize_field("value", v)?;
        }
        struct_ser.end()
    }
}
impl<'de> serde::Deserialize<'de> for NodeParameter {
    #[allow(deprecated)]
    fn deserialize<D>(deserializer: D) -> std::result::Result<Self, D::Error>
    where
        D: serde::Deserializer<'de>,
    {
        const FIELDS: &[&str] = &[
            "database_id",
            "databaseId",
            "runtime_parameter_id",
            "runtimeParameterId",
            "value",
        ];

        #[allow(clippy::enum_variant_names)]
        enum GeneratedField {
            DatabaseId,
            RuntimeParameterId,
            Value,
        }
        impl<'de> serde::Deserialize<'de> for GeneratedField {
            fn deserialize<D>(deserializer: D) -> std::result::Result<GeneratedField, D::Error>
            where
                D: serde::Deserializer<'de>,
            {
                struct GeneratedVisitor;

                impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
                    type Value = GeneratedField;

                    fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                        write!(formatter, "expected one of: {:?}", &FIELDS)
                    }

                    #[allow(unused_variables)]
                    fn visit_str<E>(self, value: &str) -> std::result::Result<GeneratedField, E>
                    where
                        E: serde::de::Error,
                    {
                        match value {
                            "databaseId" | "database_id" => Ok(GeneratedField::DatabaseId),
                            "runtimeParameterId" | "runtime_parameter_id" => Ok(GeneratedField::RuntimeParameterId),
                            "value" => Ok(GeneratedField::Value),
                            _ => Err(serde::de::Error::unknown_field(value, FIELDS)),
                        }
                    }
                }
                deserializer.deserialize_identifier(GeneratedVisitor)
            }
        }
        struct GeneratedVisitor;
        impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
            type Value = NodeParameter;

            fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                formatter.write_str("struct shared.NodeParameter")
            }

            fn visit_map<V>(self, mut map_: V) -> std::result::Result<NodeParameter, V::Error>
                where
                    V: serde::de::MapAccess<'de>,
            {
                let mut database_id__ = None;
                let mut runtime_parameter_id__ = None;
                let mut value__ = None;
                while let Some(k) = map_.next_key()? {
                    match k {
                        GeneratedField::DatabaseId => {
                            if database_id__.is_some() {
                                return Err(serde::de::Error::duplicate_field("databaseId"));
                            }
                            database_id__ = 
                                Some(map_.next_value::<::pbjson::private::NumberDeserialize<_>>()?.0)
                            ;
                        }
                        GeneratedField::RuntimeParameterId => {
                            if runtime_parameter_id__.is_some() {
                                return Err(serde::de::Error::duplicate_field("runtimeParameterId"));
                            }
                            runtime_parameter_id__ = Some(map_.next_value()?);
                        }
                        GeneratedField::Value => {
                            if value__.is_some() {
                                return Err(serde::de::Error::duplicate_field("value"));
                            }
                            value__ = map_.next_value()?;
                        }
                    }
                }
                Ok(NodeParameter {
                    database_id: database_id__.unwrap_or_default(),
                    runtime_parameter_id: runtime_parameter_id__.unwrap_or_default(),
                    value: value__,
                })
            }
        }
        deserializer.deserialize_struct("shared.NodeParameter", FIELDS, GeneratedVisitor)
    }
}
impl serde::Serialize for NodeValue {
    #[allow(deprecated)]
    fn serialize<S>(&self, serializer: S) -> std::result::Result<S::Ok, S::Error>
    where
        S: serde::Serializer,
    {
        use serde::ser::SerializeStruct;
        let mut len = 0;
        if self.value.is_some() {
            len += 1;
        }
        let mut struct_ser = serializer.serialize_struct("shared.NodeValue", len)?;
        if let Some(v) = self.value.as_ref() {
            match v {
                node_value::Value::LiteralValue(v) => {
                    struct_ser.serialize_field("literalValue", v)?;
                }
                node_value::Value::ReferenceValue(v) => {
                    struct_ser.serialize_field("referenceValue", v)?;
                }
                node_value::Value::NodeFunctionId(v) => {
                    #[allow(clippy::needless_borrow)]
                    #[allow(clippy::needless_borrows_for_generic_args)]
                    struct_ser.serialize_field("nodeFunctionId", ToString::to_string(&v).as_str())?;
                }
            }
        }
        struct_ser.end()
    }
}
impl<'de> serde::Deserialize<'de> for NodeValue {
    #[allow(deprecated)]
    fn deserialize<D>(deserializer: D) -> std::result::Result<Self, D::Error>
    where
        D: serde::Deserializer<'de>,
    {
        const FIELDS: &[&str] = &[
            "literal_value",
            "literalValue",
            "reference_value",
            "referenceValue",
            "node_function_id",
            "nodeFunctionId",
        ];

        #[allow(clippy::enum_variant_names)]
        enum GeneratedField {
            LiteralValue,
            ReferenceValue,
            NodeFunctionId,
        }
        impl<'de> serde::Deserialize<'de> for GeneratedField {
            fn deserialize<D>(deserializer: D) -> std::result::Result<GeneratedField, D::Error>
            where
                D: serde::Deserializer<'de>,
            {
                struct GeneratedVisitor;

                impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
                    type Value = GeneratedField;

                    fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                        write!(formatter, "expected one of: {:?}", &FIELDS)
                    }

                    #[allow(unused_variables)]
                    fn visit_str<E>(self, value: &str) -> std::result::Result<GeneratedField, E>
                    where
                        E: serde::de::Error,
                    {
                        match value {
                            "literalValue" | "literal_value" => Ok(GeneratedField::LiteralValue),
                            "referenceValue" | "reference_value" => Ok(GeneratedField::ReferenceValue),
                            "nodeFunctionId" | "node_function_id" => Ok(GeneratedField::NodeFunctionId),
                            _ => Err(serde::de::Error::unknown_field(value, FIELDS)),
                        }
                    }
                }
                deserializer.deserialize_identifier(GeneratedVisitor)
            }
        }
        struct GeneratedVisitor;
        impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
            type Value = NodeValue;

            fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                formatter.write_str("struct shared.NodeValue")
            }

            fn visit_map<V>(self, mut map_: V) -> std::result::Result<NodeValue, V::Error>
                where
                    V: serde::de::MapAccess<'de>,
            {
                let mut value__ = None;
                while let Some(k) = map_.next_key()? {
                    match k {
                        GeneratedField::LiteralValue => {
                            if value__.is_some() {
                                return Err(serde::de::Error::duplicate_field("literalValue"));
                            }
                            value__ = map_.next_value::<::std::option::Option<_>>()?.map(node_value::Value::LiteralValue)
;
                        }
                        GeneratedField::ReferenceValue => {
                            if value__.is_some() {
                                return Err(serde::de::Error::duplicate_field("referenceValue"));
                            }
                            value__ = map_.next_value::<::std::option::Option<_>>()?.map(node_value::Value::ReferenceValue)
;
                        }
                        GeneratedField::NodeFunctionId => {
                            if value__.is_some() {
                                return Err(serde::de::Error::duplicate_field("nodeFunctionId"));
                            }
                            value__ = map_.next_value::<::std::option::Option<::pbjson::private::NumberDeserialize<_>>>()?.map(|x| node_value::Value::NodeFunctionId(x.0));
                        }
                    }
                }
                Ok(NodeValue {
                    value: value__,
                })
            }
        }
        deserializer.deserialize_struct("shared.NodeValue", FIELDS, GeneratedVisitor)
    }
}
impl serde::Serialize for NullValue {
    #[allow(deprecated)]
    fn serialize<S>(&self, serializer: S) -> std::result::Result<S::Ok, S::Error>
    where
        S: serde::Serializer,
    {
        let variant = match self {
            Self::NullValue => "NULL_VALUE",
        };
        serializer.serialize_str(variant)
    }
}
impl<'de> serde::Deserialize<'de> for NullValue {
    #[allow(deprecated)]
    fn deserialize<D>(deserializer: D) -> std::result::Result<Self, D::Error>
    where
        D: serde::Deserializer<'de>,
    {
        const FIELDS: &[&str] = &[
            "NULL_VALUE",
        ];

        struct GeneratedVisitor;

        impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
            type Value = NullValue;

            fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                write!(formatter, "expected one of: {:?}", &FIELDS)
            }

            fn visit_i64<E>(self, v: i64) -> std::result::Result<Self::Value, E>
            where
                E: serde::de::Error,
            {
                i32::try_from(v)
                    .ok()
                    .and_then(|x| x.try_into().ok())
                    .ok_or_else(|| {
                        serde::de::Error::invalid_value(serde::de::Unexpected::Signed(v), &self)
                    })
            }

            fn visit_u64<E>(self, v: u64) -> std::result::Result<Self::Value, E>
            where
                E: serde::de::Error,
            {
                i32::try_from(v)
                    .ok()
                    .and_then(|x| x.try_into().ok())
                    .ok_or_else(|| {
                        serde::de::Error::invalid_value(serde::de::Unexpected::Unsigned(v), &self)
                    })
            }

            fn visit_str<E>(self, value: &str) -> std::result::Result<Self::Value, E>
            where
                E: serde::de::Error,
            {
                match value {
                    "NULL_VALUE" => Ok(NullValue::NullValue),
                    _ => Err(serde::de::Error::unknown_variant(value, FIELDS)),
                }
            }
        }
        deserializer.deserialize_any(GeneratedVisitor)
    }
}
impl serde::Serialize for ReferencePath {
    #[allow(deprecated)]
    fn serialize<S>(&self, serializer: S) -> std::result::Result<S::Ok, S::Error>
    where
        S: serde::Serializer,
    {
        use serde::ser::SerializeStruct;
        let mut len = 0;
        if self.path.is_some() {
            len += 1;
        }
        if self.array_index.is_some() {
            len += 1;
        }
        let mut struct_ser = serializer.serialize_struct("shared.ReferencePath", len)?;
        if let Some(v) = self.path.as_ref() {
            struct_ser.serialize_field("path", v)?;
        }
        if let Some(v) = self.array_index.as_ref() {
            #[allow(clippy::needless_borrow)]
            #[allow(clippy::needless_borrows_for_generic_args)]
            struct_ser.serialize_field("arrayIndex", ToString::to_string(&v).as_str())?;
        }
        struct_ser.end()
    }
}
impl<'de> serde::Deserialize<'de> for ReferencePath {
    #[allow(deprecated)]
    fn deserialize<D>(deserializer: D) -> std::result::Result<Self, D::Error>
    where
        D: serde::Deserializer<'de>,
    {
        const FIELDS: &[&str] = &[
            "path",
            "array_index",
            "arrayIndex",
        ];

        #[allow(clippy::enum_variant_names)]
        enum GeneratedField {
            Path,
            ArrayIndex,
        }
        impl<'de> serde::Deserialize<'de> for GeneratedField {
            fn deserialize<D>(deserializer: D) -> std::result::Result<GeneratedField, D::Error>
            where
                D: serde::Deserializer<'de>,
            {
                struct GeneratedVisitor;

                impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
                    type Value = GeneratedField;

                    fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                        write!(formatter, "expected one of: {:?}", &FIELDS)
                    }

                    #[allow(unused_variables)]
                    fn visit_str<E>(self, value: &str) -> std::result::Result<GeneratedField, E>
                    where
                        E: serde::de::Error,
                    {
                        match value {
                            "path" => Ok(GeneratedField::Path),
                            "arrayIndex" | "array_index" => Ok(GeneratedField::ArrayIndex),
                            _ => Err(serde::de::Error::unknown_field(value, FIELDS)),
                        }
                    }
                }
                deserializer.deserialize_identifier(GeneratedVisitor)
            }
        }
        struct GeneratedVisitor;
        impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
            type Value = ReferencePath;

            fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                formatter.write_str("struct shared.ReferencePath")
            }

            fn visit_map<V>(self, mut map_: V) -> std::result::Result<ReferencePath, V::Error>
                where
                    V: serde::de::MapAccess<'de>,
            {
                let mut path__ = None;
                let mut array_index__ = None;
                while let Some(k) = map_.next_key()? {
                    match k {
                        GeneratedField::Path => {
                            if path__.is_some() {
                                return Err(serde::de::Error::duplicate_field("path"));
                            }
                            path__ = map_.next_value()?;
                        }
                        GeneratedField::ArrayIndex => {
                            if array_index__.is_some() {
                                return Err(serde::de::Error::duplicate_field("arrayIndex"));
                            }
                            array_index__ = 
                                map_.next_value::<::std::option::Option<::pbjson::private::NumberDeserialize<_>>>()?.map(|x| x.0)
                            ;
                        }
                    }
                }
                Ok(ReferencePath {
                    path: path__,
                    array_index: array_index__,
                })
            }
        }
        deserializer.deserialize_struct("shared.ReferencePath", FIELDS, GeneratedVisitor)
    }
}
impl serde::Serialize for ReferenceValue {
    #[allow(deprecated)]
    fn serialize<S>(&self, serializer: S) -> std::result::Result<S::Ok, S::Error>
    where
        S: serde::Serializer,
    {
        use serde::ser::SerializeStruct;
        let mut len = 0;
        if self.node_id != 0 {
            len += 1;
        }
        if !self.paths.is_empty() {
            len += 1;
        }
        let mut struct_ser = serializer.serialize_struct("shared.ReferenceValue", len)?;
        if self.node_id != 0 {
            #[allow(clippy::needless_borrow)]
            #[allow(clippy::needless_borrows_for_generic_args)]
            struct_ser.serialize_field("nodeId", ToString::to_string(&self.node_id).as_str())?;
        }
        if !self.paths.is_empty() {
            struct_ser.serialize_field("paths", &self.paths)?;
        }
        struct_ser.end()
    }
}
impl<'de> serde::Deserialize<'de> for ReferenceValue {
    #[allow(deprecated)]
    fn deserialize<D>(deserializer: D) -> std::result::Result<Self, D::Error>
    where
        D: serde::Deserializer<'de>,
    {
        const FIELDS: &[&str] = &[
            "node_id",
            "nodeId",
            "paths",
        ];

        #[allow(clippy::enum_variant_names)]
        enum GeneratedField {
            NodeId,
            Paths,
        }
        impl<'de> serde::Deserialize<'de> for GeneratedField {
            fn deserialize<D>(deserializer: D) -> std::result::Result<GeneratedField, D::Error>
            where
                D: serde::Deserializer<'de>,
            {
                struct GeneratedVisitor;

                impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
                    type Value = GeneratedField;

                    fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                        write!(formatter, "expected one of: {:?}", &FIELDS)
                    }

                    #[allow(unused_variables)]
                    fn visit_str<E>(self, value: &str) -> std::result::Result<GeneratedField, E>
                    where
                        E: serde::de::Error,
                    {
                        match value {
                            "nodeId" | "node_id" => Ok(GeneratedField::NodeId),
                            "paths" => Ok(GeneratedField::Paths),
                            _ => Err(serde::de::Error::unknown_field(value, FIELDS)),
                        }
                    }
                }
                deserializer.deserialize_identifier(GeneratedVisitor)
            }
        }
        struct GeneratedVisitor;
        impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
            type Value = ReferenceValue;

            fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                formatter.write_str("struct shared.ReferenceValue")
            }

            fn visit_map<V>(self, mut map_: V) -> std::result::Result<ReferenceValue, V::Error>
                where
                    V: serde::de::MapAccess<'de>,
            {
                let mut node_id__ = None;
                let mut paths__ = None;
                while let Some(k) = map_.next_key()? {
                    match k {
                        GeneratedField::NodeId => {
                            if node_id__.is_some() {
                                return Err(serde::de::Error::duplicate_field("nodeId"));
                            }
                            node_id__ = 
                                Some(map_.next_value::<::pbjson::private::NumberDeserialize<_>>()?.0)
                            ;
                        }
                        GeneratedField::Paths => {
                            if paths__.is_some() {
                                return Err(serde::de::Error::duplicate_field("paths"));
                            }
                            paths__ = Some(map_.next_value()?);
                        }
                    }
                }
                Ok(ReferenceValue {
                    node_id: node_id__.unwrap_or_default(),
                    paths: paths__.unwrap_or_default(),
                })
            }
        }
        deserializer.deserialize_struct("shared.ReferenceValue", FIELDS, GeneratedVisitor)
    }
}
impl serde::Serialize for RuntimeFunctionDefinition {
    #[allow(deprecated)]
    fn serialize<S>(&self, serializer: S) -> std::result::Result<S::Ok, S::Error>
    where
        S: serde::Serializer,
    {
        use serde::ser::SerializeStruct;
        let mut len = 0;
        if !self.runtime_name.is_empty() {
            len += 1;
        }
        if !self.runtime_parameter_definitions.is_empty() {
            len += 1;
        }
        if self.return_type_identifier.is_some() {
            len += 1;
        }
        if self.throws_error {
            len += 1;
        }
        if !self.generic_keys.is_empty() {
            len += 1;
        }
        if !self.name.is_empty() {
            len += 1;
        }
        if !self.description.is_empty() {
            len += 1;
        }
        if !self.documentation.is_empty() {
            len += 1;
        }
        if !self.deprecation_message.is_empty() {
            len += 1;
        }
        if !self.display_message.is_empty() {
            len += 1;
        }
        if !self.alias.is_empty() {
            len += 1;
        }
        if !self.version.is_empty() {
            len += 1;
        }
        let mut struct_ser = serializer.serialize_struct("shared.RuntimeFunctionDefinition", len)?;
        if !self.runtime_name.is_empty() {
            struct_ser.serialize_field("runtimeName", &self.runtime_name)?;
        }
        if !self.runtime_parameter_definitions.is_empty() {
            struct_ser.serialize_field("runtimeParameterDefinitions", &self.runtime_parameter_definitions)?;
        }
        if let Some(v) = self.return_type_identifier.as_ref() {
            struct_ser.serialize_field("returnTypeIdentifier", v)?;
        }
        if self.throws_error {
            struct_ser.serialize_field("throwsError", &self.throws_error)?;
        }
        if !self.generic_keys.is_empty() {
            struct_ser.serialize_field("genericKeys", &self.generic_keys)?;
        }
        if !self.name.is_empty() {
            struct_ser.serialize_field("name", &self.name)?;
        }
        if !self.description.is_empty() {
            struct_ser.serialize_field("description", &self.description)?;
        }
        if !self.documentation.is_empty() {
            struct_ser.serialize_field("documentation", &self.documentation)?;
        }
        if !self.deprecation_message.is_empty() {
            struct_ser.serialize_field("deprecationMessage", &self.deprecation_message)?;
        }
        if !self.display_message.is_empty() {
            struct_ser.serialize_field("displayMessage", &self.display_message)?;
        }
        if !self.alias.is_empty() {
            struct_ser.serialize_field("alias", &self.alias)?;
        }
        if !self.version.is_empty() {
            struct_ser.serialize_field("version", &self.version)?;
        }
        struct_ser.end()
    }
}
impl<'de> serde::Deserialize<'de> for RuntimeFunctionDefinition {
    #[allow(deprecated)]
    fn deserialize<D>(deserializer: D) -> std::result::Result<Self, D::Error>
    where
        D: serde::Deserializer<'de>,
    {
        const FIELDS: &[&str] = &[
            "runtime_name",
            "runtimeName",
            "runtime_parameter_definitions",
            "runtimeParameterDefinitions",
            "return_type_identifier",
            "returnTypeIdentifier",
            "throws_error",
            "throwsError",
            "generic_keys",
            "genericKeys",
            "name",
            "description",
            "documentation",
            "deprecation_message",
            "deprecationMessage",
            "display_message",
            "displayMessage",
            "alias",
            "version",
        ];

        #[allow(clippy::enum_variant_names)]
        enum GeneratedField {
            RuntimeName,
            RuntimeParameterDefinitions,
            ReturnTypeIdentifier,
            ThrowsError,
            GenericKeys,
            Name,
            Description,
            Documentation,
            DeprecationMessage,
            DisplayMessage,
            Alias,
            Version,
        }
        impl<'de> serde::Deserialize<'de> for GeneratedField {
            fn deserialize<D>(deserializer: D) -> std::result::Result<GeneratedField, D::Error>
            where
                D: serde::Deserializer<'de>,
            {
                struct GeneratedVisitor;

                impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
                    type Value = GeneratedField;

                    fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                        write!(formatter, "expected one of: {:?}", &FIELDS)
                    }

                    #[allow(unused_variables)]
                    fn visit_str<E>(self, value: &str) -> std::result::Result<GeneratedField, E>
                    where
                        E: serde::de::Error,
                    {
                        match value {
                            "runtimeName" | "runtime_name" => Ok(GeneratedField::RuntimeName),
                            "runtimeParameterDefinitions" | "runtime_parameter_definitions" => Ok(GeneratedField::RuntimeParameterDefinitions),
                            "returnTypeIdentifier" | "return_type_identifier" => Ok(GeneratedField::ReturnTypeIdentifier),
                            "throwsError" | "throws_error" => Ok(GeneratedField::ThrowsError),
                            "genericKeys" | "generic_keys" => Ok(GeneratedField::GenericKeys),
                            "name" => Ok(GeneratedField::Name),
                            "description" => Ok(GeneratedField::Description),
                            "documentation" => Ok(GeneratedField::Documentation),
                            "deprecationMessage" | "deprecation_message" => Ok(GeneratedField::DeprecationMessage),
                            "displayMessage" | "display_message" => Ok(GeneratedField::DisplayMessage),
                            "alias" => Ok(GeneratedField::Alias),
                            "version" => Ok(GeneratedField::Version),
                            _ => Err(serde::de::Error::unknown_field(value, FIELDS)),
                        }
                    }
                }
                deserializer.deserialize_identifier(GeneratedVisitor)
            }
        }
        struct GeneratedVisitor;
        impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
            type Value = RuntimeFunctionDefinition;

            fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                formatter.write_str("struct shared.RuntimeFunctionDefinition")
            }

            fn visit_map<V>(self, mut map_: V) -> std::result::Result<RuntimeFunctionDefinition, V::Error>
                where
                    V: serde::de::MapAccess<'de>,
            {
                let mut runtime_name__ = None;
                let mut runtime_parameter_definitions__ = None;
                let mut return_type_identifier__ = None;
                let mut throws_error__ = None;
                let mut generic_keys__ = None;
                let mut name__ = None;
                let mut description__ = None;
                let mut documentation__ = None;
                let mut deprecation_message__ = None;
                let mut display_message__ = None;
                let mut alias__ = None;
                let mut version__ = None;
                while let Some(k) = map_.next_key()? {
                    match k {
                        GeneratedField::RuntimeName => {
                            if runtime_name__.is_some() {
                                return Err(serde::de::Error::duplicate_field("runtimeName"));
                            }
                            runtime_name__ = Some(map_.next_value()?);
                        }
                        GeneratedField::RuntimeParameterDefinitions => {
                            if runtime_parameter_definitions__.is_some() {
                                return Err(serde::de::Error::duplicate_field("runtimeParameterDefinitions"));
                            }
                            runtime_parameter_definitions__ = Some(map_.next_value()?);
                        }
                        GeneratedField::ReturnTypeIdentifier => {
                            if return_type_identifier__.is_some() {
                                return Err(serde::de::Error::duplicate_field("returnTypeIdentifier"));
                            }
                            return_type_identifier__ = map_.next_value()?;
                        }
                        GeneratedField::ThrowsError => {
                            if throws_error__.is_some() {
                                return Err(serde::de::Error::duplicate_field("throwsError"));
                            }
                            throws_error__ = Some(map_.next_value()?);
                        }
                        GeneratedField::GenericKeys => {
                            if generic_keys__.is_some() {
                                return Err(serde::de::Error::duplicate_field("genericKeys"));
                            }
                            generic_keys__ = Some(map_.next_value()?);
                        }
                        GeneratedField::Name => {
                            if name__.is_some() {
                                return Err(serde::de::Error::duplicate_field("name"));
                            }
                            name__ = Some(map_.next_value()?);
                        }
                        GeneratedField::Description => {
                            if description__.is_some() {
                                return Err(serde::de::Error::duplicate_field("description"));
                            }
                            description__ = Some(map_.next_value()?);
                        }
                        GeneratedField::Documentation => {
                            if documentation__.is_some() {
                                return Err(serde::de::Error::duplicate_field("documentation"));
                            }
                            documentation__ = Some(map_.next_value()?);
                        }
                        GeneratedField::DeprecationMessage => {
                            if deprecation_message__.is_some() {
                                return Err(serde::de::Error::duplicate_field("deprecationMessage"));
                            }
                            deprecation_message__ = Some(map_.next_value()?);
                        }
                        GeneratedField::DisplayMessage => {
                            if display_message__.is_some() {
                                return Err(serde::de::Error::duplicate_field("displayMessage"));
                            }
                            display_message__ = Some(map_.next_value()?);
                        }
                        GeneratedField::Alias => {
                            if alias__.is_some() {
                                return Err(serde::de::Error::duplicate_field("alias"));
                            }
                            alias__ = Some(map_.next_value()?);
                        }
                        GeneratedField::Version => {
                            if version__.is_some() {
                                return Err(serde::de::Error::duplicate_field("version"));
                            }
                            version__ = Some(map_.next_value()?);
                        }
                    }
                }
                Ok(RuntimeFunctionDefinition {
                    runtime_name: runtime_name__.unwrap_or_default(),
                    runtime_parameter_definitions: runtime_parameter_definitions__.unwrap_or_default(),
                    return_type_identifier: return_type_identifier__,
                    throws_error: throws_error__.unwrap_or_default(),
                    generic_keys: generic_keys__.unwrap_or_default(),
                    name: name__.unwrap_or_default(),
                    description: description__.unwrap_or_default(),
                    documentation: documentation__.unwrap_or_default(),
                    deprecation_message: deprecation_message__.unwrap_or_default(),
                    display_message: display_message__.unwrap_or_default(),
                    alias: alias__.unwrap_or_default(),
                    version: version__.unwrap_or_default(),
                })
            }
        }
        deserializer.deserialize_struct("shared.RuntimeFunctionDefinition", FIELDS, GeneratedVisitor)
    }
}
impl serde::Serialize for RuntimeParameterDefinition {
    #[allow(deprecated)]
    fn serialize<S>(&self, serializer: S) -> std::result::Result<S::Ok, S::Error>
    where
        S: serde::Serializer,
    {
        use serde::ser::SerializeStruct;
        let mut len = 0;
        if self.data_type_identifier.is_some() {
            len += 1;
        }
        if !self.runtime_name.is_empty() {
            len += 1;
        }
        if self.default_value.is_some() {
            len += 1;
        }
        if !self.name.is_empty() {
            len += 1;
        }
        if !self.description.is_empty() {
            len += 1;
        }
        if !self.documentation.is_empty() {
            len += 1;
        }
        let mut struct_ser = serializer.serialize_struct("shared.RuntimeParameterDefinition", len)?;
        if let Some(v) = self.data_type_identifier.as_ref() {
            struct_ser.serialize_field("dataTypeIdentifier", v)?;
        }
        if !self.runtime_name.is_empty() {
            struct_ser.serialize_field("runtimeName", &self.runtime_name)?;
        }
        if let Some(v) = self.default_value.as_ref() {
            struct_ser.serialize_field("defaultValue", v)?;
        }
        if !self.name.is_empty() {
            struct_ser.serialize_field("name", &self.name)?;
        }
        if !self.description.is_empty() {
            struct_ser.serialize_field("description", &self.description)?;
        }
        if !self.documentation.is_empty() {
            struct_ser.serialize_field("documentation", &self.documentation)?;
        }
        struct_ser.end()
    }
}
impl<'de> serde::Deserialize<'de> for RuntimeParameterDefinition {
    #[allow(deprecated)]
    fn deserialize<D>(deserializer: D) -> std::result::Result<Self, D::Error>
    where
        D: serde::Deserializer<'de>,
    {
        const FIELDS: &[&str] = &[
            "data_type_identifier",
            "dataTypeIdentifier",
            "runtime_name",
            "runtimeName",
            "default_value",
            "defaultValue",
            "name",
            "description",
            "documentation",
        ];

        #[allow(clippy::enum_variant_names)]
        enum GeneratedField {
            DataTypeIdentifier,
            RuntimeName,
            DefaultValue,
            Name,
            Description,
            Documentation,
        }
        impl<'de> serde::Deserialize<'de> for GeneratedField {
            fn deserialize<D>(deserializer: D) -> std::result::Result<GeneratedField, D::Error>
            where
                D: serde::Deserializer<'de>,
            {
                struct GeneratedVisitor;

                impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
                    type Value = GeneratedField;

                    fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                        write!(formatter, "expected one of: {:?}", &FIELDS)
                    }

                    #[allow(unused_variables)]
                    fn visit_str<E>(self, value: &str) -> std::result::Result<GeneratedField, E>
                    where
                        E: serde::de::Error,
                    {
                        match value {
                            "dataTypeIdentifier" | "data_type_identifier" => Ok(GeneratedField::DataTypeIdentifier),
                            "runtimeName" | "runtime_name" => Ok(GeneratedField::RuntimeName),
                            "defaultValue" | "default_value" => Ok(GeneratedField::DefaultValue),
                            "name" => Ok(GeneratedField::Name),
                            "description" => Ok(GeneratedField::Description),
                            "documentation" => Ok(GeneratedField::Documentation),
                            _ => Err(serde::de::Error::unknown_field(value, FIELDS)),
                        }
                    }
                }
                deserializer.deserialize_identifier(GeneratedVisitor)
            }
        }
        struct GeneratedVisitor;
        impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
            type Value = RuntimeParameterDefinition;

            fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                formatter.write_str("struct shared.RuntimeParameterDefinition")
            }

            fn visit_map<V>(self, mut map_: V) -> std::result::Result<RuntimeParameterDefinition, V::Error>
                where
                    V: serde::de::MapAccess<'de>,
            {
                let mut data_type_identifier__ = None;
                let mut runtime_name__ = None;
                let mut default_value__ = None;
                let mut name__ = None;
                let mut description__ = None;
                let mut documentation__ = None;
                while let Some(k) = map_.next_key()? {
                    match k {
                        GeneratedField::DataTypeIdentifier => {
                            if data_type_identifier__.is_some() {
                                return Err(serde::de::Error::duplicate_field("dataTypeIdentifier"));
                            }
                            data_type_identifier__ = map_.next_value()?;
                        }
                        GeneratedField::RuntimeName => {
                            if runtime_name__.is_some() {
                                return Err(serde::de::Error::duplicate_field("runtimeName"));
                            }
                            runtime_name__ = Some(map_.next_value()?);
                        }
                        GeneratedField::DefaultValue => {
                            if default_value__.is_some() {
                                return Err(serde::de::Error::duplicate_field("defaultValue"));
                            }
                            default_value__ = map_.next_value()?;
                        }
                        GeneratedField::Name => {
                            if name__.is_some() {
                                return Err(serde::de::Error::duplicate_field("name"));
                            }
                            name__ = Some(map_.next_value()?);
                        }
                        GeneratedField::Description => {
                            if description__.is_some() {
                                return Err(serde::de::Error::duplicate_field("description"));
                            }
                            description__ = Some(map_.next_value()?);
                        }
                        GeneratedField::Documentation => {
                            if documentation__.is_some() {
                                return Err(serde::de::Error::duplicate_field("documentation"));
                            }
                            documentation__ = Some(map_.next_value()?);
                        }
                    }
                }
                Ok(RuntimeParameterDefinition {
                    data_type_identifier: data_type_identifier__,
                    runtime_name: runtime_name__.unwrap_or_default(),
                    default_value: default_value__,
                    name: name__.unwrap_or_default(),
                    description: description__.unwrap_or_default(),
                    documentation: documentation__.unwrap_or_default(),
                })
            }
        }
        deserializer.deserialize_struct("shared.RuntimeParameterDefinition", FIELDS, GeneratedVisitor)
    }
}
impl serde::Serialize for Struct {
    #[allow(deprecated)]
    fn serialize<S>(&self, serializer: S) -> std::result::Result<S::Ok, S::Error>
    where
        S: serde::Serializer,
    {
        use serde::ser::SerializeStruct;
        let mut len = 0;
        if !self.fields.is_empty() {
            len += 1;
        }
        let mut struct_ser = serializer.serialize_struct("shared.Struct", len)?;
        if !self.fields.is_empty() {
            struct_ser.serialize_field("fields", &self.fields)?;
        }
        struct_ser.end()
    }
}
impl<'de> serde::Deserialize<'de> for Struct {
    #[allow(deprecated)]
    fn deserialize<D>(deserializer: D) -> std::result::Result<Self, D::Error>
    where
        D: serde::Deserializer<'de>,
    {
        const FIELDS: &[&str] = &[
            "fields",
        ];

        #[allow(clippy::enum_variant_names)]
        enum GeneratedField {
            Fields,
        }
        impl<'de> serde::Deserialize<'de> for GeneratedField {
            fn deserialize<D>(deserializer: D) -> std::result::Result<GeneratedField, D::Error>
            where
                D: serde::Deserializer<'de>,
            {
                struct GeneratedVisitor;

                impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
                    type Value = GeneratedField;

                    fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                        write!(formatter, "expected one of: {:?}", &FIELDS)
                    }

                    #[allow(unused_variables)]
                    fn visit_str<E>(self, value: &str) -> std::result::Result<GeneratedField, E>
                    where
                        E: serde::de::Error,
                    {
                        match value {
                            "fields" => Ok(GeneratedField::Fields),
                            _ => Err(serde::de::Error::unknown_field(value, FIELDS)),
                        }
                    }
                }
                deserializer.deserialize_identifier(GeneratedVisitor)
            }
        }
        struct GeneratedVisitor;
        impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
            type Value = Struct;

            fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                formatter.write_str("struct shared.Struct")
            }

            fn visit_map<V>(self, mut map_: V) -> std::result::Result<Struct, V::Error>
                where
                    V: serde::de::MapAccess<'de>,
            {
                let mut fields__ = None;
                while let Some(k) = map_.next_key()? {
                    match k {
                        GeneratedField::Fields => {
                            if fields__.is_some() {
                                return Err(serde::de::Error::duplicate_field("fields"));
                            }
                            fields__ = Some(
                                map_.next_value::<std::collections::HashMap<_, _>>()?
                            );
                        }
                    }
                }
                Ok(Struct {
                    fields: fields__.unwrap_or_default(),
                })
            }
        }
        deserializer.deserialize_struct("shared.Struct", FIELDS, GeneratedVisitor)
    }
}
impl serde::Serialize for Translation {
    #[allow(deprecated)]
    fn serialize<S>(&self, serializer: S) -> std::result::Result<S::Ok, S::Error>
    where
        S: serde::Serializer,
    {
        use serde::ser::SerializeStruct;
        let mut len = 0;
        if !self.code.is_empty() {
            len += 1;
        }
        if !self.content.is_empty() {
            len += 1;
        }
        let mut struct_ser = serializer.serialize_struct("shared.Translation", len)?;
        if !self.code.is_empty() {
            struct_ser.serialize_field("code", &self.code)?;
        }
        if !self.content.is_empty() {
            struct_ser.serialize_field("content", &self.content)?;
        }
        struct_ser.end()
    }
}
impl<'de> serde::Deserialize<'de> for Translation {
    #[allow(deprecated)]
    fn deserialize<D>(deserializer: D) -> std::result::Result<Self, D::Error>
    where
        D: serde::Deserializer<'de>,
    {
        const FIELDS: &[&str] = &[
            "code",
            "content",
        ];

        #[allow(clippy::enum_variant_names)]
        enum GeneratedField {
            Code,
            Content,
        }
        impl<'de> serde::Deserialize<'de> for GeneratedField {
            fn deserialize<D>(deserializer: D) -> std::result::Result<GeneratedField, D::Error>
            where
                D: serde::Deserializer<'de>,
            {
                struct GeneratedVisitor;

                impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
                    type Value = GeneratedField;

                    fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                        write!(formatter, "expected one of: {:?}", &FIELDS)
                    }

                    #[allow(unused_variables)]
                    fn visit_str<E>(self, value: &str) -> std::result::Result<GeneratedField, E>
                    where
                        E: serde::de::Error,
                    {
                        match value {
                            "code" => Ok(GeneratedField::Code),
                            "content" => Ok(GeneratedField::Content),
                            _ => Err(serde::de::Error::unknown_field(value, FIELDS)),
                        }
                    }
                }
                deserializer.deserialize_identifier(GeneratedVisitor)
            }
        }
        struct GeneratedVisitor;
        impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
            type Value = Translation;

            fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                formatter.write_str("struct shared.Translation")
            }

            fn visit_map<V>(self, mut map_: V) -> std::result::Result<Translation, V::Error>
                where
                    V: serde::de::MapAccess<'de>,
            {
                let mut code__ = None;
                let mut content__ = None;
                while let Some(k) = map_.next_key()? {
                    match k {
                        GeneratedField::Code => {
                            if code__.is_some() {
                                return Err(serde::de::Error::duplicate_field("code"));
                            }
                            code__ = Some(map_.next_value()?);
                        }
                        GeneratedField::Content => {
                            if content__.is_some() {
                                return Err(serde::de::Error::duplicate_field("content"));
                            }
                            content__ = Some(map_.next_value()?);
                        }
                    }
                }
                Ok(Translation {
                    code: code__.unwrap_or_default(),
                    content: content__.unwrap_or_default(),
                })
            }
        }
        deserializer.deserialize_struct("shared.Translation", FIELDS, GeneratedVisitor)
    }
}
impl serde::Serialize for ValidationFlow {
    #[allow(deprecated)]
    fn serialize<S>(&self, serializer: S) -> std::result::Result<S::Ok, S::Error>
    where
        S: serde::Serializer,
    {
        use serde::ser::SerializeStruct;
        let mut len = 0;
        if self.flow_id != 0 {
            len += 1;
        }
        if self.project_id != 0 {
            len += 1;
        }
        if !self.r#type.is_empty() {
            len += 1;
        }
        if !self.data_types.is_empty() {
            len += 1;
        }
        if self.input_type_identifier.is_some() {
            len += 1;
        }
        if self.return_type_identifier.is_some() {
            len += 1;
        }
        if !self.settings.is_empty() {
            len += 1;
        }
        if self.starting_node_id != 0 {
            len += 1;
        }
        if !self.node_functions.is_empty() {
            len += 1;
        }
        let mut struct_ser = serializer.serialize_struct("shared.ValidationFlow", len)?;
        if self.flow_id != 0 {
            #[allow(clippy::needless_borrow)]
            #[allow(clippy::needless_borrows_for_generic_args)]
            struct_ser.serialize_field("flowId", ToString::to_string(&self.flow_id).as_str())?;
        }
        if self.project_id != 0 {
            #[allow(clippy::needless_borrow)]
            #[allow(clippy::needless_borrows_for_generic_args)]
            struct_ser.serialize_field("projectId", ToString::to_string(&self.project_id).as_str())?;
        }
        if !self.r#type.is_empty() {
            struct_ser.serialize_field("type", &self.r#type)?;
        }
        if !self.data_types.is_empty() {
            struct_ser.serialize_field("dataTypes", &self.data_types)?;
        }
        if let Some(v) = self.input_type_identifier.as_ref() {
            struct_ser.serialize_field("inputTypeIdentifier", v)?;
        }
        if let Some(v) = self.return_type_identifier.as_ref() {
            struct_ser.serialize_field("returnTypeIdentifier", v)?;
        }
        if !self.settings.is_empty() {
            struct_ser.serialize_field("settings", &self.settings)?;
        }
        if self.starting_node_id != 0 {
            #[allow(clippy::needless_borrow)]
            #[allow(clippy::needless_borrows_for_generic_args)]
            struct_ser.serialize_field("startingNodeId", ToString::to_string(&self.starting_node_id).as_str())?;
        }
        if !self.node_functions.is_empty() {
            struct_ser.serialize_field("nodeFunctions", &self.node_functions)?;
        }
        struct_ser.end()
    }
}
impl<'de> serde::Deserialize<'de> for ValidationFlow {
    #[allow(deprecated)]
    fn deserialize<D>(deserializer: D) -> std::result::Result<Self, D::Error>
    where
        D: serde::Deserializer<'de>,
    {
        const FIELDS: &[&str] = &[
            "flow_id",
            "flowId",
            "project_id",
            "projectId",
            "type",
            "data_types",
            "dataTypes",
            "input_type_identifier",
            "inputTypeIdentifier",
            "return_type_identifier",
            "returnTypeIdentifier",
            "settings",
            "starting_node_id",
            "startingNodeId",
            "node_functions",
            "nodeFunctions",
        ];

        #[allow(clippy::enum_variant_names)]
        enum GeneratedField {
            FlowId,
            ProjectId,
            Type,
            DataTypes,
            InputTypeIdentifier,
            ReturnTypeIdentifier,
            Settings,
            StartingNodeId,
            NodeFunctions,
        }
        impl<'de> serde::Deserialize<'de> for GeneratedField {
            fn deserialize<D>(deserializer: D) -> std::result::Result<GeneratedField, D::Error>
            where
                D: serde::Deserializer<'de>,
            {
                struct GeneratedVisitor;

                impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
                    type Value = GeneratedField;

                    fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                        write!(formatter, "expected one of: {:?}", &FIELDS)
                    }

                    #[allow(unused_variables)]
                    fn visit_str<E>(self, value: &str) -> std::result::Result<GeneratedField, E>
                    where
                        E: serde::de::Error,
                    {
                        match value {
                            "flowId" | "flow_id" => Ok(GeneratedField::FlowId),
                            "projectId" | "project_id" => Ok(GeneratedField::ProjectId),
                            "type" => Ok(GeneratedField::Type),
                            "dataTypes" | "data_types" => Ok(GeneratedField::DataTypes),
                            "inputTypeIdentifier" | "input_type_identifier" => Ok(GeneratedField::InputTypeIdentifier),
                            "returnTypeIdentifier" | "return_type_identifier" => Ok(GeneratedField::ReturnTypeIdentifier),
                            "settings" => Ok(GeneratedField::Settings),
                            "startingNodeId" | "starting_node_id" => Ok(GeneratedField::StartingNodeId),
                            "nodeFunctions" | "node_functions" => Ok(GeneratedField::NodeFunctions),
                            _ => Err(serde::de::Error::unknown_field(value, FIELDS)),
                        }
                    }
                }
                deserializer.deserialize_identifier(GeneratedVisitor)
            }
        }
        struct GeneratedVisitor;
        impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
            type Value = ValidationFlow;

            fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                formatter.write_str("struct shared.ValidationFlow")
            }

            fn visit_map<V>(self, mut map_: V) -> std::result::Result<ValidationFlow, V::Error>
                where
                    V: serde::de::MapAccess<'de>,
            {
                let mut flow_id__ = None;
                let mut project_id__ = None;
                let mut r#type__ = None;
                let mut data_types__ = None;
                let mut input_type_identifier__ = None;
                let mut return_type_identifier__ = None;
                let mut settings__ = None;
                let mut starting_node_id__ = None;
                let mut node_functions__ = None;
                while let Some(k) = map_.next_key()? {
                    match k {
                        GeneratedField::FlowId => {
                            if flow_id__.is_some() {
                                return Err(serde::de::Error::duplicate_field("flowId"));
                            }
                            flow_id__ = 
                                Some(map_.next_value::<::pbjson::private::NumberDeserialize<_>>()?.0)
                            ;
                        }
                        GeneratedField::ProjectId => {
                            if project_id__.is_some() {
                                return Err(serde::de::Error::duplicate_field("projectId"));
                            }
                            project_id__ = 
                                Some(map_.next_value::<::pbjson::private::NumberDeserialize<_>>()?.0)
                            ;
                        }
                        GeneratedField::Type => {
                            if r#type__.is_some() {
                                return Err(serde::de::Error::duplicate_field("type"));
                            }
                            r#type__ = Some(map_.next_value()?);
                        }
                        GeneratedField::DataTypes => {
                            if data_types__.is_some() {
                                return Err(serde::de::Error::duplicate_field("dataTypes"));
                            }
                            data_types__ = Some(map_.next_value()?);
                        }
                        GeneratedField::InputTypeIdentifier => {
                            if input_type_identifier__.is_some() {
                                return Err(serde::de::Error::duplicate_field("inputTypeIdentifier"));
                            }
                            input_type_identifier__ = map_.next_value()?;
                        }
                        GeneratedField::ReturnTypeIdentifier => {
                            if return_type_identifier__.is_some() {
                                return Err(serde::de::Error::duplicate_field("returnTypeIdentifier"));
                            }
                            return_type_identifier__ = map_.next_value()?;
                        }
                        GeneratedField::Settings => {
                            if settings__.is_some() {
                                return Err(serde::de::Error::duplicate_field("settings"));
                            }
                            settings__ = Some(map_.next_value()?);
                        }
                        GeneratedField::StartingNodeId => {
                            if starting_node_id__.is_some() {
                                return Err(serde::de::Error::duplicate_field("startingNodeId"));
                            }
                            starting_node_id__ = 
                                Some(map_.next_value::<::pbjson::private::NumberDeserialize<_>>()?.0)
                            ;
                        }
                        GeneratedField::NodeFunctions => {
                            if node_functions__.is_some() {
                                return Err(serde::de::Error::duplicate_field("nodeFunctions"));
                            }
                            node_functions__ = Some(map_.next_value()?);
                        }
                    }
                }
                Ok(ValidationFlow {
                    flow_id: flow_id__.unwrap_or_default(),
                    project_id: project_id__.unwrap_or_default(),
                    r#type: r#type__.unwrap_or_default(),
                    data_types: data_types__.unwrap_or_default(),
                    input_type_identifier: input_type_identifier__,
                    return_type_identifier: return_type_identifier__,
                    settings: settings__.unwrap_or_default(),
                    starting_node_id: starting_node_id__.unwrap_or_default(),
                    node_functions: node_functions__.unwrap_or_default(),
                })
            }
        }
        deserializer.deserialize_struct("shared.ValidationFlow", FIELDS, GeneratedVisitor)
    }
}
impl serde::Serialize for Value {
    #[allow(deprecated)]
    fn serialize<S>(&self, serializer: S) -> std::result::Result<S::Ok, S::Error>
    where
        S: serde::Serializer,
    {
        use serde::ser::SerializeStruct;
        let mut len = 0;
        if self.kind.is_some() {
            len += 1;
        }
        let mut struct_ser = serializer.serialize_struct("shared.Value", len)?;
        if let Some(v) = self.kind.as_ref() {
            match v {
                value::Kind::NullValue(v) => {
                    let v = NullValue::try_from(*v)
                        .map_err(|_| serde::ser::Error::custom(format!("Invalid variant {}", *v)))?;
                    struct_ser.serialize_field("nullValue", &v)?;
                }
                value::Kind::NumberValue(v) => {
                    struct_ser.serialize_field("numberValue", v)?;
                }
                value::Kind::StringValue(v) => {
                    struct_ser.serialize_field("stringValue", v)?;
                }
                value::Kind::BoolValue(v) => {
                    struct_ser.serialize_field("boolValue", v)?;
                }
                value::Kind::StructValue(v) => {
                    struct_ser.serialize_field("structValue", v)?;
                }
                value::Kind::ListValue(v) => {
                    struct_ser.serialize_field("listValue", v)?;
                }
            }
        }
        struct_ser.end()
    }
}
impl<'de> serde::Deserialize<'de> for Value {
    #[allow(deprecated)]
    fn deserialize<D>(deserializer: D) -> std::result::Result<Self, D::Error>
    where
        D: serde::Deserializer<'de>,
    {
        const FIELDS: &[&str] = &[
            "null_value",
            "nullValue",
            "number_value",
            "numberValue",
            "string_value",
            "stringValue",
            "bool_value",
            "boolValue",
            "struct_value",
            "structValue",
            "list_value",
            "listValue",
        ];

        #[allow(clippy::enum_variant_names)]
        enum GeneratedField {
            NullValue,
            NumberValue,
            StringValue,
            BoolValue,
            StructValue,
            ListValue,
        }
        impl<'de> serde::Deserialize<'de> for GeneratedField {
            fn deserialize<D>(deserializer: D) -> std::result::Result<GeneratedField, D::Error>
            where
                D: serde::Deserializer<'de>,
            {
                struct GeneratedVisitor;

                impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
                    type Value = GeneratedField;

                    fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                        write!(formatter, "expected one of: {:?}", &FIELDS)
                    }

                    #[allow(unused_variables)]
                    fn visit_str<E>(self, value: &str) -> std::result::Result<GeneratedField, E>
                    where
                        E: serde::de::Error,
                    {
                        match value {
                            "nullValue" | "null_value" => Ok(GeneratedField::NullValue),
                            "numberValue" | "number_value" => Ok(GeneratedField::NumberValue),
                            "stringValue" | "string_value" => Ok(GeneratedField::StringValue),
                            "boolValue" | "bool_value" => Ok(GeneratedField::BoolValue),
                            "structValue" | "struct_value" => Ok(GeneratedField::StructValue),
                            "listValue" | "list_value" => Ok(GeneratedField::ListValue),
                            _ => Err(serde::de::Error::unknown_field(value, FIELDS)),
                        }
                    }
                }
                deserializer.deserialize_identifier(GeneratedVisitor)
            }
        }
        struct GeneratedVisitor;
        impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {
            type Value = Value;

            fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
                formatter.write_str("struct shared.Value")
            }

            fn visit_map<V>(self, mut map_: V) -> std::result::Result<Value, V::Error>
                where
                    V: serde::de::MapAccess<'de>,
            {
                let mut kind__ = None;
                while let Some(k) = map_.next_key()? {
                    match k {
                        GeneratedField::NullValue => {
                            if kind__.is_some() {
                                return Err(serde::de::Error::duplicate_field("nullValue"));
                            }
                            kind__ = map_.next_value::<::std::option::Option<NullValue>>()?.map(|x| value::Kind::NullValue(x as i32));
                        }
                        GeneratedField::NumberValue => {
                            if kind__.is_some() {
                                return Err(serde::de::Error::duplicate_field("numberValue"));
                            }
                            kind__ = map_.next_value::<::std::option::Option<::pbjson::private::NumberDeserialize<_>>>()?.map(|x| value::Kind::NumberValue(x.0));
                        }
                        GeneratedField::StringValue => {
                            if kind__.is_some() {
                                return Err(serde::de::Error::duplicate_field("stringValue"));
                            }
                            kind__ = map_.next_value::<::std::option::Option<_>>()?.map(value::Kind::StringValue);
                        }
                        GeneratedField::BoolValue => {
                            if kind__.is_some() {
                                return Err(serde::de::Error::duplicate_field("boolValue"));
                            }
                            kind__ = map_.next_value::<::std::option::Option<_>>()?.map(value::Kind::BoolValue);
                        }
                        GeneratedField::StructValue => {
                            if kind__.is_some() {
                                return Err(serde::de::Error::duplicate_field("structValue"));
                            }
                            kind__ = map_.next_value::<::std::option::Option<_>>()?.map(value::Kind::StructValue)
;
                        }
                        GeneratedField::ListValue => {
                            if kind__.is_some() {
                                return Err(serde::de::Error::duplicate_field("listValue"));
                            }
                            kind__ = map_.next_value::<::std::option::Option<_>>()?.map(value::Kind::ListValue)
;
                        }
                    }
                }
                Ok(Value {
                    kind: kind__,
                })
            }
        }
        deserializer.deserialize_struct("shared.Value", FIELDS, GeneratedVisitor)
    }
}
