// Copyright 2023 Emergent Financial, LLC - All Rights Reserved // // // This software is licensed under the Emergent Financial Limited Public License Version 1.0 // (EF-LPLv1). You may use, copy, modify, and distribute this software under the terms and // conditions of the EF-LPL. For more information, please refer to the full text of the license // at https://github.com/emergentfinancial/ef-lpl. // // // THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND, EXPRESS // OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, // FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE // AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, // WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN // CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. // // See ISO-20022 Intellectual Property Rights Policy at // // for more information. use validator::Validate; ::lazy_static::lazy_static! { static ref RESTRICTED_FINX_MAX_34_TEXT_REGEX: ::regex::Regex = ::regex::Regex::new(r#"([0-9a-zA-Z\-\?:\(\)\.,'\+ ]([0-9a-zA-Z\-\?:\(\)\.,'\+ ]*(/[0-9a-zA-Z\-\?:\(\)\.,'\+ ])?)*)"#).unwrap(); } ::lazy_static::lazy_static! { static ref ANY_BIC_DEC_2014_IDENTIFIER_REGEX: ::regex::Regex = ::regex::Regex::new(r#"[A-Z0-9]{4,4}[A-Z]{2,2}[A-Z0-9]{2,2}([A-Z0-9]{3,3}){0,1}"#).unwrap(); } ::lazy_static::lazy_static! { static ref MAX_4_ALPHA_NUMERIC_TEXT_REGEX: ::regex::Regex = ::regex::Regex::new(r#"[a-zA-Z0-9]{1,4}"#).unwrap(); } ::lazy_static::lazy_static! { static ref RESTRICTED_FINZ_MAX_8000_TEXT_REGEX: ::regex::Regex = ::regex::Regex::new(r#"[0-9a-zA-Z!"%&\*;<> \.,\(\)\n\r/='\+:\?@#\{\-_]{1,8000}"#).unwrap(); } ::lazy_static::lazy_static! { static ref RESTRICTED_FINX_MAX_140_TEXT_REGEX: ::regex::Regex = ::regex::Regex::new(r#"[0-9a-zA-Z/\-\?:\(\)\.\n\r,'\+ ]{1,140}"#).unwrap(); } ::lazy_static::lazy_static! { static ref COUNTRY_CODE_REGEX: ::regex::Regex = ::regex::Regex::new(r#"[A-Z]{2,2}"#).unwrap(); } ::lazy_static::lazy_static! { static ref ISIN_OCT_2015_IDENTIFIER_REGEX: ::regex::Regex = ::regex::Regex::new(r#"[A-Z]{2,2}[A-Z0-9]{9,9}[0-9]{1,1}"#).unwrap(); } ::lazy_static::lazy_static! { static ref RESTRICTED_FIN_EXACT_2_TEXT_REGEX: ::regex::Regex = ::regex::Regex::new(r#"XX|TS"#).unwrap(); } ::lazy_static::lazy_static! { static ref EXACT_4_ALPHA_NUMERIC_TEXT_REGEX: ::regex::Regex = ::regex::Regex::new(r#"[a-zA-Z0-9]{4}"#).unwrap(); } ::lazy_static::lazy_static! { static ref RESTRICTED_FINX_MAX_16_TEXT_REGEX: ::regex::Regex = ::regex::Regex::new(r#"([0-9a-zA-Z\-\?:\(\)\.,'\+ ]([0-9a-zA-Z\-\?:\(\)\.,'\+ ]*(/[0-9a-zA-Z\-\?:\(\)\.,'\+ ])?)*)"#).unwrap(); } ::lazy_static::lazy_static! { static ref RESTRICTED_FINX_MAX_30_TEXT_REGEX: ::regex::Regex = ::regex::Regex::new(r#"([0-9a-zA-Z\-\?:\(\)\.,'\+ ]([0-9a-zA-Z\-\?:\(\)\.,'\+ ]*(/[0-9a-zA-Z\-\?:\(\)\.,'\+ ])?)*)"#).unwrap(); } ::lazy_static::lazy_static! { static ref RESTRICTED_FINX_MAX_35_TEXT_REGEX: ::regex::Regex = ::regex::Regex::new(r#"[0-9a-zA-Z/\-\?:\(\)\.,'\+ ]{1,35}"#).unwrap(); } ::lazy_static::lazy_static! { static ref RESTRICTED_FINX_MAX_31_TEXT_REGEX: ::regex::Regex = ::regex::Regex::new(r#"[0-9a-zA-Z/\-\?:\(\)\.,'\+ ]{1,31}"#).unwrap(); } /// Returns the namespace of the schema pub fn namespace() -> String { "urn:iso:std:iso:20022:tech:xsd:seev.038.002.07".to_string() } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct ProprietaryQuantity9 { #[validate] #[serde(rename = "Qty")] pub qty: RestrictedFinDecimalNumber, #[validate] #[serde(rename = "QtyTp")] pub qty_tp: Exact4AlphaNumericText, #[validate] #[serde(rename = "Issr")] pub issr: Max4AlphaNumericText, #[serde(rename = "SchmeNm", skip_serializing_if = "Option::is_none")] pub schme_nm: Option, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct RestrictedFinxMax34Text { #[validate( length(min = 1, max = 34,), regex = "RESTRICTED_FINX_MAX_34_TEXT_REGEX" )] #[serde(rename = "$text")] pub value: String, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct AccountIdentification10 { #[serde(rename = "IdCd")] pub id_cd: SafekeepingAccountIdentification1Code, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] #[serde(rename = "Document")] pub struct Document< A: std::fmt::Debug + Default + Clone + PartialEq + ::serde::Serialize + ::validator::Validate, > { #[validate] #[serde(rename = "CorpActnNrrtv")] pub corp_actn_nrrtv: CorporateActionNarrative002V07, #[serde(rename = "@xmlns", default = "namespace")] pub xmlns: String, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct AnyBicDec2014Identifier { #[validate(regex = "ANY_BIC_DEC_2014_IDENTIFIER_REGEX")] #[serde(rename = "$text")] pub value: String, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct PartyIdentification136ChoiceEnum { #[serde(rename = "AnyBIC", skip_serializing_if = "Option::is_none")] pub any_bic: Option, #[serde(rename = "PrtryId", skip_serializing_if = "Option::is_none")] pub prtry_id: Option, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct PartyIdentification136Choice { #[serde(flatten)] pub value: PartyIdentification136ChoiceEnum, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct Max4AlphaNumericText { #[validate(length(min = 1, max = 4,), regex = "MAX_4_ALPHA_NUMERIC_TEXT_REGEX")] #[serde(rename = "$text")] pub value: String, } #[derive(Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize)] pub enum SafekeepingAccountIdentification1Code { #[serde(rename = "GENR")] Genr, #[default] Unknown, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct Quantity53ChoiceEnum { #[serde(rename = "PrtryQty", skip_serializing_if = "Option::is_none")] pub prtry_qty: Option, #[serde(rename = "Qty", skip_serializing_if = "Option::is_none")] pub qty: Option, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct Quantity53Choice { #[serde(flatten)] pub value: Quantity53ChoiceEnum, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct SupplementaryData1< A: std::fmt::Debug + Default + Clone + PartialEq + ::serde::Serialize + ::validator::Validate, > { #[serde(rename = "PlcAndNm", skip_serializing_if = "Option::is_none")] pub plc_and_nm: Option, #[validate] #[serde(rename = "Envlp")] pub envlp: SupplementaryDataEnvelope1, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct RestrictedFinzMax8000Text { #[validate( length(min = 1, max = 8000,), regex = "RESTRICTED_FINZ_MAX_8000_TEXT_REGEX" )] #[serde(rename = "$text")] pub value: String, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct GenericIdentification47 { #[validate] #[serde(rename = "Id")] pub id: Exact4AlphaNumericText, #[validate] #[serde(rename = "Issr")] pub issr: Max4AlphaNumericText, #[serde(rename = "SchmeNm", skip_serializing_if = "Option::is_none")] pub schme_nm: Option, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct SupplementaryDataEnvelope1< A: std::fmt::Debug + Default + Clone + PartialEq + ::serde::Serialize + ::validator::Validate, > { #[validate] #[serde(flatten)] pub value: A, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct UpdatedAdditionalInformation10 { #[serde(rename = "UpdDesc", skip_serializing_if = "Option::is_none")] pub upd_desc: Option, #[serde(rename = "UpdDt", skip_serializing_if = "Option::is_none")] pub upd_dt: Option, #[validate(length(min = 1,))] #[serde(rename = "AddtlInf", default)] pub addtl_inf: Vec, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct Max350Text { #[validate(length(min = 1, max = 350,))] #[serde(rename = "$text")] pub value: String, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct RestrictedFinxMax140Text { #[validate( length(min = 1, max = 140,), regex = "RESTRICTED_FINX_MAX_140_TEXT_REGEX" )] #[serde(rename = "$text")] pub value: String, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct CorporateActionNarrative4ChoiceEnum { #[serde(rename = "Cd", skip_serializing_if = "Option::is_none")] pub cd: Option, #[serde(rename = "Prtry", skip_serializing_if = "Option::is_none")] pub prtry: Option, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct CorporateActionNarrative4Choice { #[serde(flatten)] pub value: CorporateActionNarrative4ChoiceEnum, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct CountryCode { #[validate(regex = "COUNTRY_CODE_REGEX")] #[serde(rename = "$text")] pub value: String, } #[derive(Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize)] pub enum SafekeepingPlace1Code { #[serde(rename = "CUST")] Cust, #[serde(rename = "ICSD")] Icsd, #[serde(rename = "NCSD")] Ncsd, #[serde(rename = "SHHE")] Shhe, #[default] Unknown, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct SafekeepingPlaceTypeAndIdentification1 { #[serde(rename = "SfkpgPlcTp")] pub sfkpg_plc_tp: SafekeepingPlace1Code, #[validate] #[serde(rename = "Id")] pub id: AnyBicDec2014Identifier, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct GenericIdentification85 { #[validate] #[serde(rename = "Tp")] pub tp: GenericIdentification47, #[serde(rename = "Id", skip_serializing_if = "Option::is_none")] pub id: Option, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct FinancialInstrumentQuantity36ChoiceEnum { #[serde(rename = "FaceAmt", skip_serializing_if = "Option::is_none")] pub face_amt: Option, #[serde(rename = "AmtsdVal", skip_serializing_if = "Option::is_none")] pub amtsd_val: Option, #[serde(rename = "Unit", skip_serializing_if = "Option::is_none")] pub unit: Option, #[serde(rename = "DgtlTknUnit", skip_serializing_if = "Option::is_none")] pub dgtl_tkn_unit: Option, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct FinancialInstrumentQuantity36Choice { #[serde(flatten)] pub value: FinancialInstrumentQuantity36ChoiceEnum, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct IdentificationSource4ChoiceEnum { #[serde(rename = "Cd", skip_serializing_if = "Option::is_none")] pub cd: Option, #[serde(rename = "Prtry", skip_serializing_if = "Option::is_none")] pub prtry: Option, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct IdentificationSource4Choice { #[serde(flatten)] pub value: IdentificationSource4ChoiceEnum, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct AccountIdentification53ChoiceEnum { #[serde(rename = "ForAllAccts", skip_serializing_if = "Option::is_none")] pub for_all_accts: Option, #[serde( rename = "AcctsListAndBalDtls", skip_serializing_if = "Option::is_none" )] pub accts_list_and_bal_dtls: Option, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct AccountIdentification53Choice { #[serde(flatten)] pub value: AccountIdentification53ChoiceEnum, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct IsoDate { #[serde(rename = "$text")] pub value: ::chrono::NaiveDate, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct GenericIdentification84 { #[validate] #[serde(rename = "Id")] pub id: RestrictedFinxMax34Text, #[validate] #[serde(rename = "Issr")] pub issr: Max4AlphaNumericText, #[serde(rename = "SchmeNm", skip_serializing_if = "Option::is_none")] pub schme_nm: Option, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct IsinOct2015Identifier { #[validate(regex = "ISIN_OCT_2015_IDENTIFIER_REGEX")] #[serde(rename = "$text")] pub value: String, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct Max30DecimalNumber { #[serde(rename = "$text")] pub value: f64, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct OtherIdentification2 { #[validate] #[serde(rename = "Id")] pub id: RestrictedFinxMax31Text, #[serde(rename = "Sfx", skip_serializing_if = "Option::is_none")] pub sfx: Option, #[serde(rename = "Tp")] pub tp: IdentificationSource4Choice, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct Max16Text { #[validate(length(min = 1, max = 16,))] #[serde(rename = "$text")] pub value: String, } #[derive(Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize)] pub enum SafekeepingPlace2Code { #[serde(rename = "SHHE")] Shhe, #[serde(rename = "ALLP")] Allp, #[default] Unknown, } #[derive(Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize)] pub enum CorporateActionNarrative1Code { #[serde(rename = "TAXE")] Taxe, #[serde(rename = "REGI")] Regi, #[serde(rename = "WTRC")] Wtrc, #[serde(rename = "RFMC")] Rfmc, #[serde(rename = "PAUT")] Paut, #[serde(rename = "CTIN")] Ctin, #[default] Unknown, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct BalanceFormat14ChoiceEnum { #[serde(rename = "NotElgblBal", skip_serializing_if = "Option::is_none")] pub not_elgbl_bal: Option, #[serde(rename = "ElgblBal", skip_serializing_if = "Option::is_none")] pub elgbl_bal: Option, #[serde(rename = "Bal", skip_serializing_if = "Option::is_none")] pub bal: Option, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct BalanceFormat14Choice { #[serde(flatten)] pub value: BalanceFormat14ChoiceEnum, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct RestrictedFinExact2Text { #[validate(regex = "RESTRICTED_FIN_EXACT_2_TEXT_REGEX")] #[serde(rename = "$text")] pub value: String, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct ExternalFinancialInstrumentIdentificationType1Code { #[validate(length(min = 1, max = 4,))] #[serde(rename = "$text")] pub value: String, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct CorporateActionGeneralInformation102 { #[validate] #[serde(rename = "CorpActnEvtId")] pub corp_actn_evt_id: RestrictedFinxMax16Text, #[serde(rename = "OffclCorpActnEvtId", skip_serializing_if = "Option::is_none")] pub offcl_corp_actn_evt_id: Option, #[serde(rename = "NrrtvTp", skip_serializing_if = "Option::is_none")] pub nrrtv_tp: Option, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct Exact4AlphaNumericText { #[validate(regex = "EXACT_4_ALPHA_NUMERIC_TEXT_REGEX")] #[serde(rename = "$text")] pub value: String, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct RestrictedFinxMax16Text { #[validate( length(min = 1, max = 16,), regex = "RESTRICTED_FINX_MAX_16_TEXT_REGEX" )] #[serde(rename = "$text")] pub value: String, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct RestrictedFinxMax30Text { #[validate( length(min = 1, max = 30,), regex = "RESTRICTED_FINX_MAX_30_TEXT_REGEX" )] #[serde(rename = "$text")] pub value: String, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct RestrictedFinDecimalNumber { #[serde(rename = "$text")] pub value: f64, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct SafekeepingPlaceFormat32ChoiceEnum { #[serde(rename = "Id", skip_serializing_if = "Option::is_none")] pub id: Option, #[serde(rename = "TpAndId", skip_serializing_if = "Option::is_none")] pub tp_and_id: Option, #[serde(rename = "Ctry", skip_serializing_if = "Option::is_none")] pub ctry: Option, #[serde(rename = "Prtry", skip_serializing_if = "Option::is_none")] pub prtry: Option, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct SafekeepingPlaceFormat32Choice { #[serde(flatten)] pub value: SafekeepingPlaceFormat32ChoiceEnum, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct SecurityIdentification20 { #[serde(rename = "ISIN", skip_serializing_if = "Option::is_none")] pub isin: Option, #[validate(length(min = 0,))] #[serde(rename = "OthrId", default)] pub othr_id: Vec, #[serde(rename = "Desc", skip_serializing_if = "Option::is_none")] pub desc: Option, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct AccountIdentification65 { #[serde(rename = "SfkpgAcct", skip_serializing_if = "Option::is_none")] pub sfkpg_acct: Option, #[serde(rename = "BlckChainAdrOrWllt", skip_serializing_if = "Option::is_none")] pub blck_chain_adr_or_wllt: Option, #[serde(rename = "AcctOwnr", skip_serializing_if = "Option::is_none")] pub acct_ownr: Option, #[serde(rename = "SfkpgPlc", skip_serializing_if = "Option::is_none")] pub sfkpg_plc: Option, #[serde(rename = "ConfdBal")] pub confd_bal: BalanceFormat14Choice, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct SafekeepingPlaceTypeAndText9 { #[serde(rename = "SfkpgPlcTp")] pub sfkpg_plc_tp: SafekeepingPlace2Code, #[serde(rename = "Id", skip_serializing_if = "Option::is_none")] pub id: Option, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct RestrictedFinImpliedCurrencyAndAmount { #[validate(range(min = 0,))] #[serde(rename = "$text")] pub value: f64, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct RestrictedFinxMax35Text { #[validate( length(min = 1, max = 35,), regex = "RESTRICTED_FINX_MAX_35_TEXT_REGEX" )] #[serde(rename = "$text")] pub value: String, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct SignedQuantityFormat12 { #[serde(rename = "ShrtLngPos")] pub shrt_lng_pos: ShortLong1Code, #[serde(rename = "QtyChc")] pub qty_chc: Quantity53Choice, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct SignedQuantityFormat13 { #[serde(rename = "ShrtLngPos")] pub shrt_lng_pos: ShortLong1Code, #[serde(rename = "Qty")] pub qty: FinancialInstrumentQuantity36Choice, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct RestrictedFinxMax31Text { #[validate( length(min = 1, max = 31,), regex = "RESTRICTED_FINX_MAX_31_TEXT_REGEX" )] #[serde(rename = "$text")] pub value: String, } #[derive(Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize)] pub enum ShortLong1Code { #[serde(rename = "SHOR")] Shor, #[serde(rename = "LONG")] Long, #[default] Unknown, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct CorporateActionNarrative002V07< A: std::fmt::Debug + Default + Clone + PartialEq + ::serde::Serialize + ::validator::Validate, > { #[serde(rename = "AcctDtls", skip_serializing_if = "Option::is_none")] pub acct_dtls: Option, #[serde(rename = "UndrlygScty", skip_serializing_if = "Option::is_none")] pub undrlyg_scty: Option, #[validate] #[serde(rename = "CorpActnGnlInf")] pub corp_actn_gnl_inf: CorporateActionGeneralInformation102, #[validate] #[serde(rename = "AddtlInf")] pub addtl_inf: UpdatedAdditionalInformation10, #[validate(length(min = 0,))] #[serde(rename = "SplmtryData", default)] pub splmtry_data: Vec>, }