DOIOLZA6KSL5QHC4Z6H4D7GCLNCDCJKJTCYZHZUJ64DPYDTXQ6GQC
pub enum UnitOfMeasure1Code {
#[doc = "Basic unit of mass in the SI system, 1000 grams."]
Kilogram,
#[doc = "Standard length of cloth, wallpaper, as an item for sale or amount of a substance."]
Piece,
#[doc = "Measure of weight, in Britain 2240lb (long ton)and in the US 2000lb (short ton)."]
Ton,
#[doc = "Unit of length in the metric system, equal to 39.37 inches."]
Metre,
#[doc = "Measure of length equal to 2.54 cm."]
Inch,
#[doc = "Unit of length equal to 3 feet or 0.9144 metre."]
Yard,
#[doc = "Unit of volume that is equal to 8 pints."]
GbGallon,
#[doc = "Unit of measure that is equal to a 1, 000th of a kilo."]
Gram,
#[doc = "Unit of measure that is equal to one hundredth of a metre."]
Centimetre,
#[doc = "Measure of a surface, one metre by one metre."]
SquareMetre,
#[doc = "Unit of length equal to 1/3 yard."]
Foot,
#[doc = "Unit of length equal to 1, 760 yards."]
Mile,
#[doc = "Measure of a surface, one inch by one inch."]
SquareInch,
#[doc = "Measure of a surface, one foot by one foot."]
SquareFoot,
#[doc = "Measure of a surface, one mile by one mile."]
SquareMile,
#[doc = "Unit of weight equal to a sixteenth of a pound."]
GbOunce,
#[doc = "Unit of weight equal to a sixteenth of a pound."]
UsOunce,
#[doc = "Unit of volume that is equal to 568 cubic centimetres."]
GbPint,
#[doc = "Unit of volume that is equal to 473 cubic centimetres."]
UsPint,
#[doc = "Unit of volume that is equal to 2 pints."]
GbQuart,
#[doc = "Unit of volume that is equal to 2 pints."]
UsQuart,
#[doc = "Unit of volume that is equal to 8 pints."]
UsGallon,
#[doc = "Unit of measure that is a thousandth of one metre."]
Millimetre,
#[doc = "Unit of measure that is equal to 1, 000 meters."]
Kilometre,
#[doc = "Measure of a surface, one yard by one yard."]
SquareYard,
#[doc = "Unit of measure equal to 4, 840 square yards."]
Acre,
#[doc = "Unit of measure equal to a 100 square meters."]
Are,
#[doc = "Measure of a surface, one millimetre by one millimetre."]
SquareMillimetre,
#[doc = "Measure of a surface, one centimetre by one centimetre."]
SquareCentimetre,
#[doc = "Unit of measure that is equal to 10, 000 square meters."]
Hectare,
#[doc = "Measure of a surface, one kilometre by one kilometre."]
SquareKilometre,
#[doc = "Unit of volume that is equal to one thousandth of a litre."]
MilliLitre,
#[doc = "Unit of volume that is equal to one hundredth of a litre."]
Centilitre,
#[doc = "Unit of volume that is equal to a thousand cubic centimetres."]
Litre,
#[doc = "Unit of weight equal to 0.454 kilograms."]
Pound,
#[doc = "Amount of money deducted from a price or an amount due."]
Allowances,
#[doc = "Number of monetary units specified in a currency, where the unit of currency is explicit and compliant with ISO 4217."]
AmountOfCurrency,
#[doc = "Unit of volume that is equal to 42 US gallons."]
Barrels,
#[doc = "Unit of measure for large volumes of natural gas equivalent to 28316846 cubic meters."]
BillionCubicFeet,
#[doc = "Measure of length equal to 144 cubic inches."]
BoardFeet,
#[doc = "Unit of weight that is equal to 8 gallons. Mostly used for agricultural products with a specification of weight defined for each commodity differently."]
Bushels,
#[doc = "Unit of emissions type (or carbon credits) issued by the Clean Development Mechanism (CDM) Executive Board for emission reductions achieved by CDM projects and verified by a DOE (Designated Operational Entity) under the rules of the Kyoto Protocol."]
CertifiedEmissionsReduction,
#[doc = "Unit of offset credits used by the Climate Action Reserve. One Climate Reserve Tonne is equal to one metric ton of Greenhouse Gas (GHG) reduced/sequestered."]
ClimateReserveTonnes,
#[doc = "Unit of volume that is equal to one meter in length, breadth and height or also equal to 1000 liters."]
CubicMeters,
#[doc = "Unit of time that is equal to 24 hours."]
Days,
#[doc = "Unit of weight that is equal to the same mass value as a metric ton excluding moisture."]
DryMetricTons,
#[doc = "Unit of measure for ownership of credit (or allowance) of carbon dioxide emission (in metric ton)."]
EnvironmentalCredit,
#[doc = "Unit of measure for reduction of carbon dioxide emission (in metric ton) that may result in Environmental Credit."]
EnvironmentalOffset,
#[doc = "Unit of weight or mass of various values in the Imperial Unit System also known as quintal, cental or centum."]
Hundredweight,
#[doc = "Unit of measure of the capacity of production of electric power equal to 1000 watt in one day."]
KilowattDayCapacity,
#[doc = "Unit of measure that is equal to the power consumption of one kilowatt during one hour."]
KilowattHours,
#[doc = "Unit of measure of the capacity of production of electric power equal to 1000 watt in one hour."]
KilowattHoursCapacity,
#[doc = "Unit of measure of the capacity of production of electric power equal to 1000 watt in one minute."]
KilowattMinuteCapacity,
#[doc = "Unit of measure of the capacity of production of electric power equal to 1000 watt in one month."]
KilowattMonthCapacity,
#[doc = "Unit of measure of the capacity of production of electric power equal to 1000 watt in one year."]
KilowattYearCapacity,
#[doc = "Unit of measure of the capacity of production of electric power equal to 1000000 watt in one day."]
MegawattDayCapacity,
#[doc = "Unit of measure that is equal to the power consumption of one megawatt during one hour."]
MegawattHours,
#[doc = "Unit of measure of the capacity of production of electric power equal to 1000000 watt in one hour."]
MegawattHoursCapacity,
#[doc = "Unit of measure of the capacity of production of electric power equal to 1000000 watt in one minute."]
MegawattMinuteCapacity,
#[doc = "Unit of measure of the capacity of production of electric power equal to 1000000 watt in one month."]
MegawattMonthCapacity,
#[doc = "Unit of measure of the capacity of production of electric power equal to 1000000 watt in one year."]
MegawattYearCapacity,
#[doc = "Unit of mass equal to 1000 kilograms; equivalent to approximately 2,204.6 pounds, 1.102 short tons (US) or 0.984 long tons (imperial)."]
MetricTons,
#[doc = "Unit of volume that is equal to 1 million barrels equivalent to 42.000.000 US gallons."]
MillionBarrels,
#[doc = "Unit of measure of heat equal to one million British thermal unit (BTU)."]
OneMillionBtu,
#[doc = "Unit of weight equal to 31.1034768 grams. Used in precious metals."]
TroyOunces,
#[doc = "Unit of weight or mass of various values in the US Customary System also known as quintal, cental or centum. Equal to 100 lbs."]
UsHundredweight,
#[doc = "Decimal number used to calculate an amount or a price."]
IndexPoint,
#[doc = "Amount of money borrowed, or part of that amount which remains unpaid (excluding interest)."]
PrincipalWithRelationToDebtInstrument,
#[doc = "Amount of fuel alternative equal to one gallon of diesel."]
DieselGallonEquivalent,
#[doc = "Amount of fuel alternative equal to one gallon of gasoline."]
GasolineGallonEquivalent,
#[doc = "Tons of carbon dioxide."]
TonsOfCarbonDioxide,
#[doc = "Financial instrument that gives the owner right to dividends paid by a company and the most junior claim on the companies assets in the event of a bankruptcy."]
Shares,
#[doc = "Unit of heat, often used a unit of measure for natural gas in the UK."]
Therms,
#[doc = "Exchange traded contract that defines an agreement to buy specific quantities of a commodity or financial instrument at an agreed time in the future."]
Future,
#[doc = "Unit of measure that is equal to the power consumption of one Gigawatt during one hour."]
GigawattHours,
#[doc = "Unit of measure of heat required to raise the temperature of one pound of water by one degree Fahrenheit."]
BritishThermalUnit,
#[doc = "Indication of the unit of measurement."]
Lot,
#[doc = "Code for a bag."]
Bag,
#[doc = "Code for a bale."]
Bale,
#[doc = "Code for a bottle."]
Bottle,
#[doc = "Code for a box."]
Box,
#[doc = "Code for a carton."]
Carton,
#[doc = "Code for a container."]
Container,
#[doc = "Code for a crate."]
Crate,
#[doc = "Measure of a volume, one inch by one inch by one inch."]
CubicInch,
#[doc = "Unit of volume that is equal to one thousandth of a litre."]
CubicMillimetre,
#[doc = "Unit of volume equal to 2, 841 306 centilitre."]
GbFuildOunce,
#[doc = "Measure of weight, in Britain 2240 lb (long ton)."]
GbTon,
#[doc = "Unit of volume equal to 158, 9873 litre."]
UsBarrel,
#[doc = "Unit of volume equal to 2, 957353 centilitre."]
UsFluidOunce,
#[doc = "Measure of weight, in the US 2000 lb (short ton)."]
UsTon,
#[doc = "Cooling degree day"]
CoolingDegreeDay,
#[doc = "Heating degree day"]
HeatingDegreeDay,
#[doc = "Critical precipitation day"]
CriticalPrecipitationDay,
}
impl<'a> UnitOfMeasure1Code {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"KILO" => Self::Kilogram,
"PIEC" => Self::Piece,
"TONS" => Self::Ton,
"METR" => Self::Metre,
"INCH" => Self::Inch,
"YARD" => Self::Yard,
"GBGA" => Self::GbGallon,
"GRAM" => Self::Gram,
"CMET" => Self::Centimetre,
"SMET" => Self::SquareMetre,
"FOOT" => Self::Foot,
"MILE" => Self::Mile,
"SQIN" => Self::SquareInch,
"SQFO" => Self::SquareFoot,
"SQMI" => Self::SquareMile,
"GBOU" => Self::GbOunce,
"USOU" => Self::UsOunce,
"GBPI" => Self::GbPint,
"USPI" => Self::UsPint,
"GBQA" => Self::GbQuart,
"USQA" => Self::UsQuart,
"USGA" => Self::UsGallon,
"MMET" => Self::Millimetre,
"KMET" => Self::Kilometre,
"SQYA" => Self::SquareYard,
"ACRE" => Self::Acre,
"ARES" => Self::Are,
"SMIL" => Self::SquareMillimetre,
"SCMT" => Self::SquareCentimetre,
"HECT" => Self::Hectare,
"SQKI" => Self::SquareKilometre,
"MILI" => Self::MilliLitre,
"CELI" => Self::Centilitre,
"LITR" => Self::Litre,
"PUND" => Self::Pound,
"ALOW" => Self::Allowances,
"ACCY" => Self::AmountOfCurrency,
"BARL" => Self::Barrels,
"BCUF" => Self::BillionCubicFeet,
"BDFT" => Self::BoardFeet,
"BUSL" => Self::Bushels,
"CEER" => Self::CertifiedEmissionsReduction,
"CLRT" => Self::ClimateReserveTonnes,
"CBME" => Self::CubicMeters,
"DAYS" => Self::Days,
"DMET" => Self::DryMetricTons,
"ENVC" => Self::EnvironmentalCredit,
"ENVO" => Self::EnvironmentalOffset,
"HUWG" => Self::Hundredweight,
"KWDC" => Self::KilowattDayCapacity,
"KWHO" => Self::KilowattHours,
"KWHC" => Self::KilowattHoursCapacity,
"KMOC" => Self::KilowattMinuteCapacity,
"KWMC" => Self::KilowattMonthCapacity,
"KWYC" => Self::KilowattYearCapacity,
"MWDC" => Self::MegawattDayCapacity,
"MWHO" => Self::MegawattHours,
"MWHC" => Self::MegawattHoursCapacity,
"MWMC" => Self::MegawattMinuteCapacity,
"MMOC" => Self::MegawattMonthCapacity,
"MWYC" => Self::MegawattYearCapacity,
"TONE" => Self::MetricTons,
"MIBA" => Self::MillionBarrels,
"MBTU" => Self::OneMillionBtu,
"OZTR" => Self::TroyOunces,
"UCWT" => Self::UsHundredweight,
"IPNT" => Self::IndexPoint,
"PWRD" => Self::PrincipalWithRelationToDebtInstrument,
"DGEU" => Self::DieselGallonEquivalent,
"GGEU" => Self::GasolineGallonEquivalent,
"TOCD" => Self::TonsOfCarbonDioxide,
"SHAS" => Self::Shares,
"THMS" => Self::Therms,
"FUTU" => Self::Future,
"GWHO" => Self::GigawattHours,
"BRTU" => Self::BritishThermalUnit,
"LOTS" => Self::Lot,
"BAGG" => Self::Bag,
"BALE" => Self::Bale,
"BOTL" => Self::Bottle,
"BOXX" => Self::Box,
"CRTN" => Self::Carton,
"CNTR" => Self::Container,
"CRAT" => Self::Crate,
"CBIN" => Self::CubicInch,
"CBML" => Self::CubicMillimetre,
"GBFO" => Self::GbFuildOunce,
"GBTN" => Self::GbTon,
"USBA" => Self::UsBarrel,
"USFO" => Self::UsFluidOunce,
"USTN" => Self::UsTon,
"CDDA" => Self::CoolingDegreeDay,
"HDDA" => Self::HeatingDegreeDay,
"CPDA" => Self::CriticalPrecipitationDay,
tag => todo!("handle code {tag:?}"),
};
Ok(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Identifies the unit of measure by means of a code."]
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Specifies the external representment reason code in the format of character string with a maximum length of 4 characters. The list of valid codes is an external code list published separately.\n*`AMCR`-Amount corrected due to proof of transaction\n*`CLSD`-Liability Shift to acquirer due to missing card authentication method denied\n*`CRPI`-Credit previously issued\n*`OTVA`-Original transaction was valid\n*`VLSD`-Liability Shift to acquirer due to missing cardholder verification method denied"]
pub enum ExternalRePresentmentReason1Code {
Amcr,
Clsd,
Crpi,
Otva,
Vlsd,
}
impl<'a> ExternalRePresentmentReason1Code {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"AMCR" => Self::Amcr,
"CLSD" => Self::Clsd,
"CRPI" => Self::Crpi,
"OTVA" => Self::Otva,
"VLSD" => Self::Vlsd,
tag => todo!("handle code {tag:?}"),
};
Ok(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Specifies the external representment reason code in the format of character string with a maximum length of 4 characters. The list of valid codes is an external code list published separately."]
pub enum ExternalRePresentmentReasonCode {
#[doc = "Amount corrected due to proof of transaction"]
AmountCorrected,
#[doc = "Liability Shift to acquirer due to missing card authentication method denied"]
CardAuthenticationLiabilityShiftDenied,
#[doc = "Credit previously issued"]
CreditPreviouslyIssued,
#[doc = "Original transaction was valid"]
OriginalTransactionValid,
#[doc = "Liability Shift to acquirer due to missing cardholder verification method denied"]
VerificationLiabilityShiftDenied,
}
impl<'a> ExternalRePresentmentReasonCode {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"AMCR" => Self::AmountCorrected,
"CLSD" => Self::CardAuthenticationLiabilityShiftDenied,
"CRPI" => Self::CreditPreviouslyIssued,
"OTVA" => Self::OriginalTransactionValid,
"VLSD" => Self::VerificationLiabilityShiftDenied,
tag => todo!("handle code {tag:?}"),
};
Ok(value)
pub enum AuthenticationEntity1Code {
#[doc = "Application in the chip card (Integrated Circuit Card), for instance an offline PIN verification."]
Icc,
#[doc = "Authorisation agent of the issuer."]
AuthorisedAgent,
#[doc = "Merchant (for example signature verification by the attendant)."]
Merchant,
#[doc = "Acquirer of the transaction."]
Acquirer,
#[doc = "Card issuer."]
Issuer,
#[doc = "Secure application in the terminal."]
Terminal,
}
impl<'a> AuthenticationEntity1Code {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"ICCD" => Self::Icc,
"AGNT" => Self::AuthorisedAgent,
"MERC" => Self::Merchant,
"ACQR" => Self::Acquirer,
"ISSR" => Self::Issuer,
"TRML" => Self::Terminal,
tag => todo!("handle code {tag:?}"),
};
Ok(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Entity or object in charge of verifying the cardholder authenticity."]
tag => todo!("handle code {tag:?}"),
};
Ok(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Method used to authenticate a cardholder."]
pub enum AuthenticationMethod1Code {
#[doc = "Authentication method is performed unknown."]
UnknownMethod,
#[doc = "Authentication bypassed by the merchant."]
Bypass,
#[doc = "On-line PIN authentication (Personal Identification Number)."]
OnLinePin,
#[doc = "Off-line PIN authentication (Personal Identification Number)."]
OfflinePin,
#[doc = "Electronic signature capture (handwritten signature)."]
SignatureCapture,
#[doc = "Handwritten paper signature."]
PaperSignature,
#[doc = "Manual verification, for example passport or drivers license."]
ManualVerification,
#[doc = "Merchant-related authentication."]
MerchantAuthentication,
#[doc = "Electronic commerce transaction secured with the X.509 certificate of a customer."]
SecureCertificate,
#[doc = "Secure electronic transaction without cardholder certificate."]
SecureNoCertificate,
#[doc = "Channel-encrypted transaction."]
SecuredChannel,
#[doc = "Authentication by a password."]
Password,
#[doc = "Cardholder billing address verification."]
BillingAddressVerification,
#[doc = "Biometric authentication of the cardholder."]
Biometry,
#[doc = "Cardholder data provided for verification, for instance social security number, driver license number, passport number."]
CardholderIdentificationData,
#[doc = "Verification of a cryptogram generated by a chip card or another device, for instance ARQC (Authorisation Request Cryptogram)."]
CryptogramVerification,
#[doc = "Verification of Card Security Code."]
CscVerification,
#[doc = "Authentication based on statistical cardholder behaviour."]
PassiveAuthentication,
#[doc = "Authentication performed during a secure electronic commerce transaction."]
SecureElectronicCommerce,
#[doc = "Cardholder shipping address verification."]
ShippingAddressVerification,
#[doc = "Cryptogram generated by the token requestor or a customer device to validate the authorised use of a token."]
TokenAuthentication,
#[doc = "Verification or authentication related to the use of a payment token, for instance the validation of the authorised use of a token."]
PaymentToken,
#[doc = "A token is used to verify an already performed authentication."]
AuthenticationToken,
#[doc = "Customer mobile device."]
Mobile,
#[doc = "Other customer authentication."]
Other,
#[doc = "Digits of the address."]
AddressDigits,
#[doc = "Number assigned by a government agency to identify foreign nationals."]
AlienRegistrationNumber,
#[doc = "Verification of a cryptogram generated by a chip card, for instance an ARQC (Authorisation Request Cryptogram)."]
ArqcVerification,
#[doc = "Date of birth of a person."]
BirthDate,
#[doc = "Name of cardholder"]
CardholderName,
#[doc = "City of birth to authenticate a person."]
CityOfBirth,
#[doc = "Customer number used as a mechanism of authentication."]
CustomerIdentification,
#[doc = "Identification of a driver in a fleet of vehicles."]
DriverIdentification,
#[doc = "Number assigned by a driving license authority to a person driving a car."]
DriverLicenseNumber,
#[doc = "Electronic mail address"]
Email,
#[doc = "Number assigned to an employee by an employer."]
EmployeeIdentificationNumber,
#[doc = "Number assigned to an employer by a registration authority."]
EmployerIdentificationNumber,
#[doc = "Number assigned by a national authority to an identity card."]
IdentityCardNumber,
#[doc = "Verification of a one-time password provided by the issuer."]
OneTimePassword,
#[doc = "Other cardholder data provided for identification."]
OtherCardholderIdentification,
#[doc = "Verification of a cryptogram generated by a non-card form factor."]
OtherCryptogram,
#[doc = "Number assigned by a passport authority to a passport."]
PassportNumber,
#[doc = "Verification based on digits of the postal code."]
PostalCode,
#[doc = "Shipping address from verification."]
ShippingAddressFrom,
#[doc = "Shipping address to verification"]
ShippingAddressTo,
#[doc = "Verification whether the address corresponds to the cardholder's one."]
CardholderAddress,
#[doc = "Non visible Card Security Code."]
NonVisibleCsc,
#[doc = "Other type of verification defined at national level."]
OtherNational,
#[doc = "Other type of verification defined at private level"]
OtherPrivate,
#[doc = "Place of birth of a person."]
PlaceOfBirth,
#[doc = "Number assigned by a social security agency."]
SocialSecurityNumber,
#[doc = "Number assigned by a tax authority to an entity."]
TaxIdentificationNumber,
#[doc = "Account-based digital signature authentication."]
AccountDigitalSignature,
#[doc = "Response Card Cryptogram (ARPC) verification."]
ArpcVerification,
#[doc = "Application Transaction Counter"]
Atc,
#[doc = "Biographics authentication in an offline mode."]
OffLineBiographics,
#[doc = "Biometrics authentication in an offline mode"]
OffLineBiometrics,
#[doc = "Authentication of data in an offline mode"]
OffLineDataAuthentication,
#[doc = "Analysis of signature transmitted offline"]
OffLineDigitisedSignatureAnalysis,
#[doc = "PIN generated offline and transmitted encrypted"]
OffLinePinEncrypted,
#[doc = "PIN generated offline and transmitted in clear"]
OffLinePinInClear,
#[doc = "Biographics authentication in an online mode."]
OnLineBiographics,
#[doc = "Customer home phone number."]
PhoneHome,
#[doc = "Customer work phone number"]
PhoneWork,
#[doc = "PKI (Public Key Infrastructure) based digital signature"]
PkiSignature,
#[doc = "QualifiedCertificate"]
QualifiedCertificate,
#[doc = "Authentication performed during a secure electronic commerce transaction."]
ThreeDs,
}
impl<'a> AuthenticationMethod1Code {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"UKNW" => Self::UnknownMethod,
"BYPS" => Self::Bypass,
"NPIN" => Self::OnLinePin,
"FPIN" => Self::OfflinePin,
"CPSG" => Self::SignatureCapture,
"PPSG" => Self::PaperSignature,
"MANU" => Self::ManualVerification,
"MERC" => Self::MerchantAuthentication,
"SCRT" => Self::SecureCertificate,
"SNCT" => Self::SecureNoCertificate,
"SCNL" => Self::SecuredChannel,
"PSWD" => Self::Password,
"ADDB" => Self::BillingAddressVerification,
"BIOM" => Self::Biometry,
"CDHI" => Self::CardholderIdentificationData,
"CRYP" => Self::CryptogramVerification,
"CSCV" => Self::CscVerification,
"PSVE" => Self::PassiveAuthentication,
"CSEC" => Self::SecureElectronicCommerce,
"ADDS" => Self::ShippingAddressVerification,
"TOKN" => Self::TokenAuthentication,
"TOKP" => Self::PaymentToken,
"TOKA" => Self::AuthenticationToken,
"MOBL" => Self::Mobile,
"OTHR" => Self::Other,
"ADVF" => Self::AddressDigits,
"ARNB" => Self::AlienRegistrationNumber,
"ARQC" => Self::ArqcVerification,
"BTHD" => Self::BirthDate,
"CHDN" => Self::CardholderName,
"COFB" => Self::CityOfBirth,
"CUID" => Self::CustomerIdentification,
"DRVI" => Self::DriverIdentification,
"DRLN" => Self::DriverLicenseNumber,
"EMAL" => Self::Email,
"EMIN" => Self::EmployeeIdentificationNumber,
"EMRN" => Self::EmployerIdentificationNumber,
"IDCN" => Self::IdentityCardNumber,
"OTPW" => Self::OneTimePassword,
"OCHI" => Self::OtherCardholderIdentification,
"OTHC" => Self::OtherCryptogram,
"PASN" => Self::PassportNumber,
"PCDV" => Self::PostalCode,
"SHAF" => Self::ShippingAddressFrom,
"SHAT" => Self::ShippingAddressTo,
"CHSA" => Self::CardholderAddress,
"NVSC" => Self::NonVisibleCsc,
"OTHN" => Self::OtherNational,
"OTHP" => Self::OtherPrivate,
"PLOB" => Self::PlaceOfBirth,
"SSNB" => Self::SocialSecurityNumber,
"TXIN" => Self::TaxIdentificationNumber,
"APKI" => Self::AccountDigitalSignature,
"ARPC" => Self::ArpcVerification,
"ATCC" => Self::Atc,
"FBIG" => Self::OffLineBiographics,
"FBIO" => Self::OffLineBiometrics,
"OLDA" => Self::OffLineDataAuthentication,
"OLDS" => Self::OffLineDigitisedSignatureAnalysis,
"OFPE" => Self::OffLinePinEncrypted,
"FCPN" => Self::OffLinePinInClear,
"NBIG" => Self::OnLineBiographics,
"PHOM" => Self::PhoneHome,
"PWOR" => Self::PhoneWork,
"PKIS" => Self::PkiSignature,
"QWAC" => Self::QualifiedCertificate,
"THDS" => Self::ThreeDs,
pub enum TransactionChannel1Code {
#[doc = "Mail order."]
MailOrder,
#[doc = "Telephone order."]
TelephoneOrder,
#[doc = "Electronic commerce."]
ElectronicCommerce,
#[doc = "Payment on television."]
TelevisionPayment,
#[doc = "Office or branch."]
OfficeOrBranch,
#[doc = "Home banking."]
HomeBanking,
#[doc = "Financial advisor."]
FinancialAdvisor,
#[doc = "Payment performed through a cardholder mobile device."]
MobilePayment,
#[doc = "Electronic commerce with cardholder authentication."]
SecuredElectronicCommerce,
#[doc = "Payment performed through a merchant mobile device."]
MobilePos,
}
impl<'a> TransactionChannel1Code {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"MAIL" => Self::MailOrder,
"TLPH" => Self::TelephoneOrder,
"ECOM" => Self::ElectronicCommerce,
"TVPY" => Self::TelevisionPayment,
"BRAN" => Self::OfficeOrBranch,
"HOBA" => Self::HomeBanking,
"FIAD" => Self::FinancialAdvisor,
"MOBL" => Self::MobilePayment,
"SECM" => Self::SecuredElectronicCommerce,
"MPOS" => Self::MobilePos,
tag => todo!("handle code {tag:?}"),
};
Ok(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Specifies the type of communication channel."]
tag => todo!("handle code {tag:?}"),
};
Ok(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Indicates the environment of the transaction."]
pub enum TransactionEnvironment1Code {
#[doc = "Merchant environment."]
Merchant,
#[doc = "Private environment."]
Private,
#[doc = "Public environment."]
Public,
#[doc = "Bank environment."]
Branch,
#[doc = "Other environments, for instance a mall or an airport."]
Other,
}
impl<'a> TransactionEnvironment1Code {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"MERC" => Self::Merchant,
"PRIV" => Self::Private,
"PUBL" => Self::Public,
"BRCH" => Self::Branch,
"OTHR" => Self::Other,
pub enum AttendanceContext1Code {
#[doc = "Attended payment, with an attendant."]
Attended,
#[doc = "Semi-attended, including self checkout. An attendant supervises several payment, and could be called to help the cardholder."]
SemiAttended,
#[doc = "Unattended payment, no attendant present."]
Unattended,
#[doc = "Delivery by an attendant."]
AttendantDelivery,
#[doc = "Delivery by the customer."]
CustomerDelivery,
#[doc = "Delivery by a carrier."]
CarrierDelivery,
#[doc = "Full service for fuel distribution."]
FullServe,
#[doc = "Self service for fuel distribution."]
SelfServe,
}
impl<'a> AttendanceContext1Code {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"ATTD" => Self::Attended,
"SATT" => Self::SemiAttended,
"UATT" => Self::Unattended,
"ATTL" => Self::AttendantDelivery,
"CUST" => Self::CustomerDelivery,
"CARR" => Self::CarrierDelivery,
"FULL" => Self::FullServe,
"SELF" => Self::SelfServe,
tag => todo!("handle code {tag:?}"),
};
Ok(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Human attendance at the POI location during the transaction."]
};
Ok(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Specifies the external financial instrument identification type scheme name code in the format of character string with a maximum length of 4 characters.\r\nThe list of valid codes is an external code list published separately.\r\nExternal code sets can be downloaded from www.iso20022.org.\n*`BELC`-National securities identification number for BE issued by the National Numbering Association SIX Telekurs Belgium.\n*`BLOM`-Ticker-like code assigned by Bloomberg to identify financial instruments.\n*`CCCD`-National Securities Identification Number issued by the National Numbering Association for a country for which no specific financial instrument identification type code already yet. The first two letters of the code represents the country code (for example, EGDC for Egyptian NSIN). To be used only until the code is added to the ISO ExternalFinancialInstrumentIdentificationType1Code list.\n*`CMED`-Ticker-like code assigned by the Chicago Mercantile Exchange to identify listed-derivatives instruments.\n*`COMM`-National securities identification number for ICSDs issued by the National Numbering Association Clearstream and Euroclear.\n*`CTAC`-Ticker-like code assigned by the Consolidated Tape Association to identify financial instruments.\n*`CUSP`-National securities identification number for US and CA issued by the National Numbering Association Standard & Poor´s - CUSIP Global Services.\n*`FIGC`-A Financial Instrument Global Identifier Composite (FIGC) is a unique, persistent twelve character string that serves to identify financial instruments across asset classes at the composite level, is associated with one or more FIGI venue level ID’s and a single Share Class level ID.\n*`FIGG`-A Financial Instrument Global Identifier Share Class (FIGG) is a unique, persistent twelve character string that serves to identify financial instruments across asset classes at the global share class level, and is associated with one or more Composite level ID’s.\n*`FIGI`-A Financial Instrument Global Identifier (FIGI) is a unique, persistent twelve character string that serves to identify financial instruments across asset classes at the venue level. It is associated with one Composite ID.\n*`ISDU`-URL in Description to identify OTC derivatives instruments.\n*`ISDX`-XML in Description to identify OTC derivatives instruments.\n*`LCHD`-Ticker-like code assigned by LCH to identify listed-derivatives instruments.\n*`OCCS`-Ticker-like code assigned by the Options Clearing Corporation to identify financial instruments.\n*`OPRA`-Ticker-like code assigned by the Options Price Reporting Authority to identify financial instruments.\n*`RCMD`-Ticker-like code assigned by Markit to identify listed-derivatives instruments.\n*`RICC`-Ticker-like code assigned by Thomson Reuters to identify financial instruments.\n*`SEDL`-National securities identification number for GB issued by the National Numbering Association London Stock Exchange.\n*`SICC`-National securities identification number for JP issued by the National Numbering Association 6 Stock Exchanges and JASDEC (Securities Identification Ticker-like code Committee)\n*`TIKR`-Ticker Code assigned by an exchange to identify financial instruments.\n*`VALO`-National securities identification number for CH and LI issued by the National Numbering Association SIX Telekurs Ltd.\n*`WKNR`-National securities identification number for DE issued by the National Numbering Association WM Datenservice.\n*`CCDC`-National Bond identification number for China issued by CHINA CENTRAL DEPOSITORY & CLEARING CO., Limited.\n*`DTID`-Digital Token Identifier, as defined in ISO 24165."]
pub enum ExternalFinancialInstrumentIdentificationType1Code {
Belc,
Blom,
Cccd,
Cmed,
Comm,
Ctac,
Cusp,
Figc,
Figg,
Figi,
Isdu,
Isdx,
Lchd,
Occs,
Opra,
Rcmd,
Ricc,
Sedl,
Sicc,
Tikr,
Valo,
Wknr,
Ccdc,
Dtid,
}
impl<'a> ExternalFinancialInstrumentIdentificationType1Code {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"BELC" => Self::Belc,
"BLOM" => Self::Blom,
"CCCD" => Self::Cccd,
"CMED" => Self::Cmed,
"COMM" => Self::Comm,
"CTAC" => Self::Ctac,
"CUSP" => Self::Cusp,
"FIGC" => Self::Figc,
"FIGG" => Self::Figg,
"FIGI" => Self::Figi,
"ISDU" => Self::Isdu,
"ISDX" => Self::Isdx,
"LCHD" => Self::Lchd,
"OCCS" => Self::Occs,
"OPRA" => Self::Opra,
"RCMD" => Self::Rcmd,
"RICC" => Self::Ricc,
"SEDL" => Self::Sedl,
"SICC" => Self::Sicc,
"TIKR" => Self::Tikr,
"VALO" => Self::Valo,
"WKNR" => Self::Wknr,
"CCDC" => Self::Ccdc,
"DTID" => Self::Dtid,
tag => todo!("handle code {tag:?}"),
};
Ok(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Specifies the external financial instrument identification type scheme name code in the format of character string with a maximum length of 4 characters.\r\nThe list of valid codes is an external code list published separately.\r\nExternal code sets can be downloaded from www.iso20022.org."]
pub enum ExternalFinancialInstrumentIdentificationTypeCode {
#[doc = "National securities identification number for BE issued by the National Numbering Association SIX Telekurs Belgium."]
CodeSrwSecretariaatVoorRoerendeWaardenOrSvmSecrTariatDesValeursMobiliRes,
#[doc = "Ticker-like code assigned by Bloomberg to identify financial instruments."]
Bloomberg,
#[doc = "National Securities Identification Number issued by the National Numbering Association for a country for which no specific financial instrument identification type code already yet. The first two letters of the code represents the country code (for example, EGDC for Egyptian NSIN). To be used only until the code is added to the ISO ExternalFinancialInstrumentIdentificationType1Code list."]
OtherNationalSecuritiesIdentificationNumber,
#[doc = "Ticker-like code assigned by the Chicago Mercantile Exchange to identify listed-derivatives instruments."]
ChicagoMercantileExchangeCme,
#[doc = "National securities identification number for ICSDs issued by the National Numbering Association Clearstream and Euroclear."]
CommonCode,
#[doc = "Ticker-like code assigned by the Consolidated Tape Association to identify financial instruments."]
ConsolidatedTapeAssociationCta,
#[doc = "National securities identification number for US and CA issued by the National Numbering Association Standard & Poor´s - CUSIP Global Services."]
CommitteeOnUniformSecurityIdentificationProceduresCusip,
#[doc = "A Financial Instrument Global Identifier Composite (FIGC) is a unique, persistent twelve character string that serves to identify financial instruments across asset classes at the composite level, is associated with one or more FIGI venue level ID’s and a single Share Class level ID."]
FinancialInstrumentGlobalIdentifierComposite,
#[doc = "A Financial Instrument Global Identifier Share Class (FIGG) is a unique, persistent twelve character string that serves to identify financial instruments across asset classes at the global share class level, and is associated with one or more Composite level ID’s."]
FinancialInstrumentGlobalIdentifierShareClass,
#[doc = "A Financial Instrument Global Identifier (FIGI) is a unique, persistent twelve character string that serves to identify financial instruments across asset classes at the venue level. It is associated with one Composite ID."]
FinancialInstrumentGlobalIdentifier,
#[doc = "URL in Description to identify OTC derivatives instruments."]
IsdaAndFpMlProductUrlInSecurityId,
#[doc = "XML in Description to identify OTC derivatives instruments."]
IsdaAndFpMlProductSpecificationXmlInEncodedSecurityDesc,
#[doc = "Ticker-like code assigned by LCH to identify listed-derivatives instruments."]
LchClearnet,
#[doc = "Ticker-like code assigned by the Options Clearing Corporation to identify financial instruments."]
OptionsClearingCorpOcc,
#[doc = "Ticker-like code assigned by the Options Price Reporting Authority to identify financial instruments."]
OptionsPriceReportingAuthorityOpra,
#[doc = "Ticker-like code assigned by Markit to identify listed-derivatives instruments."]
MarkitRedCode,
#[doc = "Ticker-like code assigned by Thomson Reuters to identify financial instruments."]
ReutersInstrumentCodeRic,
#[doc = "National securities identification number for GB issued by the National Numbering Association London Stock Exchange."]
StockExchangeDailyOfficialListSedol,
#[doc = "National securities identification number for JP issued by the National Numbering Association 6 Stock Exchanges and JASDEC (Securities Identification Ticker-like code Committee)"]
SecuritiesIdentificationCodeCommittee,
#[doc = "Ticker Code assigned by an exchange to identify financial instruments."]
TickerSymbolTs,
#[doc = "National securities identification number for CH and LI issued by the National Numbering Association SIX Telekurs Ltd."]
Valor,
#[doc = "National securities identification number for DE issued by the National Numbering Association WM Datenservice."]
WertpapierkennummerWkn,
#[doc = "National Bond identification number for China issued by CHINA CENTRAL DEPOSITORY & CLEARING CO., Limited."]
BondIdentificationCodeListChina,
}
impl<'a> ExternalFinancialInstrumentIdentificationTypeCode {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"BELC" => {
Self::CodeSrwSecretariaatVoorRoerendeWaardenOrSvmSecrTariatDesValeursMobiliRes
}
"BLOM" => Self::Bloomberg,
"CCCD" => Self::OtherNationalSecuritiesIdentificationNumber,
"CMED" => Self::ChicagoMercantileExchangeCme,
"COMM" => Self::CommonCode,
"CTAC" => Self::ConsolidatedTapeAssociationCta,
"CUSP" => Self::CommitteeOnUniformSecurityIdentificationProceduresCusip,
"FIGC" => Self::FinancialInstrumentGlobalIdentifierComposite,
"FIGG" => Self::FinancialInstrumentGlobalIdentifierShareClass,
"FIGI" => Self::FinancialInstrumentGlobalIdentifier,
"ISDU" => Self::IsdaAndFpMlProductUrlInSecurityId,
"ISDX" => Self::IsdaAndFpMlProductSpecificationXmlInEncodedSecurityDesc,
"LCHD" => Self::LchClearnet,
"OCCS" => Self::OptionsClearingCorpOcc,
"OPRA" => Self::OptionsPriceReportingAuthorityOpra,
"RCMD" => Self::MarkitRedCode,
"RICC" => Self::ReutersInstrumentCodeRic,
"SEDL" => Self::StockExchangeDailyOfficialListSedol,
"SICC" => Self::SecuritiesIdentificationCodeCommittee,
"TIKR" => Self::TickerSymbolTs,
"VALO" => Self::Valor,
"WKNR" => Self::WertpapierkennummerWkn,
"CCDC" => Self::BondIdentificationCodeListChina,
tag => todo!("handle code {tag:?}"),
};
Ok(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Price will not be paid."]
pub enum PriceValueType1Code {
#[doc = "Price expressed as a number of percentage points below par, for example, a discount price of 2.0% equals a price of 98 when par is 100."]
Discount,
#[doc = "Price expressed as a number of percentage points above par, for example, a premium price of 2.0% equals a price of 102 when par is 100."]
Premium,
#[doc = "Price is the face amount."]
Par,
#[doc = "Price expressed as a yield."]
Yield,
#[doc = "Difference between a market maker's bid and asked price."]
Spread,
#[doc = "Price expressed per unit."]
PerUnit,
#[doc = "Price is expressed as absolute."]
Absolute,
#[doc = "Price is expressed as Treasury Euro Dollar price."]
TedPrice,
#[doc = "Price is expressed as Treasury Euro Dollar yield."]
TedYield,
#[doc = "Cabinet trades are used to indicate prices that trade at a price lower than that available on an exchange and they can be fixed or variable (primarily used for listed futures and options)."]
FixedCabinetTrade,
#[doc = "Cabinet trades are used to indicate prices that trade at a price lower than that available on an exchange and they can be fixed or variable (primarily used for listed futures and options)."]
VariableCabinetTrade,
#[doc = "Price expressed as a percentage of par."]
Percentage,
#[doc = "Price is unknown by the sender or has not been established."]
Unknown,
#[doc = "Price has not been established."]
OpenDated,
#[doc = "Price is not required to be specified by account owner."]
Unspecified,
#[doc = "Price to be specified by account owner."]
ToBeSpecified,
#[doc = "Price expressed as a currency and amount per unit or per share."]
ActualAmount,
#[doc = "Price will not be paid."]
NilPayment,
#[doc = "Price must be interpreted as a negative amount of currency per unit or per share."]
NegativeActualAmount,
}
impl<'a> PriceValueType1Code {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"DISC" => Self::Discount,
"PREM" => Self::Premium,
"PARV" => Self::Par,
"YIEL" => Self::Yield,
"SPRE" => Self::Spread,
"PEUN" => Self::PerUnit,
"ABSO" => Self::Absolute,
"TEDP" => Self::TedPrice,
"TEDY" => Self::TedYield,
"FICT" => Self::FixedCabinetTrade,
"VACT" => Self::VariableCabinetTrade,
"PRCT" => Self::Percentage,
"UKWN" => Self::Unknown,
"OPEN" => Self::OpenDated,
"UNSP" => Self::Unspecified,
"TBSP" => Self::ToBeSpecified,
"ACTU" => Self::ActualAmount,
"NILP" => Self::NilPayment,
"NEGA" => Self::NegativeActualAmount,
tag => todo!("handle code {tag:?}"),
};
Ok(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Specifies the garnishment type as published in an external document type code list.\n*`GNCS`-Garnishment from a third party payer for Child Support\n*`GNDP`-Garnishment from a direct payer for Child Support\n*`GTPP`-Garnishment from a third party payer to taxing agency"]
pub enum ExternalGarnishmentType1Code {
Gncs,
Gndp,
Gtpp,
}
impl<'a> ExternalGarnishmentType1Code {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"GNCS" => Self::Gncs,
"GNDP" => Self::Gndp,
"GTPP" => Self::Gtpp,
tag => todo!("handle code {tag:?}"),
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Specifies the garnishment type as published in an external document type code list."]
pub enum ExternalGarnishmentTypeCode {
#[doc = "Garnishment from a third party payer for Child Support"]
GarnishmentForChildSupport,
#[doc = "Garnishment from a direct payer for Child Support"]
GarnishmentForChildSupportFromDirectPayer,
#[doc = "Garnishment from a third party payer to taxing agency"]
GarnishmentToTaxingAgency,
}
impl<'a> ExternalGarnishmentTypeCode {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"GNCS" => Self::GarnishmentForChildSupport,
"GNDP" => Self::GarnishmentForChildSupportFromDirectPayer,
"GTPP" => Self::GarnishmentToTaxingAgency,
tag => todo!("handle code {tag:?}"),
};
Ok(value)
}
}
pub use self::external_code_sets::ExternalGarnishmentType1Code;
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Specifies the nature, or use, of the amount in the format of character string with a maximum length of 4 characters.\r\nThe list of valid codes is an external code list published separately.\r\nExternal code sets can be downloaded from www.iso20022.org.\n*`CITY`-Tax accessed by city jurisdications within a country.\n*`CNTY`-Tax accessed by county jurisdications within a country.\n*`LOCL`-Tax accessed by local jurisdications within a country.\n*`PROV`-Tax accessed by province jurisdications within a country.\n*`STAT`-Tax accessed by state jurisdications within a country."]
pub enum ExternalTaxAmountType1Code {
City,
Cnty,
Locl,
Prov,
Stat,
}
impl<'a> ExternalTaxAmountType1Code {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"CITY" => Self::City,
"CNTY" => Self::Cnty,
"LOCL" => Self::Locl,
"PROV" => Self::Prov,
"STAT" => Self::Stat,
tag => todo!("handle code {tag:?}"),
};
Ok(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Specifies the nature, or use, of the amount in the format of character string with a maximum length of 4 characters.\r\nThe list of valid codes is an external code list published separately.\r\nExternal code sets can be downloaded from www.iso20022.org."]
pub enum ExternalTaxAmountTypeCode {
#[doc = "Tax accessed by city jurisdications within a country."]
CityTax,
#[doc = "Tax accessed by county jurisdications within a country."]
CountyTax,
#[doc = "Tax accessed by local jurisdications within a country."]
LocalTax,
#[doc = "Tax accessed by province jurisdications within a country."]
ProvinceTax,
#[doc = "Tax accessed by state jurisdications within a country."]
StateTax,
}
impl<'a> ExternalTaxAmountTypeCode {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"CITY" => Self::CityTax,
"CNTY" => Self::CountyTax,
"LOCL" => Self::LocalTax,
"PROV" => Self::ProvinceTax,
"STAT" => Self::StateTax,
tag => todo!("handle code {tag:?}"),
};
Ok(value)
}
}
pub use self::external_code_sets::ExternalTaxAmountType1Code;
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Specifies the nature, or use, of the amount in the format of character string with a maximum length of 4 characters.\r\nThe list of valid codes is an external code list published separately.\r\nExternal code sets can be downloaded from www.iso20022.org.\n*`APDS`-Addition discount based on third-party agreed business promotional activity, i.e., extra 10 percent discount for 15 days)\n*`STDS`-Discount based on volume purchased.\n*`TMDS`-Discount based on terms negotiated for payment within a specified time period, i.e., 2/10 Net 30 (2 percent discount if paid in 10 days; otherwise, net amount is due in 30 days)."]
pub enum ExternalDiscountAmountType1Code {
Apds,
Stds,
Tmds,
}
impl<'a> ExternalDiscountAmountType1Code {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"APDS" => Self::Apds,
"STDS" => Self::Stds,
"TMDS" => Self::Tmds,
tag => todo!("handle code {tag:?}"),
};
Ok(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Specifies the nature, or use, of the amount in the format of character string with a maximum length of 4 characters.\r\nThe list of valid codes is an external code list published separately.\r\nExternal code sets can be downloaded from www.iso20022.org."]
pub enum ExternalDiscountAmountTypeCode {
#[doc = "Addition discount based on third-party agreed business promotional activity, i.e., extra 10 percent discount for 15 days)"]
AdditionalPromotionalDiscount,
#[doc = "Discount based on volume purchased."]
StandingDiscount,
#[doc = "Discount based on terms negotiated for payment within a specified time period, i.e., 2/10 Net 30 (2 percent discount if paid in 10 days; otherwise, net amount is due in 30 days)."]
TermsDiscount,
}
impl<'a> ExternalDiscountAmountTypeCode {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"APDS" => Self::AdditionalPromotionalDiscount,
"STDS" => Self::StandingDiscount,
"TMDS" => Self::TermsDiscount,
tag => todo!("handle code {tag:?}"),
};
Ok(value)
}
}
pub use self::external_code_sets::ExternalDiscountAmountType1Code;
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Specifies the document line type as published in an external document type code list.\n*`ADPI`-Line item reference is an additional product identification assigned by the manufacturer.\n*`AISB`-Line item reference is an alternate International Standard Book Number (ISBN).\n*`ASNB`-Line item reference is an asset number.\n*`CTNB`-Line item reference is a catalog number.\n*`DBSP`-Line item reference is Dun & Bradstreet Standard Product and Service code.\n*`EANN`-Line item reference is an European Article Number (EAN).\n*`EINB`-Line item reference is an equipment identification number.\n*`GSNB`-Line item reference is a general specification number.\n*`HIBC`-Line item reference is a Health Care Industry Bar Code (HIBC)\n*`ISBN`-Line item reference is an International Standard Book Number (ISBN).\n*`LTNB`-Line item reference is a lot number.\n*`MDNB`-Line item reference is a model number\n*`PRNB`-Line item reference is a part reference number.\n*`PTCD`-Line item reference is a product type code.\n*`SKNB`-Line item reference is a stock number.\n*`STNB`-Line item reference is a style number.\n*`TONB`-Line item reference is a technical order number.\n*`UPCC`-Line item reference is an UPC consumer package code.\n*`UPNB`-Line item reference is an Universal Product Number."]
pub enum ExternalDocumentLineType1Code {
Adpi,
Aisb,
Asnb,
Ctnb,
Dbsp,
Eann,
Einb,
Gsnb,
Hibc,
Isbn,
Ltnb,
Mdnb,
Prnb,
Ptcd,
Sknb,
Stnb,
Tonb,
Upcc,
Upnb,
impl<'a> ExternalDocumentLineType1Code {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"ADPI" => Self::Adpi,
"AISB" => Self::Aisb,
"ASNB" => Self::Asnb,
"CTNB" => Self::Ctnb,
"DBSP" => Self::Dbsp,
"EANN" => Self::Eann,
"EINB" => Self::Einb,
"GSNB" => Self::Gsnb,
"HIBC" => Self::Hibc,
"ISBN" => Self::Isbn,
"LTNB" => Self::Ltnb,
"MDNB" => Self::Mdnb,
"PRNB" => Self::Prnb,
"PTCD" => Self::Ptcd,
"SKNB" => Self::Sknb,
"STNB" => Self::Stnb,
"TONB" => Self::Tonb,
"UPCC" => Self::Upcc,
"UPNB" => Self::Upnb,
tag => todo!("handle code {tag:?}"),
};
Ok(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Specifies the document line type as published in an external document type code list."]
pub enum ExternalDocumentLineTypeCode {
#[doc = "Line item reference is an additional product identification assigned by the manufacturer."]
AdditionalProductIdentificationAssignedByTheManufacturer,
#[doc = "Line item reference is an alternate International Standard Book Number (ISBN)."]
AlternateIsbn,
#[doc = "Line item reference is an asset number."]
AssetNumber,
#[doc = "Line item reference is a catalog number."]
CatalogNumber,
#[doc = "Line item reference is Dun & Bradstreet Standard Product and Service code."]
DunBradstreetStandardProductAndServiceCode,
#[doc = "Line item reference is an European Article Number (EAN)."]
EuropeanArticleNumberEan2551,
#[doc = "Line item reference is an equipment identification number."]
EquipmentIdentificationNumber,
#[doc = "Line item reference is a general specification number."]
GeneralSpecificationNumber,
#[doc = "Line item reference is a Health Care Industry Bar Code (HIBC)"]
HibcHealthCareIndustryBarCode,
#[doc = "Line item reference is an International Standard Book Number (ISBN)."]
InternationalStandardBookNumberIsbn,
#[doc = "Line item reference is a lot number."]
LotNumber,
#[doc = "Line item reference is a model number"]
ModelNumber,
#[doc = "Line item reference is a part reference number."]
PartNumber,
#[doc = "Line item reference is a product type code."]
ProductTypeCode,
#[doc = "Line item reference is a stock number."]
StockNumber,
#[doc = "Line item reference is a style number."]
StyleNumber,
#[doc = "Line item reference is a technical order number."]
TechnicalOrderNumber,
#[doc = "Line item reference is an UPC consumer package code."]
UpcConsumerPackageCode,
#[doc = "Line item reference is an Universal Product Number."]
UniversalProductNumber,
}
impl<'a> ExternalDocumentLineTypeCode {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"ADPI" => Self::AdditionalProductIdentificationAssignedByTheManufacturer,
"AISB" => Self::AlternateIsbn,
"ASNB" => Self::AssetNumber,
"CTNB" => Self::CatalogNumber,
"DBSP" => Self::DunBradstreetStandardProductAndServiceCode,
"EANN" => Self::EuropeanArticleNumberEan2551,
"EINB" => Self::EquipmentIdentificationNumber,
"GSNB" => Self::GeneralSpecificationNumber,
"HIBC" => Self::HibcHealthCareIndustryBarCode,
"ISBN" => Self::InternationalStandardBookNumberIsbn,
"LTNB" => Self::LotNumber,
"MDNB" => Self::ModelNumber,
"PRNB" => Self::PartNumber,
"PTCD" => Self::ProductTypeCode,
"SKNB" => Self::StockNumber,
"STNB" => Self::StyleNumber,
"TONB" => Self::TechnicalOrderNumber,
"UPCC" => Self::UpcConsumerPackageCode,
"UPNB" => Self::UniversalProductNumber,
tag => todo!("handle code {tag:?}"),
};
Ok(value)
}
}
pub use self::external_code_sets::ExternalDocumentLineType1Code;
};
Ok(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Specifies a type of financial or commercial document."]
pub enum DocumentType6Code {
#[doc = "Document is an invoice claiming payment for the supply of metered services, for example gas or electricity supplied to a fixed meter."]
MeteredServiceInvoice,
#[doc = "Document is a credit note for the final amount settled for a commercial transaction."]
CreditNoteRelatedToFinancialAdjustment,
#[doc = "Document is a debit note for the final amount settled for a commercial transaction."]
DebitNoteRelatedToFinancialAdjustment,
#[doc = "Document is an invoice."]
CommercialInvoice,
#[doc = "Document is a credit note."]
CreditNote,
#[doc = "Document is a debit note."]
DebitNote,
#[doc = "Document is an invoice for the hiring of human resources or renting goods or equipment."]
HireInvoice,
#[doc = "Document is an invoice issued by the debtor."]
SelfBilledInvoice,
#[doc = "Document is a remittance advice sent separately from the current transaction."]
RemittanceAdviceMessage,
#[doc = "Document is a linked payment instruction to which the current payment instruction is related, for example, in a cover scenario."]
RelatedPaymentInstruction,
#[doc = "Document is an agreement between the parties, stipulating the terms and conditions of the delivery of goods or services."]
CommercialContract,
#[doc = "Document is a pre-agreed or pre-arranged foreign exchange transaction to which the payment transaction refers."]
ForeignExchangeDealReference,
#[doc = "Document is a statement of the transactions posted to the debtor's account at the supplier."]
StatementOfAccount,
#[doc = "Document is a dispatch advice."]
DispatchAdvice,
#[doc = "Document is a purchase order."]
PurchaseOrder,
#[doc = "Document is a structured communication reference provided by the creditor to identify the referred transaction."]
StructuredCommunicationReference,
#[doc = "Document is a shipping notice."]
BillOfLading,
#[doc = "Document is an electronic payment document."]
Voucher,
#[doc = "Document is a payment that applies to a specific source document."]
AccountReceivableOpenItem,
#[doc = "Document is a transaction identifier as assigned by the Trade Services Utility."]
TradeServicesUtilityTransaction,
#[doc = "When the Sale system print the Cashier copy of the Payment receipt."]
CashierReceipt,
#[doc = "When the Sale System requires\tthe POI system to print the Customer receipt."]
CustomerReceipt,
#[doc = "When the POI or the Sale System wants to store a message on the journal printer or electronic journal of the Sale Terminal (it is sometimes a Sale Logging/Journal Printer)."]
Journal,
#[doc = "When the Sale System requires the POI system to print the Sale receipt."]
SaleReceipt,
}
impl<'a> DocumentType6Code {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"MSIN" => Self::MeteredServiceInvoice,
"CNFA" => Self::CreditNoteRelatedToFinancialAdjustment,
"DNFA" => Self::DebitNoteRelatedToFinancialAdjustment,
"CINV" => Self::CommercialInvoice,
"CREN" => Self::CreditNote,
"DEBN" => Self::DebitNote,
"HIRI" => Self::HireInvoice,
"SBIN" => Self::SelfBilledInvoice,
"RADM" => Self::RemittanceAdviceMessage,
"RPIN" => Self::RelatedPaymentInstruction,
"CMCN" => Self::CommercialContract,
"FXDR" => Self::ForeignExchangeDealReference,
"SOAC" => Self::StatementOfAccount,
"DISP" => Self::DispatchAdvice,
"PUOR" => Self::PurchaseOrder,
"SCOR" => Self::StructuredCommunicationReference,
"BOLD" => Self::BillOfLading,
"VCHR" => Self::Voucher,
"AROI" => Self::AccountReceivableOpenItem,
"TSUT" => Self::TradeServicesUtilityTransaction,
"HRCP" => Self::CashierReceipt,
"CRCP" => Self::CustomerReceipt,
"JNRL" => Self::Journal,
"SRCP" => Self::SaleReceipt,
tag => todo!("handle code {tag:?}"),
};
Ok(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Specifies the external local instrument code in the format of character string with a maximum length of 35 characters.\r\nThe list of valid codes is an external code list published separately.\r\nExternal code sets can be downloaded from www.iso20022.org.\n*`DDMC`-Transaction is related to a direct debit instruction authorized under a confirmed electronic mandate.\n*`DDMP`-Transaction is related to a direct debit instruction authorized under a paper based mandate, supported by paper authorization signed by the debtor.\n*`DDMU`-Transaction is related to a direct debit instruction authorized under an unconfirmed electronic mandate requiring confirmation by the debtor.\n*`BPA`-Transaction is related to an Instant Credit Transfer under the rules of the Centrale Bank van Aruba, based on the EPC SCT Inst scheme, with a specific batch time-out delay.\n*`IPA`-Transaction is related to an Instant Credit Transfer under the rules of the Centrale Bank van Aruba, based on the EPC SCT Inst scheme.\n*`TRF`-Transaction is related to credit transfers\n*`82`-Transaction is related to a direct debit that is not pre authorised (Einzugsermächtigung). \n*`83`-Transaction is related to a direct debit that is pre authorised (Abbuchungsauftrag). \n*`CPP`-Transaction is related to cash per post.\nTransaction to ultimate recipient having no bank account. Primary beneficiary is a postal service provider. Funds are paid out by cash. Additional necessary information for address and delivery options need to be attached.\n\n*`RTR`-Transaction is related to returned credit transfers.\n*`GST`-Transaction is related to truncated credit transfers.\nConversion of physical instrument to electonric form for transmission to the paying bank and where the original paper document does not continue in the clearing process..The original instrument rules are retained throughout the life of the instrument.\nTransaction triggered by specific marked and populated paper slip.\nReconciliation reference is secured by check digits supporting secure optical recognition. All other remittance information is truncated prior transmission.\n\n*`DDT`-Transaction is related to direct debits.\n*`RDD`-Transaction is related to returned direct debits.\n*`CHN`-Transaction is related to truncated checks.\nConversion of physical instrument to electonric form for transmission to the paying bank and where the original paper document does not continue in the clearing process..The original instrument rules are retained throughout the life of the instrument.\n*`STR`-Transaction is related to revoked credit transfers\n*`SDD`-Transaction is related to revoked direct debits.\n*`SRT`-Transaction is related to revoked returned credit transfers\n*`SRD`-Transaction is related to revoked returned direct debits.\n*`SCN`-Transaction is related to revoked truncated checks.\n*`SGT`-Transaction is related to revoked truncated credit transfers.\n*`CARD`-Transaction is related to card clearing.\n*`05`-Transaction is related to a direct debit that is not pre authorised (Einzugsermächtigung). \n*`04`-Transaction is related to a direct debit that is pre authorised (Abbuchungsauftrag). \n*`ISE`-Transaction is related to the German Image-based Cheque Collection Procedure “Imagegestützter Scheckeinzug - ISE”\n*`BSE`-Transaction is related to the German Paperless Cheque Collection procedure “Belegloser Scheckeinzug - BSE”\n*`58`-Transaction is related to a business-to-business direct debit (CSB58).\n*`19`-Transaction is related to a business-to-customer direct debit (CSB19).\n*`ASTI`-Indicates that the payment is sent by an authorized third party on behalf of the participant. \n*`BACP`-Indicates that the payment was initiated manually using a GUI (Graphical User Interface).\n*`MANP`-Indicates that the payment is sent by responsible Central Bank on behalf of the participant in case of contingency.\n*`SBTI`-Indicates that the payment is submitted to move liquidity to the technical account - dedicated to real-time settlement in an external system (for example ancillary system) . The payment is processed in a separate payment queue besides the normal processing.\n*`85`-Transaction is related to an urgent direct debit that is pre authorised (Avis de Prélèvement accéléré).\n*`08`-Transaction is related to a direct debit that is pre authorised (Avis de Prélèvement).\n*`89`-Transaction is related to an urgent direct debit that is pre authorised (Avis de Prélèvement vérifié).\n*`60`-LCR - Lettre de Change Relevé (Recovered Bill of Exchange) and BOR - Billet à Orde Relevé (Promissory Note)\n*`RIBA`-Transaction is related to a non-pre authorised collection (RIBA).\n*`RIDO`-Transaction is related to a direct debit that is pre authorised and revocable (RID Ordinario).\n*`RIDV`-Transaction is related to an urgent direct debit that is pre authorised and revocable (RID Veloce).\n*`IDEAL`-Transaction is related to payments via internet owned by Currence.\n*`INSTNT01`-The transaction is related to a regular Credit Transfer and will be instantly processed under the Dutch AOS on top of the EPC SCT scheme.\n*`INSTTC01`-The transaction is related to an Instant Credit Transfer under the rules of the Dutch AOS on top of the EPC SCT Inst scheme.\n*`INSTIDEAL`-Transaction is related to payments via internet owned by Currence which uses an Instant Credit Transfer.\n*`INSTNT01IDEAL`-Transaction is related to payments via internet owned by Currence which uses a regular Credit Transfer and will be instantly processed under the Dutch AOS on top of the EPC SCT scheme.\n*`INSTTC01IDEAL`-Transaction is related to payments via internet owned by Currence which uses an Instant Credit Transfer under the rules of the Dutch AOS on top of the EPC SCT Inst scheme.\n*`NLDO`-Transaction is related to a Domestic payment initiated by PAIN.001\n*`NLUP`-Transaction is related to a Domestic payment initiated by PAIN.001\n*`SDN`-Transaction is related to payments via a ‘Standaard Digitale Nota’ InvoiceAcceptgiro payment.\n*`ACCEPT`-Transaction is related to payments via Acceptgiro owned by Currence.\n*`ICMC`-Transaction is related to an Incident Management Correction procedure based on the DD infrastructure.\n*`NLGOV`-Transaction is related to direct debit scheme owned by the NVB.\n*`0090`-Transaction is related to mass payment beneficiary.\n\n*`0091`-Transaction is related to mass payment ours.\n\n*`0092`-Transaction is related to mass payment shared.\n\n*`0002`-Transaction is related to standing order.\n*`0221`-Transaction is related to one-off authorisation.\n*`0224`-Transaction is related to one-off authorisation charities.\n*`0226`-Transaction is related to one-off authorisation construction industry.\n*`0225`-Transaction is related to one-off authorisation tuition fees.\n*`0222`-Transaction is related to standing authorisation companies.\n*`0227`-Transaction is related to standing authorisation companies without debtor revocation right.\n*`0220`-Transaction is related to standing authorisation general.\n\n*`0223`-Transaction is related to standing authorisation lotteries.\n*`0001`-Transaction is related to converted (bank) payment.\nConversion of physical instrument to electonric form for transmission to the paying bank and where the original paper document does not continue in the clearing process.The instrument rules change upon conversion.\n*`0000`-Transaction is related to business payment\n*`IN`-Transaction is related to cross border customer credit transfer.\n*`ONCL`-Transaction is related to overnight clearing.\n*`PERI`-Credit transfer contains Extended Remittance Information (ERI) as defined within the applicable scheme.\n*`SDCL`-Transaction is related to New Zealand High Value Clearing System (HVCS) same day clearing payments.\n*`DDNR`-SEPA Core Direct Debit with ‘no refund’ option\n*`DDFA`-SEPA Fixed Amount Direct Debit\n*`CORE`-Transaction is related to SEPA direct debit -core.\n*`B2BAMIPM`-SEPA B2B Direct Debit AMI based on a paper mandate\n*`B2B`-Transaction is related to SEPA business to business direct debit.\n*`CR1AMIPM`-Optional shorter time cycle (D-1) for SEPA Core Direct Debit AMI based on a paper mandate\n*`CORAMIPM`-SEPA Core Direct Debit AMI based on a paper mandate\n*`COR1`-Optional shorter time cycle (D-1) for SEPA Core Direct Debit\n*`FADAMIPM`-SEPA Fixed Amount Direct Debit AMI based on a paper mandate\n*`CLSCCPERX`-Transaction is related to the CLSClearedFX service for Eurex. \nUsage: The code is mandatory for all pacs.009 payments to this service.\n*`CLSCCPLCH`-Transaction is related to the CLSClearedFX service for London Exchange Clearing House. \nUsage: The code is mandatory for all pacs.009 payments to this service.\n*`INST`-Transaction is related to an Instant Credit Transfer.\nUse case example: SEPA Instant Credit Transfer (SCT Inst)\n*`ADD`-Transaction is authenticated direct debit for domestic use.\n*`UDD`-Transaction is unauthenticated direct debit for domestic use.\n*`CCI`-Transaction is related to an intra-group bank initiated cash management payment\n*`BTR`-Transaction is related to a bank transfer.\n*`CKS`-Transaction is related to check same day settlement wire.\n*`CTR`-Transaction is related to customer transfer.\n*`CTP`-Transaction is related to a customer transfer, which may include information related to a cover payment or extended remittance information. \n*`DEP`-Transaction is related to deposit to sender's account.\n*`FFR`-Transaction is related to Fed funds returned.\n*`FFS`-Transaction is related to Fed funds sold.\n*`SVC`-Transaction is related to non-value service message.\n*`DRW`-Transaction is related to drawdown response (value) to honor a drawdown request.\n*`DRB`-Transaction is related to bank-to-bank drawdown request or response (non-value)\n*`DRC`-Transaction is related to customer or corporate drawdown request or response (non-value).\n*`IAT`-Transaction is related to international ACH.\n*`CCD`-Transaction is related to cash concentration or disbursement corporate counterparty.\n*`CTX`-Transaction is related to corporate trade exchange.\n*`PPD`-Transaction is related to prearranged payment or deposit consumer counterparty.\n*`CIE`-A credit entry initiated by or on behalf of the holder of a consumer account\n*`RCK`-Transaction is related to re-presented check entry.\n*`ARC`-Transaction is related to accounts receivable check.\n*`WEB`-Transaction is related to internet initiated entry.\n*`POP`-Transaction is related to point-of-purchase.\n*`POS`-Transaction is related to point-of-sale.\n*`TEL`-Transaction is related to telephone initiated entry.\n*`ITP`-Request-to-pay preferred payment via Instant Credit Transfer but Credit Transfer is also possible.\n*`CTP`-Request-to-pay preferred payment via Credit Transfer but Instant Credit Transfer is also possible.\n*`MDP`-Type of New Payments Architecture (NPA) payment. Payments are processed over a three-day cycle and available to customers early in the morning of Day 3."]
pub enum ExternalLocalInstrument1Code {
Ddmc,
Ddmp,
Ddmu,
Bpa,
Ipa,
Trf,
_82,
_83,
Cpp,
Rtr,
Gst,
Ddt,
Rdd,
Chn,
Str,
Sdd,
Srt,
Srd,
Scn,
Sgt,
Card,
_05,
_04,
Ise,
Bse,
_58,
_19,
Asti,
Bacp,
Manp,
Sbti,
_85,
_08,
_89,
_60,
Riba,
Rido,
Ridv,
Ideal,
Instnt01,
Insttc01,
Instideal,
Instnt01ideal,
Insttc01ideal,
Nldo,
Nlup,
Sdn,
Accept,
Icmc,
Nlgov,
_0090,
_0091,
_0092,
_0002,
_0221,
_0224,
_0226,
_0225,
_0222,
_0227,
_0220,
_0223,
_0001,
_0000,
In,
Oncl,
Peri,
Sdcl,
Ddnr,
Ddfa,
Core,
B2bamipm,
B2b,
Cr1amipm,
Coramipm,
Cor1,
Fadamipm,
Clsccperx,
Clsccplch,
Inst,
Add,
Udd,
Cci,
Btr,
Cks,
Ctr,
Dep,
Ffr,
Ffs,
Svc,
Drw,
Drb,
Drc,
Iat,
Ccd,
Ctx,
Ppd,
Cie,
Rck,
Arc,
Web,
Pop,
Pos,
Tel,
Itp,
Ctp,
Mdp,
}
impl<'a> ExternalLocalInstrument1Code {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"DDMC" => Self::Ddmc,
"DDMP" => Self::Ddmp,
"DDMU" => Self::Ddmu,
"BPA" => Self::Bpa,
"IPA" => Self::Ipa,
"TRF" => Self::Trf,
"82" => Self::_82,
"83" => Self::_83,
"CPP" => Self::Cpp,
"RTR" => Self::Rtr,
"GST" => Self::Gst,
"DDT" => Self::Ddt,
"RDD" => Self::Rdd,
"CHN" => Self::Chn,
"STR" => Self::Str,
"SDD" => Self::Sdd,
"SRT" => Self::Srt,
"SRD" => Self::Srd,
"SCN" => Self::Scn,
"SGT" => Self::Sgt,
"CARD" => Self::Card,
"05" => Self::_05,
"04" => Self::_04,
"ISE" => Self::Ise,
"BSE" => Self::Bse,
"58" => Self::_58,
"19" => Self::_19,
"ASTI" => Self::Asti,
"BACP" => Self::Bacp,
"MANP" => Self::Manp,
"SBTI" => Self::Sbti,
"85" => Self::_85,
"08" => Self::_08,
"89" => Self::_89,
"60" => Self::_60,
"RIBA" => Self::Riba,
"RIDO" => Self::Rido,
"RIDV" => Self::Ridv,
"IDEAL" => Self::Ideal,
"INSTNT01" => Self::Instnt01,
"INSTTC01" => Self::Insttc01,
"INSTIDEAL" => Self::Instideal,
"INSTNT01IDEAL" => Self::Instnt01ideal,
"INSTTC01IDEAL" => Self::Insttc01ideal,
"NLDO" => Self::Nldo,
"NLUP" => Self::Nlup,
"SDN" => Self::Sdn,
"ACCEPT" => Self::Accept,
"ICMC" => Self::Icmc,
"NLGOV" => Self::Nlgov,
"0090" => Self::_0090,
"0091" => Self::_0091,
"0092" => Self::_0092,
"0002" => Self::_0002,
"0221" => Self::_0221,
"0224" => Self::_0224,
"0226" => Self::_0226,
"0225" => Self::_0225,
"0222" => Self::_0222,
"0227" => Self::_0227,
"0220" => Self::_0220,
"0223" => Self::_0223,
"0001" => Self::_0001,
"0000" => Self::_0000,
"IN" => Self::In,
"ONCL" => Self::Oncl,
"PERI" => Self::Peri,
"SDCL" => Self::Sdcl,
"DDNR" => Self::Ddnr,
"DDFA" => Self::Ddfa,
"CORE" => Self::Core,
"B2BAMIPM" => Self::B2bamipm,
"B2B" => Self::B2b,
"CR1AMIPM" => Self::Cr1amipm,
"CORAMIPM" => Self::Coramipm,
"COR1" => Self::Cor1,
"FADAMIPM" => Self::Fadamipm,
"CLSCCPERX" => Self::Clsccperx,
"CLSCCPLCH" => Self::Clsccplch,
"INST" => Self::Inst,
"ADD" => Self::Add,
"UDD" => Self::Udd,
"CCI" => Self::Cci,
"BTR" => Self::Btr,
"CKS" => Self::Cks,
"CTR" => Self::Ctr,
"DEP" => Self::Dep,
"FFR" => Self::Ffr,
"FFS" => Self::Ffs,
"SVC" => Self::Svc,
"DRW" => Self::Drw,
"DRB" => Self::Drb,
"DRC" => Self::Drc,
"IAT" => Self::Iat,
"CCD" => Self::Ccd,
"CTX" => Self::Ctx,
"PPD" => Self::Ppd,
"CIE" => Self::Cie,
"RCK" => Self::Rck,
"ARC" => Self::Arc,
"WEB" => Self::Web,
"POP" => Self::Pop,
"POS" => Self::Pos,
"TEL" => Self::Tel,
"ITP" => Self::Itp,
"CTP" => Self::Ctp,
"MDP" => Self::Mdp,
tag => todo!("handle code {tag:?}"),
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Specifies the external local instrument code in the format of character string with a maximum length of 35 characters.\r\nThe list of valid codes is an external code list published separately.\r\nExternal code sets can be downloaded from www.iso20022.org."]
pub enum ExternalLocalInstrumentCode {
#[doc = "Transaction is related to a direct debit instruction authorized under a confirmed electronic mandate."]
DirectDebitConfirmedElectronicMandate,
#[doc = "Transaction is related to a direct debit instruction authorized under a paper based mandate, supported by paper authorization signed by the debtor."]
DirectDebitPaperMandateWithPaperAuthorization,
#[doc = "Transaction is related to a direct debit instruction authorized under an unconfirmed electronic mandate requiring confirmation by the debtor."]
DirectDebitUnconfirmedElectronicMandate,
#[doc = "Transaction is related to an Instant Credit Transfer under the rules of the Centrale Bank van Aruba, based on the EPC SCT Inst scheme, with a specific batch time-out delay."]
BatchPaymentsAruba,
#[doc = "Transaction is related to an Instant Credit Transfer under the rules of the Centrale Bank van Aruba, based on the EPC SCT Inst scheme."]
InstantPaymentsAruba,
#[doc = "Transaction is related to credit transfers"]
CreditTransfers,
#[doc = "Transaction is related to a direct debit that is not pre authorised (Einzugsermächtigung). "]
NonPreauthorisedDirectDebitAt,
#[doc = "Transaction is related to a direct debit that is pre authorised (Abbuchungsauftrag). "]
PreauthorisedDirectDebitAt,
#[doc = "Transaction is related to cash per post.\nTransaction to ultimate recipient having no bank account. Primary beneficiary is a postal service provider. Funds are paid out by cash. Additional necessary information for address and delivery options need to be attached.\n"]
CashPerPost,
#[doc = "Transaction is related to returned credit transfers."]
ReturnedCreditTransfers,
#[doc = "Transaction is related to truncated credit transfers.\nConversion of physical instrument to electonric form for transmission to the paying bank and where the original paper document does not continue in the clearing process..The original instrument rules are retained throughout the life of the instrument.\nTransaction triggered by specific marked and populated paper slip.\nReconciliation reference is secured by check digits supporting secure optical recognition. All other remittance information is truncated prior transmission.\n"]
TruncatedCreditTransfers,
#[doc = "Transaction is related to direct debits."]
DirectDebits,
#[doc = "Transaction is related to returned direct debits."]
ReturnedDirectDebits,
#[doc = "Transaction is related to truncated checks.\nConversion of physical instrument to electonric form for transmission to the paying bank and where the original paper document does not continue in the clearing process..The original instrument rules are retained throughout the life of the instrument."]
TruncatedChecks,
#[doc = "Transaction is related to revoked credit transfers"]
RevokedCreditTransfers,
#[doc = "Transaction is related to revoked direct debits."]
RevokedDirectDebits,
#[doc = "Transaction is related to revoked returned credit transfers"]
RevokedReturnedCreditTransfers,
#[doc = "Transaction is related to revoked returned direct debits."]
RevokedReturnedDirectDebits,
#[doc = "Transaction is related to revoked truncated checks."]
RevokedTruncatedChecks,
#[doc = "Transaction is related to revoked truncated credit transfers."]
RevokedTruncatedCreditTransfers,
#[doc = "Transaction is related to card clearing."]
CardClearing,
#[doc = "Transaction is related to a direct debit that is not pre authorised (Einzugsermächtigung). "]
NonPreauthorisedDirectDebitDe,
#[doc = "Transaction is related to a direct debit that is pre authorised (Abbuchungsauftrag). "]
PreauthorisedDirectDebitDe,
#[doc = "Transaction is related to the German Image-based Cheque Collection Procedure “Imagegestützter Scheckeinzug - ISE”"]
ImageBasedChequeCollection,
#[doc = "Transaction is related to the German Paperless Cheque Collection procedure “Belegloser Scheckeinzug - BSE”"]
PaperlessChequeCollection,
#[doc = "Transaction is related to a business-to-business direct debit (CSB58)."]
BusinessToBusinessDirectDebit,
#[doc = "Transaction is related to a business-to-customer direct debit (CSB19)."]
BusinessToCustomerDirectDebit,
#[doc = "Indicates that the payment is sent by an authorized third party on behalf of the participant. "]
AncillarySystemTransferInitiation,
#[doc = "Indicates that the payment was initiated manually using a GUI (Graphical User Interface)."]
BackupPayment,
#[doc = "Indicates that the payment is sent by responsible Central Bank on behalf of the participant in case of contingency."]
MandatedPayment,
#[doc = "Indicates that the payment is submitted to move liquidity to the technical account - dedicated to real-time settlement in an external system (for example ancillary system) . The payment is processed in a separate payment queue besides the normal processing."]
SettlementBankTransferInitiation,
#[doc = "Transaction is related to an urgent direct debit that is pre authorised (Avis de Prélèvement accéléré)."]
PreauthorisedDirectDebitAccLRAcceleratedClearing2DayOrdinaireNormalClearing4Day,
#[doc = "Transaction is related to a direct debit that is pre authorised (Avis de Prélèvement)."]
PreauthorisedDirectDebitOrdinaireNormalClearing4Day,
#[doc = "Transaction is related to an urgent direct debit that is pre authorised (Avis de Prélèvement vérifié)."]
PreauthorisedDirectDebitVRifiVerifiedClearing,
#[doc = "LCR - Lettre de Change Relevé (Recovered Bill of Exchange) and BOR - Billet à Orde Relevé (Promissory Note)"]
RecoveredBillofExchangeorPromissoryNote,
#[doc = "Transaction is related to a non-pre authorised collection (RIBA)."]
NonPreauthorisedDirectDebitRiba,
#[doc = "Transaction is related to a direct debit that is pre authorised and revocable (RID Ordinario)."]
PreauthorisedRevocableDirectDebit,
#[doc = "Transaction is related to an urgent direct debit that is pre authorised and revocable (RID Veloce)."]
PreauthorisedRevocableUrgentDirectDebit,
#[doc = "Transaction is related to payments via internet owned by Currence."]
PaymentsViaInternetOwnedByCurrence,
#[doc = "The transaction is related to a regular Credit Transfer and will be instantly processed under the Dutch AOS on top of the EPC SCT scheme."]
InstantCreditTransferNotTimeCritical,
#[doc = "The transaction is related to an Instant Credit Transfer under the rules of the Dutch AOS on top of the EPC SCT Inst scheme."]
InstantCreditTransferTimeCritical,
#[doc = "Transaction is related to payments via internet owned by Currence which uses an Instant Credit Transfer."]
PaymentsViaInternetOwnedByCurrenceUsingInstantCreditTransfer,
#[doc = "Transaction is related to payments via internet owned by Currence which uses a regular Credit Transfer and will be instantly processed under the Dutch AOS on top of the EPC SCT scheme."]
PaymentsViaInternetOwnedByCurrenceUsingInstantCreditTransferNotTimeCritical,
#[doc = "Transaction is related to payments via internet owned by Currence which uses an Instant Credit Transfer under the rules of the Dutch AOS on top of the EPC SCT Inst scheme."]
PaymentsViaInternetOwnedByCurrenceUsingInstantCreditTransferTimeCritical,
#[doc = "Transaction is related to a Domestic payment initiated by PAIN.001"]
DutchDomesticBulkPayment,
#[doc = "Transaction is related to a Domestic payment initiated by PAIN.001"]
DutchUrgentPayment,
#[doc = "Transaction is related to payments via a ‘Standaard Digitale Nota’ InvoiceAcceptgiro payment."]
PaymentsViaStandaardDigitaleNota,
#[doc = "Transaction is related to payments via Acceptgiro owned by Currence."]
PaymentViaAcceptgiroOwnedByCurrence,
#[doc = "Transaction is related to an Incident Management Correction procedure based on the DD infrastructure."]
IncidentManagementCorrection,
#[doc = "Transaction is related to direct debit scheme owned by the NVB."]
DirectDebitInitiatedByTheGovernmentWithSpecialConditions,
#[doc = "Transaction is related to mass payment beneficiary.\n"]
MassPaymentBeneficiary,
#[doc = "Transaction is related to mass payment ours.\n"]
MassPaymentOurs,
#[doc = "Transaction is related to mass payment shared.\n"]
MassPaymentShared,
#[doc = "Transaction is related to standing order."]
StandingOrder,
#[doc = "Transaction is related to one-off authorisation."]
OneOffAuthorisation,
#[doc = "Transaction is related to one-off authorisation charities."]
OneOffAuthorisationCharities,
#[doc = "Transaction is related to one-off authorisation construction industry."]
OneOffAuthorisationConstructionIndustry,
#[doc = "Transaction is related to one-off authorisation tuition fees."]
OneOffAuthorisationTuitionFees,
#[doc = "Transaction is related to standing authorisation companies."]
StandingAuthorisationCompanies,
#[doc = "Transaction is related to standing authorisation companies without debtor revocation right."]
StandingAuthorisationCompaniesWithoutDebtorRevocationRight,
#[doc = "Transaction is related to standing authorisation general.\n"]
StandingAuthorisationGeneral,
#[doc = "Transaction is related to standing authorisation lotteries."]
StandingAuthorisationLotteries,
#[doc = "Transaction is related to converted (bank) payment.\nConversion of physical instrument to electonric form for transmission to the paying bank and where the original paper document does not continue in the clearing process.The instrument rules change upon conversion."]
ConvertedBankPayment,
#[doc = "Transaction is related to business payment"]
BusinessPayment,
#[doc = "Transaction is related to cross border customer credit transfer."]
CrossBorderCustomerCreditTransfer,
#[doc = "Transaction is related to overnight clearing."]
Overnight,
#[doc = "Credit transfer contains Extended Remittance Information (ERI) as defined within the applicable scheme."]
PaymentWithEri,
#[doc = "Transaction is related to New Zealand High Value Clearing System (HVCS) same day clearing payments."]
SameDayClearedPayments,
#[doc = "SEPA Core Direct Debit with ‘no refund’ option"]
CoreNoRefund,
#[doc = "SEPA Fixed Amount Direct Debit"]
DirectDebitFixedAmount,
#[doc = "Transaction is related to SEPA direct debit -core."]
SepaDirectDebitCore,
#[doc = "SEPA B2B Direct Debit AMI based on a paper mandate"]
Sepab2bDirectDebitAmi,
#[doc = "Transaction is related to SEPA business to business direct debit."]
SepaBusinessToBusinessDirectDebit,
#[doc = "Optional shorter time cycle (D-1) for SEPA Core Direct Debit AMI based on a paper mandate"]
SepaCoreD1DirectDebitAmi,
#[doc = "SEPA Core Direct Debit AMI based on a paper mandate"]
SepaCoreDirectDebitAmi,
#[doc = "Optional shorter time cycle (D-1) for SEPA Core Direct Debit"]
SepaDirectDebit1DaySettlement,
#[doc = "SEPA Fixed Amount Direct Debit AMI based on a paper mandate"]
SepafaDirectDebitAmi,
#[doc = "Transaction is related to the CLSClearedFX service for Eurex. \nUsage: The code is mandatory for all pacs.009 payments to this service."]
ClsClearedFxForEurex,
#[doc = "Transaction is related to the CLSClearedFX service for London Exchange Clearing House. \nUsage: The code is mandatory for all pacs.009 payments to this service."]
ClsClearedFxForLch,
#[doc = "Transaction is related to an Instant Credit Transfer.\nUse case example: SEPA Instant Credit Transfer (SCT Inst)"]
InstantCreditTransfer,
#[doc = "Transaction is authenticated direct debit for domestic use."]
AuthenticatedDirectDebit,
#[doc = "Transaction is unauthenticated direct debit for domestic use."]
UnauthenticatedDirectDebit,
#[doc = "Transaction is related to an intra-group bank initiated cash management payment"]
CashConcentrationIntragroup,
#[doc = "Transaction is related to a bank transfer."]
BankTransfer,
#[doc = "Transaction is related to check same day settlement wire."]
CheckSameDaySettlementWire,
#[doc = "Transaction is related to customer transfer."]
CustomerTransfer,
#[doc = "Transaction is related to a customer transfer, which may include information related to a cover payment or extended remittance information. "]
CustomerTransferPlus,
#[doc = "Transaction is related to deposit to sender's account."]
DepositToSendersAccount,
#[doc = "Transaction is related to Fed funds returned."]
FedFundsReturned,
#[doc = "Transaction is related to Fed funds sold."]
FedFundsSold,
#[doc = "Transaction is related to non-value service message."]
NonValueServiceMessage,
#[doc = "Transaction is related to drawdown response (value) to honor a drawdown request."]
DrawdownResponseValueToHonorADrawdownRequest,
#[doc = "Transaction is related to bank-to-bank drawdown request or response (non-value)"]
BankToBankDrawdownRequestOrResponseNonvalue,
#[doc = "Transaction is related to customer or corporate drawdown request or response (non-value)."]
CustomerOrCorporateDrawdownRequestOrResponseNonvalue,
#[doc = "Transaction is related to international ACH."]
InternationalAch,
#[doc = "Transaction is related to cash concentration or disbursement corporate counterparty."]
CashConcentrationOrDisbursementCorporateCounterparty,
#[doc = "Transaction is related to corporate trade exchange."]
CorporateTradeExchange,
#[doc = "Transaction is related to prearranged payment or deposit consumer counterparty."]
PrearrangedPaymentOrDepositConsumerCounterparty,
#[doc = "A credit entry initiated by or on behalf of the holder of a consumer account"]
CustomerInitiatedEntry,
#[doc = "Transaction is related to re-presented check entry."]
RepresentedCheckEntry,
#[doc = "Transaction is related to accounts receivable check."]
AccountsReceivableCheck,
#[doc = "Transaction is related to internet initiated entry."]
InternetInitiatedEntry,
#[doc = "Transaction is related to point-of-purchase."]
PointOfPurchase,
#[doc = "Transaction is related to point-of-sale."]
PointOfSale,
#[doc = "Transaction is related to telephone initiated entry."]
TelephoneInitiatedEntry,
#[doc = "Request-to-pay preferred payment via Credit Transfer but Instant Credit Transfer is also possible."]
CreditTransferPreferred,
#[doc = "Request-to-pay preferred payment via Instant Credit Transfer but Credit Transfer is also possible."]
InstantCreditTransferPreferred,
}
impl<'a> ExternalLocalInstrumentCode {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match & * reader . expect_text () ? { "DDMC" => Self :: DirectDebitConfirmedElectronicMandate , "DDMP" => Self :: DirectDebitPaperMandateWithPaperAuthorization , "DDMU" => Self :: DirectDebitUnconfirmedElectronicMandate , "BPA" => Self :: BatchPaymentsAruba , "IPA" => Self :: InstantPaymentsAruba , "TRF" => Self :: CreditTransfers , "82" => Self :: NonPreauthorisedDirectDebitAt , "83" => Self :: PreauthorisedDirectDebitAt , "CPP" => Self :: CashPerPost , "RTR" => Self :: ReturnedCreditTransfers , "GST" => Self :: TruncatedCreditTransfers , "DDT" => Self :: DirectDebits , "RDD" => Self :: ReturnedDirectDebits , "CHN" => Self :: TruncatedChecks , "STR" => Self :: RevokedCreditTransfers , "SDD" => Self :: RevokedDirectDebits , "SRT" => Self :: RevokedReturnedCreditTransfers , "SRD" => Self :: RevokedReturnedDirectDebits , "SCN" => Self :: RevokedTruncatedChecks , "SGT" => Self :: RevokedTruncatedCreditTransfers , "CARD" => Self :: CardClearing , "05" => Self :: NonPreauthorisedDirectDebitDe , "04" => Self :: PreauthorisedDirectDebitDe , "ISE" => Self :: ImageBasedChequeCollection , "BSE" => Self :: PaperlessChequeCollection , "58" => Self :: BusinessToBusinessDirectDebit , "19" => Self :: BusinessToCustomerDirectDebit , "ASTI" => Self :: AncillarySystemTransferInitiation , "BACP" => Self :: BackupPayment , "MANP" => Self :: MandatedPayment , "SBTI" => Self :: SettlementBankTransferInitiation , "85" => Self :: PreauthorisedDirectDebitAccLRAcceleratedClearing2DayOrdinaireNormalClearing4Day , "08" => Self :: PreauthorisedDirectDebitOrdinaireNormalClearing4Day , "89" => Self :: PreauthorisedDirectDebitVRifiVerifiedClearing , "60" => Self :: RecoveredBillofExchangeorPromissoryNote , "RIBA" => Self :: NonPreauthorisedDirectDebitRiba , "RIDO" => Self :: PreauthorisedRevocableDirectDebit , "RIDV" => Self :: PreauthorisedRevocableUrgentDirectDebit , "IDEAL" => Self :: PaymentsViaInternetOwnedByCurrence , "INSTNT01" => Self :: InstantCreditTransferNotTimeCritical , "INSTTC01" => Self :: InstantCreditTransferTimeCritical , "INSTIDEAL" => Self :: PaymentsViaInternetOwnedByCurrenceUsingInstantCreditTransfer , "INSTNT01IDEAL" => Self :: PaymentsViaInternetOwnedByCurrenceUsingInstantCreditTransferNotTimeCritical , "INSTTC01IDEAL" => Self :: PaymentsViaInternetOwnedByCurrenceUsingInstantCreditTransferTimeCritical , "NLDO" => Self :: DutchDomesticBulkPayment , "NLUP" => Self :: DutchUrgentPayment , "SDN" => Self :: PaymentsViaStandaardDigitaleNota , "ACCEPT" => Self :: PaymentViaAcceptgiroOwnedByCurrence , "ICMC" => Self :: IncidentManagementCorrection , "NLGOV" => Self :: DirectDebitInitiatedByTheGovernmentWithSpecialConditions , "0090" => Self :: MassPaymentBeneficiary , "0091" => Self :: MassPaymentOurs , "0092" => Self :: MassPaymentShared , "0002" => Self :: StandingOrder , "0221" => Self :: OneOffAuthorisation , "0224" => Self :: OneOffAuthorisationCharities , "0226" => Self :: OneOffAuthorisationConstructionIndustry , "0225" => Self :: OneOffAuthorisationTuitionFees , "0222" => Self :: StandingAuthorisationCompanies , "0227" => Self :: StandingAuthorisationCompaniesWithoutDebtorRevocationRight , "0220" => Self :: StandingAuthorisationGeneral , "0223" => Self :: StandingAuthorisationLotteries , "0001" => Self :: ConvertedBankPayment , "0000" => Self :: BusinessPayment , "IN" => Self :: CrossBorderCustomerCreditTransfer , "ONCL" => Self :: Overnight , "PERI" => Self :: PaymentWithEri , "SDCL" => Self :: SameDayClearedPayments , "DDNR" => Self :: CoreNoRefund , "DDFA" => Self :: DirectDebitFixedAmount , "CORE" => Self :: SepaDirectDebitCore , "B2BAMIPM" => Self :: Sepab2bDirectDebitAmi , "B2B" => Self :: SepaBusinessToBusinessDirectDebit , "CR1AMIPM" => Self :: SepaCoreD1DirectDebitAmi , "CORAMIPM" => Self :: SepaCoreDirectDebitAmi , "COR1" => Self :: SepaDirectDebit1DaySettlement , "FADAMIPM" => Self :: SepafaDirectDebitAmi , "CLSCCPERX" => Self :: ClsClearedFxForEurex , "CLSCCPLCH" => Self :: ClsClearedFxForLch , "INST" => Self :: InstantCreditTransfer , "ADD" => Self :: AuthenticatedDirectDebit , "UDD" => Self :: UnauthenticatedDirectDebit , "CCI" => Self :: CashConcentrationIntragroup , "BTR" => Self :: BankTransfer , "CKS" => Self :: CheckSameDaySettlementWire , "CTR" => Self :: CustomerTransfer , "CTP" => Self :: CustomerTransferPlus , "DEP" => Self :: DepositToSendersAccount , "FFR" => Self :: FedFundsReturned , "FFS" => Self :: FedFundsSold , "SVC" => Self :: NonValueServiceMessage , "DRW" => Self :: DrawdownResponseValueToHonorADrawdownRequest , "DRB" => Self :: BankToBankDrawdownRequestOrResponseNonvalue , "DRC" => Self :: CustomerOrCorporateDrawdownRequestOrResponseNonvalue , "IAT" => Self :: InternationalAch , "CCD" => Self :: CashConcentrationOrDisbursementCorporateCounterparty , "CTX" => Self :: CorporateTradeExchange , "PPD" => Self :: PrearrangedPaymentOrDepositConsumerCounterparty , "CIE" => Self :: CustomerInitiatedEntry , "RCK" => Self :: RepresentedCheckEntry , "ARC" => Self :: AccountsReceivableCheck , "WEB" => Self :: InternetInitiatedEntry , "POP" => Self :: PointOfPurchase , "POS" => Self :: PointOfSale , "TEL" => Self :: TelephoneInitiatedEntry , "CTP" => Self :: CreditTransferPreferred , "ITP" => Self :: InstantCreditTransferPreferred , tag => todo ! ("handle code {tag:?}") , } ;
Ok(value)
}
}
pub use self::external_code_sets::ExternalLocalInstrument1Code;
#[doc = "Specifies the category of card transaction in the format of character string with a maximum length of 4 characters.\r\nThe list of valid codes is an external code list published separately.\r\nExternal code sets can be downloaded from www.iso20022.org."]
pub enum ExternalCardTransactionCategory1Code {}
impl<'a> ExternalCardTransactionCategory1Code {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
tag => todo!("handle code {tag:?}"),
};
Ok(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum CardPaymentServiceType2Code {
#[doc = "Transfer of funds to and/or from a card account."]
CardsFundTransfer,
#[doc = "Original credit."]
OriginalCredit,
#[doc = "Card payment."]
CardPayment,
#[doc = "Card payment with cash-back."]
CashBack,
#[doc = "Cash advance or withdrawals on a POI (Point Of Interaction), or at a bank counter."]
CashAdvance,
#[doc = "Cash deposit."]
CashDeposit,
#[doc = "Deferred payment."]
DeferredPayment,
#[doc = "Reservation (pre-authorisation)."]
Reservation,
#[doc = "Loading or reloading non-financial account."]
Loading,
#[doc = "Refund transaction."]
Refund,
#[doc = "Quasi-cash."]
QuasiCash,
#[doc = "Balance enquiry."]
Balance,
#[doc = "Card activation."]
CardActivation,
#[doc = "Card verification."]
CardVerification,
#[doc = "PIN (Personal Identification Number) change."]
PinChange,
#[doc = "Card validity check."]
ValidityCheck,
#[doc = "Aggregation of low payments."]
Aggregation,
#[doc = "Dynamic currency conversion (DCC)."]
Dcc,
#[doc = "Card payment with gratuity."]
Gratuity,
#[doc = "Instalment payment."]
Instalment,
#[doc = "Loyalty services."]
Loyalty,
#[doc = "No show after reservation."]
NoShow,
#[doc = "Purchase and corporate data."]
PurchaseCorporate,
#[doc = "Recurring payment."]
RecurringPayment,
#[doc = "Solicited available funds."]
SolicitedAvailableFunds,
#[doc = "Unsolicited available funds."]
UnsolicitedAvailableFunds,
#[doc = "Voice authorisation."]
VoiceAuthorisation,
#[doc = "Initial reservation."]
InitialReservation,
#[doc = "Update reservation."]
UpdateReservation,
#[doc = "Payment after reservation."]
PaymentReservation,
#[doc = "Additional payment after reservation."]
AdditionalPayment,
#[doc = "Initial recurring payment."]
FirstRecurring,
#[doc = "Repeat recurring payment."]
FollowingRecurring,
#[doc = "Card payment transaction transfer from person to business."]
PersonToBusiness,
#[doc = "Card payment transaction transfer from person to person."]
PersonToPerson,
#[doc = "Instalment payment transaction performed by the acceptor or the acquirer."]
AcceptorInstalment,
#[doc = "Instalment payment transaction performed by the card issuer."]
IssuerInstalment,
#[doc = "Unloading non-financial account."]
Unloading,
#[doc = "Transfer of funds to a card or an account."]
CardsFundTransferPush,
#[doc = "Transfer of funds from a card or an account."]
CardsFundTransferPull,
#[doc = "Withdrawal of cash on an ATM."]
CashWithdrawal,
#[doc = "Unblock the cardholder PIN."]
PinUnblock,
#[doc = "Amount and notes values are chosen by the customer."]
ChosenWithdrawal,
#[doc = "Withdrawal transaction was pre-authorised by another channel (amount could be absent)."]
PreAuthorisedWithdrawal,
#[doc = "Amount and Notes Values are pre-defined by the customer profile."]
ProfileWithdrawal,
#[doc = "Customer pressed a button associated with a withdrawal of unique amount and notes mix."]
StandardWithdrawal,
#[doc = "Transfer for payment of bills."]
TransferCardBillPayment,
#[doc = "Transfer from cash deposit."]
TransferFromCash,
#[doc = "Transfer from cheque deposit."]
TransferFromCheque,
#[doc = "Transfer for general disbursement."]
TransferFundsDisbursementGeneral,
#[doc = "Transfer for government disbursement."]
TransferGovernmentDisbursement,
#[doc = "Transfer for merchant disbursement."]
TransferMerchantDisbursement,
#[doc = "Transfer for payroll pension disbursement."]
TransferPayrollPensionDisbursement,
#[doc = "Payment of goods or services which are not refundable, for instance low cost airline tickets."]
NonRefundable,
#[doc = "Instant transaction."]
Instant,
#[doc = "Credit adjustment to a previous transaction."]
CreditAdjustement,
#[doc = "Debit adjustment to a previous transaction."]
DebitAdjustement,
#[doc = "Creation of an X.509 certificate with the public key and the information of the owner of the asymmetric key provided by the requestor."]
CreateCertificate,
#[doc = "Renewal of an X.509 certificate, protected by the certificate to renew."]
RenewCerificate,
#[doc = "Revocation of an active X.509 certificate."]
RevokeCertificate,
#[doc = "Add a POI in the white list of the terminal manager."]
AddWhiteList,
#[doc = "Remove a POI from the white list of the terminal manager."]
RemoveWhiteList,
#[doc = "Direct Debit initiated by Card."]
CardInitiatingDirectDebit,
#[doc = "Acceptor claims for guarantee of payment."]
GuaranteeOfPayment,
}
impl<'a> CardPaymentServiceType2Code {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"CAFT" => Self::CardsFundTransfer,
"ORCR" => Self::OriginalCredit,
"CRDP" => Self::CardPayment,
"CSHB" => Self::CashBack,
"CSHW" => Self::CashAdvance,
"CSHD" => Self::CashDeposit,
"DEFR" => Self::DeferredPayment,
"RESA" => Self::Reservation,
"LOAD" => Self::Loading,
"RFND" => Self::Refund,
"QUCH" => Self::QuasiCash,
"BALC" => Self::Balance,
"CACT" => Self::CardActivation,
"CAVR" => Self::CardVerification,
"PINC" => Self::PinChange,
"VALC" => Self::ValidityCheck,
"AGGR" => Self::Aggregation,
"DCCV" => Self::Dcc,
"GRTT" => Self::Gratuity,
"INSP" => Self::Instalment,
"LOYT" => Self::Loyalty,
"NRES" => Self::NoShow,
"PUCO" => Self::PurchaseCorporate,
"RECP" => Self::RecurringPayment,
"SOAF" => Self::SolicitedAvailableFunds,
"UNAF" => Self::UnsolicitedAvailableFunds,
"VCAU" => Self::VoiceAuthorisation,
"IRES" => Self::InitialReservation,
"URES" => Self::UpdateReservation,
"PRES" => Self::PaymentReservation,
"ARES" => Self::AdditionalPayment,
"FREC" => Self::FirstRecurring,
"RREC" => Self::FollowingRecurring,
"TP2B" => Self::PersonToBusiness,
"TP2P" => Self::PersonToPerson,
"INSA" => Self::AcceptorInstalment,
"INSI" => Self::IssuerInstalment,
"UNLD" => Self::Unloading,
"CAFH" => Self::CardsFundTransferPush,
"CAFL" => Self::CardsFundTransferPull,
"CHWD" => Self::CashWithdrawal,
"PINU" => Self::PinUnblock,
"CSWD" => Self::ChosenWithdrawal,
"AUWS" => Self::PreAuthorisedWithdrawal,
"PFWD" => Self::ProfileWithdrawal,
"SDWD" => Self::StandardWithdrawal,
"TFBL" => Self::TransferCardBillPayment,
"TFCS" => Self::TransferFromCash,
"TFCH" => Self::TransferFromCheque,
"TFDB" => Self::TransferFundsDisbursementGeneral,
"TFGD" => Self::TransferGovernmentDisbursement,
"TFMD" => Self::TransferMerchantDisbursement,
"TFPD" => Self::TransferPayrollPensionDisbursement,
"NRFD" => Self::NonRefundable,
"INST" => Self::Instant,
"CADJ" => Self::CreditAdjustement,
"DADJ" => Self::DebitAdjustement,
"CRTC" => Self::CreateCertificate,
"CRTR" => Self::RenewCerificate,
"CRTK" => Self::RevokeCertificate,
"WLSA" => Self::AddWhiteList,
"WLSR" => Self::RemoveWhiteList,
"CIDD" => Self::CardInitiatingDirectDebit,
"GOPT" => Self::GuaranteeOfPayment,
tag => todo!("handle code {tag:?}"),
};
Ok(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Service provided by a card payment transaction."]
pub enum PoiComponentType1Code {
#[doc = "Payment or other software application."]
Soft,
#[doc = "EMV application kernel (EMV is the chip card specifications initially defined by Eurocard, Mastercard and Visa)."]
EmvKernel,
#[doc = "EMV physical interface (EMV is the chip card specifications initially defined by Eurocard, Mastercard and Visa)."]
EmvLevel1,
#[doc = "Merchant interface."]
MerchantInterface,
#[doc = "Cardholder Interface."]
CardholderInterface,
#[doc = "Security module."]
SecureModule,
#[doc = "Personal identification number (or PIN) entry device (PED)."]
PinEntryDevice,
#[doc = "Acquirer specific configuration parameters for the point of interaction (POI) system."]
AcquirerParameters,
#[doc = "Merchant configuration parameters for the point of interaction (POI)."]
MerchantParameters,
#[doc = "Point of interaction parameters defined by the manufacturer for instance the PIN verification capabilities."]
VendorParameters,
#[doc = "Parameters for acquirer interface of the point of interaction, including acquirer host configuration parameters."]
AcquirerProtocolParameters,
#[doc = "Parameters of a payment application running on the point of interaction."]
ApplicationParameters,
#[doc = "Device sub-component of a component of the point of interaction."]
Device,
#[doc = "Driver module of the point of interaction."]
Driver,
#[doc = "Software module of the point of interaction."]
Middleware,
#[doc = "Software that manages hardware to provide common services to the applications."]
OperatingSystem,
#[doc = "Payment application software."]
PaymentApplication,
#[doc = "Security parameters of the point of interaction."]
SecurityParameters,
#[doc = "Payment server of a point of interaction system."]
Server,
#[doc = "Payment terminal point of interaction."]
Terminal,
#[doc = "Manufacturer configuration parameters of the point of interaction."]
TerminalParameters,
#[doc = "Certificate provided by a terminal manager."]
CertificateParameters,
#[doc = "Configuration parameters for the TMS protocol."]
TmsProtocolParameters,
#[doc = "Parameters related to the Sale to POI protocol."]
SaleToPoiProtocolParameters,
#[doc = "Component of the Sale system."]
SaleComponent,
#[doc = "Any repository used for recording log traces."]
LogFile,
#[doc = "Media file managed by an application of the POI."]
MediaFile,
#[doc = "Configuration file relevant for the POI."]
ConfigurationFile,
#[doc = "Report file generated by the POI."]
ReportFile,
}
impl<'a> PoiComponentType1Code {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"SOFT" => Self::Soft,
"EMVK" => Self::EmvKernel,
"EMVO" => Self::EmvLevel1,
"MRIT" => Self::MerchantInterface,
"CHIT" => Self::CardholderInterface,
"SECM" => Self::SecureModule,
"PEDV" => Self::PinEntryDevice,
"AQPR" => Self::AcquirerParameters,
"MRPR" => Self::MerchantParameters,
"VDPR" => Self::VendorParameters,
"AQPP" => Self::AcquirerProtocolParameters,
"APPR" => Self::ApplicationParameters,
"DVCE" => Self::Device,
"DRVR" => Self::Driver,
"MDWR" => Self::Middleware,
"OPST" => Self::OperatingSystem,
"APLI" => Self::PaymentApplication,
"SCPR" => Self::SecurityParameters,
"SERV" => Self::Server,
"TERM" => Self::Terminal,
"TLPR" => Self::TerminalParameters,
"CRTF" => Self::CertificateParameters,
"TMSP" => Self::TmsProtocolParameters,
"SAPR" => Self::SaleToPoiProtocolParameters,
"SACP" => Self::SaleComponent,
"LOGF" => Self::LogFile,
"MDFL" => Self::MediaFile,
"CONF" => Self::ConfigurationFile,
"RPFL" => Self::ReportFile,
tag => todo!("handle code {tag:?}"),
};
Ok(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Generic component type belonging to a POI (Point of Interaction) Terminal."]
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Type of user interface to display or print information."]
pub enum UserInterface2Code {
#[doc = "Cardholder display or interface."]
CardholderDisplay,
#[doc = "Cardholder receipt."]
CardholderReceipt,
#[doc = "Merchant display or interface."]
MerchantDisplay,
#[doc = "Merchant receipt."]
MerchantReceipt,
#[doc = "Acquirer."]
Acquirer,
#[doc = "Issuer."]
Issuer,
#[doc = "Agent."]
Agent,
#[doc = "Other interface of the cardholder, for instance e-mail or smartphone message."]
OtherCardholderInterface,
#[doc = "Information dedicated to a software application related to a device belonging to the cardholder."]
CardholderApplication,
#[doc = "Data dedicated to an application maintained by a clearing agent."]
ClearingAgentApplication,
#[doc = "Data dedicated to a log maintained by the clearing agent."]
ClearingAgentLog,
#[doc = "Interface used in case of disputes or chargebacks."]
Dispute,
#[doc = "File used to store the message."]
File,
#[doc = "Information dedicated to a log file."]
Log,
#[doc = "Information dedicated to a software application related to a device belonging to the merchant."]
MerchantApplication,
#[doc = "Other type of acquirer interface."]
OtherAcquirerInterface,
#[doc = "Data dedicated to another interface maintained by the clearing agent."]
OtherClearingAgentInterface,
#[doc = "Other type of issuer interface."]
OtherIssuerInterface,
#[doc = "Other interface of the merchant for instance e-mail or smartphone message."]
OtherMerchantInterface,
#[doc = "Other type of interface defined at national level."]
OtherNational,
#[doc = "Other type of interface defined at private level."]
OtherPrivate,
#[doc = "Other settlement agent interface."]
OtherSettlementAgentInterface,
#[doc = "Settlement agent interface."]
SettlementAgent,
#[doc = "Credit information related to a top-up account."]
TopUpCredit,
}
impl<'a> UserInterface2Code {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"CDSP" => Self::CardholderDisplay,
"CRCP" => Self::CardholderReceipt,
"MDSP" => Self::MerchantDisplay,
"MRCP" => Self::MerchantReceipt,
"ACQU" => Self::Acquirer,
"ISSR" => Self::Issuer,
"AGNT" => Self::Agent,
"CRDO" => Self::OtherCardholderInterface,
"CHAP" => Self::CardholderApplication,
"CLRA" => Self::ClearingAgentApplication,
"CLRL" => Self::ClearingAgentLog,
"DSPU" => Self::Dispute,
"FILE" => Self::File,
"LOGF" => Self::Log,
"MRAP" => Self::MerchantApplication,
"OTAI" => Self::OtherAcquirerInterface,
"OCAI" => Self::OtherClearingAgentInterface,
"OTII" => Self::OtherIssuerInterface,
"MRIN" => Self::OtherMerchantInterface,
"OTHN" => Self::OtherNational,
"OTHP" => Self::OtherPrivate,
"OSAI" => Self::OtherSettlementAgentInterface,
"STLI" => Self::SettlementAgent,
"TUCR" => Self::TopUpCredit,
tag => todo!("handle code {tag:?}"),
};
Ok(value)
pub enum OnLineCapability1Code {
#[doc = "Off-line only capable."]
OffLine,
#[doc = "On-line only capable."]
OnLine,
#[doc = "Off-line capable with possible on-line requests to the acquirer."]
SemiOffLine,
#[doc = "Both online and offline"]
BothOnLineAndOffLine,
}
impl<'a> OnLineCapability1Code {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"OFLN" => Self::OffLine,
"ONLN" => Self::OnLine,
"SMON" => Self::SemiOffLine,
"BOTH" => Self::BothOnLineAndOffLine,
tag => todo!("handle code {tag:?}"),
};
Ok(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "On-line and off-line capabilities of the POI (Point Of Interaction)."]
tag => todo!("handle code {tag:?}"),
};
Ok(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Cardholder verification capabilities of the POI (Personal Identification Number) performing the transaction."]
pub enum CardholderVerificationCapability1Code {
#[doc = "Manual signature verification."]
ManualSignature,
#[doc = "Online PIN (Personal Identification Number)."]
OnLinePin,
#[doc = "Offline PIN in clear (Personal Identification Number)."]
OfflinePinClear,
#[doc = "Offline PIN encrypted (Personal Identification Number)."]
OfflinePinEncrypted,
#[doc = "Offline digital signature analysis."]
OfflineDigitalSignature,
#[doc = "Offline biometrics."]
OfflineBiometrics,
#[doc = "Other manual verification, for example passport or drivers license."]
ManualVerification,
#[doc = "Offline biographics."]
OfflineBiographics,
#[doc = "Account based digital signature."]
AccountDigitalSignature,
#[doc = "PKI (Public Key Infrastructure) based digital signature."]
PkiSignature,
#[doc = "Cardholder authentication data."]
CardholderData,
#[doc = "Three domain secure (three domain secure authentication of the cardholder)."]
SecureElectronicCommerce,
#[doc = "Unknown cardholder verification capability."]
Unknown,
#[doc = "Personal code of the customer for banking services."]
PersonalCode,
#[doc = "No cardholder verification capability."]
NoCapabilities,
#[doc = "Online biometrics."]
OnLineBiometrics,
#[doc = "Other cardholder verification capabilities."]
Other,
#[doc = "Other type of cardholder verification defined at national level"]
OtherNational,
#[doc = "Other type of cardholder verification defined in a private manner."]
OtherPrivate,
#[doc = "Handwritten signature verification"]
Signature,
#[doc = "Cardholder verification capability unspecified."]
Unspecified,
#[doc = "Recognition by voice."]
VoiceRecognition,
#[doc = "Device has no pin entry capability."]
NoPinEntry,
#[doc = "Device has no online pin entry capability."]
NoOnLinePinEntry,
}
impl<'a> CardholderVerificationCapability1Code {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"MNSG" => Self::ManualSignature,
"NPIN" => Self::OnLinePin,
"FCPN" => Self::OfflinePinClear,
"FEPN" => Self::OfflinePinEncrypted,
"FDSG" => Self::OfflineDigitalSignature,
"FBIO" => Self::OfflineBiometrics,
"MNVR" => Self::ManualVerification,
"FBIG" => Self::OfflineBiographics,
"APKI" => Self::AccountDigitalSignature,
"PKIS" => Self::PkiSignature,
"CHDT" => Self::CardholderData,
"SCEC" => Self::SecureElectronicCommerce,
"UNKW" => Self::Unknown,
"PCOD" => Self::PersonalCode,
"NOVF" => Self::NoCapabilities,
"NBIO" => Self::OnLineBiometrics,
"OTHR" => Self::Other,
"OTHN" => Self::OtherNational,
"OTHP" => Self::OtherPrivate,
"SIGN" => Self::Signature,
"UNSP" => Self::Unspecified,
"VORN" => Self::VoiceRecognition,
"NOPN" => Self::NoPinEntry,
"NOOP" => Self::NoOnLinePinEntry,
tag => todo!("handle code {tag:?}"),
};
Ok(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Type of reading of the card data."]
pub enum CardDataReading1Code {
#[doc = "Tag reading capabilities (RFID, etc.)."]
Tag,
#[doc = "Keyboard entry or OCR reading of embossing or printed data, either at time of transaction or after the event."]
Physical,
#[doc = "Bar code."]
BarCode,
#[doc = "Magnetic stripe."]
MagneticStripe,
#[doc = "ICC (Integrated Circuit Card) with contact containing software applications conform to ISO 7816."]
Icc,
#[doc = "Account data on file."]
AccountData,
#[doc = "Contactless proximity reader."]
ProximityReader,
#[doc = "Contactless proximity reader, with application conform to the standard EMV (standard initiated by Europay, Mastercard and Visa)."]
EmvProximityReader,
#[doc = "Card information are stored on a file."]
CardOnFile,
#[doc = "Unknown card reading capability."]
Unknown,
#[doc = "Synchronous ICC - (Integrated Circuit Card) with contact."]
SynchronousIntegratedCircuitCard,
#[doc = "ICC contact capability"]
IccContact,
#[doc = "ICC contactless proximity"]
IccProximity,
#[doc = "Recognition of magnetic ink characters"]
MagneticInkCharacterRecognition,
#[doc = "Manual, no terminal used."]
ManualEntry,
#[doc = "Magstripe image contactless proximity"]
MsiProximity,
#[doc = "OCR either at time of transaction or after the event."]
OpticalCharacterRecognition,
#[doc = "Optical coded reading capabilities (e.g. barcode, QR code, etc.)"]
OpticalCode,
#[doc = "Other national capability type assigned at national level."]
OtherNational,
#[doc = "Other card reading capability assigned on a private basis."]
OtherPrivate,
#[doc = "Radio Frequency Identification tag capabilities."]
RfidTag,
#[doc = "Unspecified capability."]
Unspecified,
#[doc = "Key entered."]
KeyEntered,
#[doc = "Quick response code."]
QrCode,
}
impl<'a> CardDataReading1Code {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"TAGC" => Self::Tag,
"PHYS" => Self::Physical,
"BRCD" => Self::BarCode,
"MGST" => Self::MagneticStripe,
"CICC" => Self::Icc,
"DFLE" => Self::AccountData,
"CTLS" => Self::ProximityReader,
"ECTL" => Self::EmvProximityReader,
"CDFL" => Self::CardOnFile,
"UNKW" => Self::Unknown,
"SICC" => Self::SynchronousIntegratedCircuitCard,
"ICCY" => Self::IccContact,
"ICPY" => Self::IccProximity,
"MICR" => Self::MagneticInkCharacterRecognition,
"MLEY" => Self::ManualEntry,
"MSIP" => Self::MsiProximity,
"OCRR" => Self::OpticalCharacterRecognition,
"OPTC" => Self::OpticalCode,
"OTHN" => Self::OtherNational,
"OTHP" => Self::OtherPrivate,
"RFID" => Self::RfidTag,
"UNSP" => Self::Unspecified,
"KEEN" => Self::KeyEntered,
"QRCD" => Self::QrCode,
pub enum PartyType4Code {
#[doc = "Party selling goods and services."]
SaleSystem,
#[doc = "Party component of a POI system or POI terminal (Point of Interaction)."]
PoiComponent,
#[doc = "Issuer is the entitled party."]
Issuer,
#[doc = "Holder is the entitled party."]
Holder,
#[doc = "Party, either an individual or organisation, whose assets are being invested."]
Investor,
#[doc = "Party that identifies an executing / give-up broker."]
ExecutingFirm,
#[doc = "Party that receives the trade credit."]
BrokerOfCredit,
#[doc = "Party that is going to carry the position on their books at another clearinghouse (exchanges)."]
CorrespondentClearingFirm,
#[doc = "Party that is the counterparty in a trade."]
ContraFirm,
#[doc = "Party that is the clearing firm of the counterparty in a trade."]
ContraClearingFirm,
#[doc = "Party (broker or other firm), which is the contra side of the trade for the underlying security."]
UnderlyingContraFirm,
#[doc = "Party to which the trade is given up (carries the position that results from a trade)."]
GiveUpClearingFirm,
#[doc = "Party that originates an order."]
OrderOriginationFirm,
#[doc = "Party (member of an exchange)that is sponsoring an entering firm to send orders directly to the exchange."]
SponsoringFirm,
#[doc = "Party (broker) that settles security transactions from another broker for a fee = take up broker."]
Clearingfirm,
#[doc = "Party that can relay an order directly to the trading floor, or give clients direct access to the floor. The introducing firm delegates the work of the floor operation, trade execution and accounting."]
IntroducingFirm,
#[doc = "Party that has recorded or reported an execution of a trade. When an entering firm that is not a party to a trade enters the trade into a trade recording system, any inquiries can be directed to the appropriate source."]
EnteringFirm,
#[doc = "A client is identified in third party-transactions or for investor in intermediary transactions."]
Client,
#[doc = "Broker to which the investment manager directs the execution of a portion of the trade."]
StepInBroker,
#[doc = "Party (buyer or seller) that positively affirms the details of a previously agreed security trade confirmation."]
AffirmingParty,
#[doc = "Party acting as the Electronic Trade Confirmation (ETC) service provider 1."]
EtcServiceProvider1,
#[doc = "Party acting as the Electronic Trade Confirmation (ETC) service provider 2."]
EtcServiceProvider2,
#[doc = "In a directed order, broker with which the Receiver of the message is requested to execute the order."]
RequestedBroker,
#[doc = "Tax authority."]
TaxAuthority,
#[doc = "Party to whom the card issuer delegates to authorise card payment transactions."]
DelegateIssuer,
#[doc = "Point Of Interaction initiating the card payment transaction."]
OriginatingPoi,
#[doc = "Party that issues cards."]
CardIssuer,
#[doc = "Card acceptor, party accepting the card and presenting transaction data to the acquirer."]
Acceptor,
#[doc = "Merchant providing goods and service in the card payment transaction."]
Merchant,
#[doc = "Entity acquiring card transactions."]
Acquirer,
#[doc = "Party acting on behalf of other parties to process or forward data to other parties."]
IntermediaryAgent,
#[doc = "Responsible for the maintenance of a card payment acceptance terminal."]
MasterTerminalManager,
#[doc = "Responsible for one or several maintenance functions of a card payment acceptance terminal."]
TerminalManager,
#[doc = "Entity providing acquiring card payment processing services on behalf on an acquirer."]
AcquirerProcessor,
#[doc = "Entity providing issuing card payment processing services on behalf on an issuer."]
CardIssuerProcessor,
#[doc = "Entity defining rules and procedures for card payment transactions acting as an intermediary between an acquirer and an issuer."]
CardScheme,
#[doc = "Entity providing card payment processing services acting on behalf of a card scheme."]
CardSchemeProcessor,
#[doc = "Entity managing the ATM."]
AtmManager,
#[doc = "Entity hosting the ATM."]
HostingEntity,
#[doc = "ATM initiating the transaction."]
OriginatingAtm,
#[doc = "Application on the terminal which has initiated the transaction."]
OriginatingTerminal,
#[doc = "Application in the smart card."]
CardApplication,
#[doc = "Configuration to apply to the whole POI system."]
PoiSystem,
#[doc = "Configuration to apply to a subset of the whole POI system."]
PoiGroup,
#[doc = "Configuration to apply to a single POI terminal."]
SinglePoi,
#[doc = "The bank of the source account."]
AccountFromBank,
#[doc = "The bank of the destination account."]
AccountToBank,
#[doc = "Entity providing card payment processing services acting as an intermediary between an acquirer and an issuer."]
Agent,
#[doc = "Holder of a payment card."]
Cardholder,
#[doc = "Agent in charge of clearing payment or related transactions."]
ClearingAgent,
#[doc = "Government organisation investigation unit. "]
GovernmentInvestigationUnit,
#[doc = "Other card payment entity type defined at national level"]
OtherNational,
#[doc = "Other card payment entity type defined at private level"]
OtherPrivate,
#[doc = "Payment Initiation Service Provider (PISP)"]
PaymentInitiationServiceProvider,
#[doc = "Entity provding payments services."]
PaymentServiceProvider,
#[doc = "Party in charge of controlling or supervising a card acceptance Point of Interaction"]
PointOfInteraction,
#[doc = "Agent in charge of the settlement of a payment or related transaction."]
SettlementAgent,
#[doc = "Provider of an electronic wallet"]
WalletProvider,
}
impl<'a> PartyType4Code {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"SALE" => Self::SaleSystem,
"PCPT" => Self::PoiComponent,
"ISUR" => Self::Issuer,
"HLDR" => Self::Holder,
"INVE" => Self::Investor,
"EXEC" => Self::ExecutingFirm,
"BROK" => Self::BrokerOfCredit,
"CORR" => Self::CorrespondentClearingFirm,
"COFI" => Self::ContraFirm,
"COCL" => Self::ContraClearingFirm,
"UNDE" => Self::UnderlyingContraFirm,
"GIVE" => Self::GiveUpClearingFirm,
"ORDE" => Self::OrderOriginationFirm,
"SPON" => Self::SponsoringFirm,
"CLEA" => Self::Clearingfirm,
"INTR" => Self::IntroducingFirm,
"ENTE" => Self::EnteringFirm,
"CLIE" => Self::Client,
"STEP" => Self::StepInBroker,
"AFFI" => Self::AffirmingParty,
"ETC1" => Self::EtcServiceProvider1,
"ETC2" => Self::EtcServiceProvider2,
"RQBR" => Self::RequestedBroker,
"TAXH" => Self::TaxAuthority,
"DLIS" => Self::DelegateIssuer,
"OPOI" => Self::OriginatingPoi,
"CISS" => Self::CardIssuer,
"ACCP" => Self::Acceptor,
"MERC" => Self::Merchant,
"ACQR" => Self::Acquirer,
"ITAG" => Self::IntermediaryAgent,
"MTMG" => Self::MasterTerminalManager,
"TMGT" => Self::TerminalManager,
"ACQP" => Self::AcquirerProcessor,
"CISP" => Self::CardIssuerProcessor,
"CSCH" => Self::CardScheme,
"SCHP" => Self::CardSchemeProcessor,
"ATMG" => Self::AtmManager,
"HSTG" => Self::HostingEntity,
"OATM" => Self::OriginatingAtm,
"OTRM" => Self::OriginatingTerminal,
"ICCA" => Self::CardApplication,
"PSYS" => Self::PoiSystem,
"PGRP" => Self::PoiGroup,
"PSNG" => Self::SinglePoi,
"BKAF" => Self::AccountFromBank,
"BKAT" => Self::AccountToBank,
"AGNT" => Self::Agent,
"CRDH" => Self::Cardholder,
"CLRA" => Self::ClearingAgent,
"GVIU" => Self::GovernmentInvestigationUnit,
"OTHN" => Self::OtherNational,
"OTHP" => Self::OtherPrivate,
"PISP" => Self::PaymentInitiationServiceProvider,
"PASP" => Self::PaymentServiceProvider,
"POOI" => Self::PointOfInteraction,
"SETA" => Self::SettlementAgent,
"WLPR" => Self::WalletProvider,
tag => todo!("handle code {tag:?}"),
};
Ok(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Specifies the entitled party."]
pub enum PartyType3Code {
#[doc = "Party selling goods and services."]
SaleSystem,
#[doc = "Party component of a POI system or POI terminal (Point of Interaction)."]
PoiComponent,
#[doc = "Issuer is the entitled party."]
Issuer,
#[doc = "Holder is the entitled party."]
Holder,
#[doc = "Party, either an individual or organisation, whose assets are being invested."]
Investor,
#[doc = "Party that identifies an executing / give-up broker."]
ExecutingFirm,
#[doc = "Party that receives the trade credit."]
BrokerOfCredit,
#[doc = "Party that is going to carry the position on their books at another clearinghouse (exchanges)."]
CorrespondentClearingFirm,
#[doc = "Party that is the counterparty in a trade."]
ContraFirm,
#[doc = "Party that is the clearing firm of the counterparty in a trade."]
ContraClearingFirm,
#[doc = "Party (broker or other firm), which is the contra side of the trade for the underlying security."]
UnderlyingContraFirm,
#[doc = "Party to which the trade is given up (carries the position that results from a trade)."]
GiveUpClearingFirm,
#[doc = "Party that originates an order."]
OrderOriginationFirm,
#[doc = "Party (member of an exchange)that is sponsoring an entering firm to send orders directly to the exchange."]
SponsoringFirm,
#[doc = "Party (broker) that settles security transactions from another broker for a fee = take up broker."]
Clearingfirm,
#[doc = "Party that can relay an order directly to the trading floor, or give clients direct access to the floor. The introducing firm delegates the work of the floor operation, trade execution and accounting."]
IntroducingFirm,
#[doc = "Party that has recorded or reported an execution of a trade. When an entering firm that is not a party to a trade enters the trade into a trade recording system, any inquiries can be directed to the appropriate source."]
EnteringFirm,
#[doc = "A client is identified in third party-transactions or for investor in intermediary transactions."]
Client,
#[doc = "Broker to which the investment manager directs the execution of a portion of the trade."]
StepInBroker,
#[doc = "Party (buyer or seller) that positively affirms the details of a previously agreed security trade confirmation."]
AffirmingParty,
#[doc = "Party acting as the Electronic Trade Confirmation (ETC) service provider 1."]
EtcServiceProvider1,
#[doc = "Party acting as the Electronic Trade Confirmation (ETC) service provider 2."]
EtcServiceProvider2,
#[doc = "In a directed order, broker with which the Receiver of the message is requested to execute the order."]
RequestedBroker,
#[doc = "Tax authority."]
TaxAuthority,
#[doc = "Party to whom the card issuer delegates to authorise card payment transactions."]
DelegateIssuer,
#[doc = "Point Of Interaction initiating the card payment transaction."]
OriginatingPoi,
#[doc = "Party that issues cards."]
CardIssuer,
#[doc = "Card acceptor, party accepting the card and presenting transaction data to the acquirer."]
Acceptor,
#[doc = "Merchant providing goods and service in the card payment transaction."]
Merchant,
#[doc = "Entity acquiring card transactions."]
Acquirer,
#[doc = "Party acting on behalf of other parties to process or forward data to other parties."]
IntermediaryAgent,
#[doc = "Responsible for the maintenance of a card payment acceptance terminal."]
MasterTerminalManager,
#[doc = "Responsible for one or several maintenance functions of a card payment acceptance terminal."]
TerminalManager,
#[doc = "Entity providing acquiring card payment processing services on behalf on an acquirer."]
AcquirerProcessor,
#[doc = "Entity providing issuing card payment processing services on behalf on an issuer."]
CardIssuerProcessor,
#[doc = "Entity defining rules and procedures for card payment transactions acting as an intermediary between an acquirer and an issuer."]
CardScheme,
#[doc = "Entity providing card payment processing services acting on behalf of a card scheme."]
CardSchemeProcessor,
#[doc = "Entity managing the ATM."]
AtmManager,
#[doc = "Entity hosting the ATM."]
HostingEntity,
#[doc = "ATM initiating the transaction."]
OriginatingAtm,
#[doc = "Application on the terminal which has initiated the transaction."]
OriginatingTerminal,
#[doc = "Application in the smart card."]
CardApplication,
#[doc = "Configuration to apply to the whole POI system."]
PoiSystem,
#[doc = "Configuration to apply to a subset of the whole POI system."]
PoiGroup,
#[doc = "Configuration to apply to a single POI terminal."]
SinglePoi,
#[doc = "The bank of the source account."]
AccountFromBank,
#[doc = "The bank of the destination account."]
AccountToBank,
#[doc = "Entity providing card payment processing services acting as an intermediary between an acquirer and an issuer."]
Agent,
#[doc = "Holder of a payment card."]
Cardholder,
#[doc = "Agent in charge of clearing payment or related transactions."]
ClearingAgent,
#[doc = "Government organisation investigation unit. "]
GovernmentInvestigationUnit,
#[doc = "Other card payment entity type defined at national level"]
OtherNational,
#[doc = "Other card payment entity type defined at private level"]
OtherPrivate,
#[doc = "Payment Initiation Service Provider (PISP)"]
PaymentInitiationServiceProvider,
#[doc = "Entity provding payments services."]
PaymentServiceProvider,
#[doc = "Party in charge of controlling or supervising a card acceptance Point of Interaction"]
PointOfInteraction,
#[doc = "Agent in charge of the settlement of a payment or related transaction."]
SettlementAgent,
#[doc = "Provider of an electronic wallet"]
WalletProvider,
}
impl<'a> PartyType3Code {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"SALE" => Self::SaleSystem,
"PCPT" => Self::PoiComponent,
"ISUR" => Self::Issuer,
"HLDR" => Self::Holder,
"INVE" => Self::Investor,
"EXEC" => Self::ExecutingFirm,
"BROK" => Self::BrokerOfCredit,
"CORR" => Self::CorrespondentClearingFirm,
"COFI" => Self::ContraFirm,
"COCL" => Self::ContraClearingFirm,
"UNDE" => Self::UnderlyingContraFirm,
"GIVE" => Self::GiveUpClearingFirm,
"ORDE" => Self::OrderOriginationFirm,
"SPON" => Self::SponsoringFirm,
"CLEA" => Self::Clearingfirm,
"INTR" => Self::IntroducingFirm,
"ENTE" => Self::EnteringFirm,
"CLIE" => Self::Client,
"STEP" => Self::StepInBroker,
"AFFI" => Self::AffirmingParty,
"ETC1" => Self::EtcServiceProvider1,
"ETC2" => Self::EtcServiceProvider2,
"RQBR" => Self::RequestedBroker,
"TAXH" => Self::TaxAuthority,
"DLIS" => Self::DelegateIssuer,
"OPOI" => Self::OriginatingPoi,
"CISS" => Self::CardIssuer,
"ACCP" => Self::Acceptor,
"MERC" => Self::Merchant,
"ACQR" => Self::Acquirer,
"ITAG" => Self::IntermediaryAgent,
"MTMG" => Self::MasterTerminalManager,
"TMGT" => Self::TerminalManager,
"ACQP" => Self::AcquirerProcessor,
"CISP" => Self::CardIssuerProcessor,
"CSCH" => Self::CardScheme,
"SCHP" => Self::CardSchemeProcessor,
"ATMG" => Self::AtmManager,
"HSTG" => Self::HostingEntity,
"OATM" => Self::OriginatingAtm,
"OTRM" => Self::OriginatingTerminal,
"ICCA" => Self::CardApplication,
"PSYS" => Self::PoiSystem,
"PGRP" => Self::PoiGroup,
"PSNG" => Self::SinglePoi,
"BKAF" => Self::AccountFromBank,
"BKAT" => Self::AccountToBank,
"AGNT" => Self::Agent,
"CRDH" => Self::Cardholder,
"CLRA" => Self::ClearingAgent,
"GVIU" => Self::GovernmentInvestigationUnit,
"OTHN" => Self::OtherNational,
"OTHP" => Self::OtherPrivate,
"PISP" => Self::PaymentInitiationServiceProvider,
"PASP" => Self::PaymentServiceProvider,
"POOI" => Self::PointOfInteraction,
"SETA" => Self::SettlementAgent,
"WLPR" => Self::WalletProvider,
tag => todo!("handle code {tag:?}"),
};
Ok(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Specifies the entitled party."]
pub enum CscManagement1Code {
#[doc = "Card security code present."]
CscPresent,
#[doc = "Card security code by-passed or not provided by the merchant."]
CscByPass,
#[doc = "Card security code unreadable."]
CscUnread,
#[doc = "No card security code imprint."]
NoCsc,
}
impl<'a> CscManagement1Code {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"PRST" => Self::CscPresent,
"BYPS" => Self::CscByPass,
"UNRD" => Self::CscUnread,
"NCSC" => Self::NoCsc,
tag => todo!("handle code {tag:?}"),
};
Ok(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "CSC (Card Security Code) management associated with the transaction."]
};
Ok(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Specifies the nature, or use, of the charges in the format of character string with a maximum length of 4 characters.\r\nThe list of valid codes is an external code list published separately.\r\nExternal code sets can be downloaded from www.iso20022.org.\n*`BRKF`-Fee paid to a broker for services provided.\n*`BTCH`-Fee paid for processing a batch of transactions.\n*`COMM`-Fee paid for services provided.\n*`SUMM`-Summation of individual fees."]
pub enum ExternalChargeType1Code {
Brkf,
Btch,
Comm,
Summ,
}
impl<'a> ExternalChargeType1Code {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"BRKF" => Self::Brkf,
"BTCH" => Self::Btch,
"COMM" => Self::Comm,
"SUMM" => Self::Summ,
tag => todo!("handle code {tag:?}"),
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Specifies the nature, or use, of the charges in the format of character string with a maximum length of 4 characters.\r\nThe list of valid codes is an external code set published separately.\r\nExternal code sets can be downloaded from www.iso20022.org."]
pub enum ExternalChargeTypeCode {
#[doc = "Fee paid to a broker for services provided."]
BrokerageFee,
#[doc = "Fee paid for processing a batch of transactions."]
Batch,
#[doc = "Fee paid for services provided."]
Commission,
#[doc = "Summation of individual fees."]
Summation,
}
impl<'a> ExternalChargeTypeCode {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"BRKF" => Self::BrokerageFee,
"BTCH" => Self::Batch,
"COMM" => Self::Commission,
"SUMM" => Self::Summation,
tag => todo!("handle code {tag:?}"),
};
Ok(value)
}
}
pub use self::external_code_sets::ExternalChargeType1Code;
};
Ok(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Specifies the status of an entry on the books of the account servicer, as published in an external code set.\r\nExternal code sets can be downloaded from www.iso20022.org.\n*`BOOK`-Booked means that the transfer of money has been completed between account servicer and account owner.\nUsage: Status Booked does not necessarily imply finality of money as this depends on other factors such as the payment system used, the completion of the end-to-end transaction and the terms agreed between account servicer and owner.\nStatus Booked is the only status that can be reversed.\n*`FUTR`-Entry is on the books of the account servicer and value will be applied to the account owner at a future date and time.\n*`INFO`-Entry is only provided for information, and no booking on the account owner's account in the account servicer's ledger has been performed.\n*`PDNG`-Booking on the account owner's account in the account servicer's ledger has not been completed.\nUsage: this can be used for expected items, or for items for which some conditions still need to be fulfilled before they can be booked. If booking takes place, the entry will be included with status Booked in subsequent account report or statement. Status Pending cannot be reversed."]
pub enum ExternalEntryStatus1Code {
Book,
Futr,
Info,
Pdng,
}
impl<'a> ExternalEntryStatus1Code {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"BOOK" => Self::Book,
"FUTR" => Self::Futr,
"INFO" => Self::Info,
"PDNG" => Self::Pdng,
tag => todo!("handle code {tag:?}"),
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Specifies the status of an entry on the books of the account servicer, as published in an external code set.\r\nExternal code sets can be downloaded from www.iso20022.org."]
pub enum ExternalEntryStatusCode {
#[doc = "Booked means that the transfer of money has been completed between account servicer and account owner.\nUsage: Status Booked does not necessarily imply finality of money as this depends on other factors such as the payment system used, the completion of the end-to-end transaction and the terms agreed between account servicer and owner.\nStatus Booked is the only status that can be reversed."]
Booked,
#[doc = "Entry is on the books of the account servicer and value will be applied to the account owner at a future date and time."]
Future,
#[doc = "Entry is only provided for information, and no booking on the account owner's account in the account servicer's ledger has been performed."]
Information,
#[doc = "Booking on the account owner's account in the account servicer's ledger has not been completed.\nUsage: this can be used for expected items, or for items for which some conditions still need to be fulfilled before they can be booked. If booking takes place, the entry will be included with status Booked in subsequent account report or statement. Status Pending cannot be reversed."]
Pending,
}
impl<'a> ExternalEntryStatusCode {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"BOOK" => Self::Booked,
"FUTR" => Self::Future,
"INFO" => Self::Information,
"PDNG" => Self::Pending,
tag => todo!("handle code {tag:?}"),
};
Ok(value)
}
}
pub use self::external_code_sets::ExternalEntryStatus1Code;
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Specifies the external credit line type code in the format of character string with a maximum length of 4 characters.\r\nThe list of valid codes is an external code set published separately.\r\nExternal code sets can be downloaded from www.iso20022.org."]
pub enum ExternalCreditLineType1Code {}
impl<'a> ExternalCreditLineType1Code {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
tag => todo!("handle code {tag:?}"),
};
Ok(value)
}
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Specifies the balance type, as published in an external balance type code set.\r\nExternal code sets can be downloaded from www.iso20022.org.\n*`CLAV`-Closing balance of amount of money that is at the disposal of the account owner on the date specified. \n*`CLBD`-Balance of the account at the end of the pre-agreed account reporting period. It is the sum of the opening booked balance at the beginning of the period and all entries booked to the account during the pre-agreed account reporting period. \n*`FWAV`-Forward available balance of money that is at the disposal of the account owner on the date specified. \n*`INFO`-Balance for informational purposes. \n*`ITAV`-Available balance calculated in the course of the account servicer's business day, at the time specified, and subject to further changes during the business day. The interim balance is calculated on the basis of booked credit and debit items during the calculation time/period specified. \n*`ITBD`-Balance calculated in the course of the account servicer's business day, at the time specified, and subject to further changes during the business day. The interim balance is calculated on the basis of booked credit and debit items during the calculation time/period specified. \n*`OPAV`-Opening balance of amount of money that is at the disposal of the account owner on the date specified. \n*`OPBD`-Book balance of the account at the beginning of the account reporting period. It always equals the closing book balance from the previous report. \n*`PRCD`-Balance of the account at the previously closed account reporting period. The opening booked balance for the new period has to be equal to this balance.\nUsage: the previously booked closing balance should equal (inclusive date) the booked closing balance of the date it references and equal the actual booked opening balance of the current date.\n*`XPCD`-Balance, composed of booked entries and pending items known at the time of calculation, which projects the end of day balance if everything is booked on the account and no other entry is posted. "]
pub enum ExternalBalanceType1Code {
Clav,
Clbd,
Fwav,
Info,
Itav,
Itbd,
Opav,
Opbd,
Prcd,
Xpcd,
impl<'a> ExternalBalanceType1Code {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"CLAV" => Self::Clav,
"CLBD" => Self::Clbd,
"FWAV" => Self::Fwav,
"INFO" => Self::Info,
"ITAV" => Self::Itav,
"ITBD" => Self::Itbd,
"OPAV" => Self::Opav,
"OPBD" => Self::Opbd,
"PRCD" => Self::Prcd,
"XPCD" => Self::Xpcd,
tag => todo!("handle code {tag:?}"),
};
Ok(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Specifies the balance type, as published in an external balance type code set.\r\nExternal code sets can be downloaded from www.iso20022.org."]
pub enum ExternalBalanceTypeCode {
#[doc = "Closing balance of amount of money that is at the disposal of the account owner on the date specified. "]
ClosingAvailable,
#[doc = "Balance of the account at the end of the pre-agreed account reporting period. It is the sum of the opening booked balance at the beginning of the period and all entries booked to the account during the pre-agreed account reporting period. "]
ClosingBooked,
#[doc = "Forward available balance of money that is at the disposal of the account owner on the date specified. "]
ForwardAvailable,
#[doc = "Balance for informational purposes. "]
Information,
#[doc = "Available balance calculated in the course of the account servicer's business day, at the time specified, and subject to further changes during the business day. The interim balance is calculated on the basis of booked credit and debit items during the calculation time/period specified. "]
InterimAvailable,
#[doc = "Balance calculated in the course of the account servicer's business day, at the time specified, and subject to further changes during the business day. The interim balance is calculated on the basis of booked credit and debit items during the calculation time/period specified. "]
InterimBooked,
#[doc = "Opening balance of amount of money that is at the disposal of the account owner on the date specified. "]
OpeningAvailable,
#[doc = "Book balance of the account at the beginning of the account reporting period. It always equals the closing book balance from the previous report. "]
OpeningBooked,
#[doc = "Balance of the account at the previously closed account reporting period. The opening booked balance for the new period has to be equal to this balance.\nUsage: the previously booked closing balance should equal (inclusive date) the booked closing balance of the date it references and equal the actual booked opening balance of the current date."]
PreviouslyClosedBooked,
#[doc = "Balance, composed of booked entries and pending items known at the time of calculation, which projects the end of day balance if everything is booked on the account and no other entry is posted. "]
Expected,
}
impl<'a> ExternalBalanceTypeCode {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"CLAV" => Self::ClosingAvailable,
"CLBD" => Self::ClosingBooked,
"FWAV" => Self::ForwardAvailable,
"INFO" => Self::Information,
"ITAV" => Self::InterimAvailable,
"ITBD" => Self::InterimBooked,
"OPAV" => Self::OpeningAvailable,
"OPBD" => Self::OpeningBooked,
"PRCD" => Self::PreviouslyClosedBooked,
"XPCD" => Self::Expected,
tag => todo!("handle code {tag:?}"),
};
Ok(value)
}
}
pub use self::external_code_sets::ExternalBalanceType1Code;
};
Ok(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Specifies the external proxy account type code, as published in the proxy account type external code set.\r\nExternal code sets can be downloaded from www.iso20022.org.\n*`TELE`-A telephone number in the format specified by the 'The international public telecommunication numbering plan ITU-T E.164. \n*`EMAL`-Internationalised address of an electronic mail box for internet messages.\n*`DNAM`-Internationalised internet domain name.\n*`CINC`-Corporate Identification issued by a national institution or regulator, used as account proxy. \n(applied for corporate account proxy).\n*`COTX`-Unique government-issued tax Identification used as account proxy to identify the corporate (for example for government tax) and typically linked to the corporate bank account (applied for corporate account proxy).\n*`COID`-Identification issued by a national institution or regulator (different from a national scheme like a clearing provider), used as account proxy (applied for corporate or individual account proxy).\n*`CUST`-Any other customer identification number issued by a corporate, bank or other organization, used as account proxy.\n(applied for corporate or individual account proxy).\n*`DRLC`-Unique government-issued Identification used as account proxy to identify the individual (for example for government charges, road taxes and tolls,vaccination charges) and typically linked to the individual's bank account (applied for individual account proxy).\n*`EIDN`-Government-issued Identification (different from a passport Identification or a national Identification). Used as account proxy to identify the individual (for example for public benefits) and typically linked to the individual's bank account (applied for individual account proxy).\n*`EWAL`-Market-adopted prepaid instruments like e-Wallets, payments to / from e-wallets from / to bank accounts (applied for corporate or individual account proxy).\n*`PVTX`-Unique government-issued tax Identification used as account proxy to identify the individual for example for government tax) and typically linked to the individual's bank account (applied for individual account proxy).\n*`LEIC`-Legal Entity Identifier used as account proxy (applied for corporate account proxy).\nUse cases: Can be used by corporates as a \"government-issued\" Identification for registration with payment schemes as a proxy. The proxy may be further used for payments and collections using the underlying instant payment rails for a variety of corporate use cases.\n*`MBNO`-Mobile phone number in the format specified by the “The international public telecommunication numbering plan ITU- T E 164\" (applied for corporate or individual account proxy).\n*`NIDN`-Unique government-issued Identification used as account proxy to identify the individual or corporate for example for public benefits, government subsidies) and typically linked to the individual's / corporate bank account.\n(applied for corporate or individual account proxy).\n*`CCPT`-Unique government-issued Identification used as account proxy to identify the individual (for example for government charges, road taxes, vaccination charges) and typically linked to the individual's bank account\n(applied for individual account proxy).\n*`SHID`-Account proxy issued by a payment scheme (applied for corporate or individual account proxy).\nUse cases: Any proxies issued by clearing systems, for example VPA (India), FPS Identifier (Hong Kong), Jompay (Malaysia) CCIN (Canada).\n*`SOSE`-Unique government-issued Identification used as account proxy to identify the individual (for example for public benefits) and typically linked to the individual's bank account (applied for individual account proxy).\n*`TOKN`-Electronic Identification used, for example, to mask an account number as a means of data secrecy.\n(applied for corporate or individual account proxy).\n*`UBIL`-Subscriber Identification for utilities and services. As opposed to a biller Identification, this identification is used for the subscriber of the service (applied for corporate or individual account proxy).\n*`VIPN`-Account proxy for receiving insurance claims, pay insurance premium, road tax payments, traffic tickets etc.(applied for corporate or individual account proxy).\n*`BIID`-Billers of specific utilities could register for a Biller Identification as supported in the clearing scheme, and use this identification for collections (applied for corporate account proxy)."]
pub enum ExternalProxyAccountType1Code {
Tele,
Emal,
Dnam,
Cinc,
Cotx,
Coid,
Cust,
Drlc,
Eidn,
Ewal,
Pvtx,
Leic,
Mbno,
Nidn,
Ccpt,
Shid,
Sose,
Tokn,
Ubil,
Vipn,
Biid,
}
impl<'a> ExternalProxyAccountType1Code {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"TELE" => Self::Tele,
"EMAL" => Self::Emal,
"DNAM" => Self::Dnam,
"CINC" => Self::Cinc,
"COTX" => Self::Cotx,
"COID" => Self::Coid,
"CUST" => Self::Cust,
"DRLC" => Self::Drlc,
"EIDN" => Self::Eidn,
"EWAL" => Self::Ewal,
"PVTX" => Self::Pvtx,
"LEIC" => Self::Leic,
"MBNO" => Self::Mbno,
"NIDN" => Self::Nidn,
"CCPT" => Self::Ccpt,
"SHID" => Self::Shid,
"SOSE" => Self::Sose,
"TOKN" => Self::Tokn,
"UBIL" => Self::Ubil,
"VIPN" => Self::Vipn,
"BIID" => Self::Biid,
tag => todo!("handle code {tag:?}"),
};
Ok(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Specifies the external proxy account type code, as published in the proxy account type external code set.\r\nExternal code sets can be downloaded from www.iso20022.org."]
pub enum ExternalProxyAccountTypeCode {
#[doc = "A telephone number in the format specified by the 'The international public telecommunication numbering plan ITU-T E.164. "]
TelephoneNumber,
#[doc = "Internationalised address of an electronic mail box for internet messages."]
EmailAddress,
#[doc = "Internationalised internet domain name."]
DomainName,
#[doc = "Account proxy issued by a payment scheme (applied for corporate or individual account proxy).\nUse cases: Any proxies issued by clearing systems, for example VPA (India), FPS Identifier (Hong Kong), Jompay (Malaysia) CCIN (Canada)."]
SchemeIdentificationNumber,
#[doc = "Mobile phone number in the format specified by the “The international public telecommunication numbering plan ITU- T E 164\" (applied for corporate or individual account proxy)."]
MobilePhoneNumber,
#[doc = "Billers of specific utilities could register for a Biller Identification as supported in the clearing scheme, and use this identification for collections (applied for corporate account proxy)."]
BillerSubscriberIdentification,
#[doc = "Market-adopted prepaid instruments like e-Wallets, payments to / from e-wallets from / to bank accounts (applied for corporate or individual account proxy)."]
EWalletIdentification,
#[doc = "Account proxy for receiving insurance claims, pay insurance premium, road tax payments, traffic tickets etc.(applied for corporate or individual account proxy)."]
VehicleIdentificationPlateNumber,
#[doc = "Subscriber Identification for utilities and services. As opposed to a biller Identification, this identification is used for the subscriber of the service (applied for corporate or individual account proxy)."]
UtilitiesSubscriptionIdentification,
#[doc = "Unique government-issued Identification used as account proxy to identify the individual (for example for public benefits) and typically linked to the individual's bank account (applied for individual account proxy)."]
SocialSecurityNumber,
#[doc = "Unique government-issued Identification used as account proxy to identify the individual or corporate for example for public benefits, government subsidies) and typically linked to the individual's / corporate bank account.\n(applied for corporate or individual account proxy)."]
NationalIdentificationNumber,
#[doc = "Unique government-issued Identification used as account proxy to identify the individual (for example for government charges, road taxes, vaccination charges) and typically linked to the individual's bank account\n(applied for individual account proxy)."]
PassportNumber,
#[doc = "Unique government-issued Identification used as account proxy to identify the individual (for example for government charges, road taxes and tolls,vaccination charges) and typically linked to the individual's bank account (applied for individual account proxy)."]
DriverLicenseNumber,
#[doc = "Government-issued Identification (different from a passport Identification or a national Identification). Used as account proxy to identify the individual (for example for public benefits) and typically linked to the individual's bank account (applied for individual account proxy)."]
ElectronicIdentification,
#[doc = "Unique government-issued tax Identification used as account proxy to identify the corporate (for example for government tax) and typically linked to the corporate bank account (applied for corporate account proxy)."]
CorporateTaxIdentification,
#[doc = "Unique government-issued tax Identification used as account proxy to identify the individual for example for government tax) and typically linked to the individual's bank account (applied for individual account proxy)."]
IndividualTaxIdentification,
#[doc = "Identification issued by a national institution or regulator (different from a national scheme like a clearing provider), used as account proxy (applied for corporate or individual account proxy)."]
CountryAuthorityIdentification,
#[doc = "Legal Entity Identifier used as account proxy (applied for corporate account proxy).\nUse cases: Can be used by corporates as a \"government-issued\" Identification for registration with payment schemes as a proxy. The proxy may be further used for payments and collections using the underlying instant payment rails for a variety of corporate use cases."]
LegalEntityIdentifierCode,
#[doc = "Corporate Identification issued by a national institution or regulator, used as account proxy. \n(applied for corporate account proxy)."]
CertificateOfIncorporationNumber,
#[doc = "Electronic Identification used, for example, to mask an account number as a means of data secrecy.\n(applied for corporate or individual account proxy)."]
TokenIdentification,
#[doc = "Any other customer identification number issued by a corporate, bank or other organization, used as account proxy.\n(applied for corporate or individual account proxy)."]
CustomerIdentificationNumber,
}
impl<'a> ExternalProxyAccountTypeCode {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"TELE" => Self::TelephoneNumber,
"EMAL" => Self::EmailAddress,
"DNAM" => Self::DomainName,
"SHID" => Self::SchemeIdentificationNumber,
"MBNO" => Self::MobilePhoneNumber,
"BIID" => Self::BillerSubscriberIdentification,
"EWAL" => Self::EWalletIdentification,
"VIPN" => Self::VehicleIdentificationPlateNumber,
"UBIL" => Self::UtilitiesSubscriptionIdentification,
"SOSE" => Self::SocialSecurityNumber,
"NIDN" => Self::NationalIdentificationNumber,
"CCPT" => Self::PassportNumber,
"DRLC" => Self::DriverLicenseNumber,
"EIDN" => Self::ElectronicIdentification,
"COTX" => Self::CorporateTaxIdentification,
"PVTX" => Self::IndividualTaxIdentification,
"COID" => Self::CountryAuthorityIdentification,
"LEIC" => Self::LegalEntityIdentifierCode,
"CINC" => Self::CertificateOfIncorporationNumber,
"TOKN" => Self::TokenIdentification,
"CUST" => Self::CustomerIdentificationNumber,
tag => todo!("handle code {tag:?}"),
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Specifies the nature, or use, of the cash account in the format of character string with a maximum length of 4 characters.\r\nThe list of valid codes is an external code list published separately.\r\nExternal code sets can be downloaded from www.iso20022.org.\n*`CACC`-Account used to post debits and credits when no specific account has been nominated.\n*`CARD`-Account used for credit card payments.\n*`CASH`-Account used for the payment of cash.\n*`CHAR`-Account used for charges if different from the account for\npayment.\n*`CISH`-Account used for payment of income if different from the current cash account\n*`COMM`-Account used for commission if different from the account\nfor payment.\n*`CPAC`-Account used to post settlement debit and credit entries on behalf of a designated Clearing Participant.\n*`LLSV`-Account used for savings with special interest and withdrawal terms. \n*`LOAN`-Account used for loans.\n*`MGLD`-Account used for a marginal lending facility.\n*`MOMA`-Account used for money markets if different from the cash\naccount.\n*`NREX`-Account used for non-resident external.\n*`ODFT`-Account is used for overdrafts.\n*`ONDP`-Account used for overnight deposits.\n*`OTHR`-Account not otherwise specified. \n*`SACC`-Account used to post debit and credit entries, as a result of transactions cleared and settled through a specific clearing and settlement system.\n*`SLRY`-Accounts used for salary payments.\n*`SVGS`-Account used for savings.\n*`TAXE`-Account used for taxes if different from the account for\npayment.\n*`TRAN`-A transacting account is the most basic type of bank account that you can get. The main difference between transaction and cheque accounts is that you usually do not get a cheque book with your transacting account and neither are you offered an overdraft facility.\n*`TRAS`-Account used for trading if different from the current cash\naccount.\n*`VACC`-Account created virtually to facilitate collection and reconciliation.\n*`NFCA`-Non-Resident Individual / Entity Foreign Current held domestically."]
pub enum ExternalCashAccountType1Code {
Cacc,
Card,
Cash,
Char,
Cish,
Comm,
Cpac,
Llsv,
Loan,
Mgld,
Moma,
Nrex,
Odft,
Ondp,
Othr,
Sacc,
Slry,
Svgs,
Taxe,
Tran,
Tras,
Vacc,
Nfca,
}
impl<'a> ExternalCashAccountType1Code {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"CACC" => Self::Cacc,
"CARD" => Self::Card,
"CASH" => Self::Cash,
"CHAR" => Self::Char,
"CISH" => Self::Cish,
"COMM" => Self::Comm,
"CPAC" => Self::Cpac,
"LLSV" => Self::Llsv,
"LOAN" => Self::Loan,
"MGLD" => Self::Mgld,
"MOMA" => Self::Moma,
"NREX" => Self::Nrex,
"ODFT" => Self::Odft,
"ONDP" => Self::Ondp,
"OTHR" => Self::Othr,
"SACC" => Self::Sacc,
"SLRY" => Self::Slry,
"SVGS" => Self::Svgs,
"TAXE" => Self::Taxe,
"TRAN" => Self::Tran,
"TRAS" => Self::Tras,
"VACC" => Self::Vacc,
"NFCA" => Self::Nfca,
tag => todo!("handle code {tag:?}"),
};
Ok(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Specifies the nature, or use, of the cash account in the format of character string with a maximum length of 4 characters.\r\nThe list of valid codes is an external code list published separately.\r\nExternal code sets can be downloaded from www.iso20022.org."]
pub enum ExternalCashAccountTypeCode {
#[doc = "Account used to post debits and credits when no specific account has been nominated."]
Current,
#[doc = "Account used for credit card payments."]
CardAccount,
#[doc = "Account used for the payment of cash."]
CashPayment,
#[doc = "Account used for charges if different from the account for\npayment."]
Charges,
#[doc = "Account used for payment of income if different from the current cash account"]
CashIncome,
#[doc = "Account used for commission if different from the account\nfor payment."]
Commission,
#[doc = "Account used to post settlement debit and credit entries on behalf of a designated Clearing Participant."]
ClearingParticipantSettlementAccount,
#[doc = "Account used for savings with special interest and withdrawal terms. "]
LimitedLiquiditySavingsAccount,
#[doc = "Account used for loans."]
Loan,
#[doc = "Account used for a marginal lending facility."]
MarginalLending,
#[doc = "Account used for money markets if different from the cash\naccount."]
MoneyMarket,
#[doc = "Account used for non-resident external."]
NonResidentExternal,
#[doc = "Account is used for overdrafts."]
Overdraft,
#[doc = "Account used for overnight deposits."]
OverNightDeposit,
#[doc = "Account not otherwise specified. "]
OtherAccount,
#[doc = "Account used to post debit and credit entries, as a result of transactions cleared and settled through a specific clearing and settlement system."]
Settlement,
#[doc = "Accounts used for salary payments."]
Salary,
#[doc = "Account used for savings."]
Savings,
#[doc = "Account used for taxes if different from the account for\npayment."]
Tax,
#[doc = "A transacting account is the most basic type of bank account that you can get. The main difference between transaction and cheque accounts is that you usually do not get a cheque book with your transacting account and neither are you offered an overdraft facility."]
TransactingAccount,
#[doc = "Account used for trading if different from the current cash\naccount."]
CashTrading,
#[doc = "Account created virtually to facilitate collection and reconciliation."]
VirtualAccount,
}
impl<'a> ExternalCashAccountTypeCode {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"CACC" => Self::Current,
"CARD" => Self::CardAccount,
"CASH" => Self::CashPayment,
"CHAR" => Self::Charges,
"CISH" => Self::CashIncome,
"COMM" => Self::Commission,
"CPAC" => Self::ClearingParticipantSettlementAccount,
"LLSV" => Self::LimitedLiquiditySavingsAccount,
"LOAN" => Self::Loan,
"MGLD" => Self::MarginalLending,
"MOMA" => Self::MoneyMarket,
"NREX" => Self::NonResidentExternal,
"ODFT" => Self::Overdraft,
"ONDP" => Self::OverNightDeposit,
"OTHR" => Self::OtherAccount,
"SACC" => Self::Settlement,
"SLRY" => Self::Salary,
"SVGS" => Self::Savings,
"TAXE" => Self::Tax,
"TRAN" => Self::TransactingAccount,
"TRAS" => Self::CashTrading,
"VACC" => Self::VirtualAccount,
tag => todo!("handle code {tag:?}"),
};
Ok(value)
}
}
pub use self::external_code_sets::ExternalCashAccountType1Code;
pub enum PreferredContactMethod1Code {
#[doc = "Preferred method used to reach the contact is per letter."]
Letter,
#[doc = "Preferred method used to reach the contact is per email."]
Email,
#[doc = "Preferred method used to reach the contact is per phone."]
Phone,
#[doc = "Preferred method used to reach the contact is per fax."]
Fax,
#[doc = "Preferred method used to reach the contact is per mobile or cell phone."]
MobileOrCellPhone,
}
impl<'a> PreferredContactMethod1Code {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"LETT" => Self::Letter,
"MAIL" => Self::Email,
"PHON" => Self::Phone,
"FAXX" => Self::Fax,
"CELL" => Self::MobileOrCellPhone,
tag => todo!("handle code {tag:?}"),
};
Ok(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Preferred method used to reach the individual contact within an organisation."]
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Specifies the terms used to formally address a person."]
pub enum NamePrefix2Code {
#[doc = "Title of the person is Doctor or Dr."]
Doctor,
#[doc = "Title of the person is Mister or Mr."]
Mister,
#[doc = "Title of the person is Miss."]
Miss,
#[doc = "Title of the person is Madam."]
Madam,
#[doc = "Title of the person is gender neutral (Mx)."]
GenderNeutral,
}
impl<'a> NamePrefix2Code {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"DOCT" => Self::Doctor,
"MIST" => Self::Mister,
"MISS" => Self::Miss,
"MADM" => Self::Madam,
"MIKS" => Self::GenderNeutral,
tag => todo!("handle code {tag:?}"),
};
Ok(value)
};
Ok(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Specifies the return reason, as published in an external return reason code list.\r\nExternal code sets can be downloaded from www.iso20022.org.\n*`AC01`-Format of the account number specified is not correct\n*`AC03`-Wrong IBAN in SCT\n*`AC04`-Account number specified has been closed on the bank of account's books\n*`AC06`-Account specified is blocked, prohibiting posting of transactions against it.\n*`AC13`-Debtor account type is missing or invalid\n*`AC14`-An agent in the payment chain is invalid.\n*`AC15`-Account details have changed.\n*`AC16`-Account is in sequestration.\n*`AC17`-Account is in liquidation.\n*`AG01`-Transaction forbidden on this type of account (formerly NoAgreement)\n*`AG02`-Bank Operation code specified in the message is not valid for receiver\n*`AM01`-Specified message amount is equal to zero\n*`AM02`-Specific transaction/message amount is greater than allowed maximum\n*`AM03`-Specified message amount is an non processable currency outside of existing agreement\n*`AM04`-Amount of funds available to cover specified message amount is insufficient.\n*`AM05`-Duplication\n*`AM06`-Specified transaction amount is less than agreed minimum.\n*`AM07`-Amount specified in message has been blocked by regulatory authorities.\n*`AM09`-Amount received is not the amount agreed or expected\n*`AM10`-Sum of instructed amounts does not equal the control sum.\n*`ARDT`-Already returned original SCT\n*`BE01`-Identification of end customer is not consistent with associated account number, organisation ID or private ID.\n*`BE04`-Specification of creditor's address, which is required for payment, is missing/not correct (formerly IncorrectCreditorAddress).\n*`BE05`-Party who initiated the message is not recognised by the end customer\n*`BE06`-End customer specified is not known at associated Sort/National Bank Code or does no longer exist in the books\n*`BE07`-Specification of debtor's address, which is required for payment, is missing/not correct.\n*`BE08`-Returned as a result of a bank error.\n*`CN01`-Authorisation is cancelled.\n*`CNOR`-Creditor bank is not registered under this BIC in the CSM\n*`CNPC`-Cash not picked up by Creditor or cash could not be delivered to Creditor\n*`CURR`-Currency of the payment is incorrect\n*`CUST`-Cancellation requested by the Debtor\n*`DNOR`-Debtor bank is not registered under this BIC in the CSM\n*`DS28`-Return following technical problems resulting in erroneous transaction.\n*`DT01`-Invalid date (eg, wrong settlement date)\n*`DT02`-Cheque has been issued but not deposited and is considered expired.\n*`ED01`-Correspondent bank not possible.\n*`ED03`-Balance of payments complementary info is requested\n*`ED05`-Settlement of the transaction has failed.\n*`EMVL`-The card payment is fraudulent and was not processed with EMV technology for an EMV card. \n*`ERIN`-The Extended Remittance Information (ERI) option is not supported.\n*`FF05`-Local Instrument code is missing or invalid\n*`FOCR`-Return following a cancellation request\n*`FR01`-Returned as a result of fraud.\n*`FRTR`-Final response/tracking is recalled as mandate is cancelled.\n*`MD01`-No Mandate\n*`MD02`-Mandate related information data required by the scheme is missing.\n*`MD06`-Return of funds requested by end customer\n*`MD07`-End customer is deceased.\n*`MS02`-Reason has not been specified by end customer\n*`MS03`-Reason has not been specified by agent.\n*`NARR`-Reason is provided as narrative information in the additional reason information.\n*`NOAS`-No response from Beneficiary\n*`NOCM`-Customer account is not compliant with regulatory requirements, for example FICA (in South Africa) or any other regulatory requirements which render an account inactive for certain processing.\n*`NOOR`-Original SCT never received\n*`PINL`-The card payment is fraudulent (lost and stolen fraud) and was processed as EMV transaction without PIN verification.\n*`RC01`-Bank Identifier code specified in the message has an incorrect format (formerly IncorrectFormatForRoutingCode).\n*`RC07`-Incorrrect BIC of the beneficiary Bank in the SCTR\n*`RF01`-Transaction reference is not unique within the message.\n*`RR01`-Specification of the debtor’s account or unique identification needed for reasons of regulatory requirements is insufficient or missing\n*`RR02`-Specification of the debtor’s name and/or address needed for regulatory requirements is insufficient or missing.\n*`RR03`-Specification of the creditor’s name and/or address needed for regulatory requirements is insufficient or missing.\n*`RR04`-Regulatory Reason\n*`RUTA`-Return following investigation request and no remediation possible.\n*`SL01`-Due to specific service offered by the Debtor Agent\n*`SL02`-Due to specific service offered by the Creditor Agent\n*`SL11`-Whitelisting service offered by the Debtor Agent; Debtor has not included the Creditor on its “Whitelist” (yet). In the Whitelist the Debtor may list all allowed Creditors to debit Debtor bank account.\n*`SL12`-Blacklisting service offered by the Debtor Agent; Debtor included the Creditor on his “Blacklist”. In the Blacklist the Debtor may list all Creditors not allowed to debit Debtor bank account.\n*`SL13`-Due to Maximum allowed Direct Debit Transactions per period service offered by the Debtor Agent.\n*`SL14`-Due to Maximum allowed Direct Debit Transaction amount service offered by the Debtor Agent.\n*`SP01`-Payment is stopped by account holder.\n*`SP02`-Previously stopped by means of a stop payment advise.\n*`SVNR`-The card payment is returned since a cash amount rendered was not correct or goods or a service was not rendered to the customer, e.g. in an e-commerce situation.\n*`TM01`-Associated message was received after agreed processing cut-off time.\n*`TRAC`-Return following direct debit being removed from tracking process.\n*`UPAY`-Payment is not justified.\n*`AGNT`-Agent in the payment workflow is incorrect.\n*`FF06`-Category Purpose code is missing or invalid.\n*`RC08`-ClearingSystemMemberidentifier is invalid or missing.\r\nGeneric usage if cannot specify between debit or credit account.\n*`BE11`-Creditor country code is missing or invalid.\n*`BE17`-Creditor or Ultimate Creditor identification code missing or invalid.\n*`AC02`-Debtor account number invalid or missing.\n*`RR11`-Invalid or missing identification of a bank proprietary service.\n*`BE10`-Debtor country code is missing or invalid.\n*`BE16`-Debtor or Ultimate Debtor identification code missing or invalid.\n*`RC11`-Intermediary Agent is invalid or missing.\n*`RR12`-Invalid or missing identification required within a particular country or payment type.\n*`FF03`-Payment Type Information is missing or invalid.\r\nGeneric usage if cannot specify Service Level or Local Instrument code.\n*`FF07`-Purpose is missing or invalid.\n*`FF04`-Service Level code is missing or invalid.\n*`RR09`-Structured creditor reference invalid or missing.\n*`RR05`-Regulatory or Central Bank Reporting information missing, incomplete or invalid.\n*`RR07`-Remittance information structure does not comply with rules for payment type.\n*`RR08`-Remittance information truncated to comply with rules for payment type.\n*`RR06`-Tax information missing, incomplete or invalid.\n*`AG07`-Debtor account cannot be debited for a generic reason.\r\nUsage: Code value may be used in general purposes and as a replacement for AM04 if debtor bank does not reveal its customer's insufficient funds for privacy reasons.\n*`G004`-In a FIToFI Customer Credit Transfer: Credit to the creditor’s account is pending, status Originator is waiting for funds provided via a cover. Update will follow from the Status Originator.\n*`MD05`-Creditor or creditor's agent should not have collected the direct debit.\n*`AC07`-Creditor account number closed.\n*`DC04`-Return of Covering Settlement due to the underlying Credit Transfer details not being received.\n*`RC04`-Creditor bank identifier is invalid or missing.\n*`DT04`-Future date not supported.\n*`DUPL`-Payment is a duplicate of another payment.\n*`RC03`-Debtor bank identifier is invalid or missing."]
pub enum ExternalReturnReason1Code {
Ac01,
Ac03,
Ac04,
Ac06,
Ac13,
Ac14,
Ac15,
Ac16,
Ac17,
Ag01,
Ag02,
Am01,
Am02,
Am03,
Am04,
Am05,
Am06,
Am07,
Am09,
Am10,
Ardt,
Be01,
Be04,
Be05,
Be06,
Be07,
Be08,
Cn01,
Cnor,
Cnpc,
Curr,
Cust,
Dnor,
Ds28,
Dt01,
Dt02,
Ed01,
Ed03,
Ed05,
Emvl,
Erin,
Ff05,
Focr,
Fr01,
Frtr,
Md01,
Md02,
Md06,
Md07,
Ms02,
Ms03,
Narr,
Noas,
Nocm,
Noor,
Pinl,
Rc01,
Rc07,
Rf01,
Rr01,
Rr02,
Rr03,
Rr04,
Ruta,
Sl01,
Sl02,
Sl11,
Sl12,
Sl13,
Sl14,
Sp01,
Sp02,
Svnr,
Tm01,
Trac,
Upay,
Agnt,
Ff06,
Rc08,
Be11,
Be17,
Ac02,
Rr11,
Be10,
Be16,
Rc11,
Rr12,
Ff03,
Ff07,
Ff04,
Rr09,
Rr05,
Rr07,
Rr08,
Rr06,
Ag07,
G004,
Md05,
Ac07,
Dc04,
Rc04,
Dt04,
Dupl,
Rc03,
}
impl<'a> ExternalReturnReason1Code {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"AC01" => Self::Ac01,
"AC03" => Self::Ac03,
"AC04" => Self::Ac04,
"AC06" => Self::Ac06,
"AC13" => Self::Ac13,
"AC14" => Self::Ac14,
"AC15" => Self::Ac15,
"AC16" => Self::Ac16,
"AC17" => Self::Ac17,
"AG01" => Self::Ag01,
"AG02" => Self::Ag02,
"AM01" => Self::Am01,
"AM02" => Self::Am02,
"AM03" => Self::Am03,
"AM04" => Self::Am04,
"AM05" => Self::Am05,
"AM06" => Self::Am06,
"AM07" => Self::Am07,
"AM09" => Self::Am09,
"AM10" => Self::Am10,
"ARDT" => Self::Ardt,
"BE01" => Self::Be01,
"BE04" => Self::Be04,
"BE05" => Self::Be05,
"BE06" => Self::Be06,
"BE07" => Self::Be07,
"BE08" => Self::Be08,
"CN01" => Self::Cn01,
"CNOR" => Self::Cnor,
"CNPC" => Self::Cnpc,
"CURR" => Self::Curr,
"CUST" => Self::Cust,
"DNOR" => Self::Dnor,
"DS28" => Self::Ds28,
"DT01" => Self::Dt01,
"DT02" => Self::Dt02,
"ED01" => Self::Ed01,
"ED03" => Self::Ed03,
"ED05" => Self::Ed05,
"EMVL" => Self::Emvl,
"ERIN" => Self::Erin,
"FF05" => Self::Ff05,
"FOCR" => Self::Focr,
"FR01" => Self::Fr01,
"FRTR" => Self::Frtr,
"MD01" => Self::Md01,
"MD02" => Self::Md02,
"MD06" => Self::Md06,
"MD07" => Self::Md07,
"MS02" => Self::Ms02,
"MS03" => Self::Ms03,
"NARR" => Self::Narr,
"NOAS" => Self::Noas,
"NOCM" => Self::Nocm,
"NOOR" => Self::Noor,
"PINL" => Self::Pinl,
"RC01" => Self::Rc01,
"RC07" => Self::Rc07,
"RF01" => Self::Rf01,
"RR01" => Self::Rr01,
"RR02" => Self::Rr02,
"RR03" => Self::Rr03,
"RR04" => Self::Rr04,
"RUTA" => Self::Ruta,
"SL01" => Self::Sl01,
"SL02" => Self::Sl02,
"SL11" => Self::Sl11,
"SL12" => Self::Sl12,
"SL13" => Self::Sl13,
"SL14" => Self::Sl14,
"SP01" => Self::Sp01,
"SP02" => Self::Sp02,
"SVNR" => Self::Svnr,
"TM01" => Self::Tm01,
"TRAC" => Self::Trac,
"UPAY" => Self::Upay,
"AGNT" => Self::Agnt,
"FF06" => Self::Ff06,
"RC08" => Self::Rc08,
"BE11" => Self::Be11,
"BE17" => Self::Be17,
"AC02" => Self::Ac02,
"RR11" => Self::Rr11,
"BE10" => Self::Be10,
"BE16" => Self::Be16,
"RC11" => Self::Rc11,
"RR12" => Self::Rr12,
"FF03" => Self::Ff03,
"FF07" => Self::Ff07,
"FF04" => Self::Ff04,
"RR09" => Self::Rr09,
"RR05" => Self::Rr05,
"RR07" => Self::Rr07,
"RR08" => Self::Rr08,
"RR06" => Self::Rr06,
"AG07" => Self::Ag07,
"G004" => Self::G004,
"MD05" => Self::Md05,
"AC07" => Self::Ac07,
"DC04" => Self::Dc04,
"RC04" => Self::Rc04,
"DT04" => Self::Dt04,
"DUPL" => Self::Dupl,
"RC03" => Self::Rc03,
tag => todo!("handle code {tag:?}"),
};
Ok(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Specifies the return reason, as published in an external return reason code list.\r\nExternal code sets can be downloaded from www.iso20022.org."]
pub enum ExternalReturnReasonCode {
#[doc = "Format of the account number specified is not correct"]
IncorrectAccountNumber,
#[doc = "Wrong IBAN in SCT"]
InvalidCreditorAccountNumber,
#[doc = "Account number specified has been closed on the bank of account's books"]
ClosedAccountNumber,
#[doc = "Account specified is blocked, prohibiting posting of transactions against it."]
BlockedAccount,
#[doc = "Debtor account type is missing or invalid"]
InvalidDebtorAccountType,
#[doc = "An agent in the payment chain is invalid."]
InvalidAgent,
#[doc = "Account details have changed."]
AccountDetailsChanged,
#[doc = "Account is in sequestration."]
AccountInSequestration,
#[doc = "Account is in liquidation."]
AccountInLiquidation,
#[doc = "Transaction forbidden on this type of account (formerly NoAgreement)"]
TransactionForbidden,
#[doc = "Bank Operation code specified in the message is not valid for receiver"]
InvalidBankOperationCode,
#[doc = "Specified message amount is equal to zero"]
ZeroAmount,
#[doc = "Specific transaction/message amount is greater than allowed maximum"]
NotAllowedAmount,
#[doc = "Specified message amount is an non processable currency outside of existing agreement"]
NotAllowedCurrency,
#[doc = "Amount of funds available to cover specified message amount is insufficient."]
InsufficientFunds,
#[doc = "Duplication"]
Duplication,
#[doc = "Specified transaction amount is less than agreed minimum."]
TooLowAmount,
#[doc = "Amount specified in message has been blocked by regulatory authorities."]
BlockedAmount,
#[doc = "Amount received is not the amount agreed or expected"]
WrongAmount,
#[doc = "Sum of instructed amounts does not equal the control sum."]
InvalidControlSum,
#[doc = "Already returned original SCT"]
AlreadyReturnedTransaction,
#[doc = "Identification of end customer is not consistent with associated account number, organisation ID or private ID."]
InconsistenWithEndCustomer,
#[doc = "Specification of creditor's address, which is required for payment, is missing/not correct (formerly IncorrectCreditorAddress)."]
MissingCreditorAddress,
#[doc = "Party who initiated the message is not recognised by the end customer"]
UnrecognisedInitiatingParty,
#[doc = "End customer specified is not known at associated Sort/National Bank Code or does no longer exist in the books"]
UnknownEndCustomer,
#[doc = "Specification of debtor's address, which is required for payment, is missing/not correct."]
MissingDebtorAddress,
#[doc = "Returned as a result of a bank error."]
BankError,
#[doc = "Authorisation is cancelled."]
AuthorisationCancelled,
#[doc = "Creditor bank is not registered under this BIC in the CSM"]
CreditorBankIsNotRegistered,
#[doc = "Cash not picked up by Creditor or cash could not be delivered to Creditor"]
CashNotPickedUp,
#[doc = "Currency of the payment is incorrect"]
IncorrectCurrency,
#[doc = "Cancellation requested by the Debtor"]
RequestedByCustomer,
#[doc = "Debtor bank is not registered under this BIC in the CSM"]
DebtorBankIsNotRegistered,
#[doc = "Return following technical problems resulting in erroneous transaction."]
ReturnForTechnicalReason,
#[doc = "Invalid date (eg, wrong settlement date)"]
InvalidDate,
#[doc = "Cheque has been issued but not deposited and is considered expired."]
ChequeExpired,
#[doc = "Correspondent bank not possible."]
CorrespondentBankNotPossible,
#[doc = "Balance of payments complementary info is requested"]
BalanceInfoRequest,
#[doc = "Settlement of the transaction has failed."]
SettlementFailed,
#[doc = "The card payment is fraudulent and was not processed with EMV technology for an EMV card. "]
EmvLiabilityShift,
#[doc = "The Extended Remittance Information (ERI) option is not supported."]
EriOptionNotSupported,
#[doc = "Local Instrument code is missing or invalid"]
InvalidLocalInstrumentCode,
#[doc = "Return following a cancellation request"]
FollowingCancellationRequest,
#[doc = "Returned as a result of fraud."]
Fraud,
#[doc = "Final response/tracking is recalled as mandate is cancelled."]
FinalResponseMandateCancelled,
#[doc = "No Mandate"]
NoMandate,
#[doc = "Mandate related information data required by the scheme is missing."]
MissingMandatoryInformationInMandate,
#[doc = "Return of funds requested by end customer"]
RefundRequestByEndCustomer,
#[doc = "End customer is deceased."]
EndCustomerDeceased,
#[doc = "Reason has not been specified by end customer"]
NotSpecifiedReasonCustomerGenerated,
#[doc = "Reason has not been specified by agent."]
NotSpecifiedReasonAgentGenerated,
#[doc = "Reason is provided as narrative information in the additional reason information."]
Narrative,
#[doc = "No response from Beneficiary"]
NoAnswerFromCustomer,
#[doc = "Customer account is not compliant with regulatory requirements, for example FICA (in South Africa) or any other regulatory requirements which render an account inactive for certain processing."]
NotCompliant,
#[doc = "Original SCT never received"]
NoOriginalTransactionReceived,
#[doc = "The card payment is fraudulent (lost and stolen fraud) and was processed as EMV transaction without PIN verification."]
PinLiabilityShift,
#[doc = "Bank Identifier code specified in the message has an incorrect format (formerly IncorrectFormatForRoutingCode)."]
BankIdentifierIncorrect,
#[doc = "Incorrrect BIC of the beneficiary Bank in the SCTR"]
InvalidCreditorBicIdentifier,
#[doc = "Transaction reference is not unique within the message."]
NotUniqueTransactionReference,
#[doc = "Specification of the debtor’s account or unique identification needed for reasons of regulatory requirements is insufficient or missing"]
MissingDebtorAccountOrIdentification,
#[doc = "Specification of the debtor’s name and/or address needed for regulatory requirements is insufficient or missing."]
MissingDebtorNameOrAddress,
#[doc = "Specification of the creditor’s name and/or address needed for regulatory requirements is insufficient or missing."]
MissingCreditorNameOrAddress,
#[doc = "Regulatory Reason"]
RegulatoryReason,
#[doc = "Return following investigation request and no remediation possible."]
ReturnUponUnableToApply,
#[doc = "Due to specific service offered by the Debtor Agent"]
SpecificServiceOfferedByDebtorAgent,
#[doc = "Due to specific service offered by the Creditor Agent"]
SpecificServiceOfferedByCreditorAgent,
#[doc = "Whitelisting service offered by the Debtor Agent; Debtor has not included the Creditor on its “Whitelist” (yet). In the Whitelist the Debtor may list all allowed Creditors to debit Debtor bank account."]
CreditorNotOnWhitelistOfDebtor,
#[doc = "Blacklisting service offered by the Debtor Agent; Debtor included the Creditor on his “Blacklist”. In the Blacklist the Debtor may list all Creditors not allowed to debit Debtor bank account."]
CreditorOnBlacklistOfDebtor,
#[doc = "Due to Maximum allowed Direct Debit Transactions per period service offered by the Debtor Agent."]
MaximumNumberOfDirectDebitTransactionsExceeded,
#[doc = "Due to Maximum allowed Direct Debit Transaction amount service offered by the Debtor Agent."]
MaximumDirectDebitTransactionAmountExceeded,
#[doc = "Payment is stopped by account holder."]
PaymentStopped,
#[doc = "Previously stopped by means of a stop payment advise."]
PreviouslyStopped,
#[doc = "The card payment is returned since a cash amount rendered was not correct or goods or a service was not rendered to the customer, e.g. in an e-commerce situation."]
ServiceNotRendered,
#[doc = "Associated message was received after agreed processing cut-off time."]
CutOffTime,
#[doc = "Return following direct debit being removed from tracking process."]
RemovedFromTracking,
#[doc = "Payment is not justified."]
UnduePayment,
#[doc = "Debtor account number invalid or missing."]
InvalidDebtorAccountNumber,
#[doc = "Creditor account number closed."]
ClosedCreditorAccountNumber,
#[doc = "Agent in the payment workflow is incorrect."]
IncorrectAgent,
#[doc = "Debtor account cannot be debited for a generic reason.\r\nUsage: Code value may be used in general purposes and as a replacement for AM04 if debtor bank does not reveal its customer's insufficient funds for privacy reasons."]
UnsuccesfulDirectDebit,
#[doc = "Debtor country code is missing or invalid."]
InvalidDebtorCountry,
#[doc = "Creditor country code is missing or invalid."]
InvalidCreditorCountry,
#[doc = "Debtor or Ultimate Debtor identification code missing or invalid."]
InvalidDebtorIdentificationCode,
#[doc = "Creditor or Ultimate Creditor identification code missing or invalid."]
InvalidCreditorIdentificationCode,
#[doc = "Payment Type Information is missing or invalid.\r\nGeneric usage if cannot specify Service Level or Local Instrument code."]
InvalidPaymentTypeInformation,
#[doc = "Service Level code is missing or invalid."]
InvalidServiceLevelCode,
#[doc = "Category Purpose code is missing or invalid."]
InvalidCategoryPurposeCode,
#[doc = "Purpose is missing or invalid."]
InvalidPurpose,
#[doc = "In a FIToFI Customer Credit Transfer: Credit to the creditor’s account is pending, status Originator is waiting for funds provided via a cover. Update will follow from the Status Originator."]
CreditPendingFunds,
#[doc = "Creditor or creditor's agent should not have collected the direct debit."]
CollectionNotDue,
#[doc = "ClearingSystemMemberidentifier is invalid or missing.\r\nGeneric usage if cannot specify between debit or credit account."]
InvalidClearingSystemMemberIdentifier,
#[doc = "Intermediary Agent is invalid or missing."]
InvalidIntermediaryAgent,
#[doc = "Regulatory or Central Bank Reporting information missing, incomplete or invalid."]
RegulatoryInformationInvalid,
#[doc = "Tax information missing, incomplete or invalid."]
TaxInformationInvalid,
#[doc = "Remittance information structure does not comply with rules for payment type."]
RemittanceInformationInvalid,
#[doc = "Remittance information truncated to comply with rules for payment type."]
RemittanceInformationTruncated,
#[doc = "Structured creditor reference invalid or missing."]
InvalidStructuredCreditorReference,
#[doc = "Invalid or missing identification of a bank proprietary service."]
InvalidDebtorAgentServiceIdentification,
#[doc = "Invalid or missing identification required within a particular country or payment type."]
InvalidPartyIdentification,
}
impl<'a> ExternalReturnReasonCode {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"AC01" => Self::IncorrectAccountNumber,
"AC03" => Self::InvalidCreditorAccountNumber,
"AC04" => Self::ClosedAccountNumber,
"AC06" => Self::BlockedAccount,
"AC13" => Self::InvalidDebtorAccountType,
"AC14" => Self::InvalidAgent,
"AC15" => Self::AccountDetailsChanged,
"AC16" => Self::AccountInSequestration,
"AC17" => Self::AccountInLiquidation,
"AG01" => Self::TransactionForbidden,
"AG02" => Self::InvalidBankOperationCode,
"AM01" => Self::ZeroAmount,
"AM02" => Self::NotAllowedAmount,
"AM03" => Self::NotAllowedCurrency,
"AM04" => Self::InsufficientFunds,
"AM05" => Self::Duplication,
"AM06" => Self::TooLowAmount,
"AM07" => Self::BlockedAmount,
"AM09" => Self::WrongAmount,
"AM10" => Self::InvalidControlSum,
"ARDT" => Self::AlreadyReturnedTransaction,
"BE01" => Self::InconsistenWithEndCustomer,
"BE04" => Self::MissingCreditorAddress,
"BE05" => Self::UnrecognisedInitiatingParty,
"BE06" => Self::UnknownEndCustomer,
"BE07" => Self::MissingDebtorAddress,
"BE08" => Self::BankError,
"CN01" => Self::AuthorisationCancelled,
"CNOR" => Self::CreditorBankIsNotRegistered,
"CNPC" => Self::CashNotPickedUp,
"CURR" => Self::IncorrectCurrency,
"CUST" => Self::RequestedByCustomer,
"DNOR" => Self::DebtorBankIsNotRegistered,
"DS28" => Self::ReturnForTechnicalReason,
"DT01" => Self::InvalidDate,
"DT02" => Self::ChequeExpired,
"ED01" => Self::CorrespondentBankNotPossible,
"ED03" => Self::BalanceInfoRequest,
"ED05" => Self::SettlementFailed,
"EMVL" => Self::EmvLiabilityShift,
"ERIN" => Self::EriOptionNotSupported,
"FF05" => Self::InvalidLocalInstrumentCode,
"FOCR" => Self::FollowingCancellationRequest,
"FR01" => Self::Fraud,
"FRTR" => Self::FinalResponseMandateCancelled,
"MD01" => Self::NoMandate,
"MD02" => Self::MissingMandatoryInformationInMandate,
"MD06" => Self::RefundRequestByEndCustomer,
"MD07" => Self::EndCustomerDeceased,
"MS02" => Self::NotSpecifiedReasonCustomerGenerated,
"MS03" => Self::NotSpecifiedReasonAgentGenerated,
"NARR" => Self::Narrative,
"NOAS" => Self::NoAnswerFromCustomer,
"NOCM" => Self::NotCompliant,
"NOOR" => Self::NoOriginalTransactionReceived,
"PINL" => Self::PinLiabilityShift,
"RC01" => Self::BankIdentifierIncorrect,
"RC07" => Self::InvalidCreditorBicIdentifier,
"RF01" => Self::NotUniqueTransactionReference,
"RR01" => Self::MissingDebtorAccountOrIdentification,
"RR02" => Self::MissingDebtorNameOrAddress,
"RR03" => Self::MissingCreditorNameOrAddress,
"RR04" => Self::RegulatoryReason,
"RUTA" => Self::ReturnUponUnableToApply,
"SL01" => Self::SpecificServiceOfferedByDebtorAgent,
"SL02" => Self::SpecificServiceOfferedByCreditorAgent,
"SL11" => Self::CreditorNotOnWhitelistOfDebtor,
"SL12" => Self::CreditorOnBlacklistOfDebtor,
"SL13" => Self::MaximumNumberOfDirectDebitTransactionsExceeded,
"SL14" => Self::MaximumDirectDebitTransactionAmountExceeded,
"SP01" => Self::PaymentStopped,
"SP02" => Self::PreviouslyStopped,
"SVNR" => Self::ServiceNotRendered,
"TM01" => Self::CutOffTime,
"TRAC" => Self::RemovedFromTracking,
"UPAY" => Self::UnduePayment,
"AC02" => Self::InvalidDebtorAccountNumber,
"AC07" => Self::ClosedCreditorAccountNumber,
"AGNT" => Self::IncorrectAgent,
"AG07" => Self::UnsuccesfulDirectDebit,
"BE10" => Self::InvalidDebtorCountry,
"BE11" => Self::InvalidCreditorCountry,
"BE16" => Self::InvalidDebtorIdentificationCode,
"BE17" => Self::InvalidCreditorIdentificationCode,
"FF03" => Self::InvalidPaymentTypeInformation,
"FF04" => Self::InvalidServiceLevelCode,
"FF06" => Self::InvalidCategoryPurposeCode,
"FF07" => Self::InvalidPurpose,
"G004" => Self::CreditPendingFunds,
"MD05" => Self::CollectionNotDue,
"RC08" => Self::InvalidClearingSystemMemberIdentifier,
"RC11" => Self::InvalidIntermediaryAgent,
"RR05" => Self::RegulatoryInformationInvalid,
"RR06" => Self::TaxInformationInvalid,
"RR07" => Self::RemittanceInformationInvalid,
"RR08" => Self::RemittanceInformationTruncated,
"RR09" => Self::InvalidStructuredCreditorReference,
"RR11" => Self::InvalidDebtorAgentServiceIdentification,
"RR12" => Self::InvalidPartyIdentification,
tag => todo!("handle code {tag:?}"),
pub enum TaxRecordPeriod1Code {
#[doc = "Tax is related to the second month of the period."]
FirstMonth,
#[doc = "Tax is related to the first month of the period."]
SecondMonth,
#[doc = "Tax is related to the third month of the period."]
ThirdMonth,
#[doc = "Tax is related to the fourth month of the period."]
FourthMonth,
#[doc = "Tax is related to the fifth month of the period."]
FifthMonth,
#[doc = "Tax is related to the sixth month of the period."]
SixthMonth,
#[doc = "Tax is related to the seventh month of the period."]
SeventhMonth,
#[doc = "Tax is related to the eighth month of the period."]
EighthMonth,
#[doc = "Tax is related to the ninth month of the period."]
NinthMonth,
#[doc = "Tax is related to the tenth month of the period."]
TenthMonth,
#[doc = "Tax is related to the eleventh month of the period."]
EleventhMonth,
#[doc = "Tax is related to the twelfth month of the period."]
TwelfthMonth,
#[doc = "Tax is related to the first quarter of the period."]
FirstQuarter,
#[doc = "Tax is related to the second quarter of the period."]
SecondQuarter,
#[doc = "Tax is related to the third quarter of the period."]
ThirdQuarter,
#[doc = "Tax is related to the forth quarter of the period."]
FourthQuarter,
#[doc = "Tax is related to the first half of the period."]
FirstHalf,
#[doc = "Tax is related to the second half of the period."]
SecondHalf,
}
impl<'a> TaxRecordPeriod1Code {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"MM01" => Self::FirstMonth,
"MM02" => Self::SecondMonth,
"MM03" => Self::ThirdMonth,
"MM04" => Self::FourthMonth,
"MM05" => Self::FifthMonth,
"MM06" => Self::SixthMonth,
"MM07" => Self::SeventhMonth,
"MM08" => Self::EighthMonth,
"MM09" => Self::NinthMonth,
"MM10" => Self::TenthMonth,
"MM11" => Self::EleventhMonth,
"MM12" => Self::TwelfthMonth,
"QTR1" => Self::FirstQuarter,
"QTR2" => Self::SecondQuarter,
"QTR3" => Self::ThirdQuarter,
"QTR4" => Self::FourthQuarter,
"HLF1" => Self::FirstHalf,
"HLF2" => Self::SecondHalf,
tag => todo!("handle code {tag:?}"),
};
Ok(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Specifies the period related to the tax payment."]
};
Ok(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Specifies a type of financial or commercial document."]
pub enum DocumentType3Code {
#[doc = "Document is an invoice claiming payment for the supply of metered services, for example gas or electricity supplied to a fixed meter."]
MeteredServiceInvoice,
#[doc = "Document is a credit note for the final amount settled for a commercial transaction."]
CreditNoteRelatedToFinancialAdjustment,
#[doc = "Document is a debit note for the final amount settled for a commercial transaction."]
DebitNoteRelatedToFinancialAdjustment,
#[doc = "Document is an invoice."]
CommercialInvoice,
#[doc = "Document is a credit note."]
CreditNote,
#[doc = "Document is a debit note."]
DebitNote,
#[doc = "Document is an invoice for the hiring of human resources or renting goods or equipment."]
HireInvoice,
#[doc = "Document is an invoice issued by the debtor."]
SelfBilledInvoice,
#[doc = "Document is a remittance advice sent separately from the current transaction."]
RemittanceAdviceMessage,
#[doc = "Document is a linked payment instruction to which the current payment instruction is related, for example, in a cover scenario."]
RelatedPaymentInstruction,
#[doc = "Document is an agreement between the parties, stipulating the terms and conditions of the delivery of goods or services."]
CommercialContract,
#[doc = "Document is a pre-agreed or pre-arranged foreign exchange transaction to which the payment transaction refers."]
ForeignExchangeDealReference,
#[doc = "Document is a statement of the transactions posted to the debtor's account at the supplier."]
StatementOfAccount,
#[doc = "Document is a dispatch advice."]
DispatchAdvice,
#[doc = "Document is a purchase order."]
PurchaseOrder,
#[doc = "Document is a structured communication reference provided by the creditor to identify the referred transaction."]
StructuredCommunicationReference,
#[doc = "Document is a shipping notice."]
BillOfLading,
#[doc = "Document is an electronic payment document."]
Voucher,
#[doc = "Document is a payment that applies to a specific source document."]
AccountReceivableOpenItem,
#[doc = "Document is a transaction identifier as assigned by the Trade Services Utility."]
TradeServicesUtilityTransaction,
#[doc = "When the Sale system print the Cashier copy of the Payment receipt."]
CashierReceipt,
#[doc = "When the Sale System requires\tthe POI system to print the Customer receipt."]
CustomerReceipt,
#[doc = "When the POI or the Sale System wants to store a message on the journal printer or electronic journal of the Sale Terminal (it is sometimes a Sale Logging/Journal Printer)."]
Journal,
#[doc = "When the Sale System requires the POI system to print the Sale receipt."]
SaleReceipt,
}
impl<'a> DocumentType3Code {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"MSIN" => Self::MeteredServiceInvoice,
"CNFA" => Self::CreditNoteRelatedToFinancialAdjustment,
"DNFA" => Self::DebitNoteRelatedToFinancialAdjustment,
"CINV" => Self::CommercialInvoice,
"CREN" => Self::CreditNote,
"DEBN" => Self::DebitNote,
"HIRI" => Self::HireInvoice,
"SBIN" => Self::SelfBilledInvoice,
"RADM" => Self::RemittanceAdviceMessage,
"RPIN" => Self::RelatedPaymentInstruction,
"CMCN" => Self::CommercialContract,
"FXDR" => Self::ForeignExchangeDealReference,
"SOAC" => Self::StatementOfAccount,
"DISP" => Self::DispatchAdvice,
"PUOR" => Self::PurchaseOrder,
"SCOR" => Self::StructuredCommunicationReference,
"BOLD" => Self::BillOfLading,
"VCHR" => Self::Voucher,
"AROI" => Self::AccountReceivableOpenItem,
"TSUT" => Self::TradeServicesUtilityTransaction,
"HRCP" => Self::CashierReceipt,
"CRCP" => Self::CustomerReceipt,
"JNRL" => Self::Journal,
"SRCP" => Self::SaleReceipt,
tag => todo!("handle code {tag:?}"),
pub enum DocumentType5Code {
#[doc = "Document is an invoice claiming payment for the supply of metered services, for example gas or electricity supplied to a fixed meter."]
MeteredServiceInvoice,
#[doc = "Document is a credit note for the final amount settled for a commercial transaction."]
CreditNoteRelatedToFinancialAdjustment,
#[doc = "Document is a debit note for the final amount settled for a commercial transaction."]
DebitNoteRelatedToFinancialAdjustment,
#[doc = "Document is an invoice."]
CommercialInvoice,
#[doc = "Document is a credit note."]
CreditNote,
#[doc = "Document is a debit note."]
DebitNote,
#[doc = "Document is an invoice for the hiring of human resources or renting goods or equipment."]
HireInvoice,
#[doc = "Document is an invoice issued by the debtor."]
SelfBilledInvoice,
#[doc = "Document is a remittance advice sent separately from the current transaction."]
RemittanceAdviceMessage,
#[doc = "Document is a linked payment instruction to which the current payment instruction is related, for example, in a cover scenario."]
RelatedPaymentInstruction,
#[doc = "Document is an agreement between the parties, stipulating the terms and conditions of the delivery of goods or services."]
CommercialContract,
#[doc = "Document is a pre-agreed or pre-arranged foreign exchange transaction to which the payment transaction refers."]
ForeignExchangeDealReference,
#[doc = "Document is a statement of the transactions posted to the debtor's account at the supplier."]
StatementOfAccount,
#[doc = "Document is a dispatch advice."]
DispatchAdvice,
#[doc = "Document is a purchase order."]
PurchaseOrder,
#[doc = "Document is a structured communication reference provided by the creditor to identify the referred transaction."]
StructuredCommunicationReference,
#[doc = "Document is a shipping notice."]
BillOfLading,
#[doc = "Document is an electronic payment document."]
Voucher,
#[doc = "Document is a payment that applies to a specific source document."]
AccountReceivableOpenItem,
#[doc = "Document is a transaction identifier as assigned by the Trade Services Utility."]
TradeServicesUtilityTransaction,
#[doc = "When the Sale system print the Cashier copy of the Payment receipt."]
CashierReceipt,
#[doc = "When the Sale System requires\tthe POI system to print the Customer receipt."]
CustomerReceipt,
#[doc = "When the POI or the Sale System wants to store a message on the journal printer or electronic journal of the Sale Terminal (it is sometimes a Sale Logging/Journal Printer)."]
Journal,
#[doc = "When the Sale System requires the POI system to print the Sale receipt."]
SaleReceipt,
}
impl<'a> DocumentType5Code {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"MSIN" => Self::MeteredServiceInvoice,
"CNFA" => Self::CreditNoteRelatedToFinancialAdjustment,
"DNFA" => Self::DebitNoteRelatedToFinancialAdjustment,
"CINV" => Self::CommercialInvoice,
"CREN" => Self::CreditNote,
"DEBN" => Self::DebitNote,
"HIRI" => Self::HireInvoice,
"SBIN" => Self::SelfBilledInvoice,
"RADM" => Self::RemittanceAdviceMessage,
"RPIN" => Self::RelatedPaymentInstruction,
"CMCN" => Self::CommercialContract,
"FXDR" => Self::ForeignExchangeDealReference,
"SOAC" => Self::StatementOfAccount,
"DISP" => Self::DispatchAdvice,
"PUOR" => Self::PurchaseOrder,
"SCOR" => Self::StructuredCommunicationReference,
"BOLD" => Self::BillOfLading,
"VCHR" => Self::Voucher,
"AROI" => Self::AccountReceivableOpenItem,
"TSUT" => Self::TradeServicesUtilityTransaction,
"HRCP" => Self::CashierReceipt,
"CRCP" => Self::CustomerReceipt,
"JNRL" => Self::Journal,
"SRCP" => Self::SaleReceipt,
tag => todo!("handle code {tag:?}"),
};
Ok(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Specifies a type of financial or commercial document."]
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Specifies the method used to deliver the remittance advice information."]
pub enum RemittanceLocationMethod2Code {
#[doc = "Remittance advice information must be faxed."]
Fax,
#[doc = "Remittance advice information must be sent through Electronic Data Interchange (EDI)."]
ElectronicDataInterchange,
#[doc = "Remittance advice information needs to be sent to a Uniform Resource Identifier (URI). URI is a compact string of characters that uniquely identify an abstract or physical resource. URI's are the super-set of identifiers, such as URLs, email addresses, ftp sites, etc, and as such, provide the syntax for all of the identification schemes."]
UniformResourceIdentifier,
#[doc = "Remittance advice information must be sent through e-mail."]
EMail,
#[doc = "Remittance advice information must be sent through postal services."]
Post,
#[doc = "Remittance advice information must be sent through by phone as a short message service (SMS)."]
Sms,
}
impl<'a> RemittanceLocationMethod2Code {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"FAXI" => Self::Fax,
"EDIC" => Self::ElectronicDataInterchange,
"URID" => Self::UniformResourceIdentifier,
"EMAL" => Self::EMail,
"POST" => Self::Post,
"SMSM" => Self::Sms,
tag => todo!("handle code {tag:?}"),
};
Ok(value)
};
Ok(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Specifies the external purpose code in the format of character string with a maximum length of 4 characters.\r\nThe list of valid codes is an external code list published separately.\r\nExternal code sets can be downloaded from www.iso20022.org.\n*`BKDF`-Delayed draw funding. Certain issuers may utilize delayed draw loans whereby the lender is committed to fund cash\nwithin a specified period once a call is made by the issuer. The lender receives a fee for entering into such a\ncommitment\n*`BKFE`-Bank loan fees. Cash activity related to specific bank loan fees, including (a) agent / assignment fees; (b) amendment fees; (c) commitment fees; (d) consent fees; (e) cost of carry fees; (f) delayed compensation fees; (g)\nfacility fees; (h) fronting fees; (i) funding fees; (j) letter of credit assignment fees\n*`BKFM`-Bank loan funding memo. Net cash movement for the loan contract final notification when sent separately from the\nloan contract final notification instruction.\n*`BKIP`-Accrued interest payments. Specific to bank loans.\n*`BKPP`-Principal paydowns. Specific to bank loans\n*`CBLK`-A Service that is settling money for a bulk of card transactions, while referring to a specific transaction file or other information like terminal ID, card acceptor ID or other transaction details.\n*`CDCB`-Purchase of Goods and Services with additional Cash disbursement at the POI (Cashback)\n*`CDCD`-ATM Cash Withdrawal in an unattended or Cash Advance in an attended environment (POI or bank counter)\n*`CDCS`-ATM Cash Withdrawal in an unattended or Cash Advance in an attended environment (POI or bank counter) with surcharging.\n*`CDDP`-A combined service which enables the card acceptor to perform an authorisation for a temporary amount and a completion for the final amount within a limited time frame. Deferred Payment is only available in the unattended environment.\nExamples where this service is widely used are unattended petrol pumps and phone booths\n*`CDOC`-A service which allows the card acceptor to effect a credit to a cardholder' account. Unlike a Merchant Refund, an Original Credit is not preceded by a card payment. This service is used for example for crediting winnings from gaming.\n*`CDQC`-Purchase of Goods which are equivalent to cash like coupons in casinos.\n*`ETUP`-Transaction is related to a Service that is first reserving money from a card account and then is loading an e-purse application by this amount.\n*`FCOL`-A Service that is settling card transaction related fees between two parties.\n*`MTUP`-A Service that is first reserving money from a card account and then is loading a prepaid mobile phone amount by this amount.\n*`ACCT`-Transaction moves funds between 2 accounts of same account holder at the same bank.\n*`CASH`-Transaction is a general cash management instruction.\n*`COLL`-Transaction is a collection of funds initiated via a credit transfer or direct debit.\n*`CSDB`-Transaction is related to cash disbursement.\n*`DEPT`-Transaction is releted to a payment of deposit.\n*`INTC`-Transaction is an intra-company payment, ie, a payment between two companies belonging to the same group.\n*`INTP`-Transaction is a payment between two accounts belonging to the same party (intra-party payment), where party is a natural person (identified by a private ID, not organisation ID).\n*`LIMA`-Bank initiated account transfer to support zero target balance management, pooling or sweeping.\n*`NETT`-Transaction is related to a netting operation.\n*`BFWD`-Cash collateral related to any securities traded out beyond 3 days which include treasury notes, JGBs and Gilts.\n*`CCIR`-Cash Collateral related to a Cross Currency Interest Rate Swap, indicating the exchange of fixed interest payments in one currency for those in another.\n*`CCPC`-Cash Collateral associated with an ISDA or Central Clearing Agreement that is covering the initial margin requirements for OTC trades clearing through a CCP. \n*`CCPM`-Cash Collateral associated with an ISDA or Central Clearing Agreement that is covering the variation margin requirements for OTC trades clearing through a CCP. \n*`CCSM`-CCP Segregated initial margin: Initial margin on OTC Derivatives cleared through a CCP that requires segregation\n*`CRDS`-Cash collateral related to trading of credit default swap.\n*`CRPR`-Cash collateral related to a combination of various types of trades.\n*`CRSP`-Cash collateral related to cash lending/borrowing; letter of Credit; signing of master agreement.\n*`CRTL`-Cash collateral related to opening of a credit line before trading.\n*`EQPT`-Cash collateral related to trading of equity option (Also known as stock options).\n*`EQUS`-Cash collateral related to equity swap trades where the return of an equity is exchanged for either a fixed or a floating rate of interest.\n*`EXPT`-Cash collateral related to trading of an exotic option for example a non-standard option.\n*`EXTD`-Cash collateral related to trading of exchanged traded derivatives in general (Opposite to Over the Counter (OTC)).\n*`FIXI`-Cash collateral related to a fixed income instrument\n*`FWBC`-Cash collateral payment against a Master Forward Agreement (MFA) where the cash is held in a segregated account and is not available for use by the client. Includes any instruments with a forward settling date such TBAs, repurchase agreements and bond forwards\n*`FWCC`-Cash collateral payment against a Master Forward Agreement (MFA) where the cash is owned and may be used by the client when returned. Includes any instruments with a forward settling date such TBAs, repurchase agreements and bond forwards\n*`FWSB`-Any cash payment related to the collateral for a Master Agreement forward, which is segregated, and not available for use by the client. Example master agreement forwards include TBA, repo and Bond Forwards.\n*`FWSC`-Any cash payment related to the collateral for a Master agreement forward, which is owned by the client and is available for use by the client when it is returned to them from the segregated account. Example master agreement forwards include TBA, repo and Bond Forwards.\n*`MARG`-Daily margin on listed derivatives – not segregated as collateral associated with an FCM agreement. Examples\ninclude listed futures and options margin payments; premiums for listed options not covered in the MT54X message\n*`MBSB`-MBS Broker Owned Segregated (40Act/Dodd Frank) Cash Collateral - Any cash payment related to the collateral for a Mortgage Back Security, which is segregated, and not available for use by the client.\n*`MBSC`-MBS Client Owned Cash Segregated (40Act/Dodd Frank) Cash Collateral - Any cash payment related to the collateral for a Mortgage Back Security, which is owned by the client and is available for use by the client when it is returned to them from the segregated account\n*`MGCC`-Initial futures margin. Where such payment is owned by the client and is available for use by them on return\n*`MGSC`-Margin Client Owned Segregated Cash Collateral - Any cash payment related to the collateral for initial futures margin, which is owned by the client and is available for use by the client when it is returned to them from the segregated account.\n*`OCCC`-Client owned collateral identified as eligible for OCC pledging\n*`OPBC`-Cash collateral payment for OTC options associated with an FCM agreement. Where such payment is segregated and not available for use by the client\n*`OPCC`-Cash collateral payment for OTC options associated with an FCM agreement. Where such payment is not segregated and is available for use by the client upon return\n*`OPSB`-Option Broker Owned Segregated Cash Collateral - Any cash payment related to the collateral for an OTC option, which is segregated, and not available for use by the client.\n*`OPSC`-Option Client Owned Cash Segregated Cash Collateral - Any cash payment related to the collateral for an OTC option, which is owned by the client and is available for use by the client when it is returned to them from the segregated account\n*`OPTN`-Cash collateral related to trading of option on Foreign Exchange.\n*`OTCD`-Cash collateral related to Over-the-counter (OTC) Derivatives in general for example contracts which are traded and privately negotiated.\n*`REPO`-Cash collateral related to a repurchase agreement transaction.\n*`RPBC`-Bi-lateral repo broker owned collateral associated with a repo master agreement – GMRA or MRA Master Repo\nAgreements\n*`RPCC`-Repo client owned collateral associated with a repo master agreement – GMRA or MRA Master Repo Agreements\n*`RPSB`-Bi-lateral repo broker owned segregated cash collateral associated with a repo master agreement\n*`RPSC`-Repo client owned segregated collateral associated with a repo master agreement\n*`RVPO`-Cash collateral related to a reverse repurchase agreement transaction.\n*`SBSC`-Cash collateral related to a Securities Buy Sell Sell Buy Back\n*`SCIE`-Cash collateral related to Exotic single currency interest rate swap.\n*`SCIR`-Cash collateral related to Single Currency Interest Rate Swap.\n*`SCRP`-Cash collateral related to Combination of securities-related exposure types.\n*`SHBC`-Short Sale broker owned collateral associated with a prime broker agreement\n*`SHCC`-Short Sale client owned collateral associated with a prime brokerage agreement\n*`SHSL`-Cash Collateral related to a Short Sell\n*`SLEB`-Cash collateral related to Securities lending and borrowing.\n*`SLOA`-Cash collateral related to a Secured loan.\n*`SWBC`-Cash collateral payment for swaps associated with an ISDA agreement. . Where such payment is segregated and\nnot available for use by the client. Includes any cash collateral payments made under the terms of a CSA agreement\nfor instruments such as swaps and FX forwards.\n*`SWCC`-Cash collateral payment for swaps associated with an ISDA agreement. Where such payment is not segregated and\nis available for use by the client upon return. Includes any cash collateral payments made under the terms of a CSA\nagreement for instruments such as swaps and FX forwards.\n*`SWPT`-Cash collateral related to an option on interest rate swap.\n*`SWSB`-Swaps Broker Owned Segregated Cash Collateral - Any cash payment related to the collateral for Swap margin ,\nwhich is segregated, and not available for use by the client. This includes any collateral identified in a CSA\nagreement such as Swap or FX Forward collateral.\n*`SWSC`-Swaps Client Owned Segregated Cash Collateral - Any cash payment related to the collateral for Swap margin,\nwhich is owned by the client and is available for use by the client when returned from the segregated account. This\nincludes any collateral identified in a CSA agreement such as Swap or FX Forward collateral.\n*`TBAS`-Cash collateral related to a To Be Announced (TBA)\n*`TBBC`-Cash collateral payment (segregated) for TBA securities associated with a TBA Master Agreement. Where such payment is segregated and not available for use by the client.\n*`TBCC`-Cash collateral payment (for use by client)for TBA securities associated with a TBA Master Agreement. Where such payment is not segregated and is available for use by the client upon return.\n*`TRCP`-Cash collateral related to a combination of treasury-related exposure types.\n*`AGRT`-Transaction is related to the agricultural domain.\n*`AREN`-Transaction is related to a payment associated with an Account Receivable Entry\n*`BEXP`-Transaction is related to a payment of business expenses.\n*`BOCE`-Transaction is related to a payment associated with a Back Office Conversion Entry\n*`COMC`-Transaction is related to a payment of commercial credit or debit. (formerly CommercialCredit)\n*`CPYR`-Transaction is payment of copyright.\n*`GDDS`-Transaction is related to purchase and sale of goods.\n*`GDSV`-Transaction is related to purchase and sale of goods and services.\n*`GSCB`-Transaction is related to purchase and sale of goods and services with cash back.\n*`LICF`-Transaction is payment of a license fee.\n*`MP2B`-A service which enables a user to use an app on its mobile to pay a merchant or other business payees by initiating a payment message. Within this context, the account information or an alias of the payee might be transported through different channels to the app, for example QR Code, NFC, Bluetooth, other Networks.\n*`POPE`-Transaction is related to a payment associated with a Point of Purchase Entry.\n*`ROYA`-Transaction is the payment of royalties.\n*`SCVE`-Transaction is related to purchase and sale of services.\n*`SERV`-Transaction is related to service charges charged by a service provider.\n*`SUBS`-Transaction is related to a payment of information or entertainment services either in printed or electronic form.\n*`SUPP`-Transaction is related to a payment to a supplier.\n*`TRAD`-Transaction is related to a trade services operation.\n*`CHAR`-Transaction is a payment for charity reasons.\n*`COMT`-Transaction is a payment used by a third party who can collect funds to pay on behalf of consumers, ie credit counseling or bill payment companies.\n*`MP2P`-A service which enables a user to use an app on its mobile to initiate moving funds from his/her bank account to another person’s bank account while not using the account number but an alias information like an MSISDN as account addressing information in his/her app.\n*`ECPG`-E-Commerce payment with payment guarantee of the issuing bank.\n*`ECPR`-E-Commerce payment return.\n*`ECPU`-E-Commerce payment without payment guarantee of the issuing bank.\n*`EPAY`-Transaction is related to ePayment.\n*`CLPR`-Transaction is a payment of car loan principal payment.\n*`COMP`-Transaction is related to the payment of a compensation relating to interest loss/value date adjustment and can include fees.\n*`DBTC`-Collection of funds initiated via a debit transfer.\n*`GOVI`-Transaction is related to a payment of government insurance.\n*`HLRP`-Transaction is related to a payment of property loan.\n*`HLST`-Transaction is related to the settlement of a property loan.\n*`INPC`-Transaction is a payment of car insurance premium.\n*`INPR`-Transaction is related to an insurance premium refund.\n*`INSC`-Transaction is related to the payment of an insurance claim.\n*`INSU`-Transaction is payment of an insurance premium.\n*`INTE`-Transaction is payment of interest.\n*`LBRI`-Transaction is a payment of labor insurance.\n*`LIFI`-Transaction is a payment of life insurance.\n*`LOAN`-Transaction is related to transfer of loan to borrower.\n*`LOAR`-Transaction is related to repayment of loan to lender.\n*`PENO`-Payment based on enforcement orders except those arising from judicial alimony decrees.\n*`PPTI`-Transaction is a payment of property insurance.\n*`RELG`-Transaction is for general rental/lease.\n*`RINP`-Transaction is related to a payment of a recurring installment made at regular intervals.\n*`TRFD`-Transaction is related to a payment of a trust fund.\n*`FORW`-FX trades with a value date in the future.\n*`FXNT`-FX netting if cash is moved by separate wire instead of within the closing FX instruction\n*`ADMG`-Transaction is related to a payment associated with administrative management.\n*`ADVA`-Transaction is an advance payment.\n*`BCDM`-Transaction is the payment of a domestic bearer cheque.\n*`BCFG`-Transaction is the payment of a foreign bearer cheque.\n*`BLDM`-Transaction is related to a payment associated with building maintenance.\n*`BNET`-Bond Forward pair-off cash net movement\n*`CBFF`-Transaction is related to capital building fringe fortune, ie capital building in general\n*`CBFR`-Transaction is related to capital building fringe fortune for retirement\n*`CCRD`-Transaction is related to a payment of credit card account.\n*`CDBL`-Transaction is related to a payment of credit card bill.\n*`CFEE`-Transaction is related to a payment of cancellation fee.\n*`CGDD`-Transaction is related to a direct debit where the mandate was generated by using data from a payment card at the point of sale.\n*`CORT`-Transaction is related to settlement of a trade, e.g. a foreign exchange deal or a securities transaction.\n*`COST`-Transaction is related to payment of costs.\n*`CPKC`-Transaction is related to carpark charges.\n*`DCRD`-Transaction is related to a debit card payment.\n*`DSMT`-Transaction is the payment of a disbursement due to a specific type of printed order for a payment of a specified sum, issued by a bank or a post office (Zahlungsanweisung zur Verrechnung)\n*`DVPM`-Code used to pre-advise the account servicer of a forthcoming deliver against payment instruction.\n*`EDUC`-Transaction is related to a payment of study/tuition fees.\n*`FACT`-Payment related to a factor update\n*`FAND`-Financial aid by State authorities for abolition of consequences of natural disasters.\n*`FCPM`-Transaction is the payment for late fees & charges. E.g Credit card charges\n*`FEES`-Payment of fees/charges.\n*`GIFT`-Payment with no commercial or statutory purpose.\n*`GOVT`-Transaction is a payment to or from a government department.\n*`ICCP`-Transaction is reimbursement of credit card payment.\n*`IDCP`-Transaction is reimbursement of debit card payment.\n*`IHRP`-Transaction is payment for an installment/hire-purchase agreement.\n*`INSM`-Transaction is related to a payment of an installment.\n*`IVPT`-Transaction is the payment for invoices.\n*`MCDM`-Transaction is the payment of a domestic multi-currency cheque\n*`MCFG`-Transaction is the payment of a foreign multi-currency cheque\n*`MSVC`-Transaction is related to a payment for multiple service types.\n*`NOWS`-Transaction is related to a payment for type of services not specified elsewhere.\n*`OCDM`-Transaction is the payment of a domestic order cheque\n*`OCFG`-Transaction is the payment of a foreign order cheque\n*`OFEE`-Transaction is related to a payment of opening fee.\n*`OTHR`-Other payment purpose.\n*`PADD`-Transaction is related to a pre-authorized debit origination\n*`PTSP`-Transaction is related to payment terms specifications\n*`RCKE`-Transaction is related to a payment associated with a re-presented check entry\n*`RCPT`-Transaction is related to a payment of receipt.\n*`REBT`-Transaction is the payment of a rebate.\n*`REFU`-Transaction is the payment of a refund.\n*`RENT`-Transaction is the payment of rent.\n*`REOD`-Transaction is for account overdraft repayment\n*`RIMB`-Transaction is related to a reimbursement of a previous erroneous transaction.\n*`RPNT`-Bi-lateral repo interest net/bulk payment at rollover/pair-off or other closing scenarios where applicable\n*`RRBN`-Cash payment resulting from a Round Robin\n*`RRCT`-Transaction is related to a reimbursement for commercial reasons of a correctly received credit transfer.\n*`RRTP`-Transaction is related to a Request to Pay.\n*`RVPM`-Code used to pre-advise the account servicer of a forthcoming receive against payment instruction.\n*`SLPI`-Transaction is payment of a well formatted payment slip.\n*`SPLT`-Split payments. To be used when cash and security movements for a security trade settlement are instructed\nseparately.\n*`STDY`-Transaction is related to a payment of study/tuition costs.\n*`TBAN`-TBA pair-off cash wire net movement\n*`TBIL`-Transaction is related to a payment of telecommunications related bill.\n*`TCSC`-Transaction is related to a payment associated with charges levied by a town council.\n*`TELI`-Transaction is related to a payment initiated via telephone.\n*`TMPG`-Cash payment resulting from a TMPG Claim\n*`TPRI`-Tri-Party Repo related interest\n*`TPRP`-Tri-party Repo related net gain/loss cash movement\n*`TRNC`-Transaction is payment of a beneficiary prefilled payment slip where beneficiary to payer information is truncated.\n*`TRVC`-Transaction is the payment of a travellers cheque\n*`WEBI`-Transaction is related to a payment initiated via internet.\n*`IPAY`-Transaction in which the amount is available to the payee immediately.\n*`IPCA`-Transaction in which the Return of the amount is fully returned.\n*`IPDO`-Transaction in which the amount is available to the payee immediately, done for donations, with sending the address data of the payer.\n*`IPEA`-Transaction in which the amount is available to the payee immediately, done in E-commerce, without sending the address data of the payer.\n*`IPEC`-Transaction in which the amount is available to the payee immediately, done in E-commerce, with sending the address data of the payer.\n*`IPEW`-Transaction in which the amount is available to the payee immediately, done in E-commerce.\n*`IPPS`-Transaction in which the amount is available to the payee immediately, done at POS.\n*`IPRT`-Transaction in which the Return of the amount is fully or partial returned.\n*`IPU2`-Transaction is made via an unattending vending machine by using 2-factor-authentification.\n*`IPUW`-Transaction is made via an unattending vending machine by without using 2-factor-authentification.\n*`ANNI`-Transaction settles annuity related to credit, insurance, investments, other.n\n*`CAFI`-Transaction is the payment of custodian account management fee where custodian bank and current account servicing bank coincide\n*`CFDI`-Transaction is the payment of capital falling due where custodian bank and current account servicing bank coincide\n*`CMDT`-Transaction is payment of commodities.\n*`DERI`-Transaction is related to a derivatives transaction\n*`DIVD`-Transaction is payment of dividends.\n*`FREX`-Transaction is related to a foreign exchange operation.\n*`HEDG`-Transaction is related to a hedging operation.\n*`INVS`-Transaction is for the payment of mutual funds, investment products and shares\n*`PRME`-Transaction is related to a precious metal operation.\n*`SAVG`-Transfer to savings/retirement account.\n*`SECU`-Transaction is the payment of securities.\n*`SEPI`-Transaction is the payment of a purchase of securities where custodian bank and current account servicing bank coincide\n*`TREA`-Transaction is related to treasury operations.\n*`UNIT`-Transaction is purchase of Unit Trust\n*`FNET`-Cash associated with a netting of futures payments. Refer to CCPM codeword for netting of initial and variation margin through a CCP\n*`FUTR`-Cash related to futures trading activity.\n*`ANTS`-Transaction is a payment for anesthesia services.\n*`CVCF`-Transaction is a payment for convalescence care facility services.\n*`DMEQ`-Transaction is a payment is for use of durable medical equipment.\n*`DNTS`-Transaction is a payment for dental services.\n*`HLTC`-Transaction is a payment for home health care services.\n*`HLTI`-Transaction is a payment of health insurance.\n*`HSPC`-Transaction is a payment for hospital care services.\n*`ICRF`-Transaction is a payment for intermediate care facility services.\n*`LTCF`-Transaction is a payment for long-term care facility services.\n*`MAFC`-Transaction is contribution to medical aid fund.\n*`MARF`-Transaction is related to a medical aid refund.\n*`MDCS`-Transaction is a payment for medical care services.\n*`VIEW`-Transaction is a payment for vision care services.\n*`CDEP`-Payment related to a credit default event\n*`SWFP`-Final payments for a swap contract\n*`SWPP`-Partial payment for a swap contract\n*`SWRS`-Reset payment for a swap contract\n*`SWUF`-Upfront payment for a swap contract\n*`ADCS`-Payments for donation, sponsorship, advisory, intellectual and other copyright services.\n*`AEMP`-Payment concerning active employment policy.\n*`ALLW`-Transaction is the payment of allowances.\n*`ALMY`-Transaction is the payment of alimony.\n*`BBSC`-Transaction is related to a payment made as incentive to encourage parents to have more children\n*`BECH`-Transaction is related to a payment made to assist parent/guardian to maintain child.\n*`BENE`-Transaction is related to a payment to a person who is unemployed/disabled.\n*`BONU`-Transaction is related to payment of a bonus.\n*`CCHD`-Payments made by Government institute related to cash compensation, helplessness, disability. These payments are made by the Government institution as a social benefit in addition to regularly paid salary or pension.\n*`COMM`-Transaction is payment of commission.\n*`CSLP`-Transaction is a payment by a company to a bank for financing social loans to employees.\n*`GFRP`-Compensation to unemployed persons during insolvency procedures.\n*`GVEA`-Transaction is payment to category A Austrian government employees.\n*`GVEB`-Transaction is payment to category B Austrian government employees.\n*`GVEC`-Transaction is payment to category C Austrian government employees.\n*`GVED`-Transaction is payment to category D Austrian government employees.\n*`GWLT`-Payment to victims of war violence and to disabled soldiers.\n*`HREC`-Transaction is a contribution by an employer to the housing expenditures (purchase, construction, renovation) of the employees within a tax free fringe benefit system \n*`PAYR`-Transaction is related to the payment of payroll.\n*`PEFC`-Transaction is contribution to pension fund.\n*`PENS`-Transaction is the payment of pension.\n*`PRCP`-Transaction is related to a payment of a price.\n*`RHBS`-Benefit for the duration of occupational rehabilitation.\n*`SALA`-Transaction is the payment of salaries.\n*`SPSP`-Salary or pension payment for more months in one amount or a delayed payment of salaries or pensions.\n*`SSBE`-Transaction is a social security benefit, ie payment made by a government to support individuals.\n*`LBIN`-Net payment related to a buy-in. When an investment manager is bought in on a sell trade that fails due to a failed securities lending recall, the IM may seize the underlying collateral to pay for the buy-in. Any difference between the value of the collateral and the sell proceeds would be paid or received under this code\n*`LCOL`-Free movement of cash collateral. Cash collateral paid by the borrower is done separately from the delivery of the shares at loan opening or return of collateral done separately from return of the loaned security. Note: common when the currency of the security is different the currency of the cash collateral.\n*`LFEE`-Fee payments, other than rebates, for securities lending. Includes (a) exclusive fees; (b) transaction fees; (c)\ncustodian fees; (d) minimum balance fees\n*`LMEQ`-Cash collateral payments resulting from the marked-to-market of a portfolio of loaned equity securities\n*`LMFI`-Cash collateral payments resulting from the marked-to-market of a portfolio of loaned fixed income securities\n*`LMRK`-Cash collateral payments resulting from the marked-to-market of a portfolio of loaned securities where the instrument\ntypes are not specified\n*`LREB`-Securities lending rebate payments\n*`LREV`-Revenue payments made by the lending agent to the client\n*`LSFL`-Payments made by a borrower to a lending agent to satisfy claims made by the investment manager related to sell fails from late loan recall deliveries\n*`ESTX`-Transaction is related to a payment of estate tax.\n*`FWLV`-Transaction is related to a payment of Foreign Worker Levy\n*`GSTX`-Transaction is the payment of Goods & Services Tax\n*`HSTX`-Transaction is related to a payment of housing tax.\n*`INTX`-Transaction is related to a payment of income tax.\n*`NITX`-Transaction is related to a payment of net income tax.\n*`PTXP`-Transaction is related to a payment of property tax.\n*`RDTX`-Transaction is related to a payment of road tax.\n*`TAXS`-Transaction is the payment of taxes.\n*`VATX`-Transaction is the payment of value added tax.\n*`WHLD`-Transaction is related to a payment of withholding tax.\n*`TAXR`-Transaction is the refund of a tax payment or obligation.\n*`B112`-US mutual fund trailer fee (12b-1) payment\n*`BR12`-US mutual fund trailer fee (12b-1) rebate payment\n*`TLRF`-Any non-US mutual fund trailer fee (retrocession) payment (use ISIN to determine onshore versus offshore designation)\n*`TLRR`-Any non-US mutual fund trailer fee (retrocession) rebate payment (use ISIN to determine onshore versus offshore designation)\n*`AIRB`-Transaction is a payment for air transport related business.\n*`BUSB`-Transaction is a payment for bus transport related business.\n*`FERB`-Transaction is a payment for ferry related business.\n*`RLWY`-Transaction is a payment for railway transport related business.\n*`TRPT`-Transaction is for the payment to top-up pre-paid card and electronic road pricing for the purpose of transportation\n*`CBTV`-Transaction is related to a payment of cable TV bill.\n*`ELEC`-Transaction is related to a payment of electricity bill.\n*`ENRG`-Transaction is related to a utility operation.\n*`GASB`-Transaction is related to a payment of gas bill.\n*`NWCH`-Transaction is related to a payment of network charges.\n*`NWCM`-Transaction is related to a payment of network communication.\n*`OTLC`-Transaction is related to a payment of other telecom related bill.\n*`PHON`-Transaction is related to a payment of telephone bill.\n*`UBIL`-Transaction is for the payment to common utility provider that provide gas, water and/or electricity.\n*`WTER`-Transaction is related to a payment of water bill.\n*`BOND`-Securities Lending-Settlement of Bond transaction.\n*`CABD`-Securities Lending-Settlement of Corporate Actions: Bonds transactions.\n*`CAEQ`-Securities Lending-Settlement of Corporate Actions: Equities transactions.\n*`CBCR`-Card Settlement-Settlement of Credit Card transactions.\n*`DBCR`-Card Settlement-Settlement of Debit Card transactions.\n*`DICL`-Card Settlement-Settlement of Diners transactions.\n*`EQTS`-Securities Lending-Settlement of Equities transactions.\n*`FLCR`-Card Settlement-Settlement of Fleet transactions.\n*`EFTC`-Utilities-Settlement of Low value Credit transactions.\n*`EFTD`-Utilities-Settlement of Low value Debit transactions.\n*`MOMA`-Securities Lending-ettlement of Money Market PCH.\n*`RAPI`-Instant Payments-Settlement of Rapid Payment Instruction (RPI) transactions.\n*`GAMB`-General-Payments towards a purchase or winnings received from gambling, betting or other wagering activities.\n*`LOTT`-General-Payment towards a purchase or winnings received from lottery activities.\n*`AMEX`-Card Settlement-Settlement of AMEX transactions.\n*`SASW`-Card Settlement-Settlement of ATM transactions.\n*`AUCO`-Utilities-Settlement of Authenticated Collections transactions.\n*`PCOM`-Final payment to complete the purchase of a property.\n*`PDEP`-Payment of the deposit required towards purchase of a property.\n*`PLDS`-Payment of funds from a lender as part of the issuance of a property loan.\n*`PLRF`-Transfer or extension of a property financing arrangement to a new deal or loan provider, without change of ownership of property.\n*`GAFA`-Salary and Benefits-Allowance from government to support family.\n*`GAHO`-Salary and Benefits-Allowance from government to individuals to support payments of housing.\n*`CPEN`-Cash penalties related to securities transaction, including CSDR Settlement Discipline Regime.\n*`DEPD`-Transaction is related to a payment concerning dependent support, for example child support or support for a person substantially financially dependent on the support provider.\n*`RETL`-Retail payment including e-commerce and online shopping."]
pub enum ExternalPurpose1Code {
Bkdf,
Bkfe,
Bkfm,
Bkip,
Bkpp,
Cblk,
Cdcb,
Cdcd,
Cdcs,
Cddp,
Cdoc,
Cdqc,
Etup,
Fcol,
Mtup,
Acct,
Cash,
Coll,
Csdb,
Dept,
Intc,
Intp,
Lima,
Nett,
Bfwd,
Ccir,
Ccpc,
Ccpm,
Ccsm,
Crds,
Crpr,
Crsp,
Crtl,
Eqpt,
Equs,
Expt,
Extd,
Fixi,
Fwbc,
Fwcc,
Fwsb,
Fwsc,
Marg,
Mbsb,
Mbsc,
Mgcc,
Mgsc,
Occc,
Opbc,
Opcc,
Opsb,
Opsc,
Optn,
Otcd,
Repo,
Rpbc,
Rpcc,
Rpsb,
Rpsc,
Rvpo,
Sbsc,
Scie,
Scir,
Scrp,
Shbc,
Shcc,
Shsl,
Sleb,
Sloa,
Swbc,
Swcc,
Swpt,
Swsb,
Swsc,
Tbas,
Tbbc,
Tbcc,
Trcp,
Agrt,
Aren,
Bexp,
Boce,
Comc,
Cpyr,
Gdds,
Gdsv,
Gscb,
Licf,
Mp2b,
Pope,
Roya,
Scve,
Serv,
Subs,
Supp,
Trad,
Char,
Comt,
Mp2p,
Ecpg,
Ecpr,
Ecpu,
Epay,
Clpr,
Comp,
Dbtc,
Govi,
Hlrp,
Hlst,
Inpc,
Inpr,
Insc,
Insu,
Inte,
Lbri,
Lifi,
Loan,
Loar,
Peno,
Ppti,
Relg,
Rinp,
Trfd,
Forw,
Fxnt,
Admg,
Adva,
Bcdm,
Bcfg,
Bldm,
Bnet,
Cbff,
Cbfr,
Ccrd,
Cdbl,
Cfee,
Cgdd,
Cort,
Cost,
Cpkc,
Dcrd,
Dsmt,
Dvpm,
Educ,
Fact,
Fand,
Fcpm,
Fees,
Gift,
Govt,
Iccp,
Idcp,
Ihrp,
Insm,
Ivpt,
Mcdm,
Mcfg,
Msvc,
Nows,
Ocdm,
Ocfg,
Ofee,
Othr,
Padd,
Ptsp,
Rcke,
Rcpt,
Rebt,
Refu,
Rent,
Reod,
Rimb,
Rpnt,
Rrbn,
Rrct,
Rrtp,
Rvpm,
Slpi,
Splt,
Stdy,
Tban,
Tbil,
Tcsc,
Teli,
Tmpg,
Tpri,
Tprp,
Trnc,
Trvc,
Webi,
Ipay,
Ipca,
Ipdo,
Ipea,
Ipec,
Ipew,
Ipps,
Iprt,
Ipu2,
Ipuw,
Anni,
Cafi,
Cfdi,
Cmdt,
Deri,
Divd,
Frex,
Hedg,
Invs,
Prme,
Savg,
Secu,
Sepi,
Trea,
Unit,
Fnet,
Futr,
Ants,
Cvcf,
Dmeq,
Dnts,
Hltc,
Hlti,
Hspc,
Icrf,
Ltcf,
Mafc,
Marf,
Mdcs,
View,
Cdep,
Swfp,
Swpp,
Swrs,
Swuf,
Adcs,
Aemp,
Allw,
Almy,
Bbsc,
Bech,
Bene,
Bonu,
Cchd,
Comm,
Cslp,
Gfrp,
Gvea,
Gveb,
Gvec,
Gved,
Gwlt,
Hrec,
Payr,
Pefc,
Pens,
Prcp,
Rhbs,
Sala,
Spsp,
Ssbe,
Lbin,
Lcol,
Lfee,
Lmeq,
Lmfi,
Lmrk,
Lreb,
Lrev,
Lsfl,
Estx,
Fwlv,
Gstx,
Hstx,
Intx,
Nitx,
Ptxp,
Rdtx,
Taxs,
Vatx,
Whld,
Taxr,
B112,
Br12,
Tlrf,
Tlrr,
Airb,
Busb,
Ferb,
Rlwy,
Trpt,
Cbtv,
Elec,
Enrg,
Gasb,
Nwch,
Nwcm,
Otlc,
Phon,
Ubil,
Wter,
Bond,
Cabd,
Caeq,
Cbcr,
Dbcr,
Dicl,
Eqts,
Flcr,
Eftc,
Eftd,
Moma,
Rapi,
Gamb,
Lott,
Amex,
Sasw,
Auco,
Pcom,
Pdep,
Plds,
Plrf,
Gafa,
Gaho,
Cpen,
Depd,
Retl,
}
impl<'a> ExternalPurpose1Code {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"BKDF" => Self::Bkdf,
"BKFE" => Self::Bkfe,
"BKFM" => Self::Bkfm,
"BKIP" => Self::Bkip,
"BKPP" => Self::Bkpp,
"CBLK" => Self::Cblk,
"CDCB" => Self::Cdcb,
"CDCD" => Self::Cdcd,
"CDCS" => Self::Cdcs,
"CDDP" => Self::Cddp,
"CDOC" => Self::Cdoc,
"CDQC" => Self::Cdqc,
"ETUP" => Self::Etup,
"FCOL" => Self::Fcol,
"MTUP" => Self::Mtup,
"ACCT" => Self::Acct,
"CASH" => Self::Cash,
"COLL" => Self::Coll,
"CSDB" => Self::Csdb,
"DEPT" => Self::Dept,
"INTC" => Self::Intc,
"INTP" => Self::Intp,
"LIMA" => Self::Lima,
"NETT" => Self::Nett,
"BFWD" => Self::Bfwd,
"CCIR" => Self::Ccir,
"CCPC" => Self::Ccpc,
"CCPM" => Self::Ccpm,
"CCSM" => Self::Ccsm,
"CRDS" => Self::Crds,
"CRPR" => Self::Crpr,
"CRSP" => Self::Crsp,
"CRTL" => Self::Crtl,
"EQPT" => Self::Eqpt,
"EQUS" => Self::Equs,
"EXPT" => Self::Expt,
"EXTD" => Self::Extd,
"FIXI" => Self::Fixi,
"FWBC" => Self::Fwbc,
"FWCC" => Self::Fwcc,
"FWSB" => Self::Fwsb,
"FWSC" => Self::Fwsc,
"MARG" => Self::Marg,
"MBSB" => Self::Mbsb,
"MBSC" => Self::Mbsc,
"MGCC" => Self::Mgcc,
"MGSC" => Self::Mgsc,
"OCCC" => Self::Occc,
"OPBC" => Self::Opbc,
"OPCC" => Self::Opcc,
"OPSB" => Self::Opsb,
"OPSC" => Self::Opsc,
"OPTN" => Self::Optn,
"OTCD" => Self::Otcd,
"REPO" => Self::Repo,
"RPBC" => Self::Rpbc,
"RPCC" => Self::Rpcc,
"RPSB" => Self::Rpsb,
"RPSC" => Self::Rpsc,
"RVPO" => Self::Rvpo,
"SBSC" => Self::Sbsc,
"SCIE" => Self::Scie,
"SCIR" => Self::Scir,
"SCRP" => Self::Scrp,
"SHBC" => Self::Shbc,
"SHCC" => Self::Shcc,
"SHSL" => Self::Shsl,
"SLEB" => Self::Sleb,
"SLOA" => Self::Sloa,
"SWBC" => Self::Swbc,
"SWCC" => Self::Swcc,
"SWPT" => Self::Swpt,
"SWSB" => Self::Swsb,
"SWSC" => Self::Swsc,
"TBAS" => Self::Tbas,
"TBBC" => Self::Tbbc,
"TBCC" => Self::Tbcc,
"TRCP" => Self::Trcp,
"AGRT" => Self::Agrt,
"AREN" => Self::Aren,
"BEXP" => Self::Bexp,
"BOCE" => Self::Boce,
"COMC" => Self::Comc,
"CPYR" => Self::Cpyr,
"GDDS" => Self::Gdds,
"GDSV" => Self::Gdsv,
"GSCB" => Self::Gscb,
"LICF" => Self::Licf,
"MP2B" => Self::Mp2b,
"POPE" => Self::Pope,
"ROYA" => Self::Roya,
"SCVE" => Self::Scve,
"SERV" => Self::Serv,
"SUBS" => Self::Subs,
"SUPP" => Self::Supp,
"TRAD" => Self::Trad,
"CHAR" => Self::Char,
"COMT" => Self::Comt,
"MP2P" => Self::Mp2p,
"ECPG" => Self::Ecpg,
"ECPR" => Self::Ecpr,
"ECPU" => Self::Ecpu,
"EPAY" => Self::Epay,
"CLPR" => Self::Clpr,
"COMP" => Self::Comp,
"DBTC" => Self::Dbtc,
"GOVI" => Self::Govi,
"HLRP" => Self::Hlrp,
"HLST" => Self::Hlst,
"INPC" => Self::Inpc,
"INPR" => Self::Inpr,
"INSC" => Self::Insc,
"INSU" => Self::Insu,
"INTE" => Self::Inte,
"LBRI" => Self::Lbri,
"LIFI" => Self::Lifi,
"LOAN" => Self::Loan,
"LOAR" => Self::Loar,
"PENO" => Self::Peno,
"PPTI" => Self::Ppti,
"RELG" => Self::Relg,
"RINP" => Self::Rinp,
"TRFD" => Self::Trfd,
"FORW" => Self::Forw,
"FXNT" => Self::Fxnt,
"ADMG" => Self::Admg,
"ADVA" => Self::Adva,
"BCDM" => Self::Bcdm,
"BCFG" => Self::Bcfg,
"BLDM" => Self::Bldm,
"BNET" => Self::Bnet,
"CBFF" => Self::Cbff,
"CBFR" => Self::Cbfr,
"CCRD" => Self::Ccrd,
"CDBL" => Self::Cdbl,
"CFEE" => Self::Cfee,
"CGDD" => Self::Cgdd,
"CORT" => Self::Cort,
"COST" => Self::Cost,
"CPKC" => Self::Cpkc,
"DCRD" => Self::Dcrd,
"DSMT" => Self::Dsmt,
"DVPM" => Self::Dvpm,
"EDUC" => Self::Educ,
"FACT" => Self::Fact,
"FAND" => Self::Fand,
"FCPM" => Self::Fcpm,
"FEES" => Self::Fees,
"GIFT" => Self::Gift,
"GOVT" => Self::Govt,
"ICCP" => Self::Iccp,
"IDCP" => Self::Idcp,
"IHRP" => Self::Ihrp,
"INSM" => Self::Insm,
"IVPT" => Self::Ivpt,
"MCDM" => Self::Mcdm,
"MCFG" => Self::Mcfg,
"MSVC" => Self::Msvc,
"NOWS" => Self::Nows,
"OCDM" => Self::Ocdm,
"OCFG" => Self::Ocfg,
"OFEE" => Self::Ofee,
"OTHR" => Self::Othr,
"PADD" => Self::Padd,
"PTSP" => Self::Ptsp,
"RCKE" => Self::Rcke,
"RCPT" => Self::Rcpt,
"REBT" => Self::Rebt,
"REFU" => Self::Refu,
"RENT" => Self::Rent,
"REOD" => Self::Reod,
"RIMB" => Self::Rimb,
"RPNT" => Self::Rpnt,
"RRBN" => Self::Rrbn,
"RRCT" => Self::Rrct,
"RRTP" => Self::Rrtp,
"RVPM" => Self::Rvpm,
"SLPI" => Self::Slpi,
"SPLT" => Self::Splt,
"STDY" => Self::Stdy,
"TBAN" => Self::Tban,
"TBIL" => Self::Tbil,
"TCSC" => Self::Tcsc,
"TELI" => Self::Teli,
"TMPG" => Self::Tmpg,
"TPRI" => Self::Tpri,
"TPRP" => Self::Tprp,
"TRNC" => Self::Trnc,
"TRVC" => Self::Trvc,
"WEBI" => Self::Webi,
"IPAY" => Self::Ipay,
"IPCA" => Self::Ipca,
"IPDO" => Self::Ipdo,
"IPEA" => Self::Ipea,
"IPEC" => Self::Ipec,
"IPEW" => Self::Ipew,
"IPPS" => Self::Ipps,
"IPRT" => Self::Iprt,
"IPU2" => Self::Ipu2,
"IPUW" => Self::Ipuw,
"ANNI" => Self::Anni,
"CAFI" => Self::Cafi,
"CFDI" => Self::Cfdi,
"CMDT" => Self::Cmdt,
"DERI" => Self::Deri,
"DIVD" => Self::Divd,
"FREX" => Self::Frex,
"HEDG" => Self::Hedg,
"INVS" => Self::Invs,
"PRME" => Self::Prme,
"SAVG" => Self::Savg,
"SECU" => Self::Secu,
"SEPI" => Self::Sepi,
"TREA" => Self::Trea,
"UNIT" => Self::Unit,
"FNET" => Self::Fnet,
"FUTR" => Self::Futr,
"ANTS" => Self::Ants,
"CVCF" => Self::Cvcf,
"DMEQ" => Self::Dmeq,
"DNTS" => Self::Dnts,
"HLTC" => Self::Hltc,
"HLTI" => Self::Hlti,
"HSPC" => Self::Hspc,
"ICRF" => Self::Icrf,
"LTCF" => Self::Ltcf,
"MAFC" => Self::Mafc,
"MARF" => Self::Marf,
"MDCS" => Self::Mdcs,
"VIEW" => Self::View,
"CDEP" => Self::Cdep,
"SWFP" => Self::Swfp,
"SWPP" => Self::Swpp,
"SWRS" => Self::Swrs,
"SWUF" => Self::Swuf,
"ADCS" => Self::Adcs,
"AEMP" => Self::Aemp,
"ALLW" => Self::Allw,
"ALMY" => Self::Almy,
"BBSC" => Self::Bbsc,
"BECH" => Self::Bech,
"BENE" => Self::Bene,
"BONU" => Self::Bonu,
"CCHD" => Self::Cchd,
"COMM" => Self::Comm,
"CSLP" => Self::Cslp,
"GFRP" => Self::Gfrp,
"GVEA" => Self::Gvea,
"GVEB" => Self::Gveb,
"GVEC" => Self::Gvec,
"GVED" => Self::Gved,
"GWLT" => Self::Gwlt,
"HREC" => Self::Hrec,
"PAYR" => Self::Payr,
"PEFC" => Self::Pefc,
"PENS" => Self::Pens,
"PRCP" => Self::Prcp,
"RHBS" => Self::Rhbs,
"SALA" => Self::Sala,
"SPSP" => Self::Spsp,
"SSBE" => Self::Ssbe,
"LBIN" => Self::Lbin,
"LCOL" => Self::Lcol,
"LFEE" => Self::Lfee,
"LMEQ" => Self::Lmeq,
"LMFI" => Self::Lmfi,
"LMRK" => Self::Lmrk,
"LREB" => Self::Lreb,
"LREV" => Self::Lrev,
"LSFL" => Self::Lsfl,
"ESTX" => Self::Estx,
"FWLV" => Self::Fwlv,
"GSTX" => Self::Gstx,
"HSTX" => Self::Hstx,
"INTX" => Self::Intx,
"NITX" => Self::Nitx,
"PTXP" => Self::Ptxp,
"RDTX" => Self::Rdtx,
"TAXS" => Self::Taxs,
"VATX" => Self::Vatx,
"WHLD" => Self::Whld,
"TAXR" => Self::Taxr,
"B112" => Self::B112,
"BR12" => Self::Br12,
"TLRF" => Self::Tlrf,
"TLRR" => Self::Tlrr,
"AIRB" => Self::Airb,
"BUSB" => Self::Busb,
"FERB" => Self::Ferb,
"RLWY" => Self::Rlwy,
"TRPT" => Self::Trpt,
"CBTV" => Self::Cbtv,
"ELEC" => Self::Elec,
"ENRG" => Self::Enrg,
"GASB" => Self::Gasb,
"NWCH" => Self::Nwch,
"NWCM" => Self::Nwcm,
"OTLC" => Self::Otlc,
"PHON" => Self::Phon,
"UBIL" => Self::Ubil,
"WTER" => Self::Wter,
"BOND" => Self::Bond,
"CABD" => Self::Cabd,
"CAEQ" => Self::Caeq,
"CBCR" => Self::Cbcr,
"DBCR" => Self::Dbcr,
"DICL" => Self::Dicl,
"EQTS" => Self::Eqts,
"FLCR" => Self::Flcr,
"EFTC" => Self::Eftc,
"EFTD" => Self::Eftd,
"MOMA" => Self::Moma,
"RAPI" => Self::Rapi,
"GAMB" => Self::Gamb,
"LOTT" => Self::Lott,
"AMEX" => Self::Amex,
"SASW" => Self::Sasw,
"AUCO" => Self::Auco,
"PCOM" => Self::Pcom,
"PDEP" => Self::Pdep,
"PLDS" => Self::Plds,
"PLRF" => Self::Plrf,
"GAFA" => Self::Gafa,
"GAHO" => Self::Gaho,
"CPEN" => Self::Cpen,
"DEPD" => Self::Depd,
"RETL" => Self::Retl,
tag => todo!("handle code {tag:?}"),
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Specifies the external purpose code in the format of character string with a maximum length of 4 characters.\r\nThe list of valid codes is an external code list published separately.\r\nExternal code sets can be downloaded from www.iso20022.org."]
pub enum ExternalPurposeCode {
#[doc = "Delayed draw funding. Certain issuers may utilize delayed draw loans whereby the lender is committed to fund cash\nwithin a specified period once a call is made by the issuer. The lender receives a fee for entering into such a\ncommitment"]
BankLoanDelayedDrawFunding,
#[doc = "Bank loan fees. Cash activity related to specific bank loan fees, including (a) agent / assignment fees; (b) amendment fees; (c) commitment fees; (d) consent fees; (e) cost of carry fees; (f) delayed compensation fees; (g)\nfacility fees; (h) fronting fees; (i) funding fees; (j) letter of credit assignment fees"]
BankLoanFees,
#[doc = "Bank loan funding memo. Net cash movement for the loan contract final notification when sent separately from the\nloan contract final notification instruction."]
BankLoanFundingMemo,
#[doc = "Accrued interest payments. Specific to bank loans."]
BankLoanAccruedInterestPayment,
#[doc = "Principal paydowns. Specific to bank loans"]
BankLoanPrincipalPaydown,
#[doc = "A Service that is settling money for a bulk of card transactions, while referring to a specific transaction file or other information like terminal ID, card acceptor ID or other transaction details."]
CardBulkClearing,
#[doc = "Purchase of Goods and Services with additional Cash disbursement at the POI (Cashback)"]
CardPaymentWithCashBack,
#[doc = "ATM Cash Withdrawal in an unattended or Cash Advance in an attended environment (POI or bank counter)"]
CashDisbursementCashSettlement,
#[doc = "ATM Cash Withdrawal in an unattended or Cash Advance in an attended environment (POI or bank counter) with surcharging."]
CashDisbursementWithSurcharging,
#[doc = "A combined service which enables the card acceptor to perform an authorisation for a temporary amount and a completion for the final amount within a limited time frame. Deferred Payment is only available in the unattended environment.\nExamples where this service is widely used are unattended petrol pumps and phone booths"]
CardDeferredPayment,
#[doc = "A service which allows the card acceptor to effect a credit to a cardholder' account. Unlike a Merchant Refund, an Original Credit is not preceded by a card payment. This service is used for example for crediting winnings from gaming."]
OriginalCredit,
#[doc = "Purchase of Goods which are equivalent to cash like coupons in casinos."]
QuasiCash,
#[doc = "Transaction is related to a Service that is first reserving money from a card account and then is loading an e-purse application by this amount."]
EPurseTopUp,
#[doc = "A Service that is settling card transaction related fees between two parties."]
FeeCollection,
#[doc = "A Service that is first reserving money from a card account and then is loading a prepaid mobile phone amount by this amount."]
MobileTopUp,
#[doc = "Transaction moves funds between 2 accounts of same account holder at the same bank."]
AccountManagement,
#[doc = "Transaction is a general cash management instruction."]
CashManagementTransfer,
#[doc = "Transaction is a collection of funds initiated via a credit transfer or direct debit."]
CollectionPayment,
#[doc = "Transaction is related to cash disbursement."]
CashDisbursementCashManagement,
#[doc = "Transaction is releted to a payment of deposit."]
Deposit,
#[doc = "Transaction is an intra-company payment, ie, a payment between two companies belonging to the same group."]
IntraCompanyPayment,
#[doc = "Transaction is a payment between two accounts belonging to the same party (intra-party payment), where party is a natural person (identified by a private ID, not organisation ID)."]
IntraPartyPayment,
#[doc = "Bank initiated account transfer to support zero target balance management, pooling or sweeping."]
LiquidityManagement,
#[doc = "Transaction is related to a netting operation."]
Netting,
#[doc = "Cash collateral related to any securities traded out beyond 3 days which include treasury notes, JGBs and Gilts."]
BondForward,
#[doc = "Cash Collateral related to a Cross Currency Interest Rate Swap, indicating the exchange of fixed interest payments in one currency for those in another."]
CrossCurrencyIrs,
#[doc = "Cash Collateral associated with an ISDA or Central Clearing Agreement that is covering the initial margin requirements for OTC trades clearing through a CCP. "]
CcpClearedInitialMargin,
#[doc = "Cash Collateral associated with an ISDA or Central Clearing Agreement that is covering the variation margin requirements for OTC trades clearing through a CCP. "]
CcpClearedVariationMargin,
#[doc = "CCP Segregated initial margin: Initial margin on OTC Derivatives cleared through a CCP that requires segregation"]
CcpClearedInitialMarginSegregatedCash,
#[doc = "Cash collateral related to trading of credit default swap."]
CreditDefaultSwap,
#[doc = "Cash collateral related to a combination of various types of trades."]
CrossProduct,
#[doc = "Cash collateral related to cash lending/borrowing; letter of Credit; signing of master agreement."]
CreditSupport,
#[doc = "Cash collateral related to opening of a credit line before trading."]
CreditLine,
#[doc = "Cash collateral related to trading of equity option (Also known as stock options)."]
EquityOption,
#[doc = "Cash collateral related to equity swap trades where the return of an equity is exchanged for either a fixed or a floating rate of interest."]
EquitySwap,
#[doc = "Cash collateral related to trading of an exotic option for example a non-standard option."]
ExoticOption,
#[doc = "Cash collateral related to trading of exchanged traded derivatives in general (Opposite to Over the Counter (OTC))."]
ExchangeTradedDerivatives,
#[doc = "Cash collateral related to a fixed income instrument"]
FixedIncome,
#[doc = "Cash collateral payment against a Master Forward Agreement (MFA) where the cash is held in a segregated account and is not available for use by the client. Includes any instruments with a forward settling date such TBAs, repurchase agreements and bond forwards"]
ForwardBrokerOwnedCashCollateral,
#[doc = "Cash collateral payment against a Master Forward Agreement (MFA) where the cash is owned and may be used by the client when returned. Includes any instruments with a forward settling date such TBAs, repurchase agreements and bond forwards"]
ForwardClientOwnedCashCollateral,
#[doc = "Any cash payment related to the collateral for a Master Agreement forward, which is segregated, and not available for use by the client. Example master agreement forwards include TBA, repo and Bond Forwards."]
ForwardBrokerOwnedCashCollateralSegregated,
#[doc = "Any cash payment related to the collateral for a Master agreement forward, which is owned by the client and is available for use by the client when it is returned to them from the segregated account. Example master agreement forwards include TBA, repo and Bond Forwards."]
ForwardClientOwnedSegregatedCashCollateral,
#[doc = "Daily margin on listed derivatives – not segregated as collateral associated with an FCM agreement. Examples\ninclude listed futures and options margin payments; premiums for listed options not covered in the MT54X message"]
DailyMarginOnListedDerivatives,
#[doc = "MBS Broker Owned Segregated (40Act/Dodd Frank) Cash Collateral - Any cash payment related to the collateral for a Mortgage Back Security, which is segregated, and not available for use by the client."]
MbsBrokerOwnedCashCollateral,
#[doc = "MBS Client Owned Cash Segregated (40Act/Dodd Frank) Cash Collateral - Any cash payment related to the collateral for a Mortgage Back Security, which is owned by the client and is available for use by the client when it is returned to them from the segregated account"]
MbsClientOwnedCashCollateral,
#[doc = "Initial futures margin. Where such payment is owned by the client and is available for use by them on return"]
FuturesInitialMargin,
#[doc = "Margin Client Owned Segregated Cash Collateral - Any cash payment related to the collateral for initial futures margin, which is owned by the client and is available for use by the client when it is returned to them from the segregated account."]
FuturesInitialMarginClientOwnedSegregatedCashCollateral,
#[doc = "Client owned collateral identified as eligible for OCC pledging"]
ClientOwnedOccPledgedCollateral,
#[doc = "Cash collateral payment for OTC options associated with an FCM agreement. Where such payment is segregated and not available for use by the client"]
OtcOptionBrokerOwnedCashCollateral,
#[doc = "Cash collateral payment for OTC options associated with an FCM agreement. Where such payment is not segregated and is available for use by the client upon return"]
OtcOptionClientOwnedCashCollateral,
#[doc = "Option Broker Owned Segregated Cash Collateral - Any cash payment related to the collateral for an OTC option, which is segregated, and not available for use by the client."]
OtcOptionBrokerOwnedSegregatedCashCollateral,
#[doc = "Option Client Owned Cash Segregated Cash Collateral - Any cash payment related to the collateral for an OTC option, which is owned by the client and is available for use by the client when it is returned to them from the segregated account"]
OtcOptionClientOwnedCashSegregatedCashCollateral,
#[doc = "Cash collateral related to trading of option on Foreign Exchange."]
FxOption,
#[doc = "Cash collateral related to Over-the-counter (OTC) Derivatives in general for example contracts which are traded and privately negotiated."]
OtcDerivatives,
#[doc = "Cash collateral related to a repurchase agreement transaction."]
RepurchaseAgreement,
#[doc = "Bi-lateral repo broker owned collateral associated with a repo master agreement – GMRA or MRA Master Repo\nAgreements"]
BilateralRepoBrokerOwnedCollateral,
#[doc = "Repo client owned collateral associated with a repo master agreement – GMRA or MRA Master Repo Agreements"]
RepoClientOwnedCollateral,
#[doc = "Bi-lateral repo broker owned segregated cash collateral associated with a repo master agreement"]
BilateralRepoBrokerOwnedSegregatedCashCollateral,
#[doc = "Repo client owned segregated collateral associated with a repo master agreement"]
BilateralRepoClientOwnedSegregatedCashCollateral,
#[doc = "Cash collateral related to a reverse repurchase agreement transaction."]
ReverseRepurchaseAgreement,
#[doc = "Cash collateral related to a Securities Buy Sell Sell Buy Back"]
SecuritiesBuySellSellBuyBack,
#[doc = "Cash collateral related to Exotic single currency interest rate swap."]
SingleCurrencyIrsExotic,
#[doc = "Cash collateral related to Single Currency Interest Rate Swap."]
SingleCurrencyIrs,
#[doc = "Cash collateral related to Combination of securities-related exposure types."]
SecuritiesCrossProducts,
#[doc = "Short Sale broker owned collateral associated with a prime broker agreement"]
BrokerOwnedCollateralShortSale,
#[doc = "Short Sale client owned collateral associated with a prime brokerage agreement"]
ClientOwnedCollateralShortSale,
#[doc = "Cash Collateral related to a Short Sell"]
ShortSell,
#[doc = "Cash collateral related to Securities lending and borrowing."]
SecuritiesLendingAndBorrowing,
#[doc = "Cash collateral related to a Secured loan."]
SecuredLoan,
#[doc = "Cash collateral payment for swaps associated with an ISDA agreement. . Where such payment is segregated and\nnot available for use by the client. Includes any cash collateral payments made under the terms of a CSA agreement\nfor instruments such as swaps and FX forwards."]
SwapBrokerOwnedCashCollateral,
#[doc = "Cash collateral payment for swaps associated with an ISDA agreement. Where such payment is not segregated and\nis available for use by the client upon return. Includes any cash collateral payments made under the terms of a CSA\nagreement for instruments such as swaps and FX forwards."]
SwapClientOwnedCashCollateral,
#[doc = "Cash collateral related to an option on interest rate swap."]
Swaption,
#[doc = "Swaps Broker Owned Segregated Cash Collateral - Any cash payment related to the collateral for Swap margin ,\nwhich is segregated, and not available for use by the client. This includes any collateral identified in a CSA\nagreement such as Swap or FX Forward collateral."]
SwapsBrokerOwnedSegregatedCashCollateral,
#[doc = "Swaps Client Owned Segregated Cash Collateral - Any cash payment related to the collateral for Swap margin,\nwhich is owned by the client and is available for use by the client when returned from the segregated account. This\nincludes any collateral identified in a CSA agreement such as Swap or FX Forward collateral."]
SwapsClientOwnedSegregatedCashCollateral,
#[doc = "Cash collateral related to a To Be Announced (TBA)"]
ToBeAnnounced,
#[doc = "Cash collateral payment (segregated) for TBA securities associated with a TBA Master Agreement. Where such payment is segregated and not available for use by the client."]
TbaBrokerOwnedCashCollateral,
#[doc = "Cash collateral payment (for use by client)for TBA securities associated with a TBA Master Agreement. Where such payment is not segregated and is available for use by the client upon return."]
TbaClientOwnedCashCollateral,
#[doc = "Cash collateral related to a combination of treasury-related exposure types."]
TreasuryCrossProduct,
#[doc = "Transaction is related to the agricultural domain."]
AgriculturalTransfer,
#[doc = "Transaction is related to a payment associated with an Account Receivable Entry"]
AccountsReceivablesEntry,
#[doc = "Transaction is related to a payment of business expenses."]
BusinessExpenses,
#[doc = "Transaction is related to a payment associated with a Back Office Conversion Entry"]
BackOfficeConversionEntry,
#[doc = "Transaction is related to a payment of commercial credit or debit. (formerly CommercialCredit)"]
CommercialPayment,
#[doc = "Transaction is payment of copyright."]
Copyright,
#[doc = "Transaction is related to purchase and sale of goods."]
PurchaseSaleOfGoods,
#[doc = "Transaction is related to purchase and sale of goods and services."]
PurchaseSaleOfGoodsAndServices,
#[doc = "Transaction is related to purchase and sale of goods and services with cash back."]
PurchaseSaleOfGoodsAndServicesWithCashBack,
#[doc = "Transaction is payment of a license fee."]
LicenseFee,
#[doc = "A service which enables a user to use an app on its mobile to pay a merchant or other business payees by initiating a payment message. Within this context, the account information or an alias of the payee might be transported through different channels to the app, for example QR Code, NFC, Bluetooth, other Networks."]
MobileP2bPayment,
#[doc = "Transaction is related to a payment associated with a Point of Purchase Entry."]
PointOfPurchaseEntry,
#[doc = "Transaction is the payment of royalties."]
Royalties,
#[doc = "Transaction is related to purchase and sale of services."]
PurchaseSaleOfServices,
#[doc = "Transaction is related to service charges charged by a service provider."]
ServiceCharges,
#[doc = "Transaction is related to a payment of information or entertainment services either in printed or electronic form."]
Subscription,
#[doc = "Transaction is related to a payment to a supplier."]
SupplierPayment,
#[doc = "Transaction is related to a trade services operation."]
Commercial,
#[doc = "Transaction is a payment for charity reasons."]
CharityPayment,
#[doc = "Transaction is a payment used by a third party who can collect funds to pay on behalf of consumers, ie credit counseling or bill payment companies."]
ConsumerThirdPartyConsolidatedPayment,
#[doc = "A service which enables a user to use an app on its mobile to initiate moving funds from his/her bank account to another person’s bank account while not using the account number but an alias information like an MSISDN as account addressing information in his/her app."]
MobileP2pPayment,
#[doc = "E-Commerce payment with payment guarantee of the issuing bank."]
GuaranteedEPayment,
#[doc = "E-Commerce payment return."]
EPaymentReturn,
#[doc = "E-Commerce payment without payment guarantee of the issuing bank."]
NonGuaranteedEPayment,
#[doc = "Transaction is related to ePayment."]
Epayment,
#[doc = "Transaction is a payment of car loan principal payment."]
CarLoanPrincipalRepayment,
#[doc = "Transaction is related to the payment of a compensation relating to interest loss/value date adjustment and can include fees."]
CompensationPayment,
#[doc = "Collection of funds initiated via a debit transfer."]
DebitCollectionPayment,
#[doc = "Transaction is related to a payment of government insurance."]
GovernmentInsurance,
#[doc = "Transaction is related to a payment of property loan."]
PropertyLoanRepayment,
#[doc = "Transaction is related to the settlement of a property loan."]
PropertyLoanSettlement,
#[doc = "Transaction is a payment of car insurance premium."]
InsurancePremiumCar,
#[doc = "Transaction is related to an insurance premium refund."]
InsurancePremiumRefund,
#[doc = "Transaction is related to the payment of an insurance claim."]
PaymentOfInsuranceClaim,
#[doc = "Transaction is payment of an insurance premium."]
InsurancePremium,
#[doc = "Transaction is payment of interest."]
Interest,
#[doc = "Transaction is a payment of labor insurance."]
LaborInsurance,
#[doc = "Transaction is a payment of life insurance."]
LifeInsurance,
#[doc = "Transaction is related to transfer of loan to borrower."]
Loan,
#[doc = "Transaction is related to repayment of loan to lender."]
LoanRepayment,
#[doc = "Payment based on enforcement orders except those arising from judicial alimony decrees."]
PaymentBasedOnEnforcementOrder,
#[doc = "Transaction is a payment of property insurance."]
PropertyInsurance,
#[doc = "Transaction is for general rental/lease."]
RentalLeaseGeneral,
#[doc = "Transaction is related to a payment of a recurring installment made at regular intervals."]
RecurringInstallmentPayment,
#[doc = "Transaction is related to a payment of a trust fund."]
TrustFund,
#[doc = "FX trades with a value date in the future."]
ForwardForeignExchange,
#[doc = "FX netting if cash is moved by separate wire instead of within the closing FX instruction"]
ForeignExchangeRelatedNetting,
#[doc = "Transaction is related to a payment associated with administrative management."]
AdministrativeManagement,
#[doc = "Transaction is an advance payment."]
AdvancePayment,
#[doc = "Transaction is the payment of a domestic bearer cheque."]
BearerChequeDomestic,
#[doc = "Transaction is the payment of a foreign bearer cheque."]
BearerChequeForeign,
#[doc = "Transaction is related to a payment associated with building maintenance."]
BuildingMaintenance,
#[doc = "Bond Forward pair-off cash net movement"]
BondForwardNetting,
#[doc = "Transaction is related to capital building fringe fortune, ie capital building in general"]
CapitalBuilding,
#[doc = "Transaction is related to capital building fringe fortune for retirement"]
CapitalBuildingRetirement,
#[doc = "Transaction is related to a payment of credit card account."]
CreditCardPayment,
#[doc = "Transaction is related to a payment of credit card bill."]
CreditCardBill,
#[doc = "Transaction is related to a payment of cancellation fee."]
CancellationFee,
#[doc = "Transaction is related to a direct debit where the mandate was generated by using data from a payment card at the point of sale."]
CardGeneratedDirectDebit,
#[doc = "Transaction is related to settlement of a trade, e.g. a foreign exchange deal or a securities transaction."]
TradeSettlementPayment,
#[doc = "Transaction is related to payment of costs."]
Costs,
#[doc = "Transaction is related to carpark charges."]
CarparkCharges,
#[doc = "Transaction is related to a debit card payment."]
DebitCardPayment,
#[doc = "Transaction is the payment of a disbursement due to a specific type of printed order for a payment of a specified sum, issued by a bank or a post office (Zahlungsanweisung zur Verrechnung)"]
PrintedOrderDisbursement,
#[doc = "Code used to pre-advise the account servicer of a forthcoming deliver against payment instruction."]
DeliverAgainstPayment,
#[doc = "Transaction is related to a payment of study/tuition fees."]
Education,
#[doc = "Payment related to a factor update"]
FactorUpdateRelatedPayment,
#[doc = "Financial aid by State authorities for abolition of consequences of natural disasters."]
FinancialAidInCaseOfNaturalDisaster,
#[doc = "Transaction is the payment for late fees & charges. E.g Credit card charges"]
LatePaymentOfFeesAndCharges,
#[doc = "Payment of fees/charges."]
PaymentOfFees,
#[doc = "Payment with no commercial or statutory purpose."]
Gift,
#[doc = "Transaction is a payment to or from a government department."]
GovernmentPayment,
#[doc = "Transaction is reimbursement of credit card payment."]
IrrevocableCreditCardPayment,
#[doc = "Transaction is reimbursement of debit card payment."]
IrrevocableDebitCardPayment,
#[doc = "Transaction is payment for an installment/hire-purchase agreement."]
InstalmentHirePurchaseAgreement,
#[doc = "Transaction is related to a payment of an installment."]
Installment,
#[doc = "Transaction is the payment for invoices."]
InvoicePayment,
#[doc = "Transaction is the payment of a domestic multi-currency cheque"]
MultiCurrenyChequeDomestic,
#[doc = "Transaction is the payment of a foreign multi-currency cheque"]
MultiCurrenyChequeForeign,
#[doc = "Transaction is related to a payment for multiple service types."]
MultipleServiceTypes,
#[doc = "Transaction is related to a payment for type of services not specified elsewhere."]
NotOtherwiseSpecified,
#[doc = "Transaction is the payment of a domestic order cheque"]
OrderChequeDomestic,
#[doc = "Transaction is the payment of a foreign order cheque"]
OrderChequeForeign,
#[doc = "Transaction is related to a payment of opening fee."]
OpeningFee,
#[doc = "Other payment purpose."]
Other,
#[doc = "Transaction is related to a pre-authorized debit origination"]
PreauthorizedDebit,
#[doc = "Transaction is related to payment terms specifications"]
PaymentTerms,
#[doc = "Transaction is related to a payment associated with a re-presented check entry"]
RepresentedCheckEntry,
#[doc = "Transaction is related to a payment of receipt."]
ReceiptPayment,
#[doc = "Transaction is the payment of a rebate."]
Rebate,
#[doc = "Transaction is the payment of a refund."]
Refund,
#[doc = "Transaction is the payment of rent."]
Rent,
#[doc = "Transaction is for account overdraft repayment"]
AccountOverdraftRepayment,
#[doc = "Transaction is related to a reimbursement of a previous erroneous transaction."]
ReimbursementOfAPreviousErroneousTransaction,
#[doc = "Bi-lateral repo interest net/bulk payment at rollover/pair-off or other closing scenarios where applicable"]
BilateralRepoInternetNetting,
#[doc = "Cash payment resulting from a Round Robin"]
RoundRobin,
#[doc = "Transaction is related to a reimbursement for commercial reasons of a correctly received credit transfer."]
ReimbursementReceivedCreditTransfer,
#[doc = "Transaction is related to a Request to Pay."]
RelatedRequestToPay,
#[doc = "Code used to pre-advise the account servicer of a forthcoming receive against payment instruction."]
ReceiveAgainstPayment,
#[doc = "Transaction is payment of a well formatted payment slip."]
PaymentSlipInstruction,
#[doc = "Split payments. To be used when cash and security movements for a security trade settlement are instructed\nseparately."]
SplitPayments,
#[doc = "Transaction is related to a payment of study/tuition costs."]
Study,
#[doc = "TBA pair-off cash wire net movement"]
TbaPairOffNetting,
#[doc = "Transaction is related to a payment of telecommunications related bill."]
TelecommunicationsBill,
#[doc = "Transaction is related to a payment associated with charges levied by a town council."]
TownCouncilServiceCharges,
#[doc = "Transaction is related to a payment initiated via telephone."]
TelephoneInitiatedTransaction,
#[doc = "Cash payment resulting from a TMPG Claim"]
TmpgClaimPayment,
#[doc = "Tri-Party Repo related interest"]
TriPartyRepoInterest,
#[doc = "Tri-party Repo related net gain/loss cash movement"]
TriPartyRepoNetting,
#[doc = "Transaction is payment of a beneficiary prefilled payment slip where beneficiary to payer information is truncated."]
TruncatedPaymentSlip,
#[doc = "Transaction is the payment of a travellers cheque"]
TravellerCheque,
#[doc = "Transaction is related to a payment initiated via internet."]
InternetInitiatedTransaction,
#[doc = "Transaction in which the amount is available to the payee immediately."]
InstantPayments,
#[doc = "Transaction in which the Return of the amount is fully returned."]
InstantPaymentsCancellation,
#[doc = "Transaction in which the amount is available to the payee immediately, done for donations, with sending the address data of the payer."]
InstantPaymentsForDonations,
#[doc = "Transaction in which the amount is available to the payee immediately, done in E-commerce, without sending the address data of the payer."]
InstantPaymentsInECommerceWithoutAddressData,
#[doc = "Transaction in which the amount is available to the payee immediately, done in E-commerce, with sending the address data of the payer."]
InstantPaymentsInECommerceWithAddressData,
#[doc = "Transaction in which the amount is available to the payee immediately, done in E-commerce."]
InstantPaymentsInECommerce,
#[doc = "Transaction in which the amount is available to the payee immediately, done at POS."]
InstantPaymentsAtPos,
#[doc = "Transaction in which the Return of the amount is fully or partial returned."]
InstantPaymentsReturn,
#[doc = "Transaction is made via an unattending vending machine by using 2-factor-authentification."]
InstantPaymentsUnattendedVendingMachineWith2Fa,
#[doc = "Transaction is made via an unattending vending machine by without using 2-factor-authentification."]
InstantPaymentsUnattendedVendingMachineWithout2Fa,
#[doc = "Transaction settles annuity related to credit, insurance, investments, other.n"]
Annuity,
#[doc = "Transaction is the payment of custodian account management fee where custodian bank and current account servicing bank coincide"]
CustodianManagementFeeInhouse,
#[doc = "Transaction is the payment of capital falling due where custodian bank and current account servicing bank coincide"]
CapitalFallingDueInhouse,
#[doc = "Transaction is payment of commodities."]
CommodityTransfer,
#[doc = "Transaction is related to a derivatives transaction"]
Derivatives,
#[doc = "Transaction is payment of dividends."]
Dividend,
#[doc = "Transaction is related to a foreign exchange operation."]
ForeignExchange,
#[doc = "Transaction is related to a hedging operation."]
Hedging,
#[doc = "Transaction is for the payment of mutual funds, investment products and shares"]
InvestmentAndSecurities,
#[doc = "Transaction is related to a precious metal operation."]
PreciousMetal,
#[doc = "Transfer to savings/retirement account."]
Savings,
#[doc = "Transaction is the payment of securities."]
Securities,
#[doc = "Transaction is the payment of a purchase of securities where custodian bank and current account servicing bank coincide"]
SecuritiesPurchaseInhouse,
#[doc = "Transaction is related to treasury operations."]
TreasuryPayment,
#[doc = "Transaction is purchase of Unit Trust"]
UnitTrustPurchase,
#[doc = "Cash associated with a netting of futures payments. Refer to CCPM codeword for netting of initial and variation margin through a CCP"]
FuturesNettingPayment,
#[doc = "Cash related to futures trading activity."]
Futures,
#[doc = "Transaction is a payment for anesthesia services."]
AnesthesiaServices,
#[doc = "Transaction is a payment for convalescence care facility services."]
ConvalescentCareFacility,
#[doc = "Transaction is a payment is for use of durable medical equipment."]
DurableMedicaleEquipment,
#[doc = "Transaction is a payment for dental services."]
DentalServices,
#[doc = "Transaction is a payment for home health care services."]
HomeHealthCare,
#[doc = "Transaction is a payment of health insurance."]
HealthInsurance,
#[doc = "Transaction is a payment for hospital care services."]
HospitalCare,
#[doc = "Transaction is a payment for intermediate care facility services."]
IntermediateCareFacility,
#[doc = "Transaction is a payment for long-term care facility services."]
LongTermCareFacility,
#[doc = "Transaction is contribution to medical aid fund."]
MedicalAidFundContribution,
#[doc = "Transaction is related to a medical aid refund."]
MedicalAidRefund,
#[doc = "Transaction is a payment for medical care services."]
MedicalServices,
#[doc = "Transaction is a payment for vision care services."]
VisionCare,
#[doc = "Payment related to a credit default event"]
CreditDefaultEventPayment,
#[doc = "Final payments for a swap contract"]
SwapContractFinalPayment,
#[doc = "Partial payment for a swap contract"]
SwapContractPartialPayment,
#[doc = "Reset payment for a swap contract"]
SwapContractResetPayment,
#[doc = "Upfront payment for a swap contract"]
SwapContractUpfrontPayment,
#[doc = "Payments for donation, sponsorship, advisory, intellectual and other copyright services."]
AdvisoryDonationCopyrightServices,
#[doc = "Payment concerning active employment policy."]
ActiveEmploymentPolicy,
#[doc = "Transaction is the payment of allowances."]
Allowance,
#[doc = "Transaction is the payment of alimony."]
AlimonyPayment,
#[doc = "Transaction is related to a payment made as incentive to encourage parents to have more children"]
BabyBonusScheme,
#[doc = "Transaction is related to a payment made to assist parent/guardian to maintain child."]
ChildBenefit,
#[doc = "Transaction is related to a payment to a person who is unemployed/disabled."]
UnemploymentDisabilityBenefit,
#[doc = "Transaction is related to payment of a bonus."]
BonusPayment,
#[doc = "Payments made by Government institute related to cash compensation, helplessness, disability. These payments are made by the Government institution as a social benefit in addition to regularly paid salary or pension."]
CashCompensationHelplessnessDisability,
#[doc = "Transaction is payment of commission."]
Commission,
#[doc = "Transaction is a payment by a company to a bank for financing social loans to employees."]
CompanySocialLoanPaymentToBank,
#[doc = "Compensation to unemployed persons during insolvency procedures."]
GuaranteeFundRightsPayment,
#[doc = "Transaction is payment to category A Austrian government employees."]
AustrianGovernmentEmployeesCategoryA,
#[doc = "Transaction is payment to category B Austrian government employees."]
AustrianGovernmentEmployeesCategoryB,
#[doc = "Transaction is payment to category C Austrian government employees."]
AustrianGovernmentEmployeesCategoryC,
#[doc = "Transaction is payment to category D Austrian government employees."]
AustrianGovernmentEmployeesCategoryD,
#[doc = "Payment to victims of war violence and to disabled soldiers."]
GovermentWarLegislationTransfer,
#[doc = "Transaction is a contribution by an employer to the housing expenditures (purchase, construction, renovation) of the employees within a tax free fringe benefit system "]
HousingRelatedContribution,
#[doc = "Transaction is related to the payment of payroll."]
Payroll,
#[doc = "Transaction is contribution to pension fund."]
PensionFundContribution,
#[doc = "Transaction is the payment of pension."]
PensionPayment,
#[doc = "Transaction is related to a payment of a price."]
PricePayment,
#[doc = "Benefit for the duration of occupational rehabilitation."]
RehabilitationSupport,
#[doc = "Transaction is the payment of salaries."]
SalaryPayment,
#[doc = "Salary or pension payment for more months in one amount or a delayed payment of salaries or pensions."]
SalaryPensionSumPayment,
#[doc = "Transaction is a social security benefit, ie payment made by a government to support individuals."]
SocialSecurityBenefit,
#[doc = "Net payment related to a buy-in. When an investment manager is bought in on a sell trade that fails due to a failed securities lending recall, the IM may seize the underlying collateral to pay for the buy-in. Any difference between the value of the collateral and the sell proceeds would be paid or received under this code"]
LendingBuyInNetting,
#[doc = "Free movement of cash collateral. Cash collateral paid by the borrower is done separately from the delivery of the shares at loan opening or return of collateral done separately from return of the loaned security. Note: common when the currency of the security is different the currency of the cash collateral."]
LendingCashCollateralFreeMovement,
#[doc = "Fee payments, other than rebates, for securities lending. Includes (a) exclusive fees; (b) transaction fees; (c)\ncustodian fees; (d) minimum balance fees"]
LendingFees,
#[doc = "Cash collateral payments resulting from the marked-to-market of a portfolio of loaned equity securities"]
LendingEquityMarkedToMarketCashCollateral,
#[doc = "Cash collateral payments resulting from the marked-to-market of a portfolio of loaned fixed income securities"]
LendingFixedIncomeMarkedToMarketCashCollateral,
#[doc = "Cash collateral payments resulting from the marked-to-market of a portfolio of loaned securities where the instrument\ntypes are not specified"]
LendingUnspecifiedTypeOfMarkedToMarketCashCollateral,
#[doc = "Securities lending rebate payments"]
LendingRebatePayments,
#[doc = "Revenue payments made by the lending agent to the client"]
LendingRevenuePayments,
#[doc = "Payments made by a borrower to a lending agent to satisfy claims made by the investment manager related to sell fails from late loan recall deliveries"]
LendingClaimPayment,
#[doc = "Transaction is related to a payment of estate tax."]
EstateTax,
#[doc = "Transaction is related to a payment of Foreign Worker Levy"]
ForeignWorkerLevy,
#[doc = "Transaction is the payment of Goods & Services Tax"]
GoodsServicesTax,
#[doc = "Transaction is related to a payment of housing tax."]
HousingTax,
#[doc = "Transaction is related to a payment of income tax."]
IncomeTax,
#[doc = "Transaction is related to a payment of net income tax."]
NetIncomeTax,
#[doc = "Transaction is related to a payment of property tax."]
PropertyTax,
#[doc = "Transaction is related to a payment of road tax."]
RoadTax,
#[doc = "Transaction is the payment of taxes."]
TaxPayment,
#[doc = "Transaction is the payment of value added tax."]
ValueAddedTaxPayment,
#[doc = "Transaction is related to a payment of withholding tax."]
WithHolding,
#[doc = "Transaction is the refund of a tax payment or obligation."]
TaxRefund,
#[doc = "US mutual fund trailer fee (12b-1) payment"]
TrailerFeePayment,
#[doc = "US mutual fund trailer fee (12b-1) rebate payment"]
TrailerFeeRebate,
#[doc = "Any non-US mutual fund trailer fee (retrocession) payment (use ISIN to determine onshore versus offshore designation)"]
NonUsMutualFundTrailerFeePayment,
#[doc = "Any non-US mutual fund trailer fee (retrocession) rebate payment (use ISIN to determine onshore versus offshore designation)"]
NonUsMutualFundTrailerFeeRebatePayment,
#[doc = "Transaction is a payment for air transport related business."]
Air,
#[doc = "Transaction is a payment for bus transport related business."]
Bus,
#[doc = "Transaction is a payment for ferry related business."]
Ferry,
#[doc = "Transaction is a payment for railway transport related business."]
Railway,
#[doc = "Transaction is for the payment to top-up pre-paid card and electronic road pricing for the purpose of transportation"]
RoadPricing,
#[doc = "Transaction is related to a payment of cable TV bill."]
CableTvBill,
#[doc = "Transaction is related to a payment of electricity bill."]
ElectricityBill,
#[doc = "Transaction is related to a utility operation."]
Energies,
#[doc = "Transaction is related to a payment of gas bill."]
GasBill,
#[doc = "Transaction is related to a payment of network charges."]
NetworkCharge,
#[doc = "Transaction is related to a payment of network communication."]
NetworkCommunication,
#[doc = "Transaction is related to a payment of other telecom related bill."]
OtherTelecomRelatedBill,
#[doc = "Transaction is related to a payment of telephone bill."]
TelephoneBill,
#[doc = "Transaction is for the payment to common utility provider that provide gas, water and/or electricity."]
Utilities,
#[doc = "Transaction is related to a payment of water bill."]
WaterBill,
#[doc = "Card Settlement-Settlement of Debit Card transactions."]
DebitCard,
#[doc = "Card Settlement-Settlement of Credit Card transactions."]
CreditCard,
#[doc = "Utilities-Settlement of Low value Credit transactions."]
LowValueCredit,
#[doc = "Utilities-Settlement of Low value Debit transactions."]
LowValueDebit,
#[doc = "Securities Lending-Settlement of Bond transaction."]
Bonds,
#[doc = "Securities Lending-Settlement of Equities transactions."]
Equities,
#[doc = "Securities Lending-Settlement of Corporate Actions: Bonds transactions."]
CorporateActionsBonds,
#[doc = "Securities Lending-Settlement of Corporate Actions: Equities transactions."]
CorporateActionsEquities,
#[doc = "Instant Payments-Settlement of Rapid Payment Instruction (RPI) transactions."]
RapidPaymentInstruction,
#[doc = "Card Settlement-Settlement of ATM transactions."]
Atm,
#[doc = "Utilities-Settlement of Authenticated Collections transactions."]
AuthenticatedCollections,
#[doc = "Card Settlement-Settlement of AMEX transactions."]
Amex,
#[doc = "Card Settlement-Settlement of Diners transactions."]
Diners,
#[doc = "Card Settlement-Settlement of Fleet transactions."]
FleetCard,
#[doc = "Securities Lending-ettlement of Money Market PCH."]
MoneyMarket,
#[doc = "General-Payments towards a purchase or winnings received from gambling, betting or other wagering activities."]
GamblingOrWageringPayment,
#[doc = "General-Payment towards a purchase or winnings received from lottery activities."]
LotteryPayment,
#[doc = "Salary and Benefits-Allowance from government to support family."]
GovernmentFamilyAllowance,
#[doc = "Salary and Benefits-Allowance from government to individuals to support payments of housing."]
GovernmentHousingAllowance,
#[doc = "Payment of funds from a lender as part of the issuance of a property loan."]
PropertyLoanDisbursement,
#[doc = "Payment of the deposit required towards purchase of a property."]
PropertyDeposit,
#[doc = "Final payment to complete the purchase of a property."]
PropertyCompletionPayment,
#[doc = "Transfer or extension of a property financing arrangement to a new deal or loan provider, without change of ownership of property."]
PropertyLoanRefinancing,
impl<'a> ExternalPurposeCode {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"BKDF" => Self::BankLoanDelayedDrawFunding,
"BKFE" => Self::BankLoanFees,
"BKFM" => Self::BankLoanFundingMemo,
"BKIP" => Self::BankLoanAccruedInterestPayment,
"BKPP" => Self::BankLoanPrincipalPaydown,
"CBLK" => Self::CardBulkClearing,
"CDCB" => Self::CardPaymentWithCashBack,
"CDCD" => Self::CashDisbursementCashSettlement,
"CDCS" => Self::CashDisbursementWithSurcharging,
"CDDP" => Self::CardDeferredPayment,
"CDOC" => Self::OriginalCredit,
"CDQC" => Self::QuasiCash,
"ETUP" => Self::EPurseTopUp,
"FCOL" => Self::FeeCollection,
"MTUP" => Self::MobileTopUp,
"ACCT" => Self::AccountManagement,
"CASH" => Self::CashManagementTransfer,
"COLL" => Self::CollectionPayment,
"CSDB" => Self::CashDisbursementCashManagement,
"DEPT" => Self::Deposit,
"INTC" => Self::IntraCompanyPayment,
"INTP" => Self::IntraPartyPayment,
"LIMA" => Self::LiquidityManagement,
"NETT" => Self::Netting,
"BFWD" => Self::BondForward,
"CCIR" => Self::CrossCurrencyIrs,
"CCPC" => Self::CcpClearedInitialMargin,
"CCPM" => Self::CcpClearedVariationMargin,
"CCSM" => Self::CcpClearedInitialMarginSegregatedCash,
"CRDS" => Self::CreditDefaultSwap,
"CRPR" => Self::CrossProduct,
"CRSP" => Self::CreditSupport,
"CRTL" => Self::CreditLine,
"EQPT" => Self::EquityOption,
"EQUS" => Self::EquitySwap,
"EXPT" => Self::ExoticOption,
"EXTD" => Self::ExchangeTradedDerivatives,
"FIXI" => Self::FixedIncome,
"FWBC" => Self::ForwardBrokerOwnedCashCollateral,
"FWCC" => Self::ForwardClientOwnedCashCollateral,
"FWSB" => Self::ForwardBrokerOwnedCashCollateralSegregated,
"FWSC" => Self::ForwardClientOwnedSegregatedCashCollateral,
"MARG" => Self::DailyMarginOnListedDerivatives,
"MBSB" => Self::MbsBrokerOwnedCashCollateral,
"MBSC" => Self::MbsClientOwnedCashCollateral,
"MGCC" => Self::FuturesInitialMargin,
"MGSC" => Self::FuturesInitialMarginClientOwnedSegregatedCashCollateral,
"OCCC" => Self::ClientOwnedOccPledgedCollateral,
"OPBC" => Self::OtcOptionBrokerOwnedCashCollateral,
"OPCC" => Self::OtcOptionClientOwnedCashCollateral,
"OPSB" => Self::OtcOptionBrokerOwnedSegregatedCashCollateral,
"OPSC" => Self::OtcOptionClientOwnedCashSegregatedCashCollateral,
"OPTN" => Self::FxOption,
"OTCD" => Self::OtcDerivatives,
"REPO" => Self::RepurchaseAgreement,
"RPBC" => Self::BilateralRepoBrokerOwnedCollateral,
"RPCC" => Self::RepoClientOwnedCollateral,
"RPSB" => Self::BilateralRepoBrokerOwnedSegregatedCashCollateral,
"RPSC" => Self::BilateralRepoClientOwnedSegregatedCashCollateral,
"RVPO" => Self::ReverseRepurchaseAgreement,
"SBSC" => Self::SecuritiesBuySellSellBuyBack,
"SCIE" => Self::SingleCurrencyIrsExotic,
"SCIR" => Self::SingleCurrencyIrs,
"SCRP" => Self::SecuritiesCrossProducts,
"SHBC" => Self::BrokerOwnedCollateralShortSale,
"SHCC" => Self::ClientOwnedCollateralShortSale,
"SHSL" => Self::ShortSell,
"SLEB" => Self::SecuritiesLendingAndBorrowing,
"SLOA" => Self::SecuredLoan,
"SWBC" => Self::SwapBrokerOwnedCashCollateral,
"SWCC" => Self::SwapClientOwnedCashCollateral,
"SWPT" => Self::Swaption,
"SWSB" => Self::SwapsBrokerOwnedSegregatedCashCollateral,
"SWSC" => Self::SwapsClientOwnedSegregatedCashCollateral,
"TBAS" => Self::ToBeAnnounced,
"TBBC" => Self::TbaBrokerOwnedCashCollateral,
"TBCC" => Self::TbaClientOwnedCashCollateral,
"TRCP" => Self::TreasuryCrossProduct,
"AGRT" => Self::AgriculturalTransfer,
"AREN" => Self::AccountsReceivablesEntry,
"BEXP" => Self::BusinessExpenses,
"BOCE" => Self::BackOfficeConversionEntry,
"COMC" => Self::CommercialPayment,
"CPYR" => Self::Copyright,
"GDDS" => Self::PurchaseSaleOfGoods,
"GDSV" => Self::PurchaseSaleOfGoodsAndServices,
"GSCB" => Self::PurchaseSaleOfGoodsAndServicesWithCashBack,
"LICF" => Self::LicenseFee,
"MP2B" => Self::MobileP2bPayment,
"POPE" => Self::PointOfPurchaseEntry,
"ROYA" => Self::Royalties,
"SCVE" => Self::PurchaseSaleOfServices,
"SERV" => Self::ServiceCharges,
"SUBS" => Self::Subscription,
"SUPP" => Self::SupplierPayment,
"TRAD" => Self::Commercial,
"CHAR" => Self::CharityPayment,
"COMT" => Self::ConsumerThirdPartyConsolidatedPayment,
"MP2P" => Self::MobileP2pPayment,
"ECPG" => Self::GuaranteedEPayment,
"ECPR" => Self::EPaymentReturn,
"ECPU" => Self::NonGuaranteedEPayment,
"EPAY" => Self::Epayment,
"CLPR" => Self::CarLoanPrincipalRepayment,
"COMP" => Self::CompensationPayment,
"DBTC" => Self::DebitCollectionPayment,
"GOVI" => Self::GovernmentInsurance,
"HLRP" => Self::PropertyLoanRepayment,
"HLST" => Self::PropertyLoanSettlement,
"INPC" => Self::InsurancePremiumCar,
"INPR" => Self::InsurancePremiumRefund,
"INSC" => Self::PaymentOfInsuranceClaim,
"INSU" => Self::InsurancePremium,
"INTE" => Self::Interest,
"LBRI" => Self::LaborInsurance,
"LIFI" => Self::LifeInsurance,
"LOAN" => Self::Loan,
"LOAR" => Self::LoanRepayment,
"PENO" => Self::PaymentBasedOnEnforcementOrder,
"PPTI" => Self::PropertyInsurance,
"RELG" => Self::RentalLeaseGeneral,
"RINP" => Self::RecurringInstallmentPayment,
"TRFD" => Self::TrustFund,
"FORW" => Self::ForwardForeignExchange,
"FXNT" => Self::ForeignExchangeRelatedNetting,
"ADMG" => Self::AdministrativeManagement,
"ADVA" => Self::AdvancePayment,
"BCDM" => Self::BearerChequeDomestic,
"BCFG" => Self::BearerChequeForeign,
"BLDM" => Self::BuildingMaintenance,
"BNET" => Self::BondForwardNetting,
"CBFF" => Self::CapitalBuilding,
"CBFR" => Self::CapitalBuildingRetirement,
"CCRD" => Self::CreditCardPayment,
"CDBL" => Self::CreditCardBill,
"CFEE" => Self::CancellationFee,
"CGDD" => Self::CardGeneratedDirectDebit,
"CORT" => Self::TradeSettlementPayment,
"COST" => Self::Costs,
"CPKC" => Self::CarparkCharges,
"DCRD" => Self::DebitCardPayment,
"DSMT" => Self::PrintedOrderDisbursement,
"DVPM" => Self::DeliverAgainstPayment,
"EDUC" => Self::Education,
"FACT" => Self::FactorUpdateRelatedPayment,
"FAND" => Self::FinancialAidInCaseOfNaturalDisaster,
"FCPM" => Self::LatePaymentOfFeesAndCharges,
"FEES" => Self::PaymentOfFees,
"GIFT" => Self::Gift,
"GOVT" => Self::GovernmentPayment,
"ICCP" => Self::IrrevocableCreditCardPayment,
"IDCP" => Self::IrrevocableDebitCardPayment,
"IHRP" => Self::InstalmentHirePurchaseAgreement,
"INSM" => Self::Installment,
"IVPT" => Self::InvoicePayment,
"MCDM" => Self::MultiCurrenyChequeDomestic,
"MCFG" => Self::MultiCurrenyChequeForeign,
"MSVC" => Self::MultipleServiceTypes,
"NOWS" => Self::NotOtherwiseSpecified,
"OCDM" => Self::OrderChequeDomestic,
"OCFG" => Self::OrderChequeForeign,
"OFEE" => Self::OpeningFee,
"OTHR" => Self::Other,
"PADD" => Self::PreauthorizedDebit,
"PTSP" => Self::PaymentTerms,
"RCKE" => Self::RepresentedCheckEntry,
"RCPT" => Self::ReceiptPayment,
"REBT" => Self::Rebate,
"REFU" => Self::Refund,
"RENT" => Self::Rent,
"REOD" => Self::AccountOverdraftRepayment,
"RIMB" => Self::ReimbursementOfAPreviousErroneousTransaction,
"RPNT" => Self::BilateralRepoInternetNetting,
"RRBN" => Self::RoundRobin,
"RRCT" => Self::ReimbursementReceivedCreditTransfer,
"RRTP" => Self::RelatedRequestToPay,
"RVPM" => Self::ReceiveAgainstPayment,
"SLPI" => Self::PaymentSlipInstruction,
"SPLT" => Self::SplitPayments,
"STDY" => Self::Study,
"TBAN" => Self::TbaPairOffNetting,
"TBIL" => Self::TelecommunicationsBill,
"TCSC" => Self::TownCouncilServiceCharges,
"TELI" => Self::TelephoneInitiatedTransaction,
"TMPG" => Self::TmpgClaimPayment,
"TPRI" => Self::TriPartyRepoInterest,
"TPRP" => Self::TriPartyRepoNetting,
"TRNC" => Self::TruncatedPaymentSlip,
"TRVC" => Self::TravellerCheque,
"WEBI" => Self::InternetInitiatedTransaction,
"IPAY" => Self::InstantPayments,
"IPCA" => Self::InstantPaymentsCancellation,
"IPDO" => Self::InstantPaymentsForDonations,
"IPEA" => Self::InstantPaymentsInECommerceWithoutAddressData,
"IPEC" => Self::InstantPaymentsInECommerceWithAddressData,
"IPEW" => Self::InstantPaymentsInECommerce,
"IPPS" => Self::InstantPaymentsAtPos,
"IPRT" => Self::InstantPaymentsReturn,
"IPU2" => Self::InstantPaymentsUnattendedVendingMachineWith2Fa,
"IPUW" => Self::InstantPaymentsUnattendedVendingMachineWithout2Fa,
"ANNI" => Self::Annuity,
"CAFI" => Self::CustodianManagementFeeInhouse,
"CFDI" => Self::CapitalFallingDueInhouse,
"CMDT" => Self::CommodityTransfer,
"DERI" => Self::Derivatives,
"DIVD" => Self::Dividend,
"FREX" => Self::ForeignExchange,
"HEDG" => Self::Hedging,
"INVS" => Self::InvestmentAndSecurities,
"PRME" => Self::PreciousMetal,
"SAVG" => Self::Savings,
"SECU" => Self::Securities,
"SEPI" => Self::SecuritiesPurchaseInhouse,
"TREA" => Self::TreasuryPayment,
"UNIT" => Self::UnitTrustPurchase,
"FNET" => Self::FuturesNettingPayment,
"FUTR" => Self::Futures,
"ANTS" => Self::AnesthesiaServices,
"CVCF" => Self::ConvalescentCareFacility,
"DMEQ" => Self::DurableMedicaleEquipment,
"DNTS" => Self::DentalServices,
"HLTC" => Self::HomeHealthCare,
"HLTI" => Self::HealthInsurance,
"HSPC" => Self::HospitalCare,
"ICRF" => Self::IntermediateCareFacility,
"LTCF" => Self::LongTermCareFacility,
"MAFC" => Self::MedicalAidFundContribution,
"MARF" => Self::MedicalAidRefund,
"MDCS" => Self::MedicalServices,
"VIEW" => Self::VisionCare,
"CDEP" => Self::CreditDefaultEventPayment,
"SWFP" => Self::SwapContractFinalPayment,
"SWPP" => Self::SwapContractPartialPayment,
"SWRS" => Self::SwapContractResetPayment,
"SWUF" => Self::SwapContractUpfrontPayment,
"ADCS" => Self::AdvisoryDonationCopyrightServices,
"AEMP" => Self::ActiveEmploymentPolicy,
"ALLW" => Self::Allowance,
"ALMY" => Self::AlimonyPayment,
"BBSC" => Self::BabyBonusScheme,
"BECH" => Self::ChildBenefit,
"BENE" => Self::UnemploymentDisabilityBenefit,
"BONU" => Self::BonusPayment,
"CCHD" => Self::CashCompensationHelplessnessDisability,
"COMM" => Self::Commission,
"CSLP" => Self::CompanySocialLoanPaymentToBank,
"GFRP" => Self::GuaranteeFundRightsPayment,
"GVEA" => Self::AustrianGovernmentEmployeesCategoryA,
"GVEB" => Self::AustrianGovernmentEmployeesCategoryB,
"GVEC" => Self::AustrianGovernmentEmployeesCategoryC,
"GVED" => Self::AustrianGovernmentEmployeesCategoryD,
"GWLT" => Self::GovermentWarLegislationTransfer,
"HREC" => Self::HousingRelatedContribution,
"PAYR" => Self::Payroll,
"PEFC" => Self::PensionFundContribution,
"PENS" => Self::PensionPayment,
"PRCP" => Self::PricePayment,
"RHBS" => Self::RehabilitationSupport,
"SALA" => Self::SalaryPayment,
"SPSP" => Self::SalaryPensionSumPayment,
"SSBE" => Self::SocialSecurityBenefit,
"LBIN" => Self::LendingBuyInNetting,
"LCOL" => Self::LendingCashCollateralFreeMovement,
"LFEE" => Self::LendingFees,
"LMEQ" => Self::LendingEquityMarkedToMarketCashCollateral,
"LMFI" => Self::LendingFixedIncomeMarkedToMarketCashCollateral,
"LMRK" => Self::LendingUnspecifiedTypeOfMarkedToMarketCashCollateral,
"LREB" => Self::LendingRebatePayments,
"LREV" => Self::LendingRevenuePayments,
"LSFL" => Self::LendingClaimPayment,
"ESTX" => Self::EstateTax,
"FWLV" => Self::ForeignWorkerLevy,
"GSTX" => Self::GoodsServicesTax,
"HSTX" => Self::HousingTax,
"INTX" => Self::IncomeTax,
"NITX" => Self::NetIncomeTax,
"PTXP" => Self::PropertyTax,
"RDTX" => Self::RoadTax,
"TAXS" => Self::TaxPayment,
"VATX" => Self::ValueAddedTaxPayment,
"WHLD" => Self::WithHolding,
"TAXR" => Self::TaxRefund,
"B112" => Self::TrailerFeePayment,
"BR12" => Self::TrailerFeeRebate,
"TLRF" => Self::NonUsMutualFundTrailerFeePayment,
"TLRR" => Self::NonUsMutualFundTrailerFeeRebatePayment,
"AIRB" => Self::Air,
"BUSB" => Self::Bus,
"FERB" => Self::Ferry,
"RLWY" => Self::Railway,
"TRPT" => Self::RoadPricing,
"CBTV" => Self::CableTvBill,
"ELEC" => Self::ElectricityBill,
"ENRG" => Self::Energies,
"GASB" => Self::GasBill,
"NWCH" => Self::NetworkCharge,
"NWCM" => Self::NetworkCommunication,
"OTLC" => Self::OtherTelecomRelatedBill,
"PHON" => Self::TelephoneBill,
"UBIL" => Self::Utilities,
"WTER" => Self::WaterBill,
"DBCR" => Self::DebitCard,
"CBCR" => Self::CreditCard,
"EFTC" => Self::LowValueCredit,
"EFTD" => Self::LowValueDebit,
"BOND" => Self::Bonds,
"EQTS" => Self::Equities,
"CABD" => Self::CorporateActionsBonds,
"CAEQ" => Self::CorporateActionsEquities,
"RAPI" => Self::RapidPaymentInstruction,
"SASW" => Self::Atm,
"AUCO" => Self::AuthenticatedCollections,
"AMEX" => Self::Amex,
"DICL" => Self::Diners,
"FLCR" => Self::FleetCard,
"MOMA" => Self::MoneyMarket,
"GAMB" => Self::GamblingOrWageringPayment,
"LOTT" => Self::LotteryPayment,
"GAFA" => Self::GovernmentFamilyAllowance,
"GAHO" => Self::GovernmentHousingAllowance,
"PLDS" => Self::PropertyLoanDisbursement,
"PDEP" => Self::PropertyDeposit,
"PCOM" => Self::PropertyCompletionPayment,
"PLRF" => Self::PropertyLoanRefinancing,
tag => todo!("handle code {tag:?}"),
};
Ok(value)
}
}
pub use self::external_code_sets::ExternalPurpose1Code;
};
Ok(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Specifies the technical input channel, as published in an external technical input channel code list.\r\nExternal code sets can be downloaded from www.iso20022.org.\n*`FAXI`-Technical Input Channel is fax or facsimile\n*`PAPR`-Technical Input Channel is paper\n*`TAPE`-Technical Input Channel is tape\n*`WEBI`-Technical Input Channel is internet"]
pub enum ExternalTechnicalInputChannel1Code {
Faxi,
Papr,
Tape,
Webi,
}
impl<'a> ExternalTechnicalInputChannel1Code {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"FAXI" => Self::Faxi,
"PAPR" => Self::Papr,
"TAPE" => Self::Tape,
"WEBI" => Self::Webi,
tag => todo!("handle code {tag:?}"),
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Specifies the technical input channel, as published in an external technical input channel code list.\r\nExternal code sets can be downloaded from www.iso20022.org."]
pub enum ExternalTechnicalInputChannelCode {
#[doc = "Technical Input Channel is fax or facsimile"]
Fax,
#[doc = "Technical Input Channel is paper"]
Paper,
#[doc = "Technical Input Channel is tape"]
Tape,
#[doc = "Technical Input Channel is internet"]
Internet,
}
impl<'a> ExternalTechnicalInputChannelCode {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"FAXI" => Self::Fax,
"PAPR" => Self::Paper,
"TAPE" => Self::Tape,
"WEBI" => Self::Internet,
tag => todo!("handle code {tag:?}"),
};
Ok(value)
}
}
pub use self::external_code_sets::ExternalTechnicalInputChannel1Code;
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Specifies which party(ies) will pay charges due for processing of the instruction."]
pub enum ChargeBearerType1Code {
#[doc = "All transaction charges are to be borne by the debtor."]
BorneByDebtor,
#[doc = "All transaction charges are to be borne by the creditor."]
BorneByCreditor,
#[doc = "In a credit transfer context, means that transaction charges on the sender side are to be borne by the debtor, transaction charges on the receiver side are to be borne by the creditor. In a direct debit context, means that transaction charges on the sender side are to be borne by the creditor, transaction charges on the receiver side are to be borne by the debtor."]
Shared,
#[doc = "Charges are to be applied following the rules agreed in the service level and/or scheme."]
FollowingServiceLevel,
}
impl<'a> ChargeBearerType1Code {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"DEBT" => Self::BorneByDebtor,
"CRED" => Self::BorneByCreditor,
"SHAR" => Self::Shared,
"SLEV" => Self::FollowingServiceLevel,
tag => todo!("handle code {tag:?}"),
};
Ok(value)
}
}
pub type ChargeBearerType1Code = ChargeBearerTypeCode;
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Type of service for which a charge is asked or paid."]
pub enum ChargeType1Code {
#[doc = "Fee paid to a broker for services provided."]
BrokerageFee,
#[doc = "Fee paid for services provided."]
Commission,
#[doc = "Sales charge paid by the investor when redeeming an investment such as an investment fund."]
BackEndLoad,
#[doc = "Sales charge paid immediately by the investor when subscribing to an investment such as an investment fund."]
FrontEndLoad,
#[doc = "In investment funds, charge related to a switch transaction."]
Switch,
#[doc = "In investment funds, a charge payable by the investor covering bid-offer spreads and dealing charges for the underlying investments. The dilution levy is paid to the fund for the benefit of other unit holders."]
DilutionLevy,
#[doc = "Charge that has been reduced from the standard initial charge levied by a fund, eg, during a launch period or as negotiated by a funds supermarket / discount broker."]
Discount,
#[doc = "Fee paid to an investment manager for services. The fee usually includes fund administration costs and investor relationship management. Typically, the amount paid is a percentage of the assets under management."]
ManagementFee,
#[doc = "In investment funds, a fee charged for the transfer of ownership of an investment fund."]
TransferFee,
#[doc = "Fee charged for matching and/or confirmation."]
MatchingFees,
#[doc = "Charge paid for the postage."]
PostageCharge,
#[doc = "Fee charged by a regulatory authority, eg, Securities and Exchange fees."]
RegulatoryFee,
#[doc = "Charge for shipping, including the insurance of securities."]
ShippingCharge,
#[doc = "Fee paid for the provision of financial services."]
ServiceProvisionFee,
#[doc = "Charges, drawdown, or other reduction from or in addition to the deal price."]
SpecialConcessions,
#[doc = "Portion of charge that the fund is entitled to receive, that cannot be reduced by an intermediary."]
PartAcquis,
#[doc = "Fee charged to the investor for early redemption of the fund."]
Penalty,
#[doc = "Deferred sales charge."]
ContingencyDeferredSalesCharge,
#[doc = "Another type of charge."]
Other,
#[doc = "The part of an investor's subscription amount that is held by the fund in order to pay incentive or performance fees at the end of the fiscal year."]
Equalisation,
#[doc = "In investment funds, the charge of the correspondent bank for transferring money."]
CorrespondentBankCharge,
#[doc = "In investment funds, pre-arranged addition to the trade amount based on the published net asset value."]
Premium,
#[doc = "Charge paid at the time of the first subscription."]
Initial,
#[doc = "Fee paid for advisory services rendered."]
AdvisoryFee,
#[doc = "Fee paid to a custodian in respect of custodial services."]
CustodyFee,
#[doc = "Fee paid in respect of publications made."]
PublicationFee,
#[doc = "Fee paid for accounting services rendered."]
AccountingFee,
#[doc = "Charge is for signature services."]
SignatureService,
#[doc = "Charge is for storage of goods at destination."]
StorageAtDestination,
#[doc = "Charge is for storage of goods at origin."]
StorageAtOrigin,
#[doc = "Charge is for packaging of goods."]
Packaging,
#[doc = "Charge is for pick-up of goods."]
PickUp,
#[doc = "Charge is for dangerous goods."]
DangerousGoodsFee,
#[doc = "Charge is for security."]
SecurityCharge,
#[doc = "Charge is a premium for insurance."]
InsurancePremium,
#[doc = "Charge is for the collection of the freight."]
CollectFreight,
#[doc = "Charge is for clearance and handling of goods at origin."]
ClearanceAndHandlingAtOrigin,
#[doc = "Charge is for clearance and handling of goods at destination."]
ClearanceAndHandlingAtDestination,
#[doc = "Charge is an airway bill fee."]
AirWayBillFee,
#[doc = "Charge is for transport."]
TransportCharges,
#[doc = "Charges paid by the investor to the Fund Company for subscription and redemption orders."]
UcitsCommission,
#[doc = "Specially agreed front-end load."]
SpeciallyAgreedFrontEndLoad,
#[doc = "Charge linked to an ADR (American Depositary Receipt)."]
AdrFee,
#[doc = "Fee linked to the cancellation of an issuance."]
IssuanceCancellationFee,
#[doc = "Miscellaneous fee."]
MiscellaneousFee,
#[doc = "Charge linked to the issuance of security."]
IssuanceFee,
}
impl<'a> ChargeType1Code {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"BRKF" => Self::BrokerageFee,
"COMM" => Self::Commission,
"BEND" => Self::BackEndLoad,
"FEND" => Self::FrontEndLoad,
"SWIT" => Self::Switch,
"DLEV" => Self::DilutionLevy,
"DISC" => Self::Discount,
"MANF" => Self::ManagementFee,
"TRAN" => Self::TransferFee,
"MACO" => Self::MatchingFees,
"POST" => Self::PostageCharge,
"REGF" => Self::RegulatoryFee,
"SHIP" => Self::ShippingCharge,
"CHAR" => Self::ServiceProvisionFee,
"SPCN" => Self::SpecialConcessions,
"PACQ" => Self::PartAcquis,
"PENA" => Self::Penalty,
"CDSC" => Self::ContingencyDeferredSalesCharge,
"OTHR" => Self::Other,
"EQUL" => Self::Equalisation,
"CBCH" => Self::CorrespondentBankCharge,
"PREM" => Self::Premium,
"INIT" => Self::Initial,
"ADVI" => Self::AdvisoryFee,
"CUST" => Self::CustodyFee,
"PUBL" => Self::PublicationFee,
"ACCT" => Self::AccountingFee,
"SIGN" => Self::SignatureService,
"STDE" => Self::StorageAtDestination,
"STOR" => Self::StorageAtOrigin,
"PACK" => Self::Packaging,
"PICK" => Self::PickUp,
"DNGR" => Self::DangerousGoodsFee,
"SECU" => Self::SecurityCharge,
"INSU" => Self::InsurancePremium,
"COLF" => Self::CollectFreight,
"CHOR" => Self::ClearanceAndHandlingAtOrigin,
"CHDE" => Self::ClearanceAndHandlingAtDestination,
"AIRF" => Self::AirWayBillFee,
"TRPT" => Self::TransportCharges,
"UCIC" => Self::UcitsCommission,
"SFEN" => Self::SpeciallyAgreedFrontEndLoad,
"ADRF" => Self::AdrFee,
"ISSC" => Self::IssuanceCancellationFee,
"MISC" => Self::MiscellaneousFee,
"ISSU" => Self::IssuanceFee,
tag => todo!("handle code {tag:?}"),
};
Ok(value)
pub enum EntryStatus2Code {
#[doc = "Booked means that the transfer of money has been completed between account servicer and account owner\n\nUsage: \nStatus Booked does not necessarily imply finality of money as this depends on other factors such as the payment system used, the completion of the end-to-end transaction and the terms agreed between account servicer and owner.\nStatus Booked is the only status that can be reversed."]
Booked,
#[doc = "Booking on the account owner's account in the account servicer's ledger has not been completed.\n\nUsage: this can be used for expected items, or for items for which some conditions still need to be fulfilled before they can be booked. If booking takes place, the entry will be included with status Booked in subsequent account report or statement. Status Pending cannot be reversed."]
Pending,
#[doc = "Entry is only provided for information, and no booking on the account owner's account in the account servicer's ledger has been performed."]
Information,
#[doc = "Entry is on the books of the account servicer and value will be applied to the account owner at a future date and time."]
Future,
}
impl<'a> EntryStatus2Code {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"BOOK" => Self::Booked,
"PDNG" => Self::Pending,
"INFO" => Self::Information,
"FUTR" => Self::Future,
tag => todo!("handle code {tag:?}"),
};
Ok(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Specifies the status of an entry."]
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Specifies the balance sub-type, as published in an external balance sub-type code list.\r\nExternal code sets can be downloaded from www.iso20022.org.\n*`ADJT`-Balance to be held in the settlement account in order to comply with the average reserve due, in the event that the bank's balance is equal to the reserve due during the remaining days of the maintenance period.\n*`BCUR`-Balance representing the amount in the domestic or base accounting currency. \n*`BLCK`-Balance representing the regulatory reserve that a financial institution must have with the account servicing institution, eg, the minimum credit balance a financial institution is to keep with its Central Bank for mandatory reserve purposes. In some countries, a blocked balance is known as a 'reserve' balance.\n*`BLKD`-Balance representing funds that cannot be touched by the account owner.\n*`DLOD`-Balance representing the intra day overdraft granted by the Central Bank to financial institutions participating in a RTGS system. This balance may vary over time and shall be offset at the end of the day.\n*`EAST`-Balance representing the potential loan a Central Bank would make in cash if the collateral is pledged, eg, securities available and eligible as collateral with the Central Bank.\n*`FCOL`-Balance representing the forecast of the cash-equivalent resulting from evaluation of existing holdings at CSD that are qualified to serve as collateral.\n*`FCOU`-Balance representing the cash equivalent resulting from evaluation of existing holdings at CSD that are qualified to serve as collateral and have been used as collateral.\n*`FORC`-Balance representing the total of all balance types representing the forecast of transactions to settle, blocked items, custody transactions and corporate actions cash disbursements.\n*`FUND`-Balance representing the net amount to be funded\u{a0}resulting from the difference between\u{a0}the total of all transactions with a cash impact and the existing cash coverage.\n*`INTM`-Balance representing an intermediate amount such as the opening or closing balance incrementally carried forward from one page to the next in a multi-page statement or report.\n*`LCUR`-Balance representing the amount in the local market currency for which the asset is held. \n*`LRLD`-Balance of a specific limit value, eg, a bilateral balance is calculated in relation to a given bilateral limit.\n*`NOTE`-Balance representing the amount that a financial institution has set aside for a specific reason and which is therefore not available. In the context of CSDs, reservation of liquidity made to meet settlement obligations.\n*`PDNG`-Balance of securities pending delivery, such as orders to sell securities have been executed but settlement of the open transactions has not been confirmed.\n*`PIPO`-Balance representing the fictive amount of automated direct debits or payment based on standing arrangements between the CSD and the user. Usage: Pay-Ins and Pay-Outs can be different based on individual payment instructions or available funds.\n*`PRAV`-Average of the daily balances on the account used to fulfil the reserve requirements calculated from the beginning of the maintenance period.\n*`RESV`-Balance representing the regulatory reserve that a financial institution must have with the account servicing institution, eg, the minimum credit balance a financial institution is to keep with its Central Bank for mandatory reserve purposes. \n*`SCOL`-Balance representing the forecast of the cash-equivalent resulting from evaluation of the net incoming balance of securities qualified to serve as collateral for which settlement instructions are held at.\n*`SCOU`-Balance representing the cash-equivalent resulting from evaluation of incoming securities, qualified to serve as collateral and actually used as collateral, which have been settled during the settlement process. \n*`THRE`-Balance representing the amount that will be destined for investment. Difference between available balance and threshold for investment limit."]
pub enum ExternalBalanceSubType1Code {
Adjt,
Bcur,
Blck,
Blkd,
Dlod,
East,
Fcol,
Fcou,
Forc,
Fund,
Intm,
Lcur,
Lrld,
Note,
Pdng,
Pipo,
Prav,
Resv,
Scol,
Scou,
Thre,
}
impl<'a> ExternalBalanceSubType1Code {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"ADJT" => Self::Adjt,
"BCUR" => Self::Bcur,
"BLCK" => Self::Blck,
"BLKD" => Self::Blkd,
"DLOD" => Self::Dlod,
"EAST" => Self::East,
"FCOL" => Self::Fcol,
"FCOU" => Self::Fcou,
"FORC" => Self::Forc,
"FUND" => Self::Fund,
"INTM" => Self::Intm,
"LCUR" => Self::Lcur,
"LRLD" => Self::Lrld,
"NOTE" => Self::Note,
"PDNG" => Self::Pdng,
"PIPO" => Self::Pipo,
"PRAV" => Self::Prav,
"RESV" => Self::Resv,
"SCOL" => Self::Scol,
"SCOU" => Self::Scou,
"THRE" => Self::Thre,
tag => todo!("handle code {tag:?}"),
};
Ok(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Specifies the balance sub-type, as published in an external balance sub-type code list.\r\nExternal code sets can be downloaded from www.iso20022.org."]
pub enum ExternalBalanceSubTypeCode {
#[doc = "Balance to be held in the settlement account in order to comply with the average reserve due, in the event that the bank's balance is equal to the reserve due during the remaining days of the maintenance period."]
Adjustment,
#[doc = "Balance representing the amount in the domestic or base accounting currency. "]
BaseCurrency,
#[doc = "Balance representing the regulatory reserve that a financial institution must have with the account servicing institution, eg, the minimum credit balance a financial institution is to keep with its Central Bank for mandatory reserve purposes. In some countries, a blocked balance is known as a 'reserve' balance."]
Blocked,
#[doc = "Balance representing funds that cannot be touched by the account owner."]
BlockedFunds,
#[doc = "Balance representing the intra day overdraft granted by the Central Bank to financial institutions participating in a RTGS system. This balance may vary over time and shall be offset at the end of the day."]
DaylightOverdraft,
#[doc = "Balance representing the potential loan a Central Bank would make in cash if the collateral is pledged, eg, securities available and eligible as collateral with the Central Bank."]
EligibleAssets,
#[doc = "Balance representing the forecast of the cash-equivalent resulting from evaluation of existing holdings at CSD that are qualified to serve as collateral."]
FirmCollateralization,
#[doc = "Balance representing the cash equivalent resulting from evaluation of existing holdings at CSD that are qualified to serve as collateral and have been used as collateral."]
AmountsThatHaveBeenUsedToServeAsFirmCollateral,
#[doc = "Balance representing the total of all balance types representing the forecast of transactions to settle, blocked items, custody transactions and corporate actions cash disbursements."]
SecuritiesForecast,
#[doc = "Balance representing the net amount to be funded\u{a0}resulting from the difference between\u{a0}the total of all transactions with a cash impact and the existing cash coverage."]
NetFunding,
#[doc = "Balance representing an intermediate amount such as the opening or closing balance incrementally carried forward from one page to the next in a multi-page statement or report."]
Intermediate,
#[doc = "Balance representing the amount in the local market currency for which the asset is held. "]
LocalCurrency,
#[doc = "Balance of a specific limit value, eg, a bilateral balance is calculated in relation to a given bilateral limit."]
LimitRelated,
#[doc = "Balance representing the amount that a financial institution has set aside for a specific reason and which is therefore not available. In the context of CSDs, reservation of liquidity made to meet settlement obligations."]
ReservedLiquidity,
#[doc = "Balance of securities pending delivery, such as orders to sell securities have been executed but settlement of the open transactions has not been confirmed."]
SecuritiesPending,
#[doc = "Balance representing the fictive amount of automated direct debits or payment based on standing arrangements between the CSD and the user. Usage: Pay-Ins and Pay-Outs can be different based on individual payment instructions or available funds."]
PayInPayOut,
#[doc = "Average of the daily balances on the account used to fulfil the reserve requirements calculated from the beginning of the maintenance period."]
ProgressiveAverage,
#[doc = "Balance representing the regulatory reserve that a financial institution must have with the account servicing institution, eg, the minimum credit balance a financial institution is to keep with its Central Bank for mandatory reserve purposes. "]
Reserve,
#[doc = "Balance representing the forecast of the cash-equivalent resulting from evaluation of the net incoming balance of securities qualified to serve as collateral for which settlement instructions are held at."]
SelfCollateralization,
#[doc = "Balance representing the cash-equivalent resulting from evaluation of incoming securities, qualified to serve as collateral and actually used as collateral, which have been settled during the settlement process. "]
AmountsThatHaveBeenUsedToServeAsSelfCollateral,
#[doc = "Balance representing the amount that will be destined for investment. Difference between available balance and threshold for investment limit."]
Threshold,
}
impl<'a> ExternalBalanceSubTypeCode {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"ADJT" => Self::Adjustment,
"BCUR" => Self::BaseCurrency,
"BLCK" => Self::Blocked,
"BLKD" => Self::BlockedFunds,
"DLOD" => Self::DaylightOverdraft,
"EAST" => Self::EligibleAssets,
"FCOL" => Self::FirmCollateralization,
"FCOU" => Self::AmountsThatHaveBeenUsedToServeAsFirmCollateral,
"FORC" => Self::SecuritiesForecast,
"FUND" => Self::NetFunding,
"INTM" => Self::Intermediate,
"LCUR" => Self::LocalCurrency,
"LRLD" => Self::LimitRelated,
"NOTE" => Self::ReservedLiquidity,
"PDNG" => Self::SecuritiesPending,
"PIPO" => Self::PayInPayOut,
"PRAV" => Self::ProgressiveAverage,
"RESV" => Self::Reserve,
"SCOL" => Self::SelfCollateralization,
"SCOU" => Self::AmountsThatHaveBeenUsedToServeAsSelfCollateral,
"THRE" => Self::Threshold,
tag => todo!("handle code {tag:?}"),
};
Ok(value)
}
}
pub use self::external_code_sets::ExternalBalanceSubType1Code;
pub enum BalanceType12Code {
#[doc = "Balance attributed to receivables."]
Receivables,
#[doc = "Balance attributed to payables."]
Payables,
#[doc = "Balance attributed according to a different classification, which is not explictly defined."]
Other,
#[doc = "Balance attributed to expenses."]
Expenses,
#[doc = "Balance attributed to cash and cash equivalents."]
CashAndCashEquivalents,
#[doc = "Balance attributed to investor inflow/outflow (creations, cancellations, income distributions)."]
InvestorInflowOutflow,
#[doc = "Balance attributed to revenues; including dividends, interest, net realised gains/losses etc."]
Revenues,
#[doc = "Balance attributed to borrowings."]
Borrowings,
#[doc = "Balance attributed to investments at value."]
Investments,
#[doc = "Book balance of the account at the beginning of the account servicer's business day. It always equals the closing book balance from the previous business day. Note: the available balance at the beginning of the account servicer's business day may be different from the closing book balance from the previous business day."]
Opening,
#[doc = "Balance calculated in the course of the account servicer's business day, at the time specified, and subject to further changes during the business day. The interim balance is calculated on the basis of booked credit and debit items during the calculation time/period specified."]
Interim,
#[doc = "Balance of the account at the end of the account servicer's business day. It is the sum of the opening balance at the beginning of the day and all entries booked to the account during the account servicer's business day."]
Closing,
#[doc = "Balance that is registered in the books of the account servicer."]
Book,
#[doc = "Balance of the account at a precise moment in time."]
Current,
#[doc = "Balance of securities pending delivery, eg, orders to sell securities have been executed but settlement of the open transactions has not been confirmed."]
Pending,
#[doc = "Balance of a specific limit value, eg, a bilateral balance is calculated in relation to a given bilateral limit."]
LimitRelated,
#[doc = "Balance of money or securities that is at the disposal of the account owner on the date specified."]
Available,
#[doc = "Balance composed of the sum of all liquidity transfers made to or from an account."]
LiquidityTransfer,
#[doc = "Balance representing the sum of all credit entries booked to an account."]
Credit,
#[doc = "Balance representing the potential loan a Central Bank would make in cash if the collateral is pledged, eg, securities available and eligible as collateral with the Central Bank."]
EligibleAssets,
#[doc = "Balance representing the sum of entries as a result of payments processing. Entries relating to fees, interest, or other movements not a result of payments sent or received by the account owner are not included."]
Payment,
#[doc = "Balance representing the regulatory reserve that a financial institution must have with the account servicing institution, eg, the minimum credit balance a financial institution is to keep with its Central Bank for mandatory reserve purposes. In some countries, a blocked balance is known as a 'reserve' balance."]
Blocked,
#[doc = "Balance, composed of booked entries and pending items known at the time of calculation, which projects the end of day balance if everything is booked on the account and no other entry is posted."]
Expected,
#[doc = "Balance representing the intra day overdraft granted by the Central Bank to financial institutions participating in a RTGS system. This balance may vary over time and shall be offset at the end of the day."]
DaylightOverdraft,
#[doc = "Balance, composed of booked entries and pending items known at the time of calculation, which projects the end of day credit balance if everything books to the account and no other credit entry is posted."]
ExpectedCredit,
#[doc = "Balance, composed of booked entries and pending items known at the time of calculation, which projects the end of day debit balance if everything books to the account and no other debit entry is posted."]
ExpectedDebit,
#[doc = "Balance to be held in the settlement account in order to comply with the average reserve due, in the event that the bank's balance is equal to the reserve due during the remaining days of the maintenance period."]
Adjustment,
#[doc = "Average of the daily balances on the account used to fulfil the reserve requirements calculated from the beginning of the maintenance period."]
ProgressiveAverage,
#[doc = "Balance representing the sum of all debit entries booked to an account."]
Debit,
#[doc = "Balance representing the amount that will be destined for investment. Difference between available balance and threshold for investment limit."]
Threshold,
#[doc = "Balance representing the amount that a financial institution has set aside for a specific reason and which is therefore not available."]
Noted,
#[doc = "Balance of the account identified (as opposed to Master Balance)."]
_Self,
#[doc = "Balance of the identified account plus the balance of all of its subaccounts."]
Master,
#[doc = "Balance representing the forecast of total of all cash legs for trades that are ready to settle via CSD. Amounts shown are still subject to processing of the securities settlement."]
ForecastSettlement,
#[doc = "Balance representing the projected total of all cash legs for trades settling via CSD that have been matched but blocked in order to not settle. These blocked trades are included in the calculation for settlement (eg, to avoid overdrafts).\nUsage rule: Blocking can be done by account owner or its counterparties. Usually this is done to chain transactions or to prioritise other trades. Blocked trades have an indicator that prevents the transactions from settling. Once matched, they can settle whenever the freeze is lifted. In this case they will move to FSET. Lifting the freeze can happen anytime during the day and the transaction will be settling in the next settlement cycle which can be the same day if the (I)CSD's operates several settlements cycles per day."]
BlockedTrades,
#[doc = "Balance representing the projected total of all cash legs for trades settling via CSD that have been matched but blocked in order to not settle. These blocked transactions are not included in the calculation for settlement."]
OtherBlockedTrades,
#[doc = "Balance representing the projected total of all asset servicing transactions such as dividends, income corporate actions equivalents, tax returns, etc."]
Custody,
#[doc = "Balance representing the total of all balance types representing transactions to settle, blocked items and custody transactions."]
CashForecast,
#[doc = "Balance representing the projected total amount of all payment obligations to the participant (bank), based on their role as main paying agent."]
DividendsCollection,
#[doc = "Balance representing the net amount to be funded resulting from all transactions which have an impact on the funding requirement."]
NetFunding,
#[doc = "Balance representing the fictive forecast of automated direct debits or payment based on standing arrangements between the CSD and the user.\n\nUsage: Pay-Ins and Pay-Outs can be different based on individual payment instructions or available funds."]
PayInPayOut,
#[doc = "Balance representing the forecast of the total of all cash legs of transactions traded in exchanges."]
ExchangeForecast,
#[doc = "Balance representing the forecast of the total of all cash legs of transactions traded in exchanges that operate a central counterparty functionality."]
CentralCounterparty,
#[doc = "Balance representing the total of the payments that were put on hold because the limits have been exceeded."]
TotalOnHold,
#[doc = "Balance representing the total incoming payments that were put on hold because the credit limit has been exceeded."]
CreditOnHold,
#[doc = "Balance representing the total outgoing payments that were put on hold because the debit limit has been exceeded."]
DebitOnHold,
#[doc = "Balance representing the total of the payments that have been processed and are waiting for settlement during the day."]
TotalProcessed,
#[doc = "Balance representing the total incoming payments that have been processed and are waiting for settlement."]
CreditProcessed,
#[doc = "Balance representing the total outgoing payments that have been processed and are waiting for settlement."]
DebitProcessed,
#[doc = "Balance representing the total of the payments with a processing date in the future."]
TotalFuture,
#[doc = "Balance representing the total of the payments that have been rejected."]
TotalRejected,
#[doc = "Opening balance of amount of money that is at the disposal of the account owner on the date specified."]
OpeningAvailable,
#[doc = "Available balance calculated in the course of the account servicer's business day, at the time specified, and subject to further changes during the business day. The interim balance is calculated on the basis of booked credit and debit items during the calculation time/period specified."]
InterimAvailable,
#[doc = "Closing balance of amount of money that is at the disposal of the account owner on the date specified."]
ClosingAvailable,
#[doc = "Forward available balance of money that is at the disposal of the account owner on the date specified."]
ForwardAvailable,
#[doc = "Balance of the account at the end of the pre-agreed account reporting period. It is the sum of the opening booked balance at the beginning of the period and all entries booked to the account during the pre-agreed account reporting period."]
ClosingBooked,
#[doc = "Balance calculated in the course of the account servicer's business day, at the time specified, and subject to further changes during the business day. The interim balance is calculated on the basis of booked credit and debit items during the calculation time/period specified."]
InterimBooked,
#[doc = "Book balance of the account at the beginning of the account reporting period. It always equals the closing book balance from the previous report."]
OpeningBooked,
#[doc = "Balance of the account at the previously closed account reporting period. The opening booked balance for the new period has to be equal to this balance. \n\nUsage: the previously booked closing balance should equal (inclusive date) the booked closing balance of the date it references and equal the actual booked opening balance of the current date."]
PreviouslyClosedBooked,
#[doc = "Investment opening balance of amount of money that is at the disposal of the account owner on the date specified."]
InvestmentOpeningAvailable,
#[doc = "Investment available balance for calculated in the course of the account servicer's business day, at the time specified, and subject to further changes during the business day. The interim balance is calculated on the basis of booked credit and debit items during the calculation time/period specified."]
InvestmentInterimAvailable,
#[doc = "Investment closing balance of an amount of money that is at the disposal of the account owner on the date specified."]
InvestmentClosingAvailable,
#[doc = "Investment forward available balance of money that is at the disposal of the account owner on the date specified."]
InvestmentForwardAvailable,
#[doc = "Investment (mutual funds) balance of the account at the end of the pre-agreed account reporting period. It is the sum of the opening booked balance at the beginning of the period and all entries booked to the account during the pre-agreed account reporting period."]
InvestmentClosingBooked,
#[doc = "Investment balance calculated in the course of the account servicer's business day, at the time specified, and subject to further changes during the business day. The interim balance is calculated on the basis of booked credit and debit items during the calculation time/period specified."]
InvestmentInterimBooked,
#[doc = "Investment book balance of the account at the beginning of the account reporting period. It always equals the closing book balance from the previous report."]
InvestmentOpeningBooked,
#[doc = "Investment balance, composed of booked entries and pending items known at the time of calculation, which projects the end of day balance if everything is booked on the account and no other entry is posted."]
InvestmentExpected,
#[doc = "Disbursement opening balance of amount of money that is at the disposal of the account owner on the date specified."]
DisbursementOpeningAvailable,
#[doc = "Disbursement available balance calculated in the course of the account servicer's business day, at the time specified, and subject to further changes during the business day. The interim balance is calculated on the basis of booked credit and debit items during the calculation time/period specified."]
DisbursementInterimAvailable,
#[doc = "Disbursement closing balance of amount of money that is at the disposal of the account owner on the date specified."]
DisbursementClosingAvailable,
#[doc = "Disbursement forward available balance of money that is at the disposal of the account owner on the date specified."]
DisbursementForwardAvailable,
#[doc = "Disbursement balance of the account at the end of the pre-agreed account reporting period. It is the sum of the opening booked balance at the beginning of the period and all entries booked to the account during the pre-agreed account reporting period."]
DisbursementClosingBooked,
#[doc = "Disbursement balance calculated in the course of the account servicer's business day, at the time specified, and subject to further changes during the business day. The interim balance is calculated on the basis of booked credit and debit items during the calculation time/period specified."]
DisbursementInterimBooked,
#[doc = "Disbursement book balance of the account at the beginning of the account reporting period. It always equals the closing book balance from the previous report."]
DisbursementOpeningBooked,
#[doc = "Disbursement balance, composed of booked entries and pending items known at the time of calculation, which projects the end of day balance if everything is booked on the account and no other entry is posted."]
DisbursementExpected,
#[doc = "Collection opening balance of amount of money that is at the disposal of the account owner on the date specified."]
CollectionOpeningAvailable,
#[doc = "Collection available balance calculated in the course of the account servicer's business day, at the time specified, and subject to further changes during the business day. The interim balance is calculated on the basis of booked credit and debit items during the calculation time/period specified."]
CollectionInterimAvailable,
#[doc = "Collection closing balance of amount of money that is at the disposal of the account owner on the date specified."]
CollectionClosingAvailable,
#[doc = "Collection forward available balance of money that is at the disposal of the account owner on the date specified."]
CollectionForwardAvailable,
#[doc = "Collection balance of the account at the end of the pre-agreed account reporting period. It is the sum of the opening booked balance at the beginning of the period and all entries booked to the account during the pre-agreed account reporting period."]
CollectionClosingBooked,
#[doc = "Collection balance calculated in the course of the account servicer's business day, at the time specified, and subject to further changes during the business day. The interim balance is calculated on the basis of booked credit and debit items during the calculation time/period specified."]
CollectionInterimBooked,
#[doc = "Collection book balance of the account at the beginning of the account reporting period. It always equals the closing book balance from the previous report."]
CollectionOpeningBooked,
#[doc = "Collection balance, composed of booked entries and pending items known at the time of calculation, which projects the end of day balance if everything is booked on the account and no other entry is posted."]
CollectionExpected,
#[doc = "Balance representing the forecast of the cash-equivalent resulting from evaluation of existing holdings at CSD that are qualified to serve as collateral."]
FirmCollateralisation,
#[doc = "Balance representing the cash equivalent resulting from evaluation of existing holdings at CSD that are qualified to serve as collateral and have been used as collateral."]
UsedAmountsFirmCollateralisation,
#[doc = "Balance representing the forecast of the cash-equivalent resulting from evaluation of the net incoming balance of securities qualified to serve as collateral for which settlement instructions are held at."]
SelfCollateralisation,
#[doc = "Balance representing the cash-equivalent resulting from evaluation of incoming securities, qualified to serve as collateral and actually used as collateral, which have been settled during the settlement process."]
UsedAmountsSelfCollateralisation,
#[doc = "Balance representing the actual total of all asset servicing transactions such as dividends, income corporate actions equivalents, tax returns, redemptions, etc."]
CustodyActual,
#[doc = "Balance representing the forecast of the total of all cash legs of transactions in exchanges, going through CCP functions."]
CcpGuaranteedForecasting,
#[doc = "Balance representing the forecast of the total of all cash legs of transactions traded in exchanges not going through CCP functions."]
NonCcpGuaranteedForecasting,
#[doc = "Balance representing the cash equivalent of all settled securities transactions."]
DefinitiveSettledSecurities,
#[doc = "Balance representing the cash equivalent of transactions with a lack of holdings."]
LackOfHoldingsTransactions,
#[doc = "Balance representing the cash equivalent of all non-settled securities transactions."]
NonSettledSecurities,
#[doc = "Balance representing the Forecast of the total of all cash-legs of transactions 'over the counter' (OTC), going through CCP functions."]
CcpGuaranteedOtcTransactions,
#[doc = "Balance representing the forecast of the total of all cash legs of transactions traded 'over the counter' (OTC)."]
ForecastOtcTransactions,
#[doc = "Balance representing the forecast of the total of all cash legs of transactions traded 'over the counter' (OTC) not going through CCP functions."]
NonCcpGuaranteedOtcTransactions,
#[doc = "Balance represents the settlement account processor direct debit amount."]
SapDirectDebitAmount,
#[doc = "Balance represents the settlement account processor direct credit amount."]
SapDirectCreditAmount,
#[doc = "Balance represents the total of the central moneymarkets unit processor repo debits."]
CmupRepoDebit,
#[doc = "Balance represents the total of the central moneymarkets unit processor repo credits."]
CmupRepoCredit,
#[doc = "Balance represents the total of the bulk settlement and central moneymarkets unit processor debit."]
BulkSettlementCmupDebit,
#[doc = "Balance represents the total of the bulk settlement and central moneymarkets unit processor credit."]
BulkSettlementCmupCredit,
#[doc = "Balance represents the settlement account processor queue amount."]
SapQueueAmount,
#[doc = "Balance represents the intraday repo limit."]
IntradayRepoLimit,
#[doc = "Balance represents the intraday repo drawings."]
IntradayRepoDrawings,
#[doc = "Balance represents the discount window repo drawings."]
DiscountWindowRepoDrawings,
#[doc = "Balance represents the available discounted market value for discount window repo."]
AvailableDmvForDiscountWindowRepo,
#[doc = "Balance represents the available discounted market value for intraday repo."]
AvailableDmvForIntradayRepo,
#[doc = "Balance of instructed position."]
Elected,
#[doc = "Balance of financial instruments that are reserved for the distribution of the proceeds."]
ReservedForDistribution,
#[doc = "Balance of securities which are reserved temporarily in the SPA account before they will effectively be exchanged."]
ReservedForRemoval,
#[doc = "Balance of cash that may only be used under certain conditions.\n\nBalance type is used to block securities/cash in the client account e.g., in relation to elections relating to certain corporate actions. The holding is under the direct control of the system paying agent, who us the only one who can transfer securities out of this balance type.\nAlso known as the \"escrow balance\" or \"sequestered balance\"."]
Restricted,
#[doc = "Total quantity of financial instruments entitled to the account owner based on the terms of the corporate action event."]
TotalEntitled,
#[doc = "Balance of uninstructed position."]
Unelected,
#[doc = "Balance for informational purposes."]
Information,
#[doc = "Amount of money due."]
AmountDue,
#[doc = "Amount put on hold."]
AmountOnHold,
#[doc = "Amount of money owed"]
AmountOwing,
#[doc = "Cleared items balance. "]
ClearedItem,
#[doc = "Credit line available."]
CreditLine,
#[doc = "Ledger balance refers to posted transactions (e.g. limit authorisation amount - posted transactions)."]
Ledger,
#[doc = "Other type of balance defined at national level"]
OtherNational,
#[doc = "Other type of balance defined at private level."]
OtherPrivate,
}
impl<'a> BalanceType12Code {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"RECE" => Self::Receivables,
"PAYA" => Self::Payables,
"OTHR" => Self::Other,
"EXPN" => Self::Expenses,
"CASE" => Self::CashAndCashEquivalents,
"IIOF" => Self::InvestorInflowOutflow,
"REVE" => Self::Revenues,
"BORR" => Self::Borrowings,
"INVE" => Self::Investments,
"OPNG" => Self::Opening,
"INTM" => Self::Interim,
"CLSG" => Self::Closing,
"BOOK" => Self::Book,
"CRRT" => Self::Current,
"PDNG" => Self::Pending,
"LRLD" => Self::LimitRelated,
"AVLB" => Self::Available,
"LTSF" => Self::LiquidityTransfer,
"CRDT" => Self::Credit,
"EAST" => Self::EligibleAssets,
"PYMT" => Self::Payment,
"BLCK" => Self::Blocked,
"XPCD" => Self::Expected,
"DLOD" => Self::DaylightOverdraft,
"XCRD" => Self::ExpectedCredit,
"XDBT" => Self::ExpectedDebit,
"ADJT" => Self::Adjustment,
"PRAV" => Self::ProgressiveAverage,
"DBIT" => Self::Debit,
"THRE" => Self::Threshold,
"NOTE" => Self::Noted,
"SELF" => Self::_Self,
"MSTR" => Self::Master,
"FSET" => Self::ForecastSettlement,
"BLOC" => Self::BlockedTrades,
"OTHB" => Self::OtherBlockedTrades,
"CUST" => Self::Custody,
"FORC" => Self::CashForecast,
"COLC" => Self::DividendsCollection,
"FUND" => Self::NetFunding,
"PIPO" => Self::PayInPayOut,
"XCHG" => Self::ExchangeForecast,
"CCPS" => Self::CentralCounterparty,
"TOHB" => Self::TotalOnHold,
"COHB" => Self::CreditOnHold,
"DOHB" => Self::DebitOnHold,
"TPBL" => Self::TotalProcessed,
"CPBL" => Self::CreditProcessed,
"DPBL" => Self::DebitProcessed,
"FUTB" => Self::TotalFuture,
"REJB" => Self::TotalRejected,
"OPAV" => Self::OpeningAvailable,
"ITAV" => Self::InterimAvailable,
"CLAV" => Self::ClosingAvailable,
"FWAV" => Self::ForwardAvailable,
"CLBD" => Self::ClosingBooked,
"ITBD" => Self::InterimBooked,
"OPBD" => Self::OpeningBooked,
"PRCD" => Self::PreviouslyClosedBooked,
"IOPA" => Self::InvestmentOpeningAvailable,
"IITA" => Self::InvestmentInterimAvailable,
"ICLA" => Self::InvestmentClosingAvailable,
"IFWA" => Self::InvestmentForwardAvailable,
"ICLB" => Self::InvestmentClosingBooked,
"IITB" => Self::InvestmentInterimBooked,
"IOPB" => Self::InvestmentOpeningBooked,
"IXPC" => Self::InvestmentExpected,
"DOPA" => Self::DisbursementOpeningAvailable,
"DITA" => Self::DisbursementInterimAvailable,
"DCLA" => Self::DisbursementClosingAvailable,
"DFWA" => Self::DisbursementForwardAvailable,
"DCLB" => Self::DisbursementClosingBooked,
"DITB" => Self::DisbursementInterimBooked,
"DOPB" => Self::DisbursementOpeningBooked,
"DXPC" => Self::DisbursementExpected,
"COPA" => Self::CollectionOpeningAvailable,
"CITA" => Self::CollectionInterimAvailable,
"CCLA" => Self::CollectionClosingAvailable,
"CFWA" => Self::CollectionForwardAvailable,
"CCLB" => Self::CollectionClosingBooked,
"CITB" => Self::CollectionInterimBooked,
"COPB" => Self::CollectionOpeningBooked,
"CXPC" => Self::CollectionExpected,
"FCOL" => Self::FirmCollateralisation,
"FCOU" => Self::UsedAmountsFirmCollateralisation,
"SCOL" => Self::SelfCollateralisation,
"SCOU" => Self::UsedAmountsSelfCollateralisation,
"CUSA" => Self::CustodyActual,
"XCHC" => Self::CcpGuaranteedForecasting,
"XCHN" => Self::NonCcpGuaranteedForecasting,
"DSET" => Self::DefinitiveSettledSecurities,
"LACK" => Self::LackOfHoldingsTransactions,
"NSET" => Self::NonSettledSecurities,
"OTCC" => Self::CcpGuaranteedOtcTransactions,
"OTCG" => Self::ForecastOtcTransactions,
"OTCN" => Self::NonCcpGuaranteedOtcTransactions,
"SAPD" => Self::SapDirectDebitAmount,
"SAPC" => Self::SapDirectCreditAmount,
"REPD" => Self::CmupRepoDebit,
"REPC" => Self::CmupRepoCredit,
"BSCD" => Self::BulkSettlementCmupDebit,
"BSCC" => Self::BulkSettlementCmupCredit,
"SAPP" => Self::SapQueueAmount,
"IRLT" => Self::IntradayRepoLimit,
"IRDR" => Self::IntradayRepoDrawings,
"DWRD" => Self::DiscountWindowRepoDrawings,
"ADWR" => Self::AvailableDmvForDiscountWindowRepo,
"AIDR" => Self::AvailableDmvForIntradayRepo,
"ELEC" => Self::Elected,
"RDIS" => Self::ReservedForDistribution,
"RREM" => Self::ReservedForRemoval,
"REST" => Self::Restricted,
"TENT" => Self::TotalEntitled,
"UNEL" => Self::Unelected,
"INFO" => Self::Information,
"AMTD" => Self::AmountDue,
"AMOH" => Self::AmountOnHold,
"AMTO" => Self::AmountOwing,
"CLRI" => Self::ClearedItem,
"CRDL" => Self::CreditLine,
"LDGR" => Self::Ledger,
"OTHN" => Self::OtherNational,
"OTHP" => Self::OtherPrivate,
tag => todo!("handle code {tag:?}"),
};
Ok(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Specifies the nature of the balance."]
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Specifies if an operation is an increase or a decrease or the result of a reversal operation."]
pub enum CreditDebitCode {
#[doc = "Operation is a decrease."]
Debit,
#[doc = "Operation is an increase."]
Credit,
#[doc = "Credit entry used to reverse a previously booked debit entry."]
ReversalDebit,
#[doc = "Debit entry used to reverse a previously booked credit entry."]
ReversalCredit,
}
impl<'a> CreditDebitCode {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"DBIT" => Self::Debit,
"CRDT" => Self::Credit,
"RVDB" => Self::ReversalDebit,
"RVCD" => Self::ReversalCredit,
tag => todo!("handle code {tag:?}"),
};
Ok(value)
pub enum InterestType1Code {
#[doc = "During or within a business day."]
IntraDay,
#[doc = "Period of time between the end of a business day and the start of the next business day (usually the day after)."]
OverNight,
}
impl<'a> InterestType1Code {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"INDY" => Self::IntraDay,
"OVRN" => Self::OverNight,
tag => todo!("handle code {tag:?}"),
};
Ok(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Indicates which type of interest is applied to a balance left on an account."]
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Specifies the external financial institution identification scheme name code in the format of character string with a maximum length of 4 characters.\r\nThe list of valid codes is an external code list published separately.\r\nExternal code sets can be downloaded from www.iso20022.org."]
pub enum ExternalFinancialInstitutionIdentification1Code {}
impl<'a> ExternalFinancialInstitutionIdentification1Code {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
tag => todo!("handle code {tag:?}"),
};
Ok(value)
}
}
};
Ok(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Specifies the clearing system identification code, as published in an external clearing system identification code list.\r\nExternal code sets can be downloaded from www.iso20022.org.\n*`ATBLZ`-Bank Branch code used in Austria\n*`AUBSB`-Bank Branch code used in Australia\n*`CACPA`-Bank Branch code used in Canada\n*`CHBCC`-Financial Institution Identification (IID) used in Switzerland, without check digit\n*`CHSIC`-Financial Institution Identification (IID) used in Switzerland, including check digit\n*`CNAPS`-Bank Branch code used in China\n*`DEBLZ`-Bank Branch code used in Germany\n*`ESNCC`-Bank Branch code used in Spain\n*`GBDSC`-Bank Branch code used in the UK\n*`GRBIC`-Bank Branch code used in Greece\n*`HKNCC`-Bank Branch code used in Hong Kong\n*`IENCC`-Bank Branch code used in Ireland\n*`INFSC`-Bank Branch code used in India\n*`ITNCC`-Bank Branch code used in Italy\n*`JPZGN`-Bank Branch code used in Japan\n*`NZNCC`-Bank Branch code used in New Zealand\n*`PLKNR`-Bank Branch code used in Poland\n*`PTNCC`-Bank Branch code used in Portugal\n*`RUCBC`-Bank Branch code used in Russia\n*`SESBA`-Bank Branch code used in Sweden\n*`SGIBG`-Bank Branch code used in Singapore\n*`THCBC`-Bank Identification code used in Thailand\n*`TWNCC`-Bank Branch code used in Taiwan\n*`USABA`-Routing Transit number assigned by the ABA for US financial institutons\n*`USPID`-Bank identifier used by CHIPs in the US\n*`ZANCC`-Bank Branch code used in South Africa\n*`NZRSA`-RTGS settlement account used in New Zealand.\n*`MZBMO`-Banco de Mocambique RTGS system.\n*`CNCIP`-Chinese Cross-border Interbank Payment System (CIPS) Identifier."]
pub enum ExternalClearingSystemIdentification1Code {
Atblz,
Aubsb,
Cacpa,
Chbcc,
Chsic,
Cnaps,
Deblz,
Esncc,
Gbdsc,
Grbic,
Hkncc,
Iencc,
Infsc,
Itncc,
Jpzgn,
Nzncc,
Plknr,
Ptncc,
Rucbc,
Sesba,
Sgibg,
Thcbc,
Twncc,
Usaba,
Uspid,
Zancc,
Nzrsa,
Mzbmo,
Cncip,
}
impl<'a> ExternalClearingSystemIdentification1Code {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"ATBLZ" => Self::Atblz,
"AUBSB" => Self::Aubsb,
"CACPA" => Self::Cacpa,
"CHBCC" => Self::Chbcc,
"CHSIC" => Self::Chsic,
"CNAPS" => Self::Cnaps,
"DEBLZ" => Self::Deblz,
"ESNCC" => Self::Esncc,
"GBDSC" => Self::Gbdsc,
"GRBIC" => Self::Grbic,
"HKNCC" => Self::Hkncc,
"IENCC" => Self::Iencc,
"INFSC" => Self::Infsc,
"ITNCC" => Self::Itncc,
"JPZGN" => Self::Jpzgn,
"NZNCC" => Self::Nzncc,
"PLKNR" => Self::Plknr,
"PTNCC" => Self::Ptncc,
"RUCBC" => Self::Rucbc,
"SESBA" => Self::Sesba,
"SGIBG" => Self::Sgibg,
"THCBC" => Self::Thcbc,
"TWNCC" => Self::Twncc,
"USABA" => Self::Usaba,
"USPID" => Self::Uspid,
"ZANCC" => Self::Zancc,
"NZRSA" => Self::Nzrsa,
"MZBMO" => Self::Mzbmo,
"CNCIP" => Self::Cncip,
tag => todo!("handle code {tag:?}"),
};
Ok(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Specifies the clearing system identification code, as published in an external clearing system identification code list.\r\nExternal code sets can be downloaded from www.iso20022.org."]
pub enum ExternalClearingSystemIdentificationCode {
#[doc = "Bank Branch code used in Austria"]
AustrianBankleitzahl,
#[doc = "Bank Branch code used in Australia"]
AustralianBankStateBranchCodeBsb,
#[doc = "Bank Branch code used in Canada"]
CanadianPaymentsAssociationPaymentRoutingNumber,
#[doc = "Financial Institution Identification (IID) used in Switzerland, without check digit"]
SwissFinancialInstitutionIdentificationShort,
#[doc = "Financial Institution Identification (IID) used in Switzerland, including check digit"]
SwissFinancialInstitutionIdentificationLong,
#[doc = "Bank Branch code used in China"]
CnapsIdentifier,
#[doc = "Bank Branch code used in Germany"]
GermanBankleitzahl,
#[doc = "Bank Branch code used in Spain"]
SpanishDomesticInterbankingCode,
#[doc = "Bank Branch code used in the UK"]
UkDomesticSortCode,
#[doc = "Bank Branch code used in Greece"]
HelenicBankIdentificationCode,
#[doc = "Bank Branch code used in Hong Kong"]
HongKongBankCode,
#[doc = "Bank Branch code used in Ireland"]
IrishNationalClearingCode,
#[doc = "Bank Branch code used in India"]
IndianFinancialSystemCode,
#[doc = "Bank Branch code used in Italy"]
ItalianDomesticIdentificationCode,
#[doc = "Bank Branch code used in Japan"]
JapanZenginClearingCode,
#[doc = "Bank Branch code used in New Zealand"]
NewZealandNationalClearingCode,
#[doc = "Bank Branch code used in Poland"]
PolishNationalClearingCode,
#[doc = "Bank Branch code used in Portugal"]
PortugueseNationalClearingCode,
#[doc = "Bank Branch code used in Russia"]
RussianCentralBankIdentificationCode,
#[doc = "Bank Branch code used in Sweden"]
SwedenBankgiroClearingCode,
#[doc = "Bank Branch code used in Singapore"]
IbgSortCode,
#[doc = "Bank Identification code used in Thailand"]
ThaiCentralBankIdentificationCode,
#[doc = "Bank Branch code used in Taiwan"]
FinancialInstitutionCode,
#[doc = "Routing Transit number assigned by the ABA for US financial institutons"]
UnitedStatesRoutingNumberFedwireNacha,
#[doc = "Bank identifier used by CHIPs in the US"]
ChipsParticipantIdentifier,
#[doc = "Bank Branch code used in South Africa"]
SouthAfricanNationalClearingCode,
#[doc = "RTGS settlement account used in New Zealand."]
NewZealandRtgsClearingCode,
}
impl<'a> ExternalClearingSystemIdentificationCode {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"ATBLZ" => Self::AustrianBankleitzahl,
"AUBSB" => Self::AustralianBankStateBranchCodeBsb,
"CACPA" => Self::CanadianPaymentsAssociationPaymentRoutingNumber,
"CHBCC" => Self::SwissFinancialInstitutionIdentificationShort,
"CHSIC" => Self::SwissFinancialInstitutionIdentificationLong,
"CNAPS" => Self::CnapsIdentifier,
"DEBLZ" => Self::GermanBankleitzahl,
"ESNCC" => Self::SpanishDomesticInterbankingCode,
"GBDSC" => Self::UkDomesticSortCode,
"GRBIC" => Self::HelenicBankIdentificationCode,
"HKNCC" => Self::HongKongBankCode,
"IENCC" => Self::IrishNationalClearingCode,
"INFSC" => Self::IndianFinancialSystemCode,
"ITNCC" => Self::ItalianDomesticIdentificationCode,
"JPZGN" => Self::JapanZenginClearingCode,
"NZNCC" => Self::NewZealandNationalClearingCode,
"PLKNR" => Self::PolishNationalClearingCode,
"PTNCC" => Self::PortugueseNationalClearingCode,
"RUCBC" => Self::RussianCentralBankIdentificationCode,
"SESBA" => Self::SwedenBankgiroClearingCode,
"SGIBG" => Self::IbgSortCode,
"THCBC" => Self::ThaiCentralBankIdentificationCode,
"TWNCC" => Self::FinancialInstitutionCode,
"USABA" => Self::UnitedStatesRoutingNumberFedwireNacha,
"USPID" => Self::ChipsParticipantIdentifier,
"ZANCC" => Self::SouthAfricanNationalClearingCode,
"NZRSA" => Self::NewZealandRtgsClearingCode,
tag => todo!("handle code {tag:?}"),
pub enum CashAccountType4Code {
#[doc = "Account used for the payment of cash."]
CashPayment,
#[doc = "Account used for charges if different from the account for payment."]
Charges,
#[doc = "Account used for commission if different from the account for payment."]
Commission,
#[doc = "Account used for taxes if different from the account for payment."]
Tax,
#[doc = "Account used for payment of income if different from the current cash account."]
CashIncome,
#[doc = "Account used for trading if different from the current cash account."]
CashTrading,
#[doc = "Account used to post debit and credit entries, as a result of transactions cleared and settled through a specific clearing and settlement system."]
Settlement,
#[doc = "Account used to post debits and credits when no specific account has been nominated."]
Current,
#[doc = "Account used for savings."]
Savings,
#[doc = "Account used for overnight deposits."]
OverNightDeposit,
#[doc = "Account used for a marginal lending facility."]
MarginalLending,
#[doc = "Account used for non-resident external."]
NonResidentExternal,
#[doc = "Account used for money markets if different from the cash account."]
MoneyMarket,
#[doc = "Account used for loans."]
Loan,
#[doc = "Accounts used for salary payments."]
Salary,
#[doc = "Account is used for overdrafts."]
Overdraft,
#[doc = "Account is for the coverage of lending."]
Lending,
#[doc = "Account is for collateral."]
Collateral,
#[doc = "Account is for financial settlements."]
FinancialSettlement,
#[doc = "Account is for margin returns."]
MarginReturn,
#[doc = "Account is an segregated account."]
Segregated,
}
impl<'a> CashAccountType4Code {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"CASH" => Self::CashPayment,
"CHAR" => Self::Charges,
"COMM" => Self::Commission,
"TAXE" => Self::Tax,
"CISH" => Self::CashIncome,
"TRAS" => Self::CashTrading,
"SACC" => Self::Settlement,
"CACC" => Self::Current,
"SVGS" => Self::Savings,
"ONDP" => Self::OverNightDeposit,
"MGLD" => Self::MarginalLending,
"NREX" => Self::NonResidentExternal,
"MOMA" => Self::MoneyMarket,
"LOAN" => Self::Loan,
"SLRY" => Self::Salary,
"ODFT" => Self::Overdraft,
"LEND" => Self::Lending,
"COLL" => Self::Collateral,
"SETT" => Self::FinancialSettlement,
"MARR" => Self::MarginReturn,
"SEGT" => Self::Segregated,
tag => todo!("handle code {tag:?}"),
};
Ok(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Specifies the nature, or use, of the cash account."]
};
Ok(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Specifies the external account identification scheme name code in the format of character string with a maximum length of 4 characters.\r\nThe list of valid codes is an external code list published separately.\r\nExternal code sets can be downloaded from www.iso20022.org.\n*`AIIN`-Issuer Identification Number (IIN) - identifies a card issuing institution in an international interchange environment. Issued by ABA (American Bankers Association).\n*`BBAN`-Basic Bank Account Number (BBAN) - identifier used nationally by financial institutions, ie, in individual countries, generally as part of a National Account Numbering Scheme(s), to uniquely identify the account of a customer.\n*`CUID`-(United States) Clearing House Interbank Payments System (CHIPS) Universal Identification (UID) - identifies entities that own accounts at CHIPS participating financial institutions, through which CHIPS payments are effected. The CHIPS UID is assigned by the New York Clearing House.\n*`UPIC`-Universal Payment Identification Code (UPIC) - identifier used by the New York Clearing House to mask confidential data, such as bank accounts and bank routing numbers. UPIC numbers remain with business customers, regardless of banking relationship changes."]
pub enum ExternalAccountIdentification1Code {
Aiin,
Bban,
Cuid,
Upic,
}
impl<'a> ExternalAccountIdentification1Code {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"AIIN" => Self::Aiin,
"BBAN" => Self::Bban,
"CUID" => Self::Cuid,
"UPIC" => Self::Upic,
tag => todo!("handle code {tag:?}"),
};
Ok(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Specifies the external account identification scheme name code in the format of character string with a maximum length of 4 characters.\r\nThe list of valid codes is an external code list published separately.\r\nExternal code sets can be downloaded from www.iso20022.org."]
pub enum ExternalAccountIdentificationCode {
#[doc = "Issuer Identification Number (IIN) - identifies a card issuing institution in an international interchange environment. Issued by ABA (American Bankers Association)."]
IssuerIdentificationNumber,
#[doc = "Basic Bank Account Number (BBAN) - identifier used nationally by financial institutions, ie, in individual countries, generally as part of a National Account Numbering Scheme(s), to uniquely identify the account of a customer."]
BbanIdentifier,
#[doc = "(United States) Clearing House Interbank Payments System (CHIPS) Universal Identification (UID) - identifies entities that own accounts at CHIPS participating financial institutions, through which CHIPS payments are effected. The CHIPS UID is assigned by the New York Clearing House."]
ChipsUniversalIdentifier,
#[doc = "Universal Payment Identification Code (UPIC) - identifier used by the New York Clearing House to mask confidential data, such as bank accounts and bank routing numbers. UPIC numbers remain with business customers, regardless of banking relationship changes."]
UpicIdentifier,
}
impl<'a> ExternalAccountIdentificationCode {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"AIIN" => Self::IssuerIdentificationNumber,
"BBAN" => Self::BbanIdentifier,
"CUID" => Self::ChipsUniversalIdentifier,
"UPIC" => Self::UpicIdentifier,
tag => todo!("handle code {tag:?}"),
};
Ok(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Specifies the reporting source, as published in an external reporting source code list.\r\nExternal code sets can be downloaded from www.iso20022.org.\n*`ACCT`-Statement or Report is based on accounting data.\n*`ARPF`-An account reconciliation system that provides full reconciliation that usually addresses checks\n*`ARPP`-An account reconciliation system that provides partial reconciliation that usually addresses checks\n*`CTDB`-A sub-application that reports presentment totals\n*`CUST`-Statement or Report is based on custody data.\n*`DEPT`-Cash or deposit accounting system\n*`DPCS`-Deposit system that reports what has been collected from various financial institutions\n*`LKBX`-Processing system that captures and reports check data in a lockbox environment.\n*`RCPT`-A system that reports consolidated remittance information obtained from various , i.e., ACH, wires, lockbox, etc.\n*`MIBO`-Transaction submitted directly from PMI (Payment Market Infrastructure back-office system.\n*`PFRE`-Transactions submitted directly from participant / PSO (Payment System Operator) applications."]
pub enum ExternalReportingSource1Code {
Acct,
Arpf,
Arpp,
Ctdb,
Cust,
Dept,
Dpcs,
Lkbx,
Rcpt,
Mibo,
Pfre,
}
impl<'a> ExternalReportingSource1Code {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"ACCT" => Self::Acct,
"ARPF" => Self::Arpf,
"ARPP" => Self::Arpp,
"CTDB" => Self::Ctdb,
"CUST" => Self::Cust,
"DEPT" => Self::Dept,
"DPCS" => Self::Dpcs,
"LKBX" => Self::Lkbx,
"RCPT" => Self::Rcpt,
"MIBO" => Self::Mibo,
"PFRE" => Self::Pfre,
tag => todo!("handle code {tag:?}"),
#[doc = "Specifies the reporting source, as published in an external reporting source code list.\r\nExternal code sets can be downloaded from www.iso20022.org."]
pub enum ExternalReportingSourceCode {
#[doc = "Statement or Report is based on accounting data."]
Accounting,
#[doc = "An account reconciliation system that provides full reconciliation that usually addresses checks"]
AccountReconciliationSystemFull,
#[doc = "An account reconciliation system that provides partial reconciliation that usually addresses checks"]
AccountReconciliationSystemPartial,
#[doc = "A sub-application that reports presentment totals"]
ControlledDisbursementSystem,
#[doc = "Statement or Report is based on custody data."]
Custody,
#[doc = "Cash or deposit accounting system"]
DepositSystem,
#[doc = "Deposit system that reports what has been collected from various financial institutions"]
DepositConcentrationSystem,
#[doc = "Processing system that captures and reports check data in a lockbox environment."]
Lockbox,
#[doc = "A system that reports consolidated remittance information obtained from various , i.e., ACH, wires, lockbox, etc."]
Receipts,
#[doc = "Transactions submitted directly from participant / PSO (Payment System Operator) applications."]
ParticipantFrontEnd,
#[doc = "Transaction submitted directly from PMI (Payment Market Infrastructure back-office system."]
MiBackOffice,
}
impl<'a> ExternalReportingSourceCode {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"ACCT" => Self::Accounting,
"ARPF" => Self::AccountReconciliationSystemFull,
"ARPP" => Self::AccountReconciliationSystemPartial,
"CTDB" => Self::ControlledDisbursementSystem,
"CUST" => Self::Custody,
"DEPT" => Self::DepositSystem,
"DPCS" => Self::DepositConcentrationSystem,
"LKBX" => Self::Lockbox,
"RCPT" => Self::Receipts,
"PFRE" => Self::ParticipantFrontEnd,
"MIBO" => Self::MiBackOffice,
tag => todo!("handle code {tag:?}"),
};
Ok(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Specifies if this document is a copy, a duplicate, or a duplicate of a copy."]
pub enum CopyDuplicate1Code {
#[doc = "Message is being sent as a copy to a party other than the account owner, for information purposes and the message is a duplicate of a message previously sent."]
CopyDuplicate,
#[doc = "Message is being sent as a copy to a party other than the account owner, for information purposes."]
Copy,
#[doc = "Message is for information/confirmation purposes. It is a duplicate of a message previously sent."]
Duplicate,
}
impl<'a> CopyDuplicate1Code {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"CODU" => Self::CopyDuplicate,
"COPY" => Self::Copy,
"DUPL" => Self::Duplicate,
tag => todo!("handle code {tag:?}"),
};
Ok(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Specifies the terms used to formally address a person."]
pub enum NamePrefix1Code {
#[doc = "Title of the person is Doctor or Dr."]
Doctor,
#[doc = "Title of the person is Mister or Mr."]
Mister,
#[doc = "Title of the person is Miss."]
Miss,
#[doc = "Title of the person is Madam."]
Madam,
#[doc = "Title of the person is gender neutral (Mx)."]
GenderNeutral,
}
impl<'a> NamePrefix1Code {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"DOCT" => Self::Doctor,
"MIST" => Self::Mister,
"MISS" => Self::Miss,
"MADM" => Self::Madam,
"MIKS" => Self::GenderNeutral,
tag => todo!("handle code {tag:?}"),
};
Ok(value)
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Specifies the external person identification scheme name code in the format of character string with a maximum length of 4 characters.\r\nThe list of valid codes is an external code list published separately.\r\nExternal code sets can be downloaded from www.iso20022.org.\n*`ARNU`-Number assigned by a social security agency to identify a non-resident person.\n*`CCPT`-Number assigned by an authority to identify the passport number of a person.\n*`CUST`-Number assigned by an issuer to identify a customer.\n*`DRLC`-Number assigned by an authority to identify a driver's license.\n*`EMPL`-Number assigned by a registration authority to an employee.\n*`NIDN`-Number assigned by an authority to identify the national identity number of a person.\n*`SOSE`-Number assigned by an authority to identify the social security number of a person.\n*`TELE`-Number assigned by a telephone or mobile phone operator to identify a person. A person may have multiple phone numbers.\n*`TXID`-Number assigned by a tax authority to identify a person.\n*`POID`-Commercial identification of the person."]
pub enum ExternalPersonIdentification1Code {
Arnu,
Ccpt,
Cust,
Drlc,
Empl,
Nidn,
Sose,
Tele,
Txid,
Poid,
}
impl<'a> ExternalPersonIdentification1Code {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"ARNU" => Self::Arnu,
"CCPT" => Self::Ccpt,
"CUST" => Self::Cust,
"DRLC" => Self::Drlc,
"EMPL" => Self::Empl,
"NIDN" => Self::Nidn,
"SOSE" => Self::Sose,
"TELE" => Self::Tele,
"TXID" => Self::Txid,
"POID" => Self::Poid,
tag => todo!("handle code {tag:?}"),
};
Ok(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Specifies the external person identification scheme name code in the format of character string with a maximum length of 4 characters.\r\nThe list of valid codes is an external code list published separately.\r\nExternal code sets can be downloaded from www.iso20022.org."]
pub enum ExternalPersonIdentificationCode {
#[doc = "Number assigned by a social security agency to identify a non-resident person."]
AlienRegistrationNumber,
#[doc = "Number assigned by an authority to identify the passport number of a person."]
PassportNumber,
#[doc = "Number assigned by an issuer to identify a customer."]
CustomerIdentificationNumber,
#[doc = "Number assigned by an authority to identify a driver's license."]
DriversLicenseNumber,
#[doc = "Number assigned by a registration authority to an employee."]
EmployeeIdentificationNumber,
#[doc = "Number assigned by an authority to identify the national identity number of a person."]
NationalIdentityNumber,
#[doc = "Number assigned by an authority to identify the social security number of a person."]
SocialSecurityNumber,
#[doc = "Number assigned by a telephone or mobile phone operator to identify a person. A person may have multiple phone numbers."]
TelephoneNumber,
#[doc = "Number assigned by a tax authority to identify a person."]
TaxIdentificationNumber,
#[doc = "Commercial identification of the person."]
PersonCommercialIdentification,
}
impl<'a> ExternalPersonIdentificationCode {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"ARNU" => Self::AlienRegistrationNumber,
"CCPT" => Self::PassportNumber,
"CUST" => Self::CustomerIdentificationNumber,
"DRLC" => Self::DriversLicenseNumber,
"EMPL" => Self::EmployeeIdentificationNumber,
"NIDN" => Self::NationalIdentityNumber,
"SOSE" => Self::SocialSecurityNumber,
"TELE" => Self::TelephoneNumber,
"TXID" => Self::TaxIdentificationNumber,
"POID" => Self::PersonCommercialIdentification,
tag => todo!("handle code {tag:?}"),
};
Ok(value)
}
}
pub use self::external_code_sets::ExternalPersonIdentification1Code;
};
Ok(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Specifies the external organisation identification scheme name code in the format of character string with a maximum length of 4 characters.\r\nThe list of valid codes is an external code list published separately.\r\nExternal code sets can be downloaded from www.iso20022.org.\n*`BANK`-Unique and unambiguous assignment made by a specific bank or similar financial institution to identify a relationship as defined between the bank and its client. \n*`CBID`-A unique identification number assigned by a central bank to identify an organisation.\n*`CHID`-A unique identification number assigned by a clearing house to identify an organisation\n*`CINC`-A unique identification number assigned by a designated authority to a certificate of incorporation and used to identify an organisation.\n*`COID`-Country authority given organisation identification (e.g., corporate registration number)\n*`CUST`-Number assigned by an issuer to identify a customer.\nNumber assigned by a party to identify a creditor or debtor relationship.\n*`DUNS`-A unique identification number provided by Dun & Bradstreet to identify an organisation.\n*`EMPL`-Number assigned by a registration authority to an employer.\n*`GS1G`-Global Location Number. A non-significant reference number used to identify legal entities, functional entities, or physical entities according to GS1 numbering scheme rules.The number is used to retrieve detailed information that is linked to it.\n*`SREN`-The SIREN number is a 9 digit code assigned by INSEE, the French National Institute for Statistics and Economic Studies, to identify an organisation in France.\n*`SRET`-The SIRET number is a 14 digit code assigned by INSEE, the French National Institute for Statistics and Economic Studies, to identify an organisation unit in France. It consists of the SIREN number, followed by a five digit classification number, to identify the local geographical unit of that entity\n*`TXID`-Number assigned by a tax authority to identify an organisation.\n*`BDID`-Identifier of the business domain in which the organisation is active.\n*`BOID`-Other identification of the organisation."]
pub enum ExternalOrganisationIdentification1Code {
Bank,
Cbid,
Chid,
Cinc,
Coid,
Cust,
Duns,
Empl,
Gs1g,
Sren,
Sret,
Txid,
Bdid,
Boid,
}
impl<'a> ExternalOrganisationIdentification1Code {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"BANK" => Self::Bank,
"CBID" => Self::Cbid,
"CHID" => Self::Chid,
"CINC" => Self::Cinc,
"COID" => Self::Coid,
"CUST" => Self::Cust,
"DUNS" => Self::Duns,
"EMPL" => Self::Empl,
"GS1G" => Self::Gs1g,
"SREN" => Self::Sren,
"SRET" => Self::Sret,
"TXID" => Self::Txid,
"BDID" => Self::Bdid,
"BOID" => Self::Boid,
tag => todo!("handle code {tag:?}"),
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Specifies the external organisation identification scheme name code in the format of character string with a maximum length of 4 characters.\r\nThe list of valid codes is an external code list published separately.\r\nExternal code sets can be downloaded from www.iso20022.org."]
pub enum ExternalOrganisationIdentificationCode {
#[doc = "Unique and unambiguous assignment made by a specific bank or similar financial institution to identify a relationship as defined between the bank and its client. "]
BankPartyIdentification,
#[doc = "A unique identification number assigned by a central bank to identify an organisation."]
CentralBankIdentificationNumber,
#[doc = "A unique identification number assigned by a clearing house to identify an organisation"]
ClearingIdentificationNumber,
#[doc = "A unique identification number assigned by a designated authority to a certificate of incorporation and used to identify an organisation."]
CertificateOfIncorporationNumber,
#[doc = "Country authority given organisation identification (e.g., corporate registration number)"]
CountryIdentificationCode,
#[doc = "Number assigned by an issuer to identify a customer.\nNumber assigned by a party to identify a creditor or debtor relationship."]
CustomerNumber,
#[doc = "A unique identification number provided by Dun & Bradstreet to identify an organisation."]
DataUniversalNumberingSystem,
#[doc = "Number assigned by a registration authority to an employer."]
EmployerIdentificationNumber,
#[doc = "Global Location Number. A non-significant reference number used to identify legal entities, functional entities, or physical entities according to GS1 numbering scheme rules.The number is used to retrieve detailed information that is linked to it."]
Gs1glnIdentifier,
#[doc = "The SIREN number is a 9 digit code assigned by INSEE, the French National Institute for Statistics and Economic Studies, to identify an organisation in France."]
Siren,
#[doc = "The SIRET number is a 14 digit code assigned by INSEE, the French National Institute for Statistics and Economic Studies, to identify an organisation unit in France. It consists of the SIREN number, followed by a five digit classification number, to identify the local geographical unit of that entity"]
Siret,
#[doc = "Number assigned by a tax authority to identify an organisation."]
TaxIdentificationNumber,
#[doc = "Identifier of the business domain in which the organisation is active."]
BusinessDomainIdentifier,
#[doc = "Other identification of the organisation."]
BusinessOtherIdentification,
}
impl<'a> ExternalOrganisationIdentificationCode {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"BANK" => Self::BankPartyIdentification,
"CBID" => Self::CentralBankIdentificationNumber,
"CHID" => Self::ClearingIdentificationNumber,
"CINC" => Self::CertificateOfIncorporationNumber,
"COID" => Self::CountryIdentificationCode,
"CUST" => Self::CustomerNumber,
"DUNS" => Self::DataUniversalNumberingSystem,
"EMPL" => Self::EmployerIdentificationNumber,
"GS1G" => Self::Gs1glnIdentifier,
"SREN" => Self::Siren,
"SRET" => Self::Siret,
"TXID" => Self::TaxIdentificationNumber,
"BDID" => Self::BusinessDomainIdentifier,
"BOID" => Self::BusinessOtherIdentification,
tag => todo!("handle code {tag:?}"),
};
Ok(value)
}
}
pub use self::external_code_sets::ExternalOrganisationIdentification1Code;
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Specifies the type of address."]
pub enum AddressType2Code {
#[doc = "Address is the home address."]
Residential,
#[doc = "Address is the business address."]
Business,
#[doc = "Address is the complete postal address."]
Postal,
#[doc = "Address is a postal office (PO) box."]
PoBox,
#[doc = "Address is the address to which mail is sent."]
MailTo,
#[doc = "Address is the address to which delivery is to take place."]
DeliveryTo,
}
impl<'a> AddressType2Code {
fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
"HOME" => Self::Residential,
"BIZZ" => Self::Business,
"ADDR" => Self::Postal,
"PBOX" => Self::PoBox,
"MLTO" => Self::MailTo,
"DLVY" => Self::DeliveryTo,
tag => todo!("handle code {tag:?}"),
};
Ok(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub struct ExternalCardTransactionCategory1Code(ArrayString<4>);
impl ExternalCardTransactionCategory1Code {
pub(crate) fn parse(reader: &mut XmlReader<'_>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let code = reader.expect_text()?;
let code = ArrayString::try_from(&*code).unwrap();
Ok(Self(code))
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub struct ExternalCreditLineType1Code(ArrayString<4>);
impl ExternalCreditLineType1Code {
pub(crate) fn parse(reader: &mut XmlReader<'_>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let code = reader.expect_text()?;
let code = ArrayString::try_from(&*code).unwrap();
Ok(Self(code))
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub struct ExternalFinancialInstitutionIdentification1Code(ArrayString<4>);
impl ExternalFinancialInstitutionIdentification1Code {
pub(crate) fn parse(reader: &mut XmlReader<'_>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let code = reader.expect_text()?;
let code = ArrayString::try_from(&*code).unwrap();
Ok(Self(code))
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Specifies the bank transaction code sub-family, as published in an external bank transaction code sub-family code list.\r\nExternal code sets can be downloaded from www.iso20022.org."]
pub enum ExternalBankTransactionSubFamily1Code {
Any,
#[derive(Clone, Debug, Eq, Hash, PartialEq)]
#[doc = "Specifies the bank transaction code domain, as published in an external bank transaction code domain code list.\r\nExternal code sets can be downloaded from www.iso20022.org."]
pub enum ExternalBankTransactionDomain1Code {
AccountManagement,
CashManagement,
Commodities,
Derivatives,
ExtendedDomain,
ForeignExchange,
LoansDepositsSyndications,
Payments,
PreciousMetal,
Securities,
TradeServices,
_ => {}
"ACMT" => Self::AccountManagement,
"CAMT" => Self::CashManagement,
"CMDT" => Self::Commodities,
"DERV" => Self::Derivatives,
"XTND" => Self::ExtendedDomain,
"FORX" => Self::ForeignExchange,
"LDAS" => Self::LoansDepositsSyndications,
"PMNT" => Self::Payments,
"PMET" => Self::PreciousMetal,
"SECU" => Self::Securities,
"TRAD" => Self::TradeServices,
tag => todo!("handle tag {tag:?}"),
Any,
// Cash Management
AccountBalancing,
CashPooling,
// Derivatives
ListedDerivativesFutures,
ListedDerivativesOptions,
OtcDerivativesBonds,
OtcDerivativesCreditDerivatives,
OtcDerivativesEquity,
OtcDerivativesInterestRates,
OtcDerivativesStructuredExoticDerivatives,
OtcDerivativesSwaps,
// Foreign Exchange
Forwards,
Futures,
NonDeliverable,
Spots,
Swaps,
// Generic
MiscellaneousCreditOperations,
MiscellaneousDebitOperations,
NotAvailable,
Other,
// Loans, Deposits & Syndication
ConsumerLoans,
FixedTermDeposits,
FixedTermLoans,
MortgageLoans,
NoticeDeposits,
NoticeLoans,
Syndications,
// Payments
CounterTransactions,
CustomerCardTransactions,
Drafts,
IssuedCashConcentrationTransactions,
IssuedCheques,
IssuedCreditTransfers,
IssuedDirectDebits,
IssuedRealTimeCreditTransfers,
LockboxTransactions,
MerchantCardTransactions,
ReceivedCashConcentrationTransactions,
ReceivedCheques,
ReceivedCreditTransfers,
ReceivedDirectDebits,
ReceivedRealTimeCreditTransfers,
// Precious Metal
Options,
Delivery,
tag => Self::Any,
"ACCB" => Self::AccountBalancing,
"CAPL" => Self::CashPooling,
"LFUT" => Self::ListedDerivativesFutures,
"LOPT" => Self::ListedDerivativesOptions,
"OBND" => Self::OtcDerivativesBonds,
"OCRD" => Self::OtcDerivativesCreditDerivatives,
"OEQT" => Self::OtcDerivativesEquity,
"OIRT" => Self::OtcDerivativesInterestRates,
"OSED" => Self::OtcDerivativesStructuredExoticDerivatives,
"OSWP" => Self::OtcDerivativesSwaps,
"FWRD" => Self::Forwards,
"FTUR" => Self::Futures,
"NDFX" => Self::NonDeliverable,
"SPOT" => Self::Spots,
"SWAP" => Self::Swaps,
"MCOP" => Self::MiscellaneousCreditOperations,
"MDOP" => Self::MiscellaneousDebitOperations,
"NTAV" => Self::NotAvailable,
"OTHR" => Self::Other,
"CSLN" => Self::ConsumerLoans,
"FTDP" => Self::FixedTermDeposits,
"FTLN" => Self::FixedTermLoans,
"MGLN" => Self::MortgageLoans,
"NTDP" => Self::NoticeDeposits,
"NTLN" => Self::NoticeLoans,
"SYDN" => Self::Syndications,
"CNTR" => Self::CounterTransactions,
"CCRD" => Self::CustomerCardTransactions,
"DRFT" => Self::Drafts,
"ICCN" => Self::IssuedCashConcentrationTransactions,
"ICHQ" => Self::IssuedCheques,
"ICDT" => Self::IssuedCreditTransfers,
"IDDT" => Self::IssuedDirectDebits,
"IRCT" => Self::IssuedRealTimeCreditTransfers,
"LBOX" => Self::LockboxTransactions,
"MCRD" => Self::MerchantCardTransactions,
"RCCN" => Self::ReceivedCashConcentrationTransactions,
"RCHQ" => Self::ReceivedCheques,
"RCDT" => Self::ReceivedCreditTransfers,
"RDDT" => Self::ReceivedDirectDebits,
"RRCT" => Self::ReceivedRealTimeCreditTransfers,
code => panic!("unhandled code: {code:?}"),
#[derive(Clone, Debug, Eq, Hash, PartialEq)]
#[doc = "Specifies the bank transaction code domain, as published in an external bank transaction code domain code list.\r\nExternal code sets can be downloaded from www.iso20022.org."]
pub enum ExternalBankTransactionDomain1Code {
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = "Specifies the bank transaction code sub-family, as published in an external bank transaction code sub-family code list.\r\nExternal code sets can be downloaded from www.iso20022.org."]
pub enum ExternalBankTransactionSubFamily1Code {
fn generate_code_set(
definitions: &HashSet<Definition>,
external_code_sets: &HashMap<&str, ExternalCodeSet>,
code_set: &CodeSet,
types: &HashMap<&str, Type>,
) -> TokenStream {
fn generate_code_set(code_set: &CodeSet, types: &HashMap<&str, Type>) -> TokenStream {
let (doc, codes, parsers) = if let Some(external_code_set) =
external_code_sets.get(&*code_set.name)
{
(
&external_code_set.description,
Either::Left(external_code_set.values.iter().map(|code| {
let code = generate_variant_name(code);
quote!(#code,)
})),
Either::Left(
external_code_set
.values
.iter()
.map(|code| (code, generate_variant_name(code))),
),
)
} else {
let code_set = code_set.trace.as_deref().map_or(
code_set,
|trace|
{
let Definition::CodeSet(code_set) = definitions.get(trace).unwrap() else { unreachable!() };
code_set
});
if code_set.is_external {
return if code_set.derivation.is_some() {
TokenStream::new()
} else {
quote! {
pub use self::external_code_sets::#ty;
}
};
}
if let Some(trace_id) = &code_set.trace {
let trace_ty = types[&**trace_id];
return quote! {
pub type #ty = #trace_ty;
};
}
if code_set.codes.is_empty() {
tracing::warn!(%code_set.name, "skipping codegen for empty code set");
return TokenStream::new();
}
let doc = &*code_set.definition;
let codes = code_set.codes.iter().map(|code| {
let doc = &code.definition;
let name = generate_variant_name(&code.name);
(
&code_set.definition,
Either::Right(code_set.codes.iter().map(|code| {
let doc = &code.definition;
let name = generate_variant_name(&code.name);
let parsers = code_set
.codes
.iter()
.map(|code| (&code.code, generate_variant_name(&code.name)));
}
}
}
}
fn generate_external_code_set(name: &str, code_set: &ExternalCodeSet) -> TokenStream {
if code_set.values.is_empty() {
tracing::warn!(name, "skipping codegen for empty external code set");
return TokenStream::new();
}
let doc = &code_set.description;
let ty = generate_ident(name);
let codes = code_set.values.iter().map(|code| {
let code = generate_variant_name(code);
quote!(#code,)
});
let parsers = code_set
.values
.iter()
.map(|code| (code, generate_variant_name(code)));
let parsers = parsers.map(|(tag, name)| quote!(#tag => Self::#name,));
quote! {
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
#[doc = #doc]
pub enum #ty {
#(#codes)*
}
impl<'a> #ty {
pub(crate) fn parse(reader: &mut XmlReader<'a>, _start: &BytesStart<'_>) -> XmlResult<Self> {
let value = match &*reader.expect_text()? {
#(#parsers)*
tag => todo!("handle code {tag:?}"),
};
Ok(value)
fn generate_erepository(sources: &mut Item, package_directory: &Utf8Path) -> Result<()> {
let sources = &mut sources["erepository"];
let input_path = package_directory.join(sources["path"].as_str().unwrap());
let current_checksum = compute_checksum_for_files(&[&input_path])?;
let old_checksum = &mut sources["checksum"];
if let Some(old_checksum) = old_checksum.as_str() {
if old_checksum == current_checksum {
return Ok(());
}
}
Ok(())
}
let code = generate_module(repository_path, codeset_path, roots, type_overrides)?;
// TODO save code to output path
let output_path = {
let mut path = package_directory.join("src");
path.push("types.rs");
let source_directory = package_directory.join("src");
generate_external_code_sets(&codeset_path, {
let mut path = source_directory.join("types");
path.push("external_code_sets.rs");
fn generate_module(
repository_path: impl AsRef<Path>,
codeset_path: impl AsRef<Path>,
fn generate_external_code_sets(
codeset_path: impl AsRef<Utf8Path>,
output_path: impl AsRef<Utf8Path>,
) -> Result<()> {
let external_code_sets = fs::read_to_string(codeset_path.as_ref()).into_diagnostic()?;
let external_code_sets: ExternalCodeSets =
serde_json::de::from_str(&external_code_sets).into_diagnostic()?;
let code = codegen::generate_external_code_sets(&external_code_sets.definitions);
fs::write(output_path.as_ref(), code.to_string()).into_diagnostic()?;
Ok(())
}
fn generate_erepository(
repository_path: impl AsRef<Utf8Path>,