// 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 EXACT_4_ALPHA_NUMERIC_TEXT_REGEX: ::regex::Regex = ::regex::Regex::new(r#"[a-zA-Z0-9]{4}"#).unwrap(); } ::lazy_static::lazy_static! { static ref LEI_IDENTIFIER_REGEX: ::regex::Regex = ::regex::Regex::new(r#"[A-Z0-9]{18,18}[0-9]{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 COUNTRY_CODE_REGEX: ::regex::Regex = ::regex::Regex::new(r#"[A-Z]{2,2}"#).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 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(); } /// Returns the namespace of the schema pub fn namespace() -> String { "urn:iso:std:iso:20022:tech:xsd:seev.008.001.07".to_string() } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct PersonName3 { #[serde(rename = "NmPrfx", skip_serializing_if = "Option::is_none")] pub nm_prfx: Option, #[validate] #[serde(rename = "FrstNm")] pub frst_nm: Max350Text, #[validate] #[serde(rename = "Srnm")] pub srnm: Max350Text, #[serde(rename = "Adr", skip_serializing_if = "Option::is_none")] pub adr: Option, } #[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, ::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 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 PostalAddress1 { #[serde(rename = "AdrTp", skip_serializing_if = "Option::is_none")] pub adr_tp: Option, #[validate(length(min = 0, max = 5,))] #[serde(rename = "AdrLine", default)] pub adr_line: Vec, #[serde(rename = "StrtNm", skip_serializing_if = "Option::is_none")] pub strt_nm: Option, #[serde(rename = "BldgNb", skip_serializing_if = "Option::is_none")] pub bldg_nb: Option, #[serde(rename = "PstCd", skip_serializing_if = "Option::is_none")] pub pst_cd: Option, #[serde(rename = "TwnNm", skip_serializing_if = "Option::is_none")] pub twn_nm: Option, #[serde(rename = "CtrySubDvsn", skip_serializing_if = "Option::is_none")] pub ctry_sub_dvsn: Option, #[serde(rename = "Ctry")] pub ctry: CountryCode, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct Max50Text { #[validate(length(min = 1, max = 50,))] #[serde(rename = "$text")] pub value: String, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct PartyIdentification240 { #[validate] #[serde(rename = "NmAndAdr")] pub nm_and_adr: PersonName3, #[serde(rename = "EmailAdr", skip_serializing_if = "Option::is_none")] pub email_adr: Option, #[serde(rename = "Id", skip_serializing_if = "Option::is_none")] pub id: Option, #[serde(rename = "Ntlty", skip_serializing_if = "Option::is_none")] pub ntlty: Option, #[serde(rename = "DtAndPlcOfBirth", skip_serializing_if = "Option::is_none")] pub dt_and_plc_of_birth: Option, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct MeetingResultDisseminationV07< A: std::fmt::Debug + Default + Clone + PartialEq + ::serde::Serialize + ::validator::Validate, > { #[serde(rename = "MtgRsltsDssmntnTp")] pub mtg_rslts_dssmntn_tp: NotificationType2Code, #[serde( rename = "PrvsMtgRsltsDssmntnId", skip_serializing_if = "Option::is_none" )] pub prvs_mtg_rslts_dssmntn_id: Option, #[validate] #[serde(rename = "MtgRef")] pub mtg_ref: MeetingReference10, #[validate(length(min = 1, max = 200,))] #[serde(rename = "Scty", default)] pub scty: Vec, #[validate(length(min = 1, max = 1000,))] #[serde(rename = "VoteRslt", default)] pub vote_rslt: Vec, #[serde(rename = "Prtcptn", skip_serializing_if = "Option::is_none")] pub prtcptn: Option, #[serde(rename = "AddtlInf", skip_serializing_if = "Option::is_none")] pub addtl_inf: Option, #[validate(length(min = 0,))] #[serde(rename = "SplmtryData", default)] pub splmtry_data: Vec>, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct Number { #[serde(rename = "$text")] pub value: f64, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct PostalAddress26 { #[serde(rename = "AdrTp", skip_serializing_if = "Option::is_none")] pub adr_tp: Option, #[validate(length(min = 0, max = 5,))] #[serde(rename = "AdrLine", default)] pub adr_line: Vec, #[serde(rename = "StrtNm", skip_serializing_if = "Option::is_none")] pub strt_nm: Option, #[serde(rename = "BldgNb", skip_serializing_if = "Option::is_none")] pub bldg_nb: Option, #[serde(rename = "PstBx", skip_serializing_if = "Option::is_none")] pub pst_bx: Option, #[serde(rename = "PstCd", skip_serializing_if = "Option::is_none")] pub pst_cd: Option, #[serde(rename = "TwnNm", skip_serializing_if = "Option::is_none")] pub twn_nm: Option, #[serde(rename = "CtrySubDvsn", skip_serializing_if = "Option::is_none")] pub ctry_sub_dvsn: Option, #[serde(rename = "Ctry")] pub ctry: CountryCode, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct IdentificationType45ChoiceEnum { #[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 IdentificationType45Choice { #[serde(flatten)] pub value: IdentificationType45ChoiceEnum, } #[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 LeiIdentifier { #[validate(regex = "LEI_IDENTIFIER_REGEX")] #[serde(rename = "$text")] pub value: String, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct MeetingTypeClassification2ChoiceEnum { #[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 MeetingTypeClassification2Choice { #[serde(flatten)] pub value: MeetingTypeClassification2ChoiceEnum, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct MeetingReference10 { #[validate] #[serde(rename = "MtgId")] pub mtg_id: Max35Text, #[serde(rename = "IssrMtgId", skip_serializing_if = "Option::is_none")] pub issr_mtg_id: Option, #[validate] #[serde(rename = "MtgDtAndTm")] pub mtg_dt_and_tm: IsoDateTime, #[serde(rename = "Tp")] pub tp: MeetingType4Code, #[serde(rename = "Clssfctn", skip_serializing_if = "Option::is_none")] pub clssfctn: Option, #[validate(length(min = 0, max = 5,))] #[serde(rename = "Lctn", default)] pub lctn: Vec, #[serde(rename = "Issr", skip_serializing_if = "Option::is_none")] pub issr: Option, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct PartyIdentification221 { #[validate] #[serde(rename = "NmAndAdr")] pub nm_and_adr: PersonName2, #[serde(rename = "EmailAdr", skip_serializing_if = "Option::is_none")] pub email_adr: Option, #[serde(rename = "Id")] pub id: PartyIdentification198Choice, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct PartyIdentification231ChoiceEnum { #[serde(rename = "NtrlPrsn", skip_serializing_if = "Option::is_none")] pub ntrl_prsn: Option, #[serde(rename = "LglPrsn", skip_serializing_if = "Option::is_none")] pub lgl_prsn: Option, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct PartyIdentification231Choice { #[serde(flatten)] pub value: PartyIdentification231ChoiceEnum, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct Max70Text { #[validate(length(min = 1, max = 70,))] #[serde(rename = "$text")] pub value: String, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct DateAndPlaceOfBirth2 { #[validate] #[serde(rename = "BirthDt")] pub birth_dt: IsoDate, #[serde(rename = "PrvcOfBirth", skip_serializing_if = "Option::is_none")] pub prvc_of_birth: Option, #[serde(rename = "CityOfBirth", skip_serializing_if = "Option::is_none")] pub city_of_birth: Option, #[serde(rename = "CtryOfBirth", skip_serializing_if = "Option::is_none")] pub ctry_of_birth: Option, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct PartyIdentification238 { #[validate] #[serde(rename = "NmAndAdr")] pub nm_and_adr: PersonName3, #[serde(rename = "EmailAdr", skip_serializing_if = "Option::is_none")] pub email_adr: Option, #[validate] #[serde(rename = "Id")] pub id: NaturalPersonIdentification1, #[serde(rename = "Ntlty", skip_serializing_if = "Option::is_none")] pub ntlty: Option, #[serde(rename = "DtAndPlcOfBirth", skip_serializing_if = "Option::is_none")] pub dt_and_plc_of_birth: 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 GenericIdentification78 { #[validate] #[serde(rename = "Tp")] pub tp: GenericIdentification30, #[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 NameAndAddress5 { #[validate] #[serde(rename = "Nm")] pub nm: Max350Text, #[serde(rename = "Adr", skip_serializing_if = "Option::is_none")] pub adr: Option, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct PercentageRate { #[serde(rename = "$text")] pub value: f64, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct IsoDateTime { #[serde(rename = "$text")] pub value: ::chrono::DateTime<::chrono::Utc>, } #[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)] pub enum SecuritiesEntryType2Code { #[serde(rename = "BLOK")] Blok, #[serde(rename = "ELIG")] Elig, #[serde(rename = "PEND")] Pend, #[serde(rename = "PENR")] Penr, #[serde(rename = "NOMI")] Nomi, #[serde(rename = "SETD")] Setd, #[serde(rename = "BORR")] Borr, #[serde(rename = "LOAN")] Loan, #[serde(rename = "SPOS")] Spos, #[serde(rename = "TRAD")] Trad, #[serde(rename = "COLI")] Coli, #[serde(rename = "COLO")] Colo, #[serde(rename = "UNBA")] Unba, #[serde(rename = "INBA")] Inba, #[serde(rename = "REGO")] Rego, #[default] Unknown, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct GenericIdentification36 { #[validate] #[serde(rename = "Id")] pub id: Max35Text, #[validate] #[serde(rename = "Issr")] pub issr: Max35Text, #[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 SafekeepingPlaceTypeAndText6 { #[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 IsoDate { #[serde(rename = "$text")] pub value: ::chrono::NaiveDate, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct PartyIdentification224 { #[validate] #[serde(rename = "NmAndAdr")] pub nm_and_adr: PersonName2, #[serde(rename = "EmailAdr", skip_serializing_if = "Option::is_none")] pub email_adr: Option, #[serde(rename = "Id", skip_serializing_if = "Option::is_none")] pub id: Option, } #[derive(Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize)] pub enum ResolutionStatus2Code { #[serde(rename = "ACPT")] Acpt, #[serde(rename = "REJT")] Rejt, #[serde(rename = "WDRA")] Wdra, #[default] Unknown, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct PartyIdentification233ChoiceEnum { #[serde(rename = "NtrlPrsn", skip_serializing_if = "Option::is_none")] pub ntrl_prsn: Option, #[serde(rename = "LglPrsn", skip_serializing_if = "Option::is_none")] pub lgl_prsn: Option, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct PartyIdentification233Choice { #[serde(flatten)] pub value: PartyIdentification233ChoiceEnum, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct GenericIdentification30 { #[validate] #[serde(rename = "Id")] pub id: Exact4AlphaNumericText, #[validate] #[serde(rename = "Issr")] pub issr: Max35Text, #[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, )] #[serde(rename = "Document")] pub struct Document< A: std::fmt::Debug + Default + Clone + PartialEq + ::serde::Serialize + ::validator::Validate, > { #[validate] #[serde(rename = "MtgRsltDssmntn")] pub mtg_rslt_dssmntn: MeetingResultDisseminationV07, #[serde(rename = "@xmlns", default = "namespace")] pub xmlns: String, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct SecurityPosition12 { #[validate] #[serde(rename = "FinInstrmId")] pub fin_instrm_id: SecurityIdentification19, #[validate(length(min = 0, max = 1000,))] #[serde(rename = "Pos", default)] pub pos: Vec, } #[derive(Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize)] pub enum TypeOfIdentification4Code { #[serde(rename = "ARNU")] Arnu, #[serde(rename = "CUST")] Cust, #[serde(rename = "CORP")] Corp, #[serde(rename = "DRLC")] Drlc, #[serde(rename = "IDCD")] Idcd, #[serde(rename = "NRIN")] Nrin, #[serde(rename = "CCPT")] Ccpt, #[serde(rename = "SOCS")] Socs, #[serde(rename = "TXID")] Txid, #[default] Unknown, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct ProprietaryVote2 { #[validate] #[serde(rename = "Cd")] pub cd: GenericIdentification30, #[serde(rename = "Qty")] pub qty: FinancialInstrumentQuantity18Choice, } #[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 CountryCode { #[validate(regex = "COUNTRY_CODE_REGEX")] #[serde(rename = "$text")] pub value: String, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct FinancialInstrumentQuantity18ChoiceEnum { #[serde(rename = "Unit", skip_serializing_if = "Option::is_none")] pub unit: Option, #[serde(rename = "FaceAmt", skip_serializing_if = "Option::is_none")] pub face_amt: Option, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct FinancialInstrumentQuantity18Choice { #[serde(flatten)] pub value: FinancialInstrumentQuantity18ChoiceEnum, } #[derive(Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize)] pub enum MeetingTypeClassification2Code { #[serde(rename = "AMET")] Amet, #[serde(rename = "CLAS")] Clas, #[serde(rename = "ISSU")] Issu, #[serde(rename = "OMET")] Omet, #[serde(rename = "VRHI")] Vrhi, #[default] Unknown, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct EligiblePosition9 { #[validate] #[serde(rename = "AcctId")] pub acct_id: Max35Text, #[serde(rename = "AcctOwnr", skip_serializing_if = "Option::is_none")] pub acct_ownr: Option, #[validate(length(min = 0, max = 15,))] #[serde(rename = "HldgBal", default)] pub hldg_bal: Vec, #[validate(length(min = 0, max = 250,))] #[serde(rename = "RghtsHldr", default)] pub rghts_hldr: Vec, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct Participation5 { #[serde(rename = "TtlNbOfVtngRghts", skip_serializing_if = "Option::is_none")] pub ttl_nb_of_vtng_rghts: Option, #[serde(rename = "PctgOfVtngRghts", skip_serializing_if = "Option::is_none")] pub pctg_of_vtng_rghts: Option, #[serde( rename = "TtlNbOfSctiesOutsdng", skip_serializing_if = "Option::is_none" )] pub ttl_nb_of_scties_outsdng: Option, #[serde(rename = "ClctnDt", skip_serializing_if = "Option::is_none")] pub clctn_dt: Option, } #[derive(Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize)] pub enum NamePrefix2Code { #[serde(rename = "DOCT")] Doct, #[serde(rename = "MADM")] Madm, #[serde(rename = "MISS")] Miss, #[serde(rename = "MIST")] Mist, #[serde(rename = "MIKS")] Miks, #[default] Unknown, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct PartyIdentification129ChoiceEnum { #[serde(rename = "LEI", skip_serializing_if = "Option::is_none")] pub lei: Option, #[serde(rename = "PrtryId", skip_serializing_if = "Option::is_none")] pub prtry_id: Option, #[serde(rename = "AnyBIC", skip_serializing_if = "Option::is_none")] pub any_bic: Option, #[serde(rename = "NmAndAdr", skip_serializing_if = "Option::is_none")] pub nm_and_adr: Option, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct PartyIdentification129Choice { #[serde(flatten)] pub value: PartyIdentification129ChoiceEnum, } #[derive(Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize)] pub enum AddressType2Code { #[serde(rename = "ADDR")] Addr, #[serde(rename = "PBOX")] Pbox, #[serde(rename = "HOME")] Home, #[serde(rename = "BIZZ")] Bizz, #[serde(rename = "MLTO")] Mlto, #[serde(rename = "DLVY")] Dlvy, #[default] Unknown, } #[derive(Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize)] pub enum NotificationType2Code { #[serde(rename = "NEWM")] Newm, #[serde(rename = "REPL")] Repl, #[default] Unknown, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct SecurityIdentification19 { #[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 Max140Text { #[validate(length(min = 1, max = 140,))] #[serde(rename = "$text")] pub value: String, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct CommunicationAddress11 { #[serde(rename = "EmailAdr", skip_serializing_if = "Option::is_none")] pub email_adr: Option, #[serde(rename = "URLAdr", skip_serializing_if = "Option::is_none")] pub url_adr: Option, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct OtherIdentification1 { #[validate] #[serde(rename = "Id")] pub id: Max35Text, #[serde(rename = "Sfx", skip_serializing_if = "Option::is_none")] pub sfx: Option, #[serde(rename = "Tp")] pub tp: IdentificationSource3Choice, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct PersonName2 { #[validate] #[serde(rename = "Nm")] pub nm: Max350Text, #[serde(rename = "Adr", skip_serializing_if = "Option::is_none")] pub adr: Option, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct IdentificationSource3ChoiceEnum { #[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 IdentificationSource3Choice { #[serde(flatten)] pub value: IdentificationSource3ChoiceEnum, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct ImpliedCurrencyAndAmount { #[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 Max2048Text { #[validate(length(min = 1, max = 2048,))] #[serde(rename = "$text")] pub value: String, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct Max256Text { #[validate(length(min = 1, max = 256,))] #[serde(rename = "$text")] pub value: String, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct Vote16 { #[validate] #[serde(rename = "IssrLabl")] pub issr_labl: Max35Text, #[serde(rename = "RsltnSts")] pub rsltn_sts: ResolutionStatus2Code, #[serde(rename = "For", skip_serializing_if = "Option::is_none")] pub r#for: Option, #[serde(rename = "Agnst", skip_serializing_if = "Option::is_none")] pub agnst: Option, #[serde(rename = "Abstn", skip_serializing_if = "Option::is_none")] pub abstn: Option, #[serde(rename = "Wthhld", skip_serializing_if = "Option::is_none")] pub wthhld: Option, #[serde(rename = "WthMgmt", skip_serializing_if = "Option::is_none")] pub wth_mgmt: Option, #[serde(rename = "AgnstMgmt", skip_serializing_if = "Option::is_none")] pub agnst_mgmt: Option, #[serde(rename = "Dscrtnry", skip_serializing_if = "Option::is_none")] pub dscrtnry: Option, #[serde(rename = "OneYr", skip_serializing_if = "Option::is_none")] pub one_yr: Option, #[serde(rename = "TwoYrs", skip_serializing_if = "Option::is_none")] pub two_yrs: Option, #[serde(rename = "ThreeYrs", skip_serializing_if = "Option::is_none")] pub three_yrs: Option, #[serde(rename = "NoActn", skip_serializing_if = "Option::is_none")] pub no_actn: Option, #[serde(rename = "Blnk", skip_serializing_if = "Option::is_none")] pub blnk: Option, #[validate(length(min = 0, max = 4,))] #[serde(rename = "Prtry", default)] pub prtry: Vec, } #[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 MeetingType4Code { #[serde(rename = "XMET")] Xmet, #[serde(rename = "GMET")] Gmet, #[serde(rename = "MIXD")] Mixd, #[serde(rename = "SPCL")] Spcl, #[serde(rename = "BMET")] Bmet, #[serde(rename = "CMET")] Cmet, #[default] Unknown, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct SafekeepingPlaceFormat28ChoiceEnum { #[serde(rename = "Prtry", skip_serializing_if = "Option::is_none")] pub prtry: Option, #[serde(rename = "Ctry", skip_serializing_if = "Option::is_none")] pub ctry: Option, #[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, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct SafekeepingPlaceFormat28Choice { #[serde(flatten)] pub value: SafekeepingPlaceFormat28ChoiceEnum, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct PartyIdentification198ChoiceEnum { #[serde(rename = "ClntId", skip_serializing_if = "Option::is_none")] pub clnt_id: Option, #[serde(rename = "AnyBIC", skip_serializing_if = "Option::is_none")] pub any_bic: Option, #[serde(rename = "NtlRegnNb", skip_serializing_if = "Option::is_none")] pub ntl_regn_nb: Option, #[serde(rename = "PrtryId", skip_serializing_if = "Option::is_none")] pub prtry_id: Option, #[serde(rename = "LEI", skip_serializing_if = "Option::is_none")] pub lei: Option, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct PartyIdentification198Choice { #[serde(flatten)] pub value: PartyIdentification198ChoiceEnum, } #[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 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 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 Max35Text { #[validate(length(min = 1, max = 35,))] #[serde(rename = "$text")] pub value: String, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct DecimalNumber { #[serde(rename = "$text")] pub value: f64, } #[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 GenericIdentification13 { #[validate] #[serde(rename = "Id")] pub id: Max4AlphaNumericText, #[serde(rename = "SchmeNm", skip_serializing_if = "Option::is_none")] pub schme_nm: Option, #[validate] #[serde(rename = "Issr")] pub issr: Max35Text, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct HoldingBalance9 { #[serde(rename = "Bal")] pub bal: FinancialInstrumentQuantity18Choice, #[serde(rename = "BalTp")] pub bal_tp: SecuritiesEntryType2Code, #[serde(rename = "SfkpgPlc", skip_serializing_if = "Option::is_none")] pub sfkpg_plc: Option, #[serde(rename = "Dt", skip_serializing_if = "Option::is_none")] pub dt: Option, } #[derive( Debug, Default, Clone, PartialEq, ::serde::Serialize, ::serde::Deserialize, ::derive_builder::Builder, ::validator::Validate, )] pub struct NaturalPersonIdentification1 { #[validate] #[serde(rename = "Id")] pub id: Max35Text, #[serde(rename = "IdTp", skip_serializing_if = "Option::is_none")] pub id_tp: Option, }