#![cfg_attr(rustfmt, rustfmt::skip)]
#![allow(clippy::module_inception)]
use refix_message::{Date, Decimal, Dialect, GroupTable, Instances, InvalidValue, KnownTags, MonthYear, MultipleValues, RawMessage, Tag, Time, UtcTimestamp};
pub const DIALECT: Dialect<'static> = Dialect::new().with_extra_length_tags(&[
Tag(90), Tag(93), Tag(95), Tag(212), Tag(348), Tag(350), Tag(352), Tag(354), Tag(356), Tag(358),
Tag(360), Tag(362), Tag(364), Tag(445),
]);
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum AdvSide<'a> {
Buy,
Sell,
Trade,
Cross,
Unrecognized(&'a str),
}
impl<'a> AdvSide<'a> {
pub fn from_value(value: &'a str) -> Self {
match value {
"B" => Self::Buy,
"S" => Self::Sell,
"T" => Self::Trade,
"X" => Self::Cross,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> &'a str {
match self {
Self::Buy => "B",
Self::Sell => "S",
Self::Trade => "T",
Self::Cross => "X",
Self::Unrecognized(value) => value,
}
}
}
impl<'a> From<&'a str> for AdvSide<'a> {
fn from(value: &'a str) -> Self {
Self::from_value(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum AdvTransType<'a> {
Cancel,
New,
Replace,
Unrecognized(&'a str),
}
impl<'a> AdvTransType<'a> {
pub fn from_value(value: &'a str) -> Self {
match value {
"C" => Self::Cancel,
"N" => Self::New,
"R" => Self::Replace,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> &'a str {
match self {
Self::Cancel => "C",
Self::New => "N",
Self::Replace => "R",
Self::Unrecognized(value) => value,
}
}
}
impl<'a> From<&'a str> for AdvTransType<'a> {
fn from(value: &'a str) -> Self {
Self::from_value(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum CommType<'a> {
PerUnit,
Percent,
Absolute,
Unrecognized(&'a str),
}
impl<'a> CommType<'a> {
pub fn from_value(value: &'a str) -> Self {
match value {
"1" => Self::PerUnit,
"2" => Self::Percent,
"3" => Self::Absolute,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> &'a str {
match self {
Self::PerUnit => "1",
Self::Percent => "2",
Self::Absolute => "3",
Self::Unrecognized(value) => value,
}
}
}
impl<'a> From<&'a str> for CommType<'a> {
fn from(value: &'a str) -> Self {
Self::from_value(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum ExecInst<'a> {
StayOnOfferSide,
NotHeld,
Work,
GoAlong,
OverTheDay,
Held,
ParticipateDoNotInitiate,
StrictScale,
TryToScale,
StayOnBidSide,
NoCross,
OkToCross,
CallFirst,
PercentOfVolume,
DoNotIncrease,
DoNotReduce,
AllOrNone,
InstitutionsOnly,
LastPeg,
MidPricePeg,
NonNegotiable,
OpeningPeg,
MarketPeg,
PrimaryPeg,
Suspend,
FixedPegToLocalBestBidOrOfferAtTimeOfOrder,
CustomerDisplayInstruction,
Netting,
PegToVwap,
Unrecognized(&'a str),
}
impl<'a> ExecInst<'a> {
pub fn from_value(value: &'a str) -> Self {
match value {
"0" => Self::StayOnOfferSide,
"1" => Self::NotHeld,
"2" => Self::Work,
"3" => Self::GoAlong,
"4" => Self::OverTheDay,
"5" => Self::Held,
"6" => Self::ParticipateDoNotInitiate,
"7" => Self::StrictScale,
"8" => Self::TryToScale,
"9" => Self::StayOnBidSide,
"A" => Self::NoCross,
"B" => Self::OkToCross,
"C" => Self::CallFirst,
"D" => Self::PercentOfVolume,
"E" => Self::DoNotIncrease,
"F" => Self::DoNotReduce,
"G" => Self::AllOrNone,
"I" => Self::InstitutionsOnly,
"L" => Self::LastPeg,
"M" => Self::MidPricePeg,
"N" => Self::NonNegotiable,
"O" => Self::OpeningPeg,
"P" => Self::MarketPeg,
"R" => Self::PrimaryPeg,
"S" => Self::Suspend,
"T" => Self::FixedPegToLocalBestBidOrOfferAtTimeOfOrder,
"U" => Self::CustomerDisplayInstruction,
"V" => Self::Netting,
"W" => Self::PegToVwap,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> &'a str {
match self {
Self::StayOnOfferSide => "0",
Self::NotHeld => "1",
Self::Work => "2",
Self::GoAlong => "3",
Self::OverTheDay => "4",
Self::Held => "5",
Self::ParticipateDoNotInitiate => "6",
Self::StrictScale => "7",
Self::TryToScale => "8",
Self::StayOnBidSide => "9",
Self::NoCross => "A",
Self::OkToCross => "B",
Self::CallFirst => "C",
Self::PercentOfVolume => "D",
Self::DoNotIncrease => "E",
Self::DoNotReduce => "F",
Self::AllOrNone => "G",
Self::InstitutionsOnly => "I",
Self::LastPeg => "L",
Self::MidPricePeg => "M",
Self::NonNegotiable => "N",
Self::OpeningPeg => "O",
Self::MarketPeg => "P",
Self::PrimaryPeg => "R",
Self::Suspend => "S",
Self::FixedPegToLocalBestBidOrOfferAtTimeOfOrder => "T",
Self::CustomerDisplayInstruction => "U",
Self::Netting => "V",
Self::PegToVwap => "W",
Self::Unrecognized(value) => value,
}
}
}
impl<'a> From<&'a str> for ExecInst<'a> {
fn from(value: &'a str) -> Self {
Self::from_value(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum ExecTransType<'a> {
New,
Cancel,
Correct,
Status,
Unrecognized(&'a str),
}
impl<'a> ExecTransType<'a> {
pub fn from_value(value: &'a str) -> Self {
match value {
"0" => Self::New,
"1" => Self::Cancel,
"2" => Self::Correct,
"3" => Self::Status,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> &'a str {
match self {
Self::New => "0",
Self::Cancel => "1",
Self::Correct => "2",
Self::Status => "3",
Self::Unrecognized(value) => value,
}
}
}
impl<'a> From<&'a str> for ExecTransType<'a> {
fn from(value: &'a str) -> Self {
Self::from_value(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum HandlInst<'a> {
AutomatedExecutionNoIntervention,
AutomatedExecutionInterventionOk,
ManualOrder,
Unrecognized(&'a str),
}
impl<'a> HandlInst<'a> {
pub fn from_value(value: &'a str) -> Self {
match value {
"1" => Self::AutomatedExecutionNoIntervention,
"2" => Self::AutomatedExecutionInterventionOk,
"3" => Self::ManualOrder,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> &'a str {
match self {
Self::AutomatedExecutionNoIntervention => "1",
Self::AutomatedExecutionInterventionOk => "2",
Self::ManualOrder => "3",
Self::Unrecognized(value) => value,
}
}
}
impl<'a> From<&'a str> for HandlInst<'a> {
fn from(value: &'a str) -> Self {
Self::from_value(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum IDSource<'a> {
Cusip,
Sedol,
Quik,
IsinNumber,
RicCode,
IsoCurrencyCode,
IsoCountryCode,
ExchangeSymbol,
ConsolidatedTapeAssociation,
Unrecognized(&'a str),
}
impl<'a> IDSource<'a> {
pub fn from_value(value: &'a str) -> Self {
match value {
"1" => Self::Cusip,
"2" => Self::Sedol,
"3" => Self::Quik,
"4" => Self::IsinNumber,
"5" => Self::RicCode,
"6" => Self::IsoCurrencyCode,
"7" => Self::IsoCountryCode,
"8" => Self::ExchangeSymbol,
"9" => Self::ConsolidatedTapeAssociation,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> &'a str {
match self {
Self::Cusip => "1",
Self::Sedol => "2",
Self::Quik => "3",
Self::IsinNumber => "4",
Self::RicCode => "5",
Self::IsoCurrencyCode => "6",
Self::IsoCountryCode => "7",
Self::ExchangeSymbol => "8",
Self::ConsolidatedTapeAssociation => "9",
Self::Unrecognized(value) => value,
}
}
}
impl<'a> From<&'a str> for IDSource<'a> {
fn from(value: &'a str) -> Self {
Self::from_value(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum IOIQltyInd<'a> {
High,
Low,
Medium,
Unrecognized(&'a str),
}
impl<'a> IOIQltyInd<'a> {
pub fn from_value(value: &'a str) -> Self {
match value {
"H" => Self::High,
"L" => Self::Low,
"M" => Self::Medium,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> &'a str {
match self {
Self::High => "H",
Self::Low => "L",
Self::Medium => "M",
Self::Unrecognized(value) => value,
}
}
}
impl<'a> From<&'a str> for IOIQltyInd<'a> {
fn from(value: &'a str) -> Self {
Self::from_value(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum IOIShares<'a> {
Large,
Medium,
Small,
Unrecognized(&'a str),
}
impl<'a> IOIShares<'a> {
pub fn from_value(value: &'a str) -> Self {
match value {
"L" => Self::Large,
"M" => Self::Medium,
"S" => Self::Small,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> &'a str {
match self {
Self::Large => "L",
Self::Medium => "M",
Self::Small => "S",
Self::Unrecognized(value) => value,
}
}
}
impl<'a> From<&'a str> for IOIShares<'a> {
fn from(value: &'a str) -> Self {
Self::from_value(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum IOITransType<'a> {
Cancel,
New,
Replace,
Unrecognized(&'a str),
}
impl<'a> IOITransType<'a> {
pub fn from_value(value: &'a str) -> Self {
match value {
"C" => Self::Cancel,
"N" => Self::New,
"R" => Self::Replace,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> &'a str {
match self {
Self::Cancel => "C",
Self::New => "N",
Self::Replace => "R",
Self::Unrecognized(value) => value,
}
}
}
impl<'a> From<&'a str> for IOITransType<'a> {
fn from(value: &'a str) -> Self {
Self::from_value(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum LastCapacity<'a> {
Agent,
CrossAsAgent,
CrossAsPrincipal,
Principal,
Unrecognized(&'a str),
}
impl<'a> LastCapacity<'a> {
pub fn from_value(value: &'a str) -> Self {
match value {
"1" => Self::Agent,
"2" => Self::CrossAsAgent,
"3" => Self::CrossAsPrincipal,
"4" => Self::Principal,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> &'a str {
match self {
Self::Agent => "1",
Self::CrossAsAgent => "2",
Self::CrossAsPrincipal => "3",
Self::Principal => "4",
Self::Unrecognized(value) => value,
}
}
}
impl<'a> From<&'a str> for LastCapacity<'a> {
fn from(value: &'a str) -> Self {
Self::from_value(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum MsgType<'a> {
Heartbeat,
TestRequest,
ResendRequest,
Reject,
SequenceReset,
Logout,
Ioi,
Advertisement,
ExecutionReport,
OrderCancelReject,
Logon,
News,
Email,
NewOrderSingle,
NewOrderList,
OrderCancelRequest,
OrderCancelReplaceRequest,
OrderStatusRequest,
AllocationInstruction,
ListCancelRequest,
ListExecute,
ListStatusRequest,
ListStatus,
AllocationInstructionAck,
DontKnowTrade,
QuoteRequest,
Quote,
SettlementInstructions,
MarketDataRequest,
MarketDataSnapshotFullRefresh,
MarketDataIncrementalRefresh,
MarketDataRequestReject,
QuoteCancel,
QuoteStatusRequest,
MassQuoteAcknowledgement,
SecurityDefinitionRequest,
SecurityDefinition,
SecurityStatusRequest,
SecurityStatus,
TradingSessionStatusRequest,
TradingSessionStatus,
MassQuote,
BusinessMessageReject,
BidRequest,
BidResponse,
ListStrikePrice,
Unrecognized(&'a str),
}
impl<'a> MsgType<'a> {
pub fn from_value(value: &'a str) -> Self {
match value {
"0" => Self::Heartbeat,
"1" => Self::TestRequest,
"2" => Self::ResendRequest,
"3" => Self::Reject,
"4" => Self::SequenceReset,
"5" => Self::Logout,
"6" => Self::Ioi,
"7" => Self::Advertisement,
"8" => Self::ExecutionReport,
"9" => Self::OrderCancelReject,
"A" => Self::Logon,
"B" => Self::News,
"C" => Self::Email,
"D" => Self::NewOrderSingle,
"E" => Self::NewOrderList,
"F" => Self::OrderCancelRequest,
"G" => Self::OrderCancelReplaceRequest,
"H" => Self::OrderStatusRequest,
"J" => Self::AllocationInstruction,
"K" => Self::ListCancelRequest,
"L" => Self::ListExecute,
"M" => Self::ListStatusRequest,
"N" => Self::ListStatus,
"P" => Self::AllocationInstructionAck,
"Q" => Self::DontKnowTrade,
"R" => Self::QuoteRequest,
"S" => Self::Quote,
"T" => Self::SettlementInstructions,
"V" => Self::MarketDataRequest,
"W" => Self::MarketDataSnapshotFullRefresh,
"X" => Self::MarketDataIncrementalRefresh,
"Y" => Self::MarketDataRequestReject,
"Z" => Self::QuoteCancel,
"a" => Self::QuoteStatusRequest,
"b" => Self::MassQuoteAcknowledgement,
"c" => Self::SecurityDefinitionRequest,
"d" => Self::SecurityDefinition,
"e" => Self::SecurityStatusRequest,
"f" => Self::SecurityStatus,
"g" => Self::TradingSessionStatusRequest,
"h" => Self::TradingSessionStatus,
"i" => Self::MassQuote,
"j" => Self::BusinessMessageReject,
"k" => Self::BidRequest,
"l" => Self::BidResponse,
"m" => Self::ListStrikePrice,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> &'a str {
match self {
Self::Heartbeat => "0",
Self::TestRequest => "1",
Self::ResendRequest => "2",
Self::Reject => "3",
Self::SequenceReset => "4",
Self::Logout => "5",
Self::Ioi => "6",
Self::Advertisement => "7",
Self::ExecutionReport => "8",
Self::OrderCancelReject => "9",
Self::Logon => "A",
Self::News => "B",
Self::Email => "C",
Self::NewOrderSingle => "D",
Self::NewOrderList => "E",
Self::OrderCancelRequest => "F",
Self::OrderCancelReplaceRequest => "G",
Self::OrderStatusRequest => "H",
Self::AllocationInstruction => "J",
Self::ListCancelRequest => "K",
Self::ListExecute => "L",
Self::ListStatusRequest => "M",
Self::ListStatus => "N",
Self::AllocationInstructionAck => "P",
Self::DontKnowTrade => "Q",
Self::QuoteRequest => "R",
Self::Quote => "S",
Self::SettlementInstructions => "T",
Self::MarketDataRequest => "V",
Self::MarketDataSnapshotFullRefresh => "W",
Self::MarketDataIncrementalRefresh => "X",
Self::MarketDataRequestReject => "Y",
Self::QuoteCancel => "Z",
Self::QuoteStatusRequest => "a",
Self::MassQuoteAcknowledgement => "b",
Self::SecurityDefinitionRequest => "c",
Self::SecurityDefinition => "d",
Self::SecurityStatusRequest => "e",
Self::SecurityStatus => "f",
Self::TradingSessionStatusRequest => "g",
Self::TradingSessionStatus => "h",
Self::MassQuote => "i",
Self::BusinessMessageReject => "j",
Self::BidRequest => "k",
Self::BidResponse => "l",
Self::ListStrikePrice => "m",
Self::Unrecognized(value) => value,
}
}
}
impl<'a> From<&'a str> for MsgType<'a> {
fn from(value: &'a str) -> Self {
Self::from_value(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum OrdStatus<'a> {
New,
PartiallyFilled,
Filled,
DoneForDay,
Canceled,
Replaced,
PendingCancel,
Stopped,
Rejected,
Suspended,
PendingNew,
Calculated,
Expired,
AcceptedForBidding,
PendingReplace,
Unrecognized(&'a str),
}
impl<'a> OrdStatus<'a> {
pub fn from_value(value: &'a str) -> Self {
match value {
"0" => Self::New,
"1" => Self::PartiallyFilled,
"2" => Self::Filled,
"3" => Self::DoneForDay,
"4" => Self::Canceled,
"5" => Self::Replaced,
"6" => Self::PendingCancel,
"7" => Self::Stopped,
"8" => Self::Rejected,
"9" => Self::Suspended,
"A" => Self::PendingNew,
"B" => Self::Calculated,
"C" => Self::Expired,
"D" => Self::AcceptedForBidding,
"E" => Self::PendingReplace,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> &'a str {
match self {
Self::New => "0",
Self::PartiallyFilled => "1",
Self::Filled => "2",
Self::DoneForDay => "3",
Self::Canceled => "4",
Self::Replaced => "5",
Self::PendingCancel => "6",
Self::Stopped => "7",
Self::Rejected => "8",
Self::Suspended => "9",
Self::PendingNew => "A",
Self::Calculated => "B",
Self::Expired => "C",
Self::AcceptedForBidding => "D",
Self::PendingReplace => "E",
Self::Unrecognized(value) => value,
}
}
}
impl<'a> From<&'a str> for OrdStatus<'a> {
fn from(value: &'a str) -> Self {
Self::from_value(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum OrdType<'a> {
Market,
Limit,
Stop,
StopLimit,
MarketOnClose,
WithOrWithout,
LimitOrBetter,
LimitWithOrWithout,
OnBasis,
OnClose,
LimitOnClose,
ForexMarket,
PreviouslyQuoted,
PreviouslyIndicated,
ForexLimit,
ForexSwap,
ForexPreviouslyQuoted,
Funari,
Pegged,
Unrecognized(&'a str),
}
impl<'a> OrdType<'a> {
pub fn from_value(value: &'a str) -> Self {
match value {
"1" => Self::Market,
"2" => Self::Limit,
"3" => Self::Stop,
"4" => Self::StopLimit,
"5" => Self::MarketOnClose,
"6" => Self::WithOrWithout,
"7" => Self::LimitOrBetter,
"8" => Self::LimitWithOrWithout,
"9" => Self::OnBasis,
"A" => Self::OnClose,
"B" => Self::LimitOnClose,
"C" => Self::ForexMarket,
"D" => Self::PreviouslyQuoted,
"E" => Self::PreviouslyIndicated,
"F" => Self::ForexLimit,
"G" => Self::ForexSwap,
"H" => Self::ForexPreviouslyQuoted,
"I" => Self::Funari,
"P" => Self::Pegged,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> &'a str {
match self {
Self::Market => "1",
Self::Limit => "2",
Self::Stop => "3",
Self::StopLimit => "4",
Self::MarketOnClose => "5",
Self::WithOrWithout => "6",
Self::LimitOrBetter => "7",
Self::LimitWithOrWithout => "8",
Self::OnBasis => "9",
Self::OnClose => "A",
Self::LimitOnClose => "B",
Self::ForexMarket => "C",
Self::PreviouslyQuoted => "D",
Self::PreviouslyIndicated => "E",
Self::ForexLimit => "F",
Self::ForexSwap => "G",
Self::ForexPreviouslyQuoted => "H",
Self::Funari => "I",
Self::Pegged => "P",
Self::Unrecognized(value) => value,
}
}
}
impl<'a> From<&'a str> for OrdType<'a> {
fn from(value: &'a str) -> Self {
Self::from_value(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum Rule80A<'a> {
AgencySingleOrder,
ShortExemptTransactionAType,
ProprietaryNonAlgo,
ProgramOrderMember,
ShortExemptTransactionForPrincipal,
ShortExemptTransactionWType,
ShortExemptTransactionIType,
IndividualInvestor,
ProprietaryAlgo,
AgencyAlgo,
ShortExemptTransactionMemberAffliated,
ProgramOrderOtherMember,
AgentForOtherMember,
ProprietaryTransactionAffiliated,
Principal,
TransactionNonMember,
SpecialistTrades,
TransactionUnaffiliatedMember,
AgencyIndexArb,
AllOtherOrdersAsAgentForOtherMember,
ShortExemptTransactionMemberNotAffliated,
AgencyNonAlgo,
ShortExemptTransactionNonMember,
Unrecognized(&'a str),
}
impl<'a> Rule80A<'a> {
pub fn from_value(value: &'a str) -> Self {
match value {
"A" => Self::AgencySingleOrder,
"B" => Self::ShortExemptTransactionAType,
"C" => Self::ProprietaryNonAlgo,
"D" => Self::ProgramOrderMember,
"E" => Self::ShortExemptTransactionForPrincipal,
"F" => Self::ShortExemptTransactionWType,
"H" => Self::ShortExemptTransactionIType,
"I" => Self::IndividualInvestor,
"J" => Self::ProprietaryAlgo,
"K" => Self::AgencyAlgo,
"L" => Self::ShortExemptTransactionMemberAffliated,
"M" => Self::ProgramOrderOtherMember,
"N" => Self::AgentForOtherMember,
"O" => Self::ProprietaryTransactionAffiliated,
"P" => Self::Principal,
"R" => Self::TransactionNonMember,
"S" => Self::SpecialistTrades,
"T" => Self::TransactionUnaffiliatedMember,
"U" => Self::AgencyIndexArb,
"W" => Self::AllOtherOrdersAsAgentForOtherMember,
"X" => Self::ShortExemptTransactionMemberNotAffliated,
"Y" => Self::AgencyNonAlgo,
"Z" => Self::ShortExemptTransactionNonMember,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> &'a str {
match self {
Self::AgencySingleOrder => "A",
Self::ShortExemptTransactionAType => "B",
Self::ProprietaryNonAlgo => "C",
Self::ProgramOrderMember => "D",
Self::ShortExemptTransactionForPrincipal => "E",
Self::ShortExemptTransactionWType => "F",
Self::ShortExemptTransactionIType => "H",
Self::IndividualInvestor => "I",
Self::ProprietaryAlgo => "J",
Self::AgencyAlgo => "K",
Self::ShortExemptTransactionMemberAffliated => "L",
Self::ProgramOrderOtherMember => "M",
Self::AgentForOtherMember => "N",
Self::ProprietaryTransactionAffiliated => "O",
Self::Principal => "P",
Self::TransactionNonMember => "R",
Self::SpecialistTrades => "S",
Self::TransactionUnaffiliatedMember => "T",
Self::AgencyIndexArb => "U",
Self::AllOtherOrdersAsAgentForOtherMember => "W",
Self::ShortExemptTransactionMemberNotAffliated => "X",
Self::AgencyNonAlgo => "Y",
Self::ShortExemptTransactionNonMember => "Z",
Self::Unrecognized(value) => value,
}
}
}
impl<'a> From<&'a str> for Rule80A<'a> {
fn from(value: &'a str) -> Self {
Self::from_value(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum Side<'a> {
Buy,
Sell,
BuyMinus,
SellPlus,
SellShort,
SellShortExempt,
Undisclosed,
Cross,
CrossShort,
Unrecognized(&'a str),
}
impl<'a> Side<'a> {
pub fn from_value(value: &'a str) -> Self {
match value {
"1" => Self::Buy,
"2" => Self::Sell,
"3" => Self::BuyMinus,
"4" => Self::SellPlus,
"5" => Self::SellShort,
"6" => Self::SellShortExempt,
"7" => Self::Undisclosed,
"8" => Self::Cross,
"9" => Self::CrossShort,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> &'a str {
match self {
Self::Buy => "1",
Self::Sell => "2",
Self::BuyMinus => "3",
Self::SellPlus => "4",
Self::SellShort => "5",
Self::SellShortExempt => "6",
Self::Undisclosed => "7",
Self::Cross => "8",
Self::CrossShort => "9",
Self::Unrecognized(value) => value,
}
}
}
impl<'a> From<&'a str> for Side<'a> {
fn from(value: &'a str) -> Self {
Self::from_value(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum TimeInForce<'a> {
Day,
GoodTillCancel,
AtTheOpening,
ImmediateOrCancel,
FillOrKill,
GoodTillCrossing,
GoodTillDate,
Unrecognized(&'a str),
}
impl<'a> TimeInForce<'a> {
pub fn from_value(value: &'a str) -> Self {
match value {
"0" => Self::Day,
"1" => Self::GoodTillCancel,
"2" => Self::AtTheOpening,
"3" => Self::ImmediateOrCancel,
"4" => Self::FillOrKill,
"5" => Self::GoodTillCrossing,
"6" => Self::GoodTillDate,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> &'a str {
match self {
Self::Day => "0",
Self::GoodTillCancel => "1",
Self::AtTheOpening => "2",
Self::ImmediateOrCancel => "3",
Self::FillOrKill => "4",
Self::GoodTillCrossing => "5",
Self::GoodTillDate => "6",
Self::Unrecognized(value) => value,
}
}
}
impl<'a> From<&'a str> for TimeInForce<'a> {
fn from(value: &'a str) -> Self {
Self::from_value(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum Urgency<'a> {
Normal,
Flash,
Background,
Unrecognized(&'a str),
}
impl<'a> Urgency<'a> {
pub fn from_value(value: &'a str) -> Self {
match value {
"0" => Self::Normal,
"1" => Self::Flash,
"2" => Self::Background,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> &'a str {
match self {
Self::Normal => "0",
Self::Flash => "1",
Self::Background => "2",
Self::Unrecognized(value) => value,
}
}
}
impl<'a> From<&'a str> for Urgency<'a> {
fn from(value: &'a str) -> Self {
Self::from_value(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum SettlmntTyp<'a> {
Regular,
Cash,
NextDay,
TPlus2,
TPlus3,
TPlus4,
Future,
WhenAndIfIssued,
SellersOption,
TPlus5,
Unrecognized(&'a str),
}
impl<'a> SettlmntTyp<'a> {
pub fn from_value(value: &'a str) -> Self {
match value {
"0" => Self::Regular,
"1" => Self::Cash,
"2" => Self::NextDay,
"3" => Self::TPlus2,
"4" => Self::TPlus3,
"5" => Self::TPlus4,
"6" => Self::Future,
"7" => Self::WhenAndIfIssued,
"8" => Self::SellersOption,
"9" => Self::TPlus5,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> &'a str {
match self {
Self::Regular => "0",
Self::Cash => "1",
Self::NextDay => "2",
Self::TPlus2 => "3",
Self::TPlus3 => "4",
Self::TPlus4 => "5",
Self::Future => "6",
Self::WhenAndIfIssued => "7",
Self::SellersOption => "8",
Self::TPlus5 => "9",
Self::Unrecognized(value) => value,
}
}
}
impl<'a> From<&'a str> for SettlmntTyp<'a> {
fn from(value: &'a str) -> Self {
Self::from_value(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum AllocTransType<'a> {
New,
Replace,
Cancel,
Preliminary,
Calculated,
CalculatedWithoutPreliminary,
Unrecognized(&'a str),
}
impl<'a> AllocTransType<'a> {
pub fn from_value(value: &'a str) -> Self {
match value {
"0" => Self::New,
"1" => Self::Replace,
"2" => Self::Cancel,
"3" => Self::Preliminary,
"4" => Self::Calculated,
"5" => Self::CalculatedWithoutPreliminary,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> &'a str {
match self {
Self::New => "0",
Self::Replace => "1",
Self::Cancel => "2",
Self::Preliminary => "3",
Self::Calculated => "4",
Self::CalculatedWithoutPreliminary => "5",
Self::Unrecognized(value) => value,
}
}
}
impl<'a> From<&'a str> for AllocTransType<'a> {
fn from(value: &'a str) -> Self {
Self::from_value(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum OpenClose<'a> {
Close,
Open,
Unrecognized(&'a str),
}
impl<'a> OpenClose<'a> {
pub fn from_value(value: &'a str) -> Self {
match value {
"C" => Self::Close,
"O" => Self::Open,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> &'a str {
match self {
Self::Close => "C",
Self::Open => "O",
Self::Unrecognized(value) => value,
}
}
}
impl<'a> From<&'a str> for OpenClose<'a> {
fn from(value: &'a str) -> Self {
Self::from_value(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum ProcessCode<'a> {
Regular,
SoftDollar,
StepIn,
StepOut,
SoftDollarStepIn,
SoftDollarStepOut,
PlanSponsor,
Unrecognized(&'a str),
}
impl<'a> ProcessCode<'a> {
pub fn from_value(value: &'a str) -> Self {
match value {
"0" => Self::Regular,
"1" => Self::SoftDollar,
"2" => Self::StepIn,
"3" => Self::StepOut,
"4" => Self::SoftDollarStepIn,
"5" => Self::SoftDollarStepOut,
"6" => Self::PlanSponsor,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> &'a str {
match self {
Self::Regular => "0",
Self::SoftDollar => "1",
Self::StepIn => "2",
Self::StepOut => "3",
Self::SoftDollarStepIn => "4",
Self::SoftDollarStepOut => "5",
Self::PlanSponsor => "6",
Self::Unrecognized(value) => value,
}
}
}
impl<'a> From<&'a str> for ProcessCode<'a> {
fn from(value: &'a str) -> Self {
Self::from_value(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum AllocStatus {
Accepted,
BlockLevelReject,
AccountLevelReject,
Received,
Unrecognized(i64),
}
impl AllocStatus {
pub fn from_value(value: i64) -> Self {
match value {
0 => Self::Accepted,
1 => Self::BlockLevelReject,
2 => Self::AccountLevelReject,
3 => Self::Received,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> i64 {
match self {
Self::Accepted => 0,
Self::BlockLevelReject => 1,
Self::AccountLevelReject => 2,
Self::Received => 3,
Self::Unrecognized(value) => value,
}
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum AllocRejCode {
UnknownAccount,
IncorrectQuantity,
IncorrectAveragegPrice,
UnknownExecutingBrokerMnemonic,
CommissionDifference,
UnknownOrderId,
UnknownListId,
OtherSeeText,
Unrecognized(i64),
}
impl AllocRejCode {
pub fn from_value(value: i64) -> Self {
match value {
0 => Self::UnknownAccount,
1 => Self::IncorrectQuantity,
2 => Self::IncorrectAveragegPrice,
3 => Self::UnknownExecutingBrokerMnemonic,
4 => Self::CommissionDifference,
5 => Self::UnknownOrderId,
6 => Self::UnknownListId,
7 => Self::OtherSeeText,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> i64 {
match self {
Self::UnknownAccount => 0,
Self::IncorrectQuantity => 1,
Self::IncorrectAveragegPrice => 2,
Self::UnknownExecutingBrokerMnemonic => 3,
Self::CommissionDifference => 4,
Self::UnknownOrderId => 5,
Self::UnknownListId => 6,
Self::OtherSeeText => 7,
Self::Unrecognized(value) => value,
}
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum EmailType<'a> {
New,
Reply,
AdminReply,
Unrecognized(&'a str),
}
impl<'a> EmailType<'a> {
pub fn from_value(value: &'a str) -> Self {
match value {
"0" => Self::New,
"1" => Self::Reply,
"2" => Self::AdminReply,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> &'a str {
match self {
Self::New => "0",
Self::Reply => "1",
Self::AdminReply => "2",
Self::Unrecognized(value) => value,
}
}
}
impl<'a> From<&'a str> for EmailType<'a> {
fn from(value: &'a str) -> Self {
Self::from_value(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum EncryptMethod {
None,
Pkcs,
Des,
Pkcsdes,
Pgpdes,
Pgpdesmd5,
Pem,
Unrecognized(i64),
}
impl EncryptMethod {
pub fn from_value(value: i64) -> Self {
match value {
0 => Self::None,
1 => Self::Pkcs,
2 => Self::Des,
3 => Self::Pkcsdes,
4 => Self::Pgpdes,
5 => Self::Pgpdesmd5,
6 => Self::Pem,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> i64 {
match self {
Self::None => 0,
Self::Pkcs => 1,
Self::Des => 2,
Self::Pkcsdes => 3,
Self::Pgpdes => 4,
Self::Pgpdesmd5 => 5,
Self::Pem => 6,
Self::Unrecognized(value) => value,
}
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum CxlRejReason {
TooLateToCancel,
UnknownOrder,
BrokerCredit,
OrderAlreadyInPendingStatus,
Unrecognized(i64),
}
impl CxlRejReason {
pub fn from_value(value: i64) -> Self {
match value {
0 => Self::TooLateToCancel,
1 => Self::UnknownOrder,
2 => Self::BrokerCredit,
3 => Self::OrderAlreadyInPendingStatus,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> i64 {
match self {
Self::TooLateToCancel => 0,
Self::UnknownOrder => 1,
Self::BrokerCredit => 2,
Self::OrderAlreadyInPendingStatus => 3,
Self::Unrecognized(value) => value,
}
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum OrdRejReason {
BrokerCredit,
UnknownSymbol,
ExchangeClosed,
OrderExceedsLimit,
TooLateToEnter,
UnknownOrder,
DuplicateOrder,
DuplicateOfAVerballyCommunicatedOrder,
StaleOrder,
Unrecognized(i64),
}
impl OrdRejReason {
pub fn from_value(value: i64) -> Self {
match value {
0 => Self::BrokerCredit,
1 => Self::UnknownSymbol,
2 => Self::ExchangeClosed,
3 => Self::OrderExceedsLimit,
4 => Self::TooLateToEnter,
5 => Self::UnknownOrder,
6 => Self::DuplicateOrder,
7 => Self::DuplicateOfAVerballyCommunicatedOrder,
8 => Self::StaleOrder,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> i64 {
match self {
Self::BrokerCredit => 0,
Self::UnknownSymbol => 1,
Self::ExchangeClosed => 2,
Self::OrderExceedsLimit => 3,
Self::TooLateToEnter => 4,
Self::UnknownOrder => 5,
Self::DuplicateOrder => 6,
Self::DuplicateOfAVerballyCommunicatedOrder => 7,
Self::StaleOrder => 8,
Self::Unrecognized(value) => value,
}
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum IOIQualifier<'a> {
AllOrNone,
AtTheClose,
InTouchWith,
Limit,
MoreBehind,
AtTheOpen,
TakingAPosition,
AtTheMarket,
ReadyToTrade,
PortfolioShown,
ThroughTheDay,
Versus,
Indication,
CrossingOpportunity,
AtTheMidpoint,
PreOpen,
Unrecognized(&'a str),
}
impl<'a> IOIQualifier<'a> {
pub fn from_value(value: &'a str) -> Self {
match value {
"A" => Self::AllOrNone,
"C" => Self::AtTheClose,
"I" => Self::InTouchWith,
"L" => Self::Limit,
"M" => Self::MoreBehind,
"O" => Self::AtTheOpen,
"P" => Self::TakingAPosition,
"Q" => Self::AtTheMarket,
"R" => Self::ReadyToTrade,
"S" => Self::PortfolioShown,
"T" => Self::ThroughTheDay,
"V" => Self::Versus,
"W" => Self::Indication,
"X" => Self::CrossingOpportunity,
"Y" => Self::AtTheMidpoint,
"Z" => Self::PreOpen,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> &'a str {
match self {
Self::AllOrNone => "A",
Self::AtTheClose => "C",
Self::InTouchWith => "I",
Self::Limit => "L",
Self::MoreBehind => "M",
Self::AtTheOpen => "O",
Self::TakingAPosition => "P",
Self::AtTheMarket => "Q",
Self::ReadyToTrade => "R",
Self::PortfolioShown => "S",
Self::ThroughTheDay => "T",
Self::Versus => "V",
Self::Indication => "W",
Self::CrossingOpportunity => "X",
Self::AtTheMidpoint => "Y",
Self::PreOpen => "Z",
Self::Unrecognized(value) => value,
}
}
}
impl<'a> From<&'a str> for IOIQualifier<'a> {
fn from(value: &'a str) -> Self {
Self::from_value(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum DKReason<'a> {
UnknownSymbol,
WrongSide,
QuantityExceedsOrder,
NoMatchingOrder,
PriceExceedsLimit,
Other,
Unrecognized(&'a str),
}
impl<'a> DKReason<'a> {
pub fn from_value(value: &'a str) -> Self {
match value {
"A" => Self::UnknownSymbol,
"B" => Self::WrongSide,
"C" => Self::QuantityExceedsOrder,
"D" => Self::NoMatchingOrder,
"E" => Self::PriceExceedsLimit,
"Z" => Self::Other,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> &'a str {
match self {
Self::UnknownSymbol => "A",
Self::WrongSide => "B",
Self::QuantityExceedsOrder => "C",
Self::NoMatchingOrder => "D",
Self::PriceExceedsLimit => "E",
Self::Other => "Z",
Self::Unrecognized(value) => value,
}
}
}
impl<'a> From<&'a str> for DKReason<'a> {
fn from(value: &'a str) -> Self {
Self::from_value(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum MiscFeeType<'a> {
Regulatory,
Tax,
LocalCommission,
ExchangeFees,
Stamp,
Levy,
Other,
Markup,
ConsumptionTax,
Unrecognized(&'a str),
}
impl<'a> MiscFeeType<'a> {
pub fn from_value(value: &'a str) -> Self {
match value {
"1" => Self::Regulatory,
"2" => Self::Tax,
"3" => Self::LocalCommission,
"4" => Self::ExchangeFees,
"5" => Self::Stamp,
"6" => Self::Levy,
"7" => Self::Other,
"8" => Self::Markup,
"9" => Self::ConsumptionTax,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> &'a str {
match self {
Self::Regulatory => "1",
Self::Tax => "2",
Self::LocalCommission => "3",
Self::ExchangeFees => "4",
Self::Stamp => "5",
Self::Levy => "6",
Self::Other => "7",
Self::Markup => "8",
Self::ConsumptionTax => "9",
Self::Unrecognized(value) => value,
}
}
}
impl<'a> From<&'a str> for MiscFeeType<'a> {
fn from(value: &'a str) -> Self {
Self::from_value(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum ExecType<'a> {
New,
PartialFill,
Fill,
DoneForDay,
Canceled,
Replaced,
PendingCancel,
Stopped,
Rejected,
Suspended,
PendingNew,
Calculated,
Expired,
Restated,
PendingReplace,
Unrecognized(&'a str),
}
impl<'a> ExecType<'a> {
pub fn from_value(value: &'a str) -> Self {
match value {
"0" => Self::New,
"1" => Self::PartialFill,
"2" => Self::Fill,
"3" => Self::DoneForDay,
"4" => Self::Canceled,
"5" => Self::Replaced,
"6" => Self::PendingCancel,
"7" => Self::Stopped,
"8" => Self::Rejected,
"9" => Self::Suspended,
"A" => Self::PendingNew,
"B" => Self::Calculated,
"C" => Self::Expired,
"D" => Self::Restated,
"E" => Self::PendingReplace,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> &'a str {
match self {
Self::New => "0",
Self::PartialFill => "1",
Self::Fill => "2",
Self::DoneForDay => "3",
Self::Canceled => "4",
Self::Replaced => "5",
Self::PendingCancel => "6",
Self::Stopped => "7",
Self::Rejected => "8",
Self::Suspended => "9",
Self::PendingNew => "A",
Self::Calculated => "B",
Self::Expired => "C",
Self::Restated => "D",
Self::PendingReplace => "E",
Self::Unrecognized(value) => value,
}
}
}
impl<'a> From<&'a str> for ExecType<'a> {
fn from(value: &'a str) -> Self {
Self::from_value(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum SettlInstMode<'a> {
Default,
StandingInstructionsProvided,
SpecificAllocationAccountOverriding,
SpecificAllocationAccountStanding,
Unrecognized(&'a str),
}
impl<'a> SettlInstMode<'a> {
pub fn from_value(value: &'a str) -> Self {
match value {
"0" => Self::Default,
"1" => Self::StandingInstructionsProvided,
"2" => Self::SpecificAllocationAccountOverriding,
"3" => Self::SpecificAllocationAccountStanding,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> &'a str {
match self {
Self::Default => "0",
Self::StandingInstructionsProvided => "1",
Self::SpecificAllocationAccountOverriding => "2",
Self::SpecificAllocationAccountStanding => "3",
Self::Unrecognized(value) => value,
}
}
}
impl<'a> From<&'a str> for SettlInstMode<'a> {
fn from(value: &'a str) -> Self {
Self::from_value(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum SettlInstTransType<'a> {
Cancel,
New,
Replace,
Unrecognized(&'a str),
}
impl<'a> SettlInstTransType<'a> {
pub fn from_value(value: &'a str) -> Self {
match value {
"C" => Self::Cancel,
"N" => Self::New,
"R" => Self::Replace,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> &'a str {
match self {
Self::Cancel => "C",
Self::New => "N",
Self::Replace => "R",
Self::Unrecognized(value) => value,
}
}
}
impl<'a> From<&'a str> for SettlInstTransType<'a> {
fn from(value: &'a str) -> Self {
Self::from_value(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum SettlInstSource<'a> {
BrokerCredit,
Institution,
Unrecognized(&'a str),
}
impl<'a> SettlInstSource<'a> {
pub fn from_value(value: &'a str) -> Self {
match value {
"1" => Self::BrokerCredit,
"2" => Self::Institution,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> &'a str {
match self {
Self::BrokerCredit => "1",
Self::Institution => "2",
Self::Unrecognized(value) => value,
}
}
}
impl<'a> From<&'a str> for SettlInstSource<'a> {
fn from(value: &'a str) -> Self {
Self::from_value(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum SettlLocation<'a> {
Cedel,
DepositoryTrustCompany,
EuroClear,
FederalBookEntry,
LocalMarketSettleLocation,
Physical,
ParticipantTrustCompany,
Unrecognized(&'a str),
}
impl<'a> SettlLocation<'a> {
pub fn from_value(value: &'a str) -> Self {
match value {
"CED" => Self::Cedel,
"DTC" => Self::DepositoryTrustCompany,
"EUR" => Self::EuroClear,
"FED" => Self::FederalBookEntry,
"ISO Country Code" => Self::LocalMarketSettleLocation,
"PNY" => Self::Physical,
"PTC" => Self::ParticipantTrustCompany,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> &'a str {
match self {
Self::Cedel => "CED",
Self::DepositoryTrustCompany => "DTC",
Self::EuroClear => "EUR",
Self::FederalBookEntry => "FED",
Self::LocalMarketSettleLocation => "ISO Country Code",
Self::Physical => "PNY",
Self::ParticipantTrustCompany => "PTC",
Self::Unrecognized(value) => value,
}
}
}
impl<'a> From<&'a str> for SettlLocation<'a> {
fn from(value: &'a str) -> Self {
Self::from_value(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum SecurityType<'a> {
Wildcard,
BankersAcceptance,
ConvertibleBond,
CertificateOfDeposit,
CollateralizedMortgageObligation,
CorporateBond,
CommercialPaper,
CorporatePrivatePlacement,
CommonStock,
FederalHousingAuthority,
FederalHomeLoan,
FederalNationalMortgageAssociation,
ForeignExchangeContract,
Future,
GovernmentNationalMortgageAssociation,
TreasuriesAgencyDebenture,
IoetteMortgage,
MutualFund,
MortgageInterestOnly,
MortgagePrincipalOnly,
MortgagePrivatePlacement,
MiscellaneousPassThrough,
MunicipalBond,
NoSecurityType,
Option,
PreferredStock,
RepurchaseAgreement,
ReverseRepurchaseAgreement,
StudentLoanMarketingAssociation,
TimeDeposit,
UsTreasuryBillOld,
Warrant,
CatsTigersAndLions,
Unrecognized(&'a str),
}
impl<'a> SecurityType<'a> {
pub fn from_value(value: &'a str) -> Self {
match value {
"?" => Self::Wildcard,
"BA" => Self::BankersAcceptance,
"CB" => Self::ConvertibleBond,
"CD" => Self::CertificateOfDeposit,
"CMO" => Self::CollateralizedMortgageObligation,
"CORP" => Self::CorporateBond,
"CP" => Self::CommercialPaper,
"CPP" => Self::CorporatePrivatePlacement,
"CS" => Self::CommonStock,
"FHA" => Self::FederalHousingAuthority,
"FHL" => Self::FederalHomeLoan,
"FN" => Self::FederalNationalMortgageAssociation,
"FOR" => Self::ForeignExchangeContract,
"FUT" => Self::Future,
"GN" => Self::GovernmentNationalMortgageAssociation,
"GOVT" => Self::TreasuriesAgencyDebenture,
"IET" => Self::IoetteMortgage,
"MF" => Self::MutualFund,
"MIO" => Self::MortgageInterestOnly,
"MPO" => Self::MortgagePrincipalOnly,
"MPP" => Self::MortgagePrivatePlacement,
"MPT" => Self::MiscellaneousPassThrough,
"MUNI" => Self::MunicipalBond,
"NONE" => Self::NoSecurityType,
"OPT" => Self::Option,
"PS" => Self::PreferredStock,
"RP" => Self::RepurchaseAgreement,
"RVRP" => Self::ReverseRepurchaseAgreement,
"SL" => Self::StudentLoanMarketingAssociation,
"TD" => Self::TimeDeposit,
"USTB" => Self::UsTreasuryBillOld,
"WAR" => Self::Warrant,
"ZOO" => Self::CatsTigersAndLions,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> &'a str {
match self {
Self::Wildcard => "?",
Self::BankersAcceptance => "BA",
Self::ConvertibleBond => "CB",
Self::CertificateOfDeposit => "CD",
Self::CollateralizedMortgageObligation => "CMO",
Self::CorporateBond => "CORP",
Self::CommercialPaper => "CP",
Self::CorporatePrivatePlacement => "CPP",
Self::CommonStock => "CS",
Self::FederalHousingAuthority => "FHA",
Self::FederalHomeLoan => "FHL",
Self::FederalNationalMortgageAssociation => "FN",
Self::ForeignExchangeContract => "FOR",
Self::Future => "FUT",
Self::GovernmentNationalMortgageAssociation => "GN",
Self::TreasuriesAgencyDebenture => "GOVT",
Self::IoetteMortgage => "IET",
Self::MutualFund => "MF",
Self::MortgageInterestOnly => "MIO",
Self::MortgagePrincipalOnly => "MPO",
Self::MortgagePrivatePlacement => "MPP",
Self::MiscellaneousPassThrough => "MPT",
Self::MunicipalBond => "MUNI",
Self::NoSecurityType => "NONE",
Self::Option => "OPT",
Self::PreferredStock => "PS",
Self::RepurchaseAgreement => "RP",
Self::ReverseRepurchaseAgreement => "RVRP",
Self::StudentLoanMarketingAssociation => "SL",
Self::TimeDeposit => "TD",
Self::UsTreasuryBillOld => "USTB",
Self::Warrant => "WAR",
Self::CatsTigersAndLions => "ZOO",
Self::Unrecognized(value) => value,
}
}
}
impl<'a> From<&'a str> for SecurityType<'a> {
fn from(value: &'a str) -> Self {
Self::from_value(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum StandInstDbType {
Other,
Dtcsid,
ThomsonAlert,
AGlobalCustodian,
Unrecognized(i64),
}
impl StandInstDbType {
pub fn from_value(value: i64) -> Self {
match value {
0 => Self::Other,
1 => Self::Dtcsid,
2 => Self::ThomsonAlert,
3 => Self::AGlobalCustodian,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> i64 {
match self {
Self::Other => 0,
Self::Dtcsid => 1,
Self::ThomsonAlert => 2,
Self::AGlobalCustodian => 3,
Self::Unrecognized(value) => value,
}
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum AllocLinkType {
FxNetting,
FxSwap,
Unrecognized(i64),
}
impl AllocLinkType {
pub fn from_value(value: i64) -> Self {
match value {
0 => Self::FxNetting,
1 => Self::FxSwap,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> i64 {
match self {
Self::FxNetting => 0,
Self::FxSwap => 1,
Self::Unrecognized(value) => value,
}
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum PutOrCall {
Put,
Call,
Unrecognized(i64),
}
impl PutOrCall {
pub fn from_value(value: i64) -> Self {
match value {
0 => Self::Put,
1 => Self::Call,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> i64 {
match self {
Self::Put => 0,
Self::Call => 1,
Self::Unrecognized(value) => value,
}
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum CoveredOrUncovered {
Covered,
Uncovered,
Unrecognized(i64),
}
impl CoveredOrUncovered {
pub fn from_value(value: i64) -> Self {
match value {
0 => Self::Covered,
1 => Self::Uncovered,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> i64 {
match self {
Self::Covered => 0,
Self::Uncovered => 1,
Self::Unrecognized(value) => value,
}
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum CustomerOrFirm {
Customer,
Firm,
Unrecognized(i64),
}
impl CustomerOrFirm {
pub fn from_value(value: i64) -> Self {
match value {
0 => Self::Customer,
1 => Self::Firm,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> i64 {
match self {
Self::Customer => 0,
Self::Firm => 1,
Self::Unrecognized(value) => value,
}
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum AllocHandlInst {
Match,
Forward,
ForwardAndMatch,
Unrecognized(i64),
}
impl AllocHandlInst {
pub fn from_value(value: i64) -> Self {
match value {
1 => Self::Match,
2 => Self::Forward,
3 => Self::ForwardAndMatch,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> i64 {
match self {
Self::Match => 1,
Self::Forward => 2,
Self::ForwardAndMatch => 3,
Self::Unrecognized(value) => value,
}
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum RoutingType {
TargetFirm,
TargetList,
BlockFirm,
BlockList,
Unrecognized(i64),
}
impl RoutingType {
pub fn from_value(value: i64) -> Self {
match value {
1 => Self::TargetFirm,
2 => Self::TargetList,
3 => Self::BlockFirm,
4 => Self::BlockList,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> i64 {
match self {
Self::TargetFirm => 1,
Self::TargetList => 2,
Self::BlockFirm => 3,
Self::BlockList => 4,
Self::Unrecognized(value) => value,
}
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum Benchmark<'a> {
Curve,
FiveYr,
Old5,
TenYr,
Old10,
ThirtyYr,
Old30,
ThreeMolibor,
SixMolibor,
Unrecognized(&'a str),
}
impl<'a> Benchmark<'a> {
pub fn from_value(value: &'a str) -> Self {
match value {
"1" => Self::Curve,
"2" => Self::FiveYr,
"3" => Self::Old5,
"4" => Self::TenYr,
"5" => Self::Old10,
"6" => Self::ThirtyYr,
"7" => Self::Old30,
"8" => Self::ThreeMolibor,
"9" => Self::SixMolibor,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> &'a str {
match self {
Self::Curve => "1",
Self::FiveYr => "2",
Self::Old5 => "3",
Self::TenYr => "4",
Self::Old10 => "5",
Self::ThirtyYr => "6",
Self::Old30 => "7",
Self::ThreeMolibor => "8",
Self::SixMolibor => "9",
Self::Unrecognized(value) => value,
}
}
}
impl<'a> From<&'a str> for Benchmark<'a> {
fn from(value: &'a str) -> Self {
Self::from_value(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum SubscriptionRequestType<'a> {
Snapshot,
SnapshotAndUpdates,
DisablePreviousSnapshot,
Unrecognized(&'a str),
}
impl<'a> SubscriptionRequestType<'a> {
pub fn from_value(value: &'a str) -> Self {
match value {
"0" => Self::Snapshot,
"1" => Self::SnapshotAndUpdates,
"2" => Self::DisablePreviousSnapshot,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> &'a str {
match self {
Self::Snapshot => "0",
Self::SnapshotAndUpdates => "1",
Self::DisablePreviousSnapshot => "2",
Self::Unrecognized(value) => value,
}
}
}
impl<'a> From<&'a str> for SubscriptionRequestType<'a> {
fn from(value: &'a str) -> Self {
Self::from_value(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum MDUpdateType {
FullRefresh,
IncrementalRefresh,
Unrecognized(i64),
}
impl MDUpdateType {
pub fn from_value(value: i64) -> Self {
match value {
0 => Self::FullRefresh,
1 => Self::IncrementalRefresh,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> i64 {
match self {
Self::FullRefresh => 0,
Self::IncrementalRefresh => 1,
Self::Unrecognized(value) => value,
}
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum MDEntryType<'a> {
Bid,
Offer,
Trade,
IndexValue,
OpeningPrice,
ClosingPrice,
SettlementPrice,
TradingSessionHighPrice,
TradingSessionLowPrice,
TradingSessionVwapPrice,
Unrecognized(&'a str),
}
impl<'a> MDEntryType<'a> {
pub fn from_value(value: &'a str) -> Self {
match value {
"0" => Self::Bid,
"1" => Self::Offer,
"2" => Self::Trade,
"3" => Self::IndexValue,
"4" => Self::OpeningPrice,
"5" => Self::ClosingPrice,
"6" => Self::SettlementPrice,
"7" => Self::TradingSessionHighPrice,
"8" => Self::TradingSessionLowPrice,
"9" => Self::TradingSessionVwapPrice,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> &'a str {
match self {
Self::Bid => "0",
Self::Offer => "1",
Self::Trade => "2",
Self::IndexValue => "3",
Self::OpeningPrice => "4",
Self::ClosingPrice => "5",
Self::SettlementPrice => "6",
Self::TradingSessionHighPrice => "7",
Self::TradingSessionLowPrice => "8",
Self::TradingSessionVwapPrice => "9",
Self::Unrecognized(value) => value,
}
}
}
impl<'a> From<&'a str> for MDEntryType<'a> {
fn from(value: &'a str) -> Self {
Self::from_value(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum TickDirection<'a> {
PlusTick,
ZeroPlusTick,
MinusTick,
ZeroMinusTick,
Unrecognized(&'a str),
}
impl<'a> TickDirection<'a> {
pub fn from_value(value: &'a str) -> Self {
match value {
"0" => Self::PlusTick,
"1" => Self::ZeroPlusTick,
"2" => Self::MinusTick,
"3" => Self::ZeroMinusTick,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> &'a str {
match self {
Self::PlusTick => "0",
Self::ZeroPlusTick => "1",
Self::MinusTick => "2",
Self::ZeroMinusTick => "3",
Self::Unrecognized(value) => value,
}
}
}
impl<'a> From<&'a str> for TickDirection<'a> {
fn from(value: &'a str) -> Self {
Self::from_value(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum QuoteCondition<'a> {
Open,
Closed,
ExchangeBest,
ConsolidatedBest,
Locked,
Crossed,
Depth,
FastTrading,
NonFirm,
Unrecognized(&'a str),
}
impl<'a> QuoteCondition<'a> {
pub fn from_value(value: &'a str) -> Self {
match value {
"A" => Self::Open,
"B" => Self::Closed,
"C" => Self::ExchangeBest,
"D" => Self::ConsolidatedBest,
"E" => Self::Locked,
"F" => Self::Crossed,
"G" => Self::Depth,
"H" => Self::FastTrading,
"I" => Self::NonFirm,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> &'a str {
match self {
Self::Open => "A",
Self::Closed => "B",
Self::ExchangeBest => "C",
Self::ConsolidatedBest => "D",
Self::Locked => "E",
Self::Crossed => "F",
Self::Depth => "G",
Self::FastTrading => "H",
Self::NonFirm => "I",
Self::Unrecognized(value) => value,
}
}
}
impl<'a> From<&'a str> for QuoteCondition<'a> {
fn from(value: &'a str) -> Self {
Self::from_value(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum TradeCondition<'a> {
Cash,
AveragePriceTrade,
CashTrade,
NextDay,
Opening,
IntradayTradeDetail,
Rule127Trade,
Rule155Trade,
SoldLast,
NextDayTrade,
Opened,
Seller,
Sold,
StoppedStock,
Unrecognized(&'a str),
}
impl<'a> TradeCondition<'a> {
pub fn from_value(value: &'a str) -> Self {
match value {
"A" => Self::Cash,
"B" => Self::AveragePriceTrade,
"C" => Self::CashTrade,
"D" => Self::NextDay,
"E" => Self::Opening,
"F" => Self::IntradayTradeDetail,
"G" => Self::Rule127Trade,
"H" => Self::Rule155Trade,
"I" => Self::SoldLast,
"J" => Self::NextDayTrade,
"K" => Self::Opened,
"L" => Self::Seller,
"M" => Self::Sold,
"N" => Self::StoppedStock,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> &'a str {
match self {
Self::Cash => "A",
Self::AveragePriceTrade => "B",
Self::CashTrade => "C",
Self::NextDay => "D",
Self::Opening => "E",
Self::IntradayTradeDetail => "F",
Self::Rule127Trade => "G",
Self::Rule155Trade => "H",
Self::SoldLast => "I",
Self::NextDayTrade => "J",
Self::Opened => "K",
Self::Seller => "L",
Self::Sold => "M",
Self::StoppedStock => "N",
Self::Unrecognized(value) => value,
}
}
}
impl<'a> From<&'a str> for TradeCondition<'a> {
fn from(value: &'a str) -> Self {
Self::from_value(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum MDUpdateAction<'a> {
New,
Change,
Delete,
Unrecognized(&'a str),
}
impl<'a> MDUpdateAction<'a> {
pub fn from_value(value: &'a str) -> Self {
match value {
"0" => Self::New,
"1" => Self::Change,
"2" => Self::Delete,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> &'a str {
match self {
Self::New => "0",
Self::Change => "1",
Self::Delete => "2",
Self::Unrecognized(value) => value,
}
}
}
impl<'a> From<&'a str> for MDUpdateAction<'a> {
fn from(value: &'a str) -> Self {
Self::from_value(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum MDReqRejReason<'a> {
UnknownSymbol,
DuplicateMdReqId,
InsufficientBandwidth,
InsufficientPermissions,
UnsupportedSubscriptionRequestType,
UnsupportedMarketDepth,
UnsupportedMdUpdateType,
UnsupportedAggregatedBook,
UnsupportedMdEntryType,
Unrecognized(&'a str),
}
impl<'a> MDReqRejReason<'a> {
pub fn from_value(value: &'a str) -> Self {
match value {
"0" => Self::UnknownSymbol,
"1" => Self::DuplicateMdReqId,
"2" => Self::InsufficientBandwidth,
"3" => Self::InsufficientPermissions,
"4" => Self::UnsupportedSubscriptionRequestType,
"5" => Self::UnsupportedMarketDepth,
"6" => Self::UnsupportedMdUpdateType,
"7" => Self::UnsupportedAggregatedBook,
"8" => Self::UnsupportedMdEntryType,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> &'a str {
match self {
Self::UnknownSymbol => "0",
Self::DuplicateMdReqId => "1",
Self::InsufficientBandwidth => "2",
Self::InsufficientPermissions => "3",
Self::UnsupportedSubscriptionRequestType => "4",
Self::UnsupportedMarketDepth => "5",
Self::UnsupportedMdUpdateType => "6",
Self::UnsupportedAggregatedBook => "7",
Self::UnsupportedMdEntryType => "8",
Self::Unrecognized(value) => value,
}
}
}
impl<'a> From<&'a str> for MDReqRejReason<'a> {
fn from(value: &'a str) -> Self {
Self::from_value(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum DeleteReason<'a> {
Cancellation,
Error,
Unrecognized(&'a str),
}
impl<'a> DeleteReason<'a> {
pub fn from_value(value: &'a str) -> Self {
match value {
"0" => Self::Cancellation,
"1" => Self::Error,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> &'a str {
match self {
Self::Cancellation => "0",
Self::Error => "1",
Self::Unrecognized(value) => value,
}
}
}
impl<'a> From<&'a str> for DeleteReason<'a> {
fn from(value: &'a str) -> Self {
Self::from_value(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum OpenCloseSettleFlag<'a> {
DailyOpen,
SessionOpen,
DeliverySettlementEntry,
Unrecognized(&'a str),
}
impl<'a> OpenCloseSettleFlag<'a> {
pub fn from_value(value: &'a str) -> Self {
match value {
"0" => Self::DailyOpen,
"1" => Self::SessionOpen,
"2" => Self::DeliverySettlementEntry,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> &'a str {
match self {
Self::DailyOpen => "0",
Self::SessionOpen => "1",
Self::DeliverySettlementEntry => "2",
Self::Unrecognized(value) => value,
}
}
}
impl<'a> From<&'a str> for OpenCloseSettleFlag<'a> {
fn from(value: &'a str) -> Self {
Self::from_value(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum FinancialStatus<'a> {
Bankrupt,
Unrecognized(&'a str),
}
impl<'a> FinancialStatus<'a> {
pub fn from_value(value: &'a str) -> Self {
match value {
"1" => Self::Bankrupt,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> &'a str {
match self {
Self::Bankrupt => "1",
Self::Unrecognized(value) => value,
}
}
}
impl<'a> From<&'a str> for FinancialStatus<'a> {
fn from(value: &'a str) -> Self {
Self::from_value(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum CorporateAction<'a> {
ExDividend,
ExDistribution,
ExRights,
New,
ExInterest,
Unrecognized(&'a str),
}
impl<'a> CorporateAction<'a> {
pub fn from_value(value: &'a str) -> Self {
match value {
"A" => Self::ExDividend,
"B" => Self::ExDistribution,
"C" => Self::ExRights,
"D" => Self::New,
"E" => Self::ExInterest,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> &'a str {
match self {
Self::ExDividend => "A",
Self::ExDistribution => "B",
Self::ExRights => "C",
Self::New => "D",
Self::ExInterest => "E",
Self::Unrecognized(value) => value,
}
}
}
impl<'a> From<&'a str> for CorporateAction<'a> {
fn from(value: &'a str) -> Self {
Self::from_value(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum QuoteStatus {
Accepted,
CancelForSymbol,
CanceledForSecurityType,
CanceledForUnderlying,
CanceledAll,
Rejected,
Unrecognized(i64),
}
impl QuoteStatus {
pub fn from_value(value: i64) -> Self {
match value {
0 => Self::Accepted,
1 => Self::CancelForSymbol,
2 => Self::CanceledForSecurityType,
3 => Self::CanceledForUnderlying,
4 => Self::CanceledAll,
5 => Self::Rejected,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> i64 {
match self {
Self::Accepted => 0,
Self::CancelForSymbol => 1,
Self::CanceledForSecurityType => 2,
Self::CanceledForUnderlying => 3,
Self::CanceledAll => 4,
Self::Rejected => 5,
Self::Unrecognized(value) => value,
}
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum QuoteCancelType {
CancelForOneOrMoreSecurities,
CancelForSecurityType,
CancelForUnderlyingSecurity,
CancelAllQuotes,
Unrecognized(i64),
}
impl QuoteCancelType {
pub fn from_value(value: i64) -> Self {
match value {
1 => Self::CancelForOneOrMoreSecurities,
2 => Self::CancelForSecurityType,
3 => Self::CancelForUnderlyingSecurity,
4 => Self::CancelAllQuotes,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> i64 {
match self {
Self::CancelForOneOrMoreSecurities => 1,
Self::CancelForSecurityType => 2,
Self::CancelForUnderlyingSecurity => 3,
Self::CancelAllQuotes => 4,
Self::Unrecognized(value) => value,
}
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum QuoteRejectReason {
UnknownSymbol,
Exchange,
QuoteRequestExceedsLimit,
TooLateToEnter,
UnknownQuote,
DuplicateQuote,
InvalidBid,
InvalidPrice,
NotAuthorizedToQuoteSecurity,
Unrecognized(i64),
}
impl QuoteRejectReason {
pub fn from_value(value: i64) -> Self {
match value {
1 => Self::UnknownSymbol,
2 => Self::Exchange,
3 => Self::QuoteRequestExceedsLimit,
4 => Self::TooLateToEnter,
5 => Self::UnknownQuote,
6 => Self::DuplicateQuote,
7 => Self::InvalidBid,
8 => Self::InvalidPrice,
9 => Self::NotAuthorizedToQuoteSecurity,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> i64 {
match self {
Self::UnknownSymbol => 1,
Self::Exchange => 2,
Self::QuoteRequestExceedsLimit => 3,
Self::TooLateToEnter => 4,
Self::UnknownQuote => 5,
Self::DuplicateQuote => 6,
Self::InvalidBid => 7,
Self::InvalidPrice => 8,
Self::NotAuthorizedToQuoteSecurity => 9,
Self::Unrecognized(value) => value,
}
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum QuoteResponseLevel {
NoAcknowledgement,
AcknowledgeOnlyNegativeOrErroneousQuotes,
AcknowledgeEachQuoteMessage,
Unrecognized(i64),
}
impl QuoteResponseLevel {
pub fn from_value(value: i64) -> Self {
match value {
0 => Self::NoAcknowledgement,
1 => Self::AcknowledgeOnlyNegativeOrErroneousQuotes,
2 => Self::AcknowledgeEachQuoteMessage,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> i64 {
match self {
Self::NoAcknowledgement => 0,
Self::AcknowledgeOnlyNegativeOrErroneousQuotes => 1,
Self::AcknowledgeEachQuoteMessage => 2,
Self::Unrecognized(value) => value,
}
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum QuoteRequestType {
Manual,
Automatic,
Unrecognized(i64),
}
impl QuoteRequestType {
pub fn from_value(value: i64) -> Self {
match value {
1 => Self::Manual,
2 => Self::Automatic,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> i64 {
match self {
Self::Manual => 1,
Self::Automatic => 2,
Self::Unrecognized(value) => value,
}
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum SecurityRequestType {
RequestSecurityIdentityAndSpecifications,
RequestSecurityIdentityForSpecifications,
RequestListSecurityTypes,
RequestListSecurities,
Unrecognized(i64),
}
impl SecurityRequestType {
pub fn from_value(value: i64) -> Self {
match value {
0 => Self::RequestSecurityIdentityAndSpecifications,
1 => Self::RequestSecurityIdentityForSpecifications,
2 => Self::RequestListSecurityTypes,
3 => Self::RequestListSecurities,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> i64 {
match self {
Self::RequestSecurityIdentityAndSpecifications => 0,
Self::RequestSecurityIdentityForSpecifications => 1,
Self::RequestListSecurityTypes => 2,
Self::RequestListSecurities => 3,
Self::Unrecognized(value) => value,
}
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum SecurityResponseType {
AcceptAsIs,
AcceptWithRevisions,
ListOfSecurityTypesReturnedPerRequest,
ListOfSecuritiesReturnedPerRequest,
RejectSecurityProposal,
CannotMatchSelectionCriteria,
Unrecognized(i64),
}
impl SecurityResponseType {
pub fn from_value(value: i64) -> Self {
match value {
1 => Self::AcceptAsIs,
2 => Self::AcceptWithRevisions,
3 => Self::ListOfSecurityTypesReturnedPerRequest,
4 => Self::ListOfSecuritiesReturnedPerRequest,
5 => Self::RejectSecurityProposal,
6 => Self::CannotMatchSelectionCriteria,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> i64 {
match self {
Self::AcceptAsIs => 1,
Self::AcceptWithRevisions => 2,
Self::ListOfSecurityTypesReturnedPerRequest => 3,
Self::ListOfSecuritiesReturnedPerRequest => 4,
Self::RejectSecurityProposal => 5,
Self::CannotMatchSelectionCriteria => 6,
Self::Unrecognized(value) => value,
}
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum SecurityTradingStatus {
OpeningDelay,
MarketOnCloseImbalanceSell,
NoMarketImbalance,
NoMarketOnCloseImbalance,
ItsPreOpening,
NewPriceIndication,
TradeDisseminationTime,
ReadyToTrade,
NotAvailableForTrading,
NotTradedOnThisMarket,
TradingHalt,
UnknownOrInvalid,
Resume,
NoOpen,
PriceIndication,
TradingRangeIndication,
MarketImbalanceBuy,
MarketImbalanceSell,
MarketOnCloseImbalanceBuy,
Unrecognized(i64),
}
impl SecurityTradingStatus {
pub fn from_value(value: i64) -> Self {
match value {
1 => Self::OpeningDelay,
10 => Self::MarketOnCloseImbalanceSell,
12 => Self::NoMarketImbalance,
13 => Self::NoMarketOnCloseImbalance,
14 => Self::ItsPreOpening,
15 => Self::NewPriceIndication,
16 => Self::TradeDisseminationTime,
17 => Self::ReadyToTrade,
18 => Self::NotAvailableForTrading,
19 => Self::NotTradedOnThisMarket,
2 => Self::TradingHalt,
20 => Self::UnknownOrInvalid,
3 => Self::Resume,
4 => Self::NoOpen,
5 => Self::PriceIndication,
6 => Self::TradingRangeIndication,
7 => Self::MarketImbalanceBuy,
8 => Self::MarketImbalanceSell,
9 => Self::MarketOnCloseImbalanceBuy,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> i64 {
match self {
Self::OpeningDelay => 1,
Self::MarketOnCloseImbalanceSell => 10,
Self::NoMarketImbalance => 12,
Self::NoMarketOnCloseImbalance => 13,
Self::ItsPreOpening => 14,
Self::NewPriceIndication => 15,
Self::TradeDisseminationTime => 16,
Self::ReadyToTrade => 17,
Self::NotAvailableForTrading => 18,
Self::NotTradedOnThisMarket => 19,
Self::TradingHalt => 2,
Self::UnknownOrInvalid => 20,
Self::Resume => 3,
Self::NoOpen => 4,
Self::PriceIndication => 5,
Self::TradingRangeIndication => 6,
Self::MarketImbalanceBuy => 7,
Self::MarketImbalanceSell => 8,
Self::MarketOnCloseImbalanceBuy => 9,
Self::Unrecognized(value) => value,
}
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum HaltReasonChar<'a> {
NewsDissemination,
OrderInflux,
OrderImbalance,
AdditionalInformation,
NewsPending,
EquipmentChangeover,
Unrecognized(&'a str),
}
impl<'a> HaltReasonChar<'a> {
pub fn from_value(value: &'a str) -> Self {
match value {
"D" => Self::NewsDissemination,
"E" => Self::OrderInflux,
"I" => Self::OrderImbalance,
"M" => Self::AdditionalInformation,
"P" => Self::NewsPending,
"X" => Self::EquipmentChangeover,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> &'a str {
match self {
Self::NewsDissemination => "D",
Self::OrderInflux => "E",
Self::OrderImbalance => "I",
Self::AdditionalInformation => "M",
Self::NewsPending => "P",
Self::EquipmentChangeover => "X",
Self::Unrecognized(value) => value,
}
}
}
impl<'a> From<&'a str> for HaltReasonChar<'a> {
fn from(value: &'a str) -> Self {
Self::from_value(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum Adjustment {
Cancel,
Error,
Correction,
Unrecognized(i64),
}
impl Adjustment {
pub fn from_value(value: i64) -> Self {
match value {
1 => Self::Cancel,
2 => Self::Error,
3 => Self::Correction,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> i64 {
match self {
Self::Cancel => 1,
Self::Error => 2,
Self::Correction => 3,
Self::Unrecognized(value) => value,
}
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum TradSesMethod {
Electronic,
OpenOutcry,
TwoParty,
Unrecognized(i64),
}
impl TradSesMethod {
pub fn from_value(value: i64) -> Self {
match value {
1 => Self::Electronic,
2 => Self::OpenOutcry,
3 => Self::TwoParty,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> i64 {
match self {
Self::Electronic => 1,
Self::OpenOutcry => 2,
Self::TwoParty => 3,
Self::Unrecognized(value) => value,
}
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum TradSesMode {
Testing,
Simulated,
Production,
Unrecognized(i64),
}
impl TradSesMode {
pub fn from_value(value: i64) -> Self {
match value {
1 => Self::Testing,
2 => Self::Simulated,
3 => Self::Production,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> i64 {
match self {
Self::Testing => 1,
Self::Simulated => 2,
Self::Production => 3,
Self::Unrecognized(value) => value,
}
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum TradSesStatus {
Halted,
Open,
Closed,
PreOpen,
PreClose,
Unrecognized(i64),
}
impl TradSesStatus {
pub fn from_value(value: i64) -> Self {
match value {
1 => Self::Halted,
2 => Self::Open,
3 => Self::Closed,
4 => Self::PreOpen,
5 => Self::PreClose,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> i64 {
match self {
Self::Halted => 1,
Self::Open => 2,
Self::Closed => 3,
Self::PreOpen => 4,
Self::PreClose => 5,
Self::Unrecognized(value) => value,
}
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum MessageEncoding<'a> {
Eucjp,
Iso2022Jp,
ShiftJis,
Utf8,
Unrecognized(&'a str),
}
impl<'a> MessageEncoding<'a> {
pub fn from_value(value: &'a str) -> Self {
match value {
"EUC-JP" => Self::Eucjp,
"ISO-2022-JP" => Self::Iso2022Jp,
"Shift_JIS" => Self::ShiftJis,
"UTF-8" => Self::Utf8,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> &'a str {
match self {
Self::Eucjp => "EUC-JP",
Self::Iso2022Jp => "ISO-2022-JP",
Self::ShiftJis => "Shift_JIS",
Self::Utf8 => "UTF-8",
Self::Unrecognized(value) => value,
}
}
}
impl<'a> From<&'a str> for MessageEncoding<'a> {
fn from(value: &'a str) -> Self {
Self::from_value(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum QuoteEntryRejectReason {
UnknownSymbol,
Exchange,
QuoteExceedsLimit,
TooLateToEnter,
UnknownQuote,
DuplicateQuote,
InvalidBidAskSpread,
InvalidPrice,
NotAuthorizedToQuoteSecurity,
Unrecognized(i64),
}
impl QuoteEntryRejectReason {
pub fn from_value(value: i64) -> Self {
match value {
1 => Self::UnknownSymbol,
2 => Self::Exchange,
3 => Self::QuoteExceedsLimit,
4 => Self::TooLateToEnter,
5 => Self::UnknownQuote,
6 => Self::DuplicateQuote,
7 => Self::InvalidBidAskSpread,
8 => Self::InvalidPrice,
9 => Self::NotAuthorizedToQuoteSecurity,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> i64 {
match self {
Self::UnknownSymbol => 1,
Self::Exchange => 2,
Self::QuoteExceedsLimit => 3,
Self::TooLateToEnter => 4,
Self::UnknownQuote => 5,
Self::DuplicateQuote => 6,
Self::InvalidBidAskSpread => 7,
Self::InvalidPrice => 8,
Self::NotAuthorizedToQuoteSecurity => 9,
Self::Unrecognized(value) => value,
}
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum SessionRejectReason {
InvalidTagNumber,
RequiredTagMissing,
SendingTimeAccuracyProblem,
InvalidMsgType,
TagNotDefinedForThisMessageType,
UndefinedTag,
TagSpecifiedWithoutAValue,
ValueIsIncorrect,
IncorrectDataFormatForValue,
DecryptionProblem,
SignatureProblem,
CompIdProblem,
Unrecognized(i64),
}
impl SessionRejectReason {
pub fn from_value(value: i64) -> Self {
match value {
0 => Self::InvalidTagNumber,
1 => Self::RequiredTagMissing,
10 => Self::SendingTimeAccuracyProblem,
11 => Self::InvalidMsgType,
2 => Self::TagNotDefinedForThisMessageType,
3 => Self::UndefinedTag,
4 => Self::TagSpecifiedWithoutAValue,
5 => Self::ValueIsIncorrect,
6 => Self::IncorrectDataFormatForValue,
7 => Self::DecryptionProblem,
8 => Self::SignatureProblem,
9 => Self::CompIdProblem,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> i64 {
match self {
Self::InvalidTagNumber => 0,
Self::RequiredTagMissing => 1,
Self::SendingTimeAccuracyProblem => 10,
Self::InvalidMsgType => 11,
Self::TagNotDefinedForThisMessageType => 2,
Self::UndefinedTag => 3,
Self::TagSpecifiedWithoutAValue => 4,
Self::ValueIsIncorrect => 5,
Self::IncorrectDataFormatForValue => 6,
Self::DecryptionProblem => 7,
Self::SignatureProblem => 8,
Self::CompIdProblem => 9,
Self::Unrecognized(value) => value,
}
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum BidRequestTransType<'a> {
Cancel,
New,
Unrecognized(&'a str),
}
impl<'a> BidRequestTransType<'a> {
pub fn from_value(value: &'a str) -> Self {
match value {
"C" => Self::Cancel,
"N" => Self::New,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> &'a str {
match self {
Self::Cancel => "C",
Self::New => "N",
Self::Unrecognized(value) => value,
}
}
}
impl<'a> From<&'a str> for BidRequestTransType<'a> {
fn from(value: &'a str) -> Self {
Self::from_value(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum ExecRestatementReason {
GtCorporateAction,
GtRenewal,
VerbalChange,
RepricingOfOrder,
BrokerOption,
PartialDeclineOfOrderQty,
Unrecognized(i64),
}
impl ExecRestatementReason {
pub fn from_value(value: i64) -> Self {
match value {
0 => Self::GtCorporateAction,
1 => Self::GtRenewal,
2 => Self::VerbalChange,
3 => Self::RepricingOfOrder,
4 => Self::BrokerOption,
5 => Self::PartialDeclineOfOrderQty,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> i64 {
match self {
Self::GtCorporateAction => 0,
Self::GtRenewal => 1,
Self::VerbalChange => 2,
Self::RepricingOfOrder => 3,
Self::BrokerOption => 4,
Self::PartialDeclineOfOrderQty => 5,
Self::Unrecognized(value) => value,
}
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum BusinessRejectReason {
Other,
UnknownId,
UnknownSecurity,
UnsupportedMessageType,
ApplicationNotAvailable,
ConditionallyRequiredFieldMissing,
Unrecognized(i64),
}
impl BusinessRejectReason {
pub fn from_value(value: i64) -> Self {
match value {
0 => Self::Other,
1 => Self::UnknownId,
2 => Self::UnknownSecurity,
3 => Self::UnsupportedMessageType,
4 => Self::ApplicationNotAvailable,
5 => Self::ConditionallyRequiredFieldMissing,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> i64 {
match self {
Self::Other => 0,
Self::UnknownId => 1,
Self::UnknownSecurity => 2,
Self::UnsupportedMessageType => 3,
Self::ApplicationNotAvailable => 4,
Self::ConditionallyRequiredFieldMissing => 5,
Self::Unrecognized(value) => value,
}
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum MsgDirection<'a> {
Receive,
Send,
Unrecognized(&'a str),
}
impl<'a> MsgDirection<'a> {
pub fn from_value(value: &'a str) -> Self {
match value {
"R" => Self::Receive,
"S" => Self::Send,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> &'a str {
match self {
Self::Receive => "R",
Self::Send => "S",
Self::Unrecognized(value) => value,
}
}
}
impl<'a> From<&'a str> for MsgDirection<'a> {
fn from(value: &'a str) -> Self {
Self::from_value(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum DiscretionInst<'a> {
RelatedToDisplayedPrice,
RelatedToMarketPrice,
RelatedToPrimaryPrice,
RelatedToLocalPrimaryPrice,
RelatedToMidpointPrice,
RelatedToLastTradePrice,
Unrecognized(&'a str),
}
impl<'a> DiscretionInst<'a> {
pub fn from_value(value: &'a str) -> Self {
match value {
"0" => Self::RelatedToDisplayedPrice,
"1" => Self::RelatedToMarketPrice,
"2" => Self::RelatedToPrimaryPrice,
"3" => Self::RelatedToLocalPrimaryPrice,
"4" => Self::RelatedToMidpointPrice,
"5" => Self::RelatedToLastTradePrice,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> &'a str {
match self {
Self::RelatedToDisplayedPrice => "0",
Self::RelatedToMarketPrice => "1",
Self::RelatedToPrimaryPrice => "2",
Self::RelatedToLocalPrimaryPrice => "3",
Self::RelatedToMidpointPrice => "4",
Self::RelatedToLastTradePrice => "5",
Self::Unrecognized(value) => value,
}
}
}
impl<'a> From<&'a str> for DiscretionInst<'a> {
fn from(value: &'a str) -> Self {
Self::from_value(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum LiquidityIndType {
FiveDayMovingAverage,
TwentyDayMovingAverage,
NormalMarketSize,
Other,
Unrecognized(i64),
}
impl LiquidityIndType {
pub fn from_value(value: i64) -> Self {
match value {
1 => Self::FiveDayMovingAverage,
2 => Self::TwentyDayMovingAverage,
3 => Self::NormalMarketSize,
4 => Self::Other,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> i64 {
match self {
Self::FiveDayMovingAverage => 1,
Self::TwentyDayMovingAverage => 2,
Self::NormalMarketSize => 3,
Self::Other => 4,
Self::Unrecognized(value) => value,
}
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum ProgRptReqs {
BuySideRequests,
SellSideSends,
RealTimeExecutionReports,
Unrecognized(i64),
}
impl ProgRptReqs {
pub fn from_value(value: i64) -> Self {
match value {
1 => Self::BuySideRequests,
2 => Self::SellSideSends,
3 => Self::RealTimeExecutionReports,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> i64 {
match self {
Self::BuySideRequests => 1,
Self::SellSideSends => 2,
Self::RealTimeExecutionReports => 3,
Self::Unrecognized(value) => value,
}
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum IncTaxInd {
Net,
Gross,
Unrecognized(i64),
}
impl IncTaxInd {
pub fn from_value(value: i64) -> Self {
match value {
1 => Self::Net,
2 => Self::Gross,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> i64 {
match self {
Self::Net => 1,
Self::Gross => 2,
Self::Unrecognized(value) => value,
}
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum TradeType<'a> {
Agency,
VwapGuarantee,
GuaranteedClose,
RiskTrade,
Unrecognized(&'a str),
}
impl<'a> TradeType<'a> {
pub fn from_value(value: &'a str) -> Self {
match value {
"A" => Self::Agency,
"G" => Self::VwapGuarantee,
"J" => Self::GuaranteedClose,
"R" => Self::RiskTrade,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> &'a str {
match self {
Self::Agency => "A",
Self::VwapGuarantee => "G",
Self::GuaranteedClose => "J",
Self::RiskTrade => "R",
Self::Unrecognized(value) => value,
}
}
}
impl<'a> From<&'a str> for TradeType<'a> {
fn from(value: &'a str) -> Self {
Self::from_value(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum BasisPxType<'a> {
ClosingPriceAtMorningSession,
ClosingPrice,
CurrentPrice,
Sq,
VwapThroughADay,
VwapThroughAMorningSession,
VwapThroughAnAfternoonSession,
VwapThroughADayExcept,
VwapThroughAMorningSessionExcept,
VwapThroughAnAfternoonSessionExcept,
Strike,
Open,
Others,
Unrecognized(&'a str),
}
impl<'a> BasisPxType<'a> {
pub fn from_value(value: &'a str) -> Self {
match value {
"2" => Self::ClosingPriceAtMorningSession,
"3" => Self::ClosingPrice,
"4" => Self::CurrentPrice,
"5" => Self::Sq,
"6" => Self::VwapThroughADay,
"7" => Self::VwapThroughAMorningSession,
"8" => Self::VwapThroughAnAfternoonSession,
"9" => Self::VwapThroughADayExcept,
"A" => Self::VwapThroughAMorningSessionExcept,
"B" => Self::VwapThroughAnAfternoonSessionExcept,
"C" => Self::Strike,
"D" => Self::Open,
"Z" => Self::Others,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> &'a str {
match self {
Self::ClosingPriceAtMorningSession => "2",
Self::ClosingPrice => "3",
Self::CurrentPrice => "4",
Self::Sq => "5",
Self::VwapThroughADay => "6",
Self::VwapThroughAMorningSession => "7",
Self::VwapThroughAnAfternoonSession => "8",
Self::VwapThroughADayExcept => "9",
Self::VwapThroughAMorningSessionExcept => "A",
Self::VwapThroughAnAfternoonSessionExcept => "B",
Self::Strike => "C",
Self::Open => "D",
Self::Others => "Z",
Self::Unrecognized(value) => value,
}
}
}
impl<'a> From<&'a str> for BasisPxType<'a> {
fn from(value: &'a str) -> Self {
Self::from_value(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum PriceType {
Percentage,
PerUnit,
FixedAmount,
Unrecognized(i64),
}
impl PriceType {
pub fn from_value(value: i64) -> Self {
match value {
1 => Self::Percentage,
2 => Self::PerUnit,
3 => Self::FixedAmount,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> i64 {
match self {
Self::Percentage => 1,
Self::PerUnit => 2,
Self::FixedAmount => 3,
Self::Unrecognized(value) => value,
}
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum GTBookingInst {
BookOutAllTradesOnDayOfExecution,
AccumulateUntilFilledOrExpired,
AccumulateUntilVerballlyNotifiedOtherwise,
Unrecognized(i64),
}
impl GTBookingInst {
pub fn from_value(value: i64) -> Self {
match value {
0 => Self::BookOutAllTradesOnDayOfExecution,
1 => Self::AccumulateUntilFilledOrExpired,
2 => Self::AccumulateUntilVerballlyNotifiedOtherwise,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> i64 {
match self {
Self::BookOutAllTradesOnDayOfExecution => 0,
Self::AccumulateUntilFilledOrExpired => 1,
Self::AccumulateUntilVerballlyNotifiedOtherwise => 2,
Self::Unrecognized(value) => value,
}
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum NetGrossInd {
Net,
Gross,
Unrecognized(i64),
}
impl NetGrossInd {
pub fn from_value(value: i64) -> Self {
match value {
1 => Self::Net,
2 => Self::Gross,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> i64 {
match self {
Self::Net => 1,
Self::Gross => 2,
Self::Unrecognized(value) => value,
}
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum ListExecInstType<'a> {
Immediate,
WaitForInstruction,
Unrecognized(&'a str),
}
impl<'a> ListExecInstType<'a> {
pub fn from_value(value: &'a str) -> Self {
match value {
"1" => Self::Immediate,
"2" => Self::WaitForInstruction,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> &'a str {
match self {
Self::Immediate => "1",
Self::WaitForInstruction => "2",
Self::Unrecognized(value) => value,
}
}
}
impl<'a> From<&'a str> for ListExecInstType<'a> {
fn from(value: &'a str) -> Self {
Self::from_value(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum CxlRejResponseTo<'a> {
OrderCancelRequest,
OrderCancel,
Unrecognized(&'a str),
}
impl<'a> CxlRejResponseTo<'a> {
pub fn from_value(value: &'a str) -> Self {
match value {
"1" => Self::OrderCancelRequest,
"2" => Self::OrderCancel,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> &'a str {
match self {
Self::OrderCancelRequest => "1",
Self::OrderCancel => "2",
Self::Unrecognized(value) => value,
}
}
}
impl<'a> From<&'a str> for CxlRejResponseTo<'a> {
fn from(value: &'a str) -> Self {
Self::from_value(value)
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
pub enum MultiLegReportingType<'a> {
SingleSecurity,
IndividualLegOfAMultiLegSecurity,
MultiLegSecurity,
Unrecognized(&'a str),
}
impl<'a> MultiLegReportingType<'a> {
pub fn from_value(value: &'a str) -> Self {
match value {
"1" => Self::SingleSecurity,
"2" => Self::IndividualLegOfAMultiLegSecurity,
"3" => Self::MultiLegSecurity,
unrecognized => Self::Unrecognized(unrecognized),
}
}
pub fn value(self) -> &'a str {
match self {
Self::SingleSecurity => "1",
Self::IndividualLegOfAMultiLegSecurity => "2",
Self::MultiLegSecurity => "3",
Self::Unrecognized(value) => value,
}
}
}
impl<'a> From<&'a str> for MultiLegReportingType<'a> {
fn from(value: &'a str) -> Self {
Self::from_value(value)
}
}
#[derive(Clone, Copy, Debug)]
pub struct Header<'a>(refix_message::Scope<'a>);
impl<'a> From<refix_message::Scope<'a>> for Header<'a> {
fn from(scope: refix_message::Scope<'a>) -> Self {
Self(scope)
}
}
impl<'a> Header<'a> {
pub fn raw(&self) -> refix_message::Scope<'a> {
self.0
}
#[doc(alias = "BeginString")]
pub fn begin_string(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(8))
}
#[doc(alias = "BodyLength")]
pub fn body_length(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(9))
}
#[doc(alias = "MsgType")]
pub fn msg_type(&self) -> Result<Option<MsgType<'a>>, InvalidValue> {
Ok(self.0.get_str(Tag(35))?.map(MsgType::from_value))
}
#[doc(alias = "SenderCompID")]
pub fn sender_comp_id(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(49))
}
#[doc(alias = "TargetCompID")]
pub fn target_comp_id(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(56))
}
#[doc(alias = "OnBehalfOfCompID")]
pub fn on_behalf_of_comp_id(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(115))
}
#[doc(alias = "DeliverToCompID")]
pub fn deliver_to_comp_id(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(128))
}
#[doc(alias = "SecureDataLen")]
pub fn secure_data_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(90))
}
#[doc(alias = "SecureData")]
pub fn secure_data(&self) -> Option<&'a [u8]> {
self.0.get(Tag(91))
}
#[doc(alias = "MsgSeqNum")]
pub fn msg_seq_num(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(34))
}
#[doc(alias = "SenderSubID")]
pub fn sender_sub_id(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(50))
}
#[doc(alias = "SenderLocationID")]
pub fn sender_location_id(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(142))
}
#[doc(alias = "TargetSubID")]
pub fn target_sub_id(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(57))
}
#[doc(alias = "TargetLocationID")]
pub fn target_location_id(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(143))
}
#[doc(alias = "OnBehalfOfSubID")]
pub fn on_behalf_of_sub_id(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(116))
}
#[doc(alias = "OnBehalfOfLocationID")]
pub fn on_behalf_of_location_id(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(144))
}
#[doc(alias = "DeliverToSubID")]
pub fn deliver_to_sub_id(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(129))
}
#[doc(alias = "DeliverToLocationID")]
pub fn deliver_to_location_id(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(145))
}
#[doc(alias = "PossDupFlag")]
pub fn poss_dup_flag(&self) -> Result<Option<bool>, InvalidValue> {
self.0.get_bool(Tag(43))
}
#[doc(alias = "PossResend")]
pub fn poss_resend(&self) -> Result<Option<bool>, InvalidValue> {
self.0.get_bool(Tag(97))
}
#[doc(alias = "SendingTime")]
pub fn sending_time(&self) -> Result<Option<UtcTimestamp>, InvalidValue> {
self.0.get_utc_timestamp(Tag(52))
}
#[doc(alias = "OrigSendingTime")]
pub fn orig_sending_time(&self) -> Result<Option<UtcTimestamp>, InvalidValue> {
self.0.get_utc_timestamp(Tag(122))
}
#[doc(alias = "XmlDataLen")]
pub fn xml_data_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(212))
}
#[doc(alias = "XmlData")]
pub fn xml_data(&self) -> Option<&'a [u8]> {
self.0.get(Tag(213))
}
#[doc(alias = "MessageEncoding")]
pub fn message_encoding(&self) -> Result<Option<MessageEncoding<'a>>, InvalidValue> {
Ok(self.0.get_str(Tag(347))?.map(MessageEncoding::from_value))
}
#[doc(alias = "LastMsgSeqNumProcessed")]
pub fn last_msg_seq_num_processed(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(369))
}
#[doc(alias = "OnBehalfOfSendingTime")]
pub fn on_behalf_of_sending_time(&self) -> Result<Option<UtcTimestamp>, InvalidValue> {
self.0.get_utc_timestamp(Tag(370))
}
}
#[derive(Clone, Copy, Debug)]
pub struct Trailer<'a>(refix_message::Scope<'a>);
impl<'a> From<refix_message::Scope<'a>> for Trailer<'a> {
fn from(scope: refix_message::Scope<'a>) -> Self {
Self(scope)
}
}
impl<'a> Trailer<'a> {
pub fn raw(&self) -> refix_message::Scope<'a> {
self.0
}
#[doc(alias = "SignatureLength")]
pub fn signature_length(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(93))
}
#[doc(alias = "Signature")]
pub fn signature(&self) -> Option<&'a [u8]> {
self.0.get(Tag(89))
}
#[doc(alias = "CheckSum")]
pub fn check_sum(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(10))
}
}
pub struct Heartbeat(RawMessage);
impl Heartbeat {
pub const MSG_TYPE: &[u8] = b"0";
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(8), Tag(9), Tag(10), Tag(34), Tag(35), Tag(43), Tag(49), Tag(50), Tag(52), Tag(56),
Tag(57), Tag(89), Tag(90), Tag(91), Tag(93), Tag(97), Tag(112), Tag(115), Tag(116),
Tag(122), Tag(128), Tag(129), Tag(142), Tag(143), Tag(144), Tag(145), Tag(212), Tag(213),
Tag(347), Tag(369), Tag(370),
]);
pub fn from_raw(raw: RawMessage) -> Self {
Self(raw)
}
pub fn raw(&self) -> &RawMessage {
&self.0
}
pub fn header(&self) -> Header<'_> {
Header(self.0.scope())
}
pub fn trailer(&self) -> Trailer<'_> {
Trailer(self.0.scope())
}
#[doc(alias = "TestReqID")]
pub fn test_req_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(112))
}
}
impl std::fmt::Debug for Heartbeat {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "Heartbeat({})", self.0)
}
}
impl std::fmt::Display for Heartbeat {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
std::fmt::Display::fmt(&self.0, f)
}
}
pub struct TestRequest(RawMessage);
impl TestRequest {
pub const MSG_TYPE: &[u8] = b"1";
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(8), Tag(9), Tag(10), Tag(34), Tag(35), Tag(43), Tag(49), Tag(50), Tag(52), Tag(56),
Tag(57), Tag(89), Tag(90), Tag(91), Tag(93), Tag(97), Tag(112), Tag(115), Tag(116),
Tag(122), Tag(128), Tag(129), Tag(142), Tag(143), Tag(144), Tag(145), Tag(212), Tag(213),
Tag(347), Tag(369), Tag(370),
]);
pub fn from_raw(raw: RawMessage) -> Self {
Self(raw)
}
pub fn raw(&self) -> &RawMessage {
&self.0
}
pub fn header(&self) -> Header<'_> {
Header(self.0.scope())
}
pub fn trailer(&self) -> Trailer<'_> {
Trailer(self.0.scope())
}
#[doc(alias = "TestReqID")]
pub fn test_req_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(112))
}
}
impl std::fmt::Debug for TestRequest {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "TestRequest({})", self.0)
}
}
impl std::fmt::Display for TestRequest {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
std::fmt::Display::fmt(&self.0, f)
}
}
pub struct ResendRequest(RawMessage);
impl ResendRequest {
pub const MSG_TYPE: &[u8] = b"2";
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(7), Tag(8), Tag(9), Tag(10), Tag(16), Tag(34), Tag(35), Tag(43), Tag(49), Tag(50),
Tag(52), Tag(56), Tag(57), Tag(89), Tag(90), Tag(91), Tag(93), Tag(97), Tag(115), Tag(116),
Tag(122), Tag(128), Tag(129), Tag(142), Tag(143), Tag(144), Tag(145), Tag(212), Tag(213),
Tag(347), Tag(369), Tag(370),
]);
pub fn from_raw(raw: RawMessage) -> Self {
Self(raw)
}
pub fn raw(&self) -> &RawMessage {
&self.0
}
pub fn header(&self) -> Header<'_> {
Header(self.0.scope())
}
pub fn trailer(&self) -> Trailer<'_> {
Trailer(self.0.scope())
}
#[doc(alias = "BeginSeqNo")]
pub fn begin_seq_no(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(7))
}
#[doc(alias = "EndSeqNo")]
pub fn end_seq_no(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(16))
}
}
impl std::fmt::Debug for ResendRequest {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "ResendRequest({})", self.0)
}
}
impl std::fmt::Display for ResendRequest {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
std::fmt::Display::fmt(&self.0, f)
}
}
pub struct Reject(RawMessage);
impl Reject {
pub const MSG_TYPE: &[u8] = b"3";
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(8), Tag(9), Tag(10), Tag(34), Tag(35), Tag(43), Tag(45), Tag(49), Tag(50), Tag(52),
Tag(56), Tag(57), Tag(58), Tag(89), Tag(90), Tag(91), Tag(93), Tag(97), Tag(115), Tag(116),
Tag(122), Tag(128), Tag(129), Tag(142), Tag(143), Tag(144), Tag(145), Tag(212), Tag(213),
Tag(347), Tag(354), Tag(355), Tag(369), Tag(370), Tag(371), Tag(372), Tag(373),
]);
pub fn from_raw(raw: RawMessage) -> Self {
Self(raw)
}
pub fn raw(&self) -> &RawMessage {
&self.0
}
pub fn header(&self) -> Header<'_> {
Header(self.0.scope())
}
pub fn trailer(&self) -> Trailer<'_> {
Trailer(self.0.scope())
}
#[doc(alias = "RefSeqNum")]
pub fn ref_seq_num(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(45))
}
#[doc(alias = "RefTagID")]
pub fn ref_tag_id(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(371))
}
#[doc(alias = "RefMsgType")]
pub fn ref_msg_type(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(372))
}
#[doc(alias = "SessionRejectReason")]
pub fn session_reject_reason(&self) -> Result<Option<SessionRejectReason>, InvalidValue> {
Ok(self.0.get_int(Tag(373))?.map(SessionRejectReason::from_value))
}
#[doc(alias = "Text")]
pub fn text(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(58))
}
#[doc(alias = "EncodedTextLen")]
pub fn encoded_text_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(354))
}
#[doc(alias = "EncodedText")]
pub fn encoded_text(&self) -> Option<&[u8]> {
self.0.get(Tag(355))
}
}
impl std::fmt::Debug for Reject {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "Reject({})", self.0)
}
}
impl std::fmt::Display for Reject {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
std::fmt::Display::fmt(&self.0, f)
}
}
pub struct SequenceReset(RawMessage);
impl SequenceReset {
pub const MSG_TYPE: &[u8] = b"4";
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(8), Tag(9), Tag(10), Tag(34), Tag(35), Tag(36), Tag(43), Tag(49), Tag(50), Tag(52),
Tag(56), Tag(57), Tag(89), Tag(90), Tag(91), Tag(93), Tag(97), Tag(115), Tag(116), Tag(122),
Tag(123), Tag(128), Tag(129), Tag(142), Tag(143), Tag(144), Tag(145), Tag(212), Tag(213),
Tag(347), Tag(369), Tag(370),
]);
pub fn from_raw(raw: RawMessage) -> Self {
Self(raw)
}
pub fn raw(&self) -> &RawMessage {
&self.0
}
pub fn header(&self) -> Header<'_> {
Header(self.0.scope())
}
pub fn trailer(&self) -> Trailer<'_> {
Trailer(self.0.scope())
}
#[doc(alias = "GapFillFlag")]
pub fn gap_fill_flag(&self) -> Result<Option<bool>, InvalidValue> {
self.0.get_bool(Tag(123))
}
#[doc(alias = "NewSeqNo")]
pub fn new_seq_no(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(36))
}
}
impl std::fmt::Debug for SequenceReset {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "SequenceReset({})", self.0)
}
}
impl std::fmt::Display for SequenceReset {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
std::fmt::Display::fmt(&self.0, f)
}
}
pub struct Logout(RawMessage);
impl Logout {
pub const MSG_TYPE: &[u8] = b"5";
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(8), Tag(9), Tag(10), Tag(34), Tag(35), Tag(43), Tag(49), Tag(50), Tag(52), Tag(56),
Tag(57), Tag(58), Tag(89), Tag(90), Tag(91), Tag(93), Tag(97), Tag(115), Tag(116), Tag(122),
Tag(128), Tag(129), Tag(142), Tag(143), Tag(144), Tag(145), Tag(212), Tag(213), Tag(347),
Tag(354), Tag(355), Tag(369), Tag(370),
]);
pub fn from_raw(raw: RawMessage) -> Self {
Self(raw)
}
pub fn raw(&self) -> &RawMessage {
&self.0
}
pub fn header(&self) -> Header<'_> {
Header(self.0.scope())
}
pub fn trailer(&self) -> Trailer<'_> {
Trailer(self.0.scope())
}
#[doc(alias = "Text")]
pub fn text(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(58))
}
#[doc(alias = "EncodedTextLen")]
pub fn encoded_text_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(354))
}
#[doc(alias = "EncodedText")]
pub fn encoded_text(&self) -> Option<&[u8]> {
self.0.get(Tag(355))
}
}
impl std::fmt::Debug for Logout {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "Logout({})", self.0)
}
}
impl std::fmt::Display for Logout {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
std::fmt::Display::fmt(&self.0, f)
}
}
pub struct IOI(RawMessage);
impl IOI {
pub const MSG_TYPE: &[u8] = b"6";
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(8), Tag(9), Tag(10), Tag(15), Tag(22), Tag(23), Tag(25), Tag(26), Tag(27), Tag(28),
Tag(34), Tag(35), Tag(43), Tag(44), Tag(48), Tag(49), Tag(50), Tag(52), Tag(54), Tag(55),
Tag(56), Tag(57), Tag(58), Tag(60), Tag(62), Tag(65), Tag(89), Tag(90), Tag(91), Tag(93),
Tag(97), Tag(104), Tag(106), Tag(107), Tag(115), Tag(116), Tag(122), Tag(128), Tag(129),
Tag(130), Tag(142), Tag(143), Tag(144), Tag(145), Tag(149), Tag(167), Tag(199), Tag(200),
Tag(201), Tag(202), Tag(205), Tag(206), Tag(207), Tag(212), Tag(213), Tag(215), Tag(216),
Tag(217), Tag(218), Tag(219), Tag(223), Tag(231), Tag(347), Tag(348), Tag(349), Tag(350),
Tag(351), Tag(354), Tag(355), Tag(369), Tag(370),
]);
pub fn from_raw(raw: RawMessage) -> Self {
Self(raw)
}
pub fn raw(&self) -> &RawMessage {
&self.0
}
pub fn header(&self) -> Header<'_> {
Header(self.0.scope())
}
pub fn trailer(&self) -> Trailer<'_> {
Trailer(self.0.scope())
}
#[doc(alias = "IOIid")]
pub fn io_iid(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(23))
}
#[doc(alias = "IOITransType")]
pub fn ioi_trans_type(&self) -> Result<Option<IOITransType<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(28))?.map(IOITransType::from_value))
}
#[doc(alias = "IOIRefID")]
pub fn ioi_ref_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(26))
}
#[doc(alias = "Symbol")]
pub fn symbol(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(55))
}
#[doc(alias = "SymbolSfx")]
pub fn symbol_sfx(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(65))
}
#[doc(alias = "SecurityID")]
pub fn security_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(48))
}
#[doc(alias = "IDSource")]
pub fn id_source(&self) -> Result<Option<IDSource<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(22))?.map(IDSource::from_value))
}
#[doc(alias = "SecurityType")]
pub fn security_type(&self) -> Result<Option<SecurityType<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(167))?.map(SecurityType::from_value))
}
#[doc(alias = "MaturityMonthYear")]
pub fn maturity_month_year(&self) -> Result<Option<MonthYear>, InvalidValue> {
self.0.get_month_year(Tag(200))
}
#[doc(alias = "MaturityDay")]
pub fn maturity_day(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(205))
}
#[doc(alias = "PutOrCall")]
pub fn put_or_call(&self) -> Result<Option<PutOrCall>, InvalidValue> {
Ok(self.0.get_int(Tag(201))?.map(PutOrCall::from_value))
}
#[doc(alias = "StrikePrice")]
pub fn strike_price(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(202))
}
#[doc(alias = "OptAttribute")]
pub fn opt_attribute(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(206))
}
#[doc(alias = "ContractMultiplier")]
pub fn contract_multiplier(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(231))
}
#[doc(alias = "CouponRate")]
pub fn coupon_rate(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(223))
}
#[doc(alias = "SecurityExchange")]
pub fn security_exchange(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(207))
}
#[doc(alias = "Issuer")]
pub fn issuer(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(106))
}
#[doc(alias = "EncodedIssuerLen")]
pub fn encoded_issuer_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(348))
}
#[doc(alias = "EncodedIssuer")]
pub fn encoded_issuer(&self) -> Option<&[u8]> {
self.0.get(Tag(349))
}
#[doc(alias = "SecurityDesc")]
pub fn security_desc(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(107))
}
#[doc(alias = "EncodedSecurityDescLen")]
pub fn encoded_security_desc_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(350))
}
#[doc(alias = "EncodedSecurityDesc")]
pub fn encoded_security_desc(&self) -> Option<&[u8]> {
self.0.get(Tag(351))
}
#[doc(alias = "Side")]
pub fn side(&self) -> Result<Option<Side<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(54))?.map(Side::from_value))
}
#[doc(alias = "IOIShares")]
pub fn ioi_shares(&self) -> Result<Option<IOIShares<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(27))?.map(IOIShares::from_value))
}
#[doc(alias = "Price")]
pub fn price(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(44))
}
#[doc(alias = "Currency")]
pub fn currency(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(15))
}
#[doc(alias = "ValidUntilTime")]
pub fn valid_until_time(&self) -> Result<Option<UtcTimestamp>, InvalidValue> {
self.0.get_utc_timestamp(Tag(62))
}
#[doc(alias = "IOIQltyInd")]
pub fn ioi_qlty_ind(&self) -> Result<Option<IOIQltyInd<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(25))?.map(IOIQltyInd::from_value))
}
#[doc(alias = "IOINaturalFlag")]
pub fn ioi_natural_flag(&self) -> Result<Option<bool>, InvalidValue> {
self.0.get_bool(Tag(130))
}
#[doc(alias = "NoIOIQualifiers")]
pub fn ioi_qualifiers(&self) -> Result<Instances<'_, ioi::ioi_qualifiers::Instance<'_>>, InvalidValue> {
self.0.get_group(&ioi::ioi_qualifiers::TABLE, &Self::KNOWN_TAGS).map(Instances::from)
}
#[doc(alias = "Text")]
pub fn text(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(58))
}
#[doc(alias = "EncodedTextLen")]
pub fn encoded_text_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(354))
}
#[doc(alias = "EncodedText")]
pub fn encoded_text(&self) -> Option<&[u8]> {
self.0.get(Tag(355))
}
#[doc(alias = "TransactTime")]
pub fn transact_time(&self) -> Result<Option<UtcTimestamp>, InvalidValue> {
self.0.get_utc_timestamp(Tag(60))
}
#[doc(alias = "URLLink")]
pub fn url_link(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(149))
}
#[doc(alias = "NoRoutingIDs")]
pub fn routing_ids(&self) -> Result<Instances<'_, ioi::routing_ids::Instance<'_>>, InvalidValue> {
self.0.get_group(&ioi::routing_ids::TABLE, &Self::KNOWN_TAGS).map(Instances::from)
}
#[doc(alias = "SpreadToBenchmark")]
pub fn spread_to_benchmark(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(218))
}
#[doc(alias = "Benchmark")]
pub fn benchmark(&self) -> Result<Option<Benchmark<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(219))?.map(Benchmark::from_value))
}
}
impl std::fmt::Debug for IOI {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "IOI({})", self.0)
}
}
impl std::fmt::Display for IOI {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
std::fmt::Display::fmt(&self.0, f)
}
}
pub mod ioi {
pub mod ioi_qualifiers {
use super::super::*;
pub const TABLE: GroupTable<'static> = GroupTable::new(
Tag(199),
Tag(104),
&[Tag(104)],
&[],
);
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[Tag(104)]);
#[derive(Clone, Copy, Debug)]
pub struct Instance<'a>(refix_message::Scope<'a>);
impl<'a> From<refix_message::Scope<'a>> for Instance<'a> {
fn from(scope: refix_message::Scope<'a>) -> Self {
Self(scope)
}
}
impl<'a> Instance<'a> {
pub fn raw(&self) -> refix_message::Scope<'a> {
self.0
}
#[doc(alias = "IOIQualifier")]
pub fn ioi_qualifier(&self) -> Result<Option<IOIQualifier<'a>>, InvalidValue> {
Ok(self.0.get_str(Tag(104))?.map(IOIQualifier::from_value))
}
}
}
pub mod routing_ids {
use super::super::*;
pub const TABLE: GroupTable<'static> = GroupTable::new(
Tag(215),
Tag(216),
&[Tag(216), Tag(217)],
&[],
);
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[Tag(216), Tag(217)]);
#[derive(Clone, Copy, Debug)]
pub struct Instance<'a>(refix_message::Scope<'a>);
impl<'a> From<refix_message::Scope<'a>> for Instance<'a> {
fn from(scope: refix_message::Scope<'a>) -> Self {
Self(scope)
}
}
impl<'a> Instance<'a> {
pub fn raw(&self) -> refix_message::Scope<'a> {
self.0
}
#[doc(alias = "RoutingType")]
pub fn routing_type(&self) -> Result<Option<RoutingType>, InvalidValue> {
Ok(self.0.get_int(Tag(216))?.map(RoutingType::from_value))
}
#[doc(alias = "RoutingID")]
pub fn routing_id(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(217))
}
}
}
}
pub struct Advertisement(RawMessage);
impl Advertisement {
pub const MSG_TYPE: &[u8] = b"7";
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(2), Tag(3), Tag(4), Tag(5), Tag(8), Tag(9), Tag(10), Tag(15), Tag(22), Tag(30), Tag(34),
Tag(35), Tag(43), Tag(44), Tag(48), Tag(49), Tag(50), Tag(52), Tag(53), Tag(55), Tag(56),
Tag(57), Tag(58), Tag(60), Tag(65), Tag(75), Tag(89), Tag(90), Tag(91), Tag(93), Tag(97),
Tag(106), Tag(107), Tag(115), Tag(116), Tag(122), Tag(128), Tag(129), Tag(142), Tag(143),
Tag(144), Tag(145), Tag(149), Tag(167), Tag(200), Tag(201), Tag(202), Tag(205), Tag(206),
Tag(207), Tag(212), Tag(213), Tag(223), Tag(231), Tag(336), Tag(347), Tag(348), Tag(349),
Tag(350), Tag(351), Tag(354), Tag(355), Tag(369), Tag(370),
]);
pub fn from_raw(raw: RawMessage) -> Self {
Self(raw)
}
pub fn raw(&self) -> &RawMessage {
&self.0
}
pub fn header(&self) -> Header<'_> {
Header(self.0.scope())
}
pub fn trailer(&self) -> Trailer<'_> {
Trailer(self.0.scope())
}
#[doc(alias = "AdvId")]
pub fn adv_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(2))
}
#[doc(alias = "AdvTransType")]
pub fn adv_trans_type(&self) -> Result<Option<AdvTransType<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(5))?.map(AdvTransType::from_value))
}
#[doc(alias = "AdvRefID")]
pub fn adv_ref_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(3))
}
#[doc(alias = "Symbol")]
pub fn symbol(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(55))
}
#[doc(alias = "SymbolSfx")]
pub fn symbol_sfx(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(65))
}
#[doc(alias = "SecurityID")]
pub fn security_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(48))
}
#[doc(alias = "IDSource")]
pub fn id_source(&self) -> Result<Option<IDSource<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(22))?.map(IDSource::from_value))
}
#[doc(alias = "SecurityType")]
pub fn security_type(&self) -> Result<Option<SecurityType<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(167))?.map(SecurityType::from_value))
}
#[doc(alias = "MaturityMonthYear")]
pub fn maturity_month_year(&self) -> Result<Option<MonthYear>, InvalidValue> {
self.0.get_month_year(Tag(200))
}
#[doc(alias = "MaturityDay")]
pub fn maturity_day(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(205))
}
#[doc(alias = "PutOrCall")]
pub fn put_or_call(&self) -> Result<Option<PutOrCall>, InvalidValue> {
Ok(self.0.get_int(Tag(201))?.map(PutOrCall::from_value))
}
#[doc(alias = "StrikePrice")]
pub fn strike_price(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(202))
}
#[doc(alias = "OptAttribute")]
pub fn opt_attribute(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(206))
}
#[doc(alias = "ContractMultiplier")]
pub fn contract_multiplier(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(231))
}
#[doc(alias = "CouponRate")]
pub fn coupon_rate(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(223))
}
#[doc(alias = "SecurityExchange")]
pub fn security_exchange(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(207))
}
#[doc(alias = "Issuer")]
pub fn issuer(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(106))
}
#[doc(alias = "EncodedIssuerLen")]
pub fn encoded_issuer_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(348))
}
#[doc(alias = "EncodedIssuer")]
pub fn encoded_issuer(&self) -> Option<&[u8]> {
self.0.get(Tag(349))
}
#[doc(alias = "SecurityDesc")]
pub fn security_desc(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(107))
}
#[doc(alias = "EncodedSecurityDescLen")]
pub fn encoded_security_desc_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(350))
}
#[doc(alias = "EncodedSecurityDesc")]
pub fn encoded_security_desc(&self) -> Option<&[u8]> {
self.0.get(Tag(351))
}
#[doc(alias = "AdvSide")]
pub fn adv_side(&self) -> Result<Option<AdvSide<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(4))?.map(AdvSide::from_value))
}
#[doc(alias = "Shares")]
pub fn shares(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(53))
}
#[doc(alias = "Price")]
pub fn price(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(44))
}
#[doc(alias = "Currency")]
pub fn currency(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(15))
}
#[doc(alias = "TradeDate")]
pub fn trade_date(&self) -> Result<Option<Date>, InvalidValue> {
self.0.get_date(Tag(75))
}
#[doc(alias = "TransactTime")]
pub fn transact_time(&self) -> Result<Option<UtcTimestamp>, InvalidValue> {
self.0.get_utc_timestamp(Tag(60))
}
#[doc(alias = "Text")]
pub fn text(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(58))
}
#[doc(alias = "EncodedTextLen")]
pub fn encoded_text_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(354))
}
#[doc(alias = "EncodedText")]
pub fn encoded_text(&self) -> Option<&[u8]> {
self.0.get(Tag(355))
}
#[doc(alias = "URLLink")]
pub fn url_link(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(149))
}
#[doc(alias = "LastMkt")]
pub fn last_mkt(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(30))
}
#[doc(alias = "TradingSessionID")]
pub fn trading_session_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(336))
}
}
impl std::fmt::Debug for Advertisement {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "Advertisement({})", self.0)
}
}
impl std::fmt::Display for Advertisement {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
std::fmt::Display::fmt(&self.0, f)
}
}
pub struct ExecutionReport(RawMessage);
impl ExecutionReport {
pub const MSG_TYPE: &[u8] = b"8";
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(1), Tag(6), Tag(8), Tag(9), Tag(10), Tag(11), Tag(12), Tag(13), Tag(14), Tag(15),
Tag(17), Tag(18), Tag(19), Tag(20), Tag(21), Tag(22), Tag(29), Tag(30), Tag(31), Tag(32),
Tag(34), Tag(35), Tag(37), Tag(38), Tag(39), Tag(40), Tag(41), Tag(43), Tag(44), Tag(47),
Tag(48), Tag(49), Tag(50), Tag(52), Tag(54), Tag(55), Tag(56), Tag(57), Tag(58), Tag(59),
Tag(60), Tag(63), Tag(64), Tag(65), Tag(66), Tag(75), Tag(76), Tag(77), Tag(89), Tag(90),
Tag(91), Tag(93), Tag(97), Tag(99), Tag(103), Tag(106), Tag(107), Tag(109), Tag(110),
Tag(111), Tag(113), Tag(115), Tag(116), Tag(119), Tag(120), Tag(122), Tag(126), Tag(128),
Tag(129), Tag(142), Tag(143), Tag(144), Tag(145), Tag(150), Tag(151), Tag(152), Tag(155),
Tag(156), Tag(167), Tag(168), Tag(192), Tag(193), Tag(194), Tag(195), Tag(198), Tag(200),
Tag(201), Tag(202), Tag(205), Tag(206), Tag(207), Tag(210), Tag(211), Tag(212), Tag(213),
Tag(223), Tag(231), Tag(336), Tag(337), Tag(347), Tag(348), Tag(349), Tag(350), Tag(351),
Tag(354), Tag(355), Tag(369), Tag(370), Tag(375), Tag(376), Tag(377), Tag(378), Tag(381),
Tag(382), Tag(388), Tag(389), Tag(424), Tag(425), Tag(426), Tag(427), Tag(432), Tag(437),
Tag(438), Tag(439), Tag(440), Tag(442),
]);
pub fn from_raw(raw: RawMessage) -> Self {
Self(raw)
}
pub fn raw(&self) -> &RawMessage {
&self.0
}
pub fn header(&self) -> Header<'_> {
Header(self.0.scope())
}
pub fn trailer(&self) -> Trailer<'_> {
Trailer(self.0.scope())
}
#[doc(alias = "OrderID")]
pub fn order_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(37))
}
#[doc(alias = "SecondaryOrderID")]
pub fn secondary_order_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(198))
}
#[doc(alias = "ClOrdID")]
pub fn cl_ord_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(11))
}
#[doc(alias = "OrigClOrdID")]
pub fn orig_cl_ord_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(41))
}
#[doc(alias = "ClientID")]
pub fn client_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(109))
}
#[doc(alias = "ExecBroker")]
pub fn exec_broker(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(76))
}
#[doc(alias = "NoContraBrokers")]
pub fn contra_brokers(&self) -> Result<Instances<'_, execution_report::contra_brokers::Instance<'_>>, InvalidValue> {
self.0.get_group(&execution_report::contra_brokers::TABLE, &Self::KNOWN_TAGS).map(Instances::from)
}
#[doc(alias = "ListID")]
pub fn list_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(66))
}
#[doc(alias = "ExecID")]
pub fn exec_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(17))
}
#[doc(alias = "ExecTransType")]
pub fn exec_trans_type(&self) -> Result<Option<ExecTransType<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(20))?.map(ExecTransType::from_value))
}
#[doc(alias = "ExecRefID")]
pub fn exec_ref_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(19))
}
#[doc(alias = "ExecType")]
pub fn exec_type(&self) -> Result<Option<ExecType<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(150))?.map(ExecType::from_value))
}
#[doc(alias = "OrdStatus")]
pub fn ord_status(&self) -> Result<Option<OrdStatus<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(39))?.map(OrdStatus::from_value))
}
#[doc(alias = "OrdRejReason")]
pub fn ord_rej_reason(&self) -> Result<Option<OrdRejReason>, InvalidValue> {
Ok(self.0.get_int(Tag(103))?.map(OrdRejReason::from_value))
}
#[doc(alias = "ExecRestatementReason")]
pub fn exec_restatement_reason(&self) -> Result<Option<ExecRestatementReason>, InvalidValue> {
Ok(self.0.get_int(Tag(378))?.map(ExecRestatementReason::from_value))
}
#[doc(alias = "Account")]
pub fn account(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(1))
}
#[doc(alias = "SettlmntTyp")]
pub fn settlmnt_typ(&self) -> Result<Option<SettlmntTyp<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(63))?.map(SettlmntTyp::from_value))
}
#[doc(alias = "FutSettDate")]
pub fn fut_sett_date(&self) -> Result<Option<Date>, InvalidValue> {
self.0.get_date(Tag(64))
}
#[doc(alias = "Symbol")]
pub fn symbol(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(55))
}
#[doc(alias = "SymbolSfx")]
pub fn symbol_sfx(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(65))
}
#[doc(alias = "SecurityID")]
pub fn security_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(48))
}
#[doc(alias = "IDSource")]
pub fn id_source(&self) -> Result<Option<IDSource<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(22))?.map(IDSource::from_value))
}
#[doc(alias = "SecurityType")]
pub fn security_type(&self) -> Result<Option<SecurityType<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(167))?.map(SecurityType::from_value))
}
#[doc(alias = "MaturityMonthYear")]
pub fn maturity_month_year(&self) -> Result<Option<MonthYear>, InvalidValue> {
self.0.get_month_year(Tag(200))
}
#[doc(alias = "MaturityDay")]
pub fn maturity_day(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(205))
}
#[doc(alias = "PutOrCall")]
pub fn put_or_call(&self) -> Result<Option<PutOrCall>, InvalidValue> {
Ok(self.0.get_int(Tag(201))?.map(PutOrCall::from_value))
}
#[doc(alias = "StrikePrice")]
pub fn strike_price(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(202))
}
#[doc(alias = "OptAttribute")]
pub fn opt_attribute(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(206))
}
#[doc(alias = "ContractMultiplier")]
pub fn contract_multiplier(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(231))
}
#[doc(alias = "CouponRate")]
pub fn coupon_rate(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(223))
}
#[doc(alias = "SecurityExchange")]
pub fn security_exchange(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(207))
}
#[doc(alias = "Issuer")]
pub fn issuer(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(106))
}
#[doc(alias = "EncodedIssuerLen")]
pub fn encoded_issuer_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(348))
}
#[doc(alias = "EncodedIssuer")]
pub fn encoded_issuer(&self) -> Option<&[u8]> {
self.0.get(Tag(349))
}
#[doc(alias = "SecurityDesc")]
pub fn security_desc(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(107))
}
#[doc(alias = "EncodedSecurityDescLen")]
pub fn encoded_security_desc_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(350))
}
#[doc(alias = "EncodedSecurityDesc")]
pub fn encoded_security_desc(&self) -> Option<&[u8]> {
self.0.get(Tag(351))
}
#[doc(alias = "Side")]
pub fn side(&self) -> Result<Option<Side<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(54))?.map(Side::from_value))
}
#[doc(alias = "OrderQty")]
pub fn order_qty(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(38))
}
#[doc(alias = "CashOrderQty")]
pub fn cash_order_qty(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(152))
}
#[doc(alias = "OrdType")]
pub fn ord_type(&self) -> Result<Option<OrdType<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(40))?.map(OrdType::from_value))
}
#[doc(alias = "Price")]
pub fn price(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(44))
}
#[doc(alias = "StopPx")]
pub fn stop_px(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(99))
}
#[doc(alias = "PegDifference")]
pub fn peg_difference(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(211))
}
#[doc(alias = "DiscretionInst")]
pub fn discretion_inst(&self) -> Result<Option<DiscretionInst<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(388))?.map(DiscretionInst::from_value))
}
#[doc(alias = "DiscretionOffset")]
pub fn discretion_offset(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(389))
}
#[doc(alias = "Currency")]
pub fn currency(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(15))
}
#[doc(alias = "ComplianceID")]
pub fn compliance_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(376))
}
#[doc(alias = "SolicitedFlag")]
pub fn solicited_flag(&self) -> Result<Option<bool>, InvalidValue> {
self.0.get_bool(Tag(377))
}
#[doc(alias = "TimeInForce")]
pub fn time_in_force(&self) -> Result<Option<TimeInForce<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(59))?.map(TimeInForce::from_value))
}
#[doc(alias = "EffectiveTime")]
pub fn effective_time(&self) -> Result<Option<UtcTimestamp>, InvalidValue> {
self.0.get_utc_timestamp(Tag(168))
}
#[doc(alias = "ExpireDate")]
pub fn expire_date(&self) -> Result<Option<Date>, InvalidValue> {
self.0.get_date(Tag(432))
}
#[doc(alias = "ExpireTime")]
pub fn expire_time(&self) -> Result<Option<UtcTimestamp>, InvalidValue> {
self.0.get_utc_timestamp(Tag(126))
}
#[doc(alias = "ExecInst")]
pub fn exec_inst(&self) -> Result<Option<MultipleValues<'_, ExecInst<'_>>>, InvalidValue> {
self.0.get_multiple_values(Tag(18))
}
#[doc(alias = "Rule80A")]
pub fn rule80_a(&self) -> Result<Option<Rule80A<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(47))?.map(Rule80A::from_value))
}
#[doc(alias = "LastShares")]
pub fn last_shares(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(32))
}
#[doc(alias = "LastPx")]
pub fn last_px(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(31))
}
#[doc(alias = "LastSpotRate")]
pub fn last_spot_rate(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(194))
}
#[doc(alias = "LastForwardPoints")]
pub fn last_forward_points(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(195))
}
#[doc(alias = "LastMkt")]
pub fn last_mkt(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(30))
}
#[doc(alias = "TradingSessionID")]
pub fn trading_session_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(336))
}
#[doc(alias = "LastCapacity")]
pub fn last_capacity(&self) -> Result<Option<LastCapacity<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(29))?.map(LastCapacity::from_value))
}
#[doc(alias = "LeavesQty")]
pub fn leaves_qty(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(151))
}
#[doc(alias = "CumQty")]
pub fn cum_qty(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(14))
}
#[doc(alias = "AvgPx")]
pub fn avg_px(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(6))
}
#[doc(alias = "DayOrderQty")]
pub fn day_order_qty(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(424))
}
#[doc(alias = "DayCumQty")]
pub fn day_cum_qty(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(425))
}
#[doc(alias = "DayAvgPx")]
pub fn day_avg_px(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(426))
}
#[doc(alias = "GTBookingInst")]
pub fn gt_booking_inst(&self) -> Result<Option<GTBookingInst>, InvalidValue> {
Ok(self.0.get_int(Tag(427))?.map(GTBookingInst::from_value))
}
#[doc(alias = "TradeDate")]
pub fn trade_date(&self) -> Result<Option<Date>, InvalidValue> {
self.0.get_date(Tag(75))
}
#[doc(alias = "TransactTime")]
pub fn transact_time(&self) -> Result<Option<UtcTimestamp>, InvalidValue> {
self.0.get_utc_timestamp(Tag(60))
}
#[doc(alias = "ReportToExch")]
pub fn report_to_exch(&self) -> Result<Option<bool>, InvalidValue> {
self.0.get_bool(Tag(113))
}
#[doc(alias = "Commission")]
pub fn commission(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(12))
}
#[doc(alias = "CommType")]
pub fn comm_type(&self) -> Result<Option<CommType<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(13))?.map(CommType::from_value))
}
#[doc(alias = "GrossTradeAmt")]
pub fn gross_trade_amt(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(381))
}
#[doc(alias = "SettlCurrAmt")]
pub fn settl_curr_amt(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(119))
}
#[doc(alias = "SettlCurrency")]
pub fn settl_currency(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(120))
}
#[doc(alias = "SettlCurrFxRate")]
pub fn settl_curr_fx_rate(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(155))
}
#[doc(alias = "SettlCurrFxRateCalc")]
pub fn settl_curr_fx_rate_calc(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(156))
}
#[doc(alias = "HandlInst")]
pub fn handl_inst(&self) -> Result<Option<HandlInst<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(21))?.map(HandlInst::from_value))
}
#[doc(alias = "MinQty")]
pub fn min_qty(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(110))
}
#[doc(alias = "MaxFloor")]
pub fn max_floor(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(111))
}
#[doc(alias = "OpenClose")]
pub fn open_close(&self) -> Result<Option<OpenClose<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(77))?.map(OpenClose::from_value))
}
#[doc(alias = "MaxShow")]
pub fn max_show(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(210))
}
#[doc(alias = "Text")]
pub fn text(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(58))
}
#[doc(alias = "EncodedTextLen")]
pub fn encoded_text_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(354))
}
#[doc(alias = "EncodedText")]
pub fn encoded_text(&self) -> Option<&[u8]> {
self.0.get(Tag(355))
}
#[doc(alias = "FutSettDate2")]
pub fn fut_sett_date2(&self) -> Result<Option<Date>, InvalidValue> {
self.0.get_date(Tag(193))
}
#[doc(alias = "OrderQty2")]
pub fn order_qty2(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(192))
}
#[doc(alias = "ClearingFirm")]
pub fn clearing_firm(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(439))
}
#[doc(alias = "ClearingAccount")]
pub fn clearing_account(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(440))
}
#[doc(alias = "MultiLegReportingType")]
pub fn multi_leg_reporting_type(&self) -> Result<Option<MultiLegReportingType<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(442))?.map(MultiLegReportingType::from_value))
}
}
impl std::fmt::Debug for ExecutionReport {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "ExecutionReport({})", self.0)
}
}
impl std::fmt::Display for ExecutionReport {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
std::fmt::Display::fmt(&self.0, f)
}
}
pub mod execution_report {
pub mod contra_brokers {
use super::super::*;
pub const TABLE: GroupTable<'static> = GroupTable::new(
Tag(382),
Tag(375),
&[Tag(337), Tag(375), Tag(437), Tag(438)],
&[],
);
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(337), Tag(375), Tag(437), Tag(438),
]);
#[derive(Clone, Copy, Debug)]
pub struct Instance<'a>(refix_message::Scope<'a>);
impl<'a> From<refix_message::Scope<'a>> for Instance<'a> {
fn from(scope: refix_message::Scope<'a>) -> Self {
Self(scope)
}
}
impl<'a> Instance<'a> {
pub fn raw(&self) -> refix_message::Scope<'a> {
self.0
}
#[doc(alias = "ContraBroker")]
pub fn contra_broker(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(375))
}
#[doc(alias = "ContraTrader")]
pub fn contra_trader(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(337))
}
#[doc(alias = "ContraTradeQty")]
pub fn contra_trade_qty(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(437))
}
#[doc(alias = "ContraTradeTime")]
pub fn contra_trade_time(&self) -> Result<Option<UtcTimestamp>, InvalidValue> {
self.0.get_utc_timestamp(Tag(438))
}
}
}
}
pub struct OrderCancelReject(RawMessage);
impl OrderCancelReject {
pub const MSG_TYPE: &[u8] = b"9";
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(1), Tag(8), Tag(9), Tag(10), Tag(11), Tag(34), Tag(35), Tag(37), Tag(39), Tag(41),
Tag(43), Tag(49), Tag(50), Tag(52), Tag(56), Tag(57), Tag(58), Tag(60), Tag(66), Tag(76),
Tag(89), Tag(90), Tag(91), Tag(93), Tag(97), Tag(102), Tag(109), Tag(115), Tag(116),
Tag(122), Tag(128), Tag(129), Tag(142), Tag(143), Tag(144), Tag(145), Tag(198), Tag(212),
Tag(213), Tag(347), Tag(354), Tag(355), Tag(369), Tag(370), Tag(434),
]);
pub fn from_raw(raw: RawMessage) -> Self {
Self(raw)
}
pub fn raw(&self) -> &RawMessage {
&self.0
}
pub fn header(&self) -> Header<'_> {
Header(self.0.scope())
}
pub fn trailer(&self) -> Trailer<'_> {
Trailer(self.0.scope())
}
#[doc(alias = "OrderID")]
pub fn order_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(37))
}
#[doc(alias = "SecondaryOrderID")]
pub fn secondary_order_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(198))
}
#[doc(alias = "ClOrdID")]
pub fn cl_ord_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(11))
}
#[doc(alias = "OrigClOrdID")]
pub fn orig_cl_ord_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(41))
}
#[doc(alias = "OrdStatus")]
pub fn ord_status(&self) -> Result<Option<OrdStatus<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(39))?.map(OrdStatus::from_value))
}
#[doc(alias = "ClientID")]
pub fn client_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(109))
}
#[doc(alias = "ExecBroker")]
pub fn exec_broker(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(76))
}
#[doc(alias = "ListID")]
pub fn list_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(66))
}
#[doc(alias = "Account")]
pub fn account(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(1))
}
#[doc(alias = "TransactTime")]
pub fn transact_time(&self) -> Result<Option<UtcTimestamp>, InvalidValue> {
self.0.get_utc_timestamp(Tag(60))
}
#[doc(alias = "CxlRejResponseTo")]
pub fn cxl_rej_response_to(&self) -> Result<Option<CxlRejResponseTo<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(434))?.map(CxlRejResponseTo::from_value))
}
#[doc(alias = "CxlRejReason")]
pub fn cxl_rej_reason(&self) -> Result<Option<CxlRejReason>, InvalidValue> {
Ok(self.0.get_int(Tag(102))?.map(CxlRejReason::from_value))
}
#[doc(alias = "Text")]
pub fn text(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(58))
}
#[doc(alias = "EncodedTextLen")]
pub fn encoded_text_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(354))
}
#[doc(alias = "EncodedText")]
pub fn encoded_text(&self) -> Option<&[u8]> {
self.0.get(Tag(355))
}
}
impl std::fmt::Debug for OrderCancelReject {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "OrderCancelReject({})", self.0)
}
}
impl std::fmt::Display for OrderCancelReject {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
std::fmt::Display::fmt(&self.0, f)
}
}
pub struct Logon(RawMessage);
impl Logon {
pub const MSG_TYPE: &[u8] = b"A";
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(8), Tag(9), Tag(10), Tag(34), Tag(35), Tag(43), Tag(49), Tag(50), Tag(52), Tag(56),
Tag(57), Tag(89), Tag(90), Tag(91), Tag(93), Tag(95), Tag(96), Tag(97), Tag(98), Tag(108),
Tag(115), Tag(116), Tag(122), Tag(128), Tag(129), Tag(141), Tag(142), Tag(143), Tag(144),
Tag(145), Tag(212), Tag(213), Tag(347), Tag(369), Tag(370), Tag(372), Tag(383), Tag(384),
Tag(385),
]);
pub fn from_raw(raw: RawMessage) -> Self {
Self(raw)
}
pub fn raw(&self) -> &RawMessage {
&self.0
}
pub fn header(&self) -> Header<'_> {
Header(self.0.scope())
}
pub fn trailer(&self) -> Trailer<'_> {
Trailer(self.0.scope())
}
#[doc(alias = "EncryptMethod")]
pub fn encrypt_method(&self) -> Result<Option<EncryptMethod>, InvalidValue> {
Ok(self.0.get_int(Tag(98))?.map(EncryptMethod::from_value))
}
#[doc(alias = "HeartBtInt")]
pub fn heart_bt_int(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(108))
}
#[doc(alias = "RawDataLength")]
pub fn raw_data_length(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(95))
}
#[doc(alias = "RawData")]
pub fn raw_data(&self) -> Option<&[u8]> {
self.0.get(Tag(96))
}
#[doc(alias = "ResetSeqNumFlag")]
pub fn reset_seq_num_flag(&self) -> Result<Option<bool>, InvalidValue> {
self.0.get_bool(Tag(141))
}
#[doc(alias = "MaxMessageSize")]
pub fn max_message_size(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(383))
}
#[doc(alias = "NoMsgTypes")]
pub fn msg_types(&self) -> Result<Instances<'_, logon::msg_types::Instance<'_>>, InvalidValue> {
self.0.get_group(&logon::msg_types::TABLE, &Self::KNOWN_TAGS).map(Instances::from)
}
}
impl std::fmt::Debug for Logon {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "Logon({})", self.0)
}
}
impl std::fmt::Display for Logon {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
std::fmt::Display::fmt(&self.0, f)
}
}
pub mod logon {
pub mod msg_types {
use super::super::*;
pub const TABLE: GroupTable<'static> = GroupTable::new(
Tag(384),
Tag(372),
&[Tag(372), Tag(385)],
&[],
);
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[Tag(372), Tag(385)]);
#[derive(Clone, Copy, Debug)]
pub struct Instance<'a>(refix_message::Scope<'a>);
impl<'a> From<refix_message::Scope<'a>> for Instance<'a> {
fn from(scope: refix_message::Scope<'a>) -> Self {
Self(scope)
}
}
impl<'a> Instance<'a> {
pub fn raw(&self) -> refix_message::Scope<'a> {
self.0
}
#[doc(alias = "RefMsgType")]
pub fn ref_msg_type(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(372))
}
#[doc(alias = "MsgDirection")]
pub fn msg_direction(&self) -> Result<Option<MsgDirection<'a>>, InvalidValue> {
Ok(self.0.get_str(Tag(385))?.map(MsgDirection::from_value))
}
}
}
}
pub struct News(RawMessage);
impl News {
pub const MSG_TYPE: &[u8] = b"B";
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(8), Tag(9), Tag(10), Tag(22), Tag(33), Tag(34), Tag(35), Tag(42), Tag(43), Tag(46),
Tag(48), Tag(49), Tag(50), Tag(52), Tag(56), Tag(57), Tag(58), Tag(61), Tag(65), Tag(89),
Tag(90), Tag(91), Tag(93), Tag(95), Tag(96), Tag(97), Tag(106), Tag(107), Tag(115),
Tag(116), Tag(122), Tag(128), Tag(129), Tag(142), Tag(143), Tag(144), Tag(145), Tag(146),
Tag(148), Tag(149), Tag(167), Tag(200), Tag(201), Tag(202), Tag(205), Tag(206), Tag(207),
Tag(212), Tag(213), Tag(215), Tag(216), Tag(217), Tag(223), Tag(231), Tag(347), Tag(348),
Tag(349), Tag(350), Tag(351), Tag(354), Tag(355), Tag(358), Tag(359), Tag(369), Tag(370),
]);
pub fn from_raw(raw: RawMessage) -> Self {
Self(raw)
}
pub fn raw(&self) -> &RawMessage {
&self.0
}
pub fn header(&self) -> Header<'_> {
Header(self.0.scope())
}
pub fn trailer(&self) -> Trailer<'_> {
Trailer(self.0.scope())
}
#[doc(alias = "OrigTime")]
pub fn orig_time(&self) -> Result<Option<UtcTimestamp>, InvalidValue> {
self.0.get_utc_timestamp(Tag(42))
}
#[doc(alias = "Urgency")]
pub fn urgency(&self) -> Result<Option<Urgency<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(61))?.map(Urgency::from_value))
}
#[doc(alias = "Headline")]
pub fn headline(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(148))
}
#[doc(alias = "EncodedHeadlineLen")]
pub fn encoded_headline_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(358))
}
#[doc(alias = "EncodedHeadline")]
pub fn encoded_headline(&self) -> Option<&[u8]> {
self.0.get(Tag(359))
}
#[doc(alias = "NoRoutingIDs")]
pub fn routing_ids(&self) -> Result<Instances<'_, news::routing_ids::Instance<'_>>, InvalidValue> {
self.0.get_group(&news::routing_ids::TABLE, &Self::KNOWN_TAGS).map(Instances::from)
}
#[doc(alias = "NoRelatedSym")]
pub fn related_sym(&self) -> Result<Instances<'_, news::related_sym::Instance<'_>>, InvalidValue> {
self.0.get_group(&news::related_sym::TABLE, &Self::KNOWN_TAGS).map(Instances::from)
}
#[doc(alias = "LinesOfText")]
pub fn lines_of_text(&self) -> Result<Instances<'_, news::lines_of_text::Instance<'_>>, InvalidValue> {
self.0.get_group(&news::lines_of_text::TABLE, &Self::KNOWN_TAGS).map(Instances::from)
}
#[doc(alias = "URLLink")]
pub fn url_link(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(149))
}
#[doc(alias = "RawDataLength")]
pub fn raw_data_length(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(95))
}
#[doc(alias = "RawData")]
pub fn raw_data(&self) -> Option<&[u8]> {
self.0.get(Tag(96))
}
}
impl std::fmt::Debug for News {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "News({})", self.0)
}
}
impl std::fmt::Display for News {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
std::fmt::Display::fmt(&self.0, f)
}
}
pub mod news {
pub mod routing_ids {
use super::super::*;
pub const TABLE: GroupTable<'static> = GroupTable::new(
Tag(215),
Tag(216),
&[Tag(216), Tag(217)],
&[],
);
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[Tag(216), Tag(217)]);
#[derive(Clone, Copy, Debug)]
pub struct Instance<'a>(refix_message::Scope<'a>);
impl<'a> From<refix_message::Scope<'a>> for Instance<'a> {
fn from(scope: refix_message::Scope<'a>) -> Self {
Self(scope)
}
}
impl<'a> Instance<'a> {
pub fn raw(&self) -> refix_message::Scope<'a> {
self.0
}
#[doc(alias = "RoutingType")]
pub fn routing_type(&self) -> Result<Option<RoutingType>, InvalidValue> {
Ok(self.0.get_int(Tag(216))?.map(RoutingType::from_value))
}
#[doc(alias = "RoutingID")]
pub fn routing_id(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(217))
}
}
}
pub mod related_sym {
use super::super::*;
pub const TABLE: GroupTable<'static> = GroupTable::new(
Tag(146),
Tag(46),
&[
Tag(22), Tag(46), Tag(48), Tag(65), Tag(106), Tag(107), Tag(167), Tag(200),
Tag(201), Tag(202), Tag(205), Tag(206), Tag(207), Tag(223), Tag(231), Tag(348),
Tag(349), Tag(350), Tag(351),
],
&[],
);
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(22), Tag(46), Tag(48), Tag(65), Tag(106), Tag(107), Tag(167), Tag(200), Tag(201),
Tag(202), Tag(205), Tag(206), Tag(207), Tag(223), Tag(231), Tag(348), Tag(349),
Tag(350), Tag(351),
]);
#[derive(Clone, Copy, Debug)]
pub struct Instance<'a>(refix_message::Scope<'a>);
impl<'a> From<refix_message::Scope<'a>> for Instance<'a> {
fn from(scope: refix_message::Scope<'a>) -> Self {
Self(scope)
}
}
impl<'a> Instance<'a> {
pub fn raw(&self) -> refix_message::Scope<'a> {
self.0
}
#[doc(alias = "RelatdSym")]
pub fn relatd_sym(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(46))
}
#[doc(alias = "SymbolSfx")]
pub fn symbol_sfx(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(65))
}
#[doc(alias = "SecurityID")]
pub fn security_id(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(48))
}
#[doc(alias = "IDSource")]
pub fn id_source(&self) -> Result<Option<IDSource<'a>>, InvalidValue> {
Ok(self.0.get_str(Tag(22))?.map(IDSource::from_value))
}
#[doc(alias = "SecurityType")]
pub fn security_type(&self) -> Result<Option<SecurityType<'a>>, InvalidValue> {
Ok(self.0.get_str(Tag(167))?.map(SecurityType::from_value))
}
#[doc(alias = "MaturityMonthYear")]
pub fn maturity_month_year(&self) -> Result<Option<MonthYear>, InvalidValue> {
self.0.get_month_year(Tag(200))
}
#[doc(alias = "MaturityDay")]
pub fn maturity_day(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(205))
}
#[doc(alias = "PutOrCall")]
pub fn put_or_call(&self) -> Result<Option<PutOrCall>, InvalidValue> {
Ok(self.0.get_int(Tag(201))?.map(PutOrCall::from_value))
}
#[doc(alias = "StrikePrice")]
pub fn strike_price(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(202))
}
#[doc(alias = "OptAttribute")]
pub fn opt_attribute(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(206))
}
#[doc(alias = "ContractMultiplier")]
pub fn contract_multiplier(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(231))
}
#[doc(alias = "CouponRate")]
pub fn coupon_rate(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(223))
}
#[doc(alias = "SecurityExchange")]
pub fn security_exchange(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(207))
}
#[doc(alias = "Issuer")]
pub fn issuer(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(106))
}
#[doc(alias = "EncodedIssuerLen")]
pub fn encoded_issuer_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(348))
}
#[doc(alias = "EncodedIssuer")]
pub fn encoded_issuer(&self) -> Option<&'a [u8]> {
self.0.get(Tag(349))
}
#[doc(alias = "SecurityDesc")]
pub fn security_desc(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(107))
}
#[doc(alias = "EncodedSecurityDescLen")]
pub fn encoded_security_desc_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(350))
}
#[doc(alias = "EncodedSecurityDesc")]
pub fn encoded_security_desc(&self) -> Option<&'a [u8]> {
self.0.get(Tag(351))
}
}
}
pub mod lines_of_text {
use super::super::*;
pub const TABLE: GroupTable<'static> = GroupTable::new(
Tag(33),
Tag(58),
&[Tag(58), Tag(354), Tag(355)],
&[],
);
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[Tag(58), Tag(354), Tag(355)]);
#[derive(Clone, Copy, Debug)]
pub struct Instance<'a>(refix_message::Scope<'a>);
impl<'a> From<refix_message::Scope<'a>> for Instance<'a> {
fn from(scope: refix_message::Scope<'a>) -> Self {
Self(scope)
}
}
impl<'a> Instance<'a> {
pub fn raw(&self) -> refix_message::Scope<'a> {
self.0
}
#[doc(alias = "Text")]
pub fn text(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(58))
}
#[doc(alias = "EncodedTextLen")]
pub fn encoded_text_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(354))
}
#[doc(alias = "EncodedText")]
pub fn encoded_text(&self) -> Option<&'a [u8]> {
self.0.get(Tag(355))
}
}
}
}
pub struct Email(RawMessage);
impl Email {
pub const MSG_TYPE: &[u8] = b"C";
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(8), Tag(9), Tag(10), Tag(11), Tag(22), Tag(33), Tag(34), Tag(35), Tag(37), Tag(42),
Tag(43), Tag(46), Tag(48), Tag(49), Tag(50), Tag(52), Tag(56), Tag(57), Tag(58), Tag(65),
Tag(89), Tag(90), Tag(91), Tag(93), Tag(94), Tag(95), Tag(96), Tag(97), Tag(106), Tag(107),
Tag(115), Tag(116), Tag(122), Tag(128), Tag(129), Tag(142), Tag(143), Tag(144), Tag(145),
Tag(146), Tag(147), Tag(164), Tag(167), Tag(200), Tag(201), Tag(202), Tag(205), Tag(206),
Tag(207), Tag(212), Tag(213), Tag(215), Tag(216), Tag(217), Tag(223), Tag(231), Tag(347),
Tag(348), Tag(349), Tag(350), Tag(351), Tag(354), Tag(355), Tag(356), Tag(357), Tag(369),
Tag(370),
]);
pub fn from_raw(raw: RawMessage) -> Self {
Self(raw)
}
pub fn raw(&self) -> &RawMessage {
&self.0
}
pub fn header(&self) -> Header<'_> {
Header(self.0.scope())
}
pub fn trailer(&self) -> Trailer<'_> {
Trailer(self.0.scope())
}
#[doc(alias = "EmailThreadID")]
pub fn email_thread_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(164))
}
#[doc(alias = "EmailType")]
pub fn email_type(&self) -> Result<Option<EmailType<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(94))?.map(EmailType::from_value))
}
#[doc(alias = "OrigTime")]
pub fn orig_time(&self) -> Result<Option<UtcTimestamp>, InvalidValue> {
self.0.get_utc_timestamp(Tag(42))
}
#[doc(alias = "Subject")]
pub fn subject(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(147))
}
#[doc(alias = "EncodedSubjectLen")]
pub fn encoded_subject_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(356))
}
#[doc(alias = "EncodedSubject")]
pub fn encoded_subject(&self) -> Option<&[u8]> {
self.0.get(Tag(357))
}
#[doc(alias = "NoRoutingIDs")]
pub fn routing_ids(&self) -> Result<Instances<'_, email::routing_ids::Instance<'_>>, InvalidValue> {
self.0.get_group(&email::routing_ids::TABLE, &Self::KNOWN_TAGS).map(Instances::from)
}
#[doc(alias = "NoRelatedSym")]
pub fn related_sym(&self) -> Result<Instances<'_, email::related_sym::Instance<'_>>, InvalidValue> {
self.0.get_group(&email::related_sym::TABLE, &Self::KNOWN_TAGS).map(Instances::from)
}
#[doc(alias = "OrderID")]
pub fn order_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(37))
}
#[doc(alias = "ClOrdID")]
pub fn cl_ord_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(11))
}
#[doc(alias = "LinesOfText")]
pub fn lines_of_text(&self) -> Result<Instances<'_, email::lines_of_text::Instance<'_>>, InvalidValue> {
self.0.get_group(&email::lines_of_text::TABLE, &Self::KNOWN_TAGS).map(Instances::from)
}
#[doc(alias = "RawDataLength")]
pub fn raw_data_length(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(95))
}
#[doc(alias = "RawData")]
pub fn raw_data(&self) -> Option<&[u8]> {
self.0.get(Tag(96))
}
}
impl std::fmt::Debug for Email {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "Email({})", self.0)
}
}
impl std::fmt::Display for Email {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
std::fmt::Display::fmt(&self.0, f)
}
}
pub mod email {
pub mod routing_ids {
use super::super::*;
pub const TABLE: GroupTable<'static> = GroupTable::new(
Tag(215),
Tag(216),
&[Tag(216), Tag(217)],
&[],
);
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[Tag(216), Tag(217)]);
#[derive(Clone, Copy, Debug)]
pub struct Instance<'a>(refix_message::Scope<'a>);
impl<'a> From<refix_message::Scope<'a>> for Instance<'a> {
fn from(scope: refix_message::Scope<'a>) -> Self {
Self(scope)
}
}
impl<'a> Instance<'a> {
pub fn raw(&self) -> refix_message::Scope<'a> {
self.0
}
#[doc(alias = "RoutingType")]
pub fn routing_type(&self) -> Result<Option<RoutingType>, InvalidValue> {
Ok(self.0.get_int(Tag(216))?.map(RoutingType::from_value))
}
#[doc(alias = "RoutingID")]
pub fn routing_id(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(217))
}
}
}
pub mod related_sym {
use super::super::*;
pub const TABLE: GroupTable<'static> = GroupTable::new(
Tag(146),
Tag(46),
&[
Tag(22), Tag(46), Tag(48), Tag(65), Tag(106), Tag(107), Tag(167), Tag(200),
Tag(201), Tag(202), Tag(205), Tag(206), Tag(207), Tag(223), Tag(231), Tag(348),
Tag(349), Tag(350), Tag(351),
],
&[],
);
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(22), Tag(46), Tag(48), Tag(65), Tag(106), Tag(107), Tag(167), Tag(200), Tag(201),
Tag(202), Tag(205), Tag(206), Tag(207), Tag(223), Tag(231), Tag(348), Tag(349),
Tag(350), Tag(351),
]);
#[derive(Clone, Copy, Debug)]
pub struct Instance<'a>(refix_message::Scope<'a>);
impl<'a> From<refix_message::Scope<'a>> for Instance<'a> {
fn from(scope: refix_message::Scope<'a>) -> Self {
Self(scope)
}
}
impl<'a> Instance<'a> {
pub fn raw(&self) -> refix_message::Scope<'a> {
self.0
}
#[doc(alias = "RelatdSym")]
pub fn relatd_sym(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(46))
}
#[doc(alias = "SymbolSfx")]
pub fn symbol_sfx(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(65))
}
#[doc(alias = "SecurityID")]
pub fn security_id(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(48))
}
#[doc(alias = "IDSource")]
pub fn id_source(&self) -> Result<Option<IDSource<'a>>, InvalidValue> {
Ok(self.0.get_str(Tag(22))?.map(IDSource::from_value))
}
#[doc(alias = "SecurityType")]
pub fn security_type(&self) -> Result<Option<SecurityType<'a>>, InvalidValue> {
Ok(self.0.get_str(Tag(167))?.map(SecurityType::from_value))
}
#[doc(alias = "MaturityMonthYear")]
pub fn maturity_month_year(&self) -> Result<Option<MonthYear>, InvalidValue> {
self.0.get_month_year(Tag(200))
}
#[doc(alias = "MaturityDay")]
pub fn maturity_day(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(205))
}
#[doc(alias = "PutOrCall")]
pub fn put_or_call(&self) -> Result<Option<PutOrCall>, InvalidValue> {
Ok(self.0.get_int(Tag(201))?.map(PutOrCall::from_value))
}
#[doc(alias = "StrikePrice")]
pub fn strike_price(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(202))
}
#[doc(alias = "OptAttribute")]
pub fn opt_attribute(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(206))
}
#[doc(alias = "ContractMultiplier")]
pub fn contract_multiplier(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(231))
}
#[doc(alias = "CouponRate")]
pub fn coupon_rate(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(223))
}
#[doc(alias = "SecurityExchange")]
pub fn security_exchange(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(207))
}
#[doc(alias = "Issuer")]
pub fn issuer(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(106))
}
#[doc(alias = "EncodedIssuerLen")]
pub fn encoded_issuer_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(348))
}
#[doc(alias = "EncodedIssuer")]
pub fn encoded_issuer(&self) -> Option<&'a [u8]> {
self.0.get(Tag(349))
}
#[doc(alias = "SecurityDesc")]
pub fn security_desc(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(107))
}
#[doc(alias = "EncodedSecurityDescLen")]
pub fn encoded_security_desc_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(350))
}
#[doc(alias = "EncodedSecurityDesc")]
pub fn encoded_security_desc(&self) -> Option<&'a [u8]> {
self.0.get(Tag(351))
}
}
}
pub mod lines_of_text {
use super::super::*;
pub const TABLE: GroupTable<'static> = GroupTable::new(
Tag(33),
Tag(58),
&[Tag(58), Tag(354), Tag(355)],
&[],
);
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[Tag(58), Tag(354), Tag(355)]);
#[derive(Clone, Copy, Debug)]
pub struct Instance<'a>(refix_message::Scope<'a>);
impl<'a> From<refix_message::Scope<'a>> for Instance<'a> {
fn from(scope: refix_message::Scope<'a>) -> Self {
Self(scope)
}
}
impl<'a> Instance<'a> {
pub fn raw(&self) -> refix_message::Scope<'a> {
self.0
}
#[doc(alias = "Text")]
pub fn text(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(58))
}
#[doc(alias = "EncodedTextLen")]
pub fn encoded_text_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(354))
}
#[doc(alias = "EncodedText")]
pub fn encoded_text(&self) -> Option<&'a [u8]> {
self.0.get(Tag(355))
}
}
}
}
pub struct NewOrderSingle(RawMessage);
impl NewOrderSingle {
pub const MSG_TYPE: &[u8] = b"D";
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(1), Tag(8), Tag(9), Tag(10), Tag(11), Tag(12), Tag(13), Tag(15), Tag(18), Tag(21),
Tag(22), Tag(23), Tag(34), Tag(35), Tag(38), Tag(40), Tag(43), Tag(44), Tag(47), Tag(48),
Tag(49), Tag(50), Tag(52), Tag(54), Tag(55), Tag(56), Tag(57), Tag(58), Tag(59), Tag(60),
Tag(63), Tag(64), Tag(65), Tag(76), Tag(77), Tag(78), Tag(79), Tag(80), Tag(81), Tag(89),
Tag(90), Tag(91), Tag(93), Tag(97), Tag(99), Tag(100), Tag(106), Tag(107), Tag(109),
Tag(110), Tag(111), Tag(114), Tag(115), Tag(116), Tag(117), Tag(120), Tag(121), Tag(122),
Tag(126), Tag(128), Tag(129), Tag(140), Tag(142), Tag(143), Tag(144), Tag(145), Tag(152),
Tag(167), Tag(168), Tag(192), Tag(193), Tag(200), Tag(201), Tag(202), Tag(203), Tag(204),
Tag(205), Tag(206), Tag(207), Tag(210), Tag(211), Tag(212), Tag(213), Tag(223), Tag(231),
Tag(336), Tag(347), Tag(348), Tag(349), Tag(350), Tag(351), Tag(354), Tag(355), Tag(369),
Tag(370), Tag(376), Tag(377), Tag(386), Tag(388), Tag(389), Tag(427), Tag(432), Tag(439),
Tag(440),
]);
pub fn from_raw(raw: RawMessage) -> Self {
Self(raw)
}
pub fn raw(&self) -> &RawMessage {
&self.0
}
pub fn header(&self) -> Header<'_> {
Header(self.0.scope())
}
pub fn trailer(&self) -> Trailer<'_> {
Trailer(self.0.scope())
}
#[doc(alias = "ClOrdID")]
pub fn cl_ord_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(11))
}
#[doc(alias = "ClientID")]
pub fn client_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(109))
}
#[doc(alias = "ExecBroker")]
pub fn exec_broker(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(76))
}
#[doc(alias = "Account")]
pub fn account(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(1))
}
#[doc(alias = "NoAllocs")]
pub fn allocs(&self) -> Result<Instances<'_, new_order_single::allocs::Instance<'_>>, InvalidValue> {
self.0.get_group(&new_order_single::allocs::TABLE, &Self::KNOWN_TAGS).map(Instances::from)
}
#[doc(alias = "SettlmntTyp")]
pub fn settlmnt_typ(&self) -> Result<Option<SettlmntTyp<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(63))?.map(SettlmntTyp::from_value))
}
#[doc(alias = "FutSettDate")]
pub fn fut_sett_date(&self) -> Result<Option<Date>, InvalidValue> {
self.0.get_date(Tag(64))
}
#[doc(alias = "HandlInst")]
pub fn handl_inst(&self) -> Result<Option<HandlInst<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(21))?.map(HandlInst::from_value))
}
#[doc(alias = "ExecInst")]
pub fn exec_inst(&self) -> Result<Option<MultipleValues<'_, ExecInst<'_>>>, InvalidValue> {
self.0.get_multiple_values(Tag(18))
}
#[doc(alias = "MinQty")]
pub fn min_qty(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(110))
}
#[doc(alias = "MaxFloor")]
pub fn max_floor(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(111))
}
#[doc(alias = "ExDestination")]
pub fn ex_destination(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(100))
}
#[doc(alias = "NoTradingSessions")]
pub fn trading_sessions(&self) -> Result<Instances<'_, new_order_single::trading_sessions::Instance<'_>>, InvalidValue> {
self.0.get_group(&new_order_single::trading_sessions::TABLE, &Self::KNOWN_TAGS).map(Instances::from)
}
#[doc(alias = "ProcessCode")]
pub fn process_code(&self) -> Result<Option<ProcessCode<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(81))?.map(ProcessCode::from_value))
}
#[doc(alias = "Symbol")]
pub fn symbol(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(55))
}
#[doc(alias = "SymbolSfx")]
pub fn symbol_sfx(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(65))
}
#[doc(alias = "SecurityID")]
pub fn security_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(48))
}
#[doc(alias = "IDSource")]
pub fn id_source(&self) -> Result<Option<IDSource<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(22))?.map(IDSource::from_value))
}
#[doc(alias = "SecurityType")]
pub fn security_type(&self) -> Result<Option<SecurityType<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(167))?.map(SecurityType::from_value))
}
#[doc(alias = "MaturityMonthYear")]
pub fn maturity_month_year(&self) -> Result<Option<MonthYear>, InvalidValue> {
self.0.get_month_year(Tag(200))
}
#[doc(alias = "MaturityDay")]
pub fn maturity_day(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(205))
}
#[doc(alias = "PutOrCall")]
pub fn put_or_call(&self) -> Result<Option<PutOrCall>, InvalidValue> {
Ok(self.0.get_int(Tag(201))?.map(PutOrCall::from_value))
}
#[doc(alias = "StrikePrice")]
pub fn strike_price(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(202))
}
#[doc(alias = "OptAttribute")]
pub fn opt_attribute(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(206))
}
#[doc(alias = "ContractMultiplier")]
pub fn contract_multiplier(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(231))
}
#[doc(alias = "CouponRate")]
pub fn coupon_rate(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(223))
}
#[doc(alias = "SecurityExchange")]
pub fn security_exchange(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(207))
}
#[doc(alias = "Issuer")]
pub fn issuer(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(106))
}
#[doc(alias = "EncodedIssuerLen")]
pub fn encoded_issuer_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(348))
}
#[doc(alias = "EncodedIssuer")]
pub fn encoded_issuer(&self) -> Option<&[u8]> {
self.0.get(Tag(349))
}
#[doc(alias = "SecurityDesc")]
pub fn security_desc(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(107))
}
#[doc(alias = "EncodedSecurityDescLen")]
pub fn encoded_security_desc_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(350))
}
#[doc(alias = "EncodedSecurityDesc")]
pub fn encoded_security_desc(&self) -> Option<&[u8]> {
self.0.get(Tag(351))
}
#[doc(alias = "PrevClosePx")]
pub fn prev_close_px(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(140))
}
#[doc(alias = "Side")]
pub fn side(&self) -> Result<Option<Side<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(54))?.map(Side::from_value))
}
#[doc(alias = "LocateReqd")]
pub fn locate_reqd(&self) -> Result<Option<bool>, InvalidValue> {
self.0.get_bool(Tag(114))
}
#[doc(alias = "TransactTime")]
pub fn transact_time(&self) -> Result<Option<UtcTimestamp>, InvalidValue> {
self.0.get_utc_timestamp(Tag(60))
}
#[doc(alias = "OrderQty")]
pub fn order_qty(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(38))
}
#[doc(alias = "CashOrderQty")]
pub fn cash_order_qty(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(152))
}
#[doc(alias = "OrdType")]
pub fn ord_type(&self) -> Result<Option<OrdType<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(40))?.map(OrdType::from_value))
}
#[doc(alias = "Price")]
pub fn price(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(44))
}
#[doc(alias = "StopPx")]
pub fn stop_px(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(99))
}
#[doc(alias = "Currency")]
pub fn currency(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(15))
}
#[doc(alias = "ComplianceID")]
pub fn compliance_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(376))
}
#[doc(alias = "SolicitedFlag")]
pub fn solicited_flag(&self) -> Result<Option<bool>, InvalidValue> {
self.0.get_bool(Tag(377))
}
#[doc(alias = "IOIid")]
pub fn io_iid(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(23))
}
#[doc(alias = "QuoteID")]
pub fn quote_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(117))
}
#[doc(alias = "TimeInForce")]
pub fn time_in_force(&self) -> Result<Option<TimeInForce<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(59))?.map(TimeInForce::from_value))
}
#[doc(alias = "EffectiveTime")]
pub fn effective_time(&self) -> Result<Option<UtcTimestamp>, InvalidValue> {
self.0.get_utc_timestamp(Tag(168))
}
#[doc(alias = "ExpireDate")]
pub fn expire_date(&self) -> Result<Option<Date>, InvalidValue> {
self.0.get_date(Tag(432))
}
#[doc(alias = "ExpireTime")]
pub fn expire_time(&self) -> Result<Option<UtcTimestamp>, InvalidValue> {
self.0.get_utc_timestamp(Tag(126))
}
#[doc(alias = "GTBookingInst")]
pub fn gt_booking_inst(&self) -> Result<Option<GTBookingInst>, InvalidValue> {
Ok(self.0.get_int(Tag(427))?.map(GTBookingInst::from_value))
}
#[doc(alias = "Commission")]
pub fn commission(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(12))
}
#[doc(alias = "CommType")]
pub fn comm_type(&self) -> Result<Option<CommType<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(13))?.map(CommType::from_value))
}
#[doc(alias = "Rule80A")]
pub fn rule80_a(&self) -> Result<Option<Rule80A<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(47))?.map(Rule80A::from_value))
}
#[doc(alias = "ForexReq")]
pub fn forex_req(&self) -> Result<Option<bool>, InvalidValue> {
self.0.get_bool(Tag(121))
}
#[doc(alias = "SettlCurrency")]
pub fn settl_currency(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(120))
}
#[doc(alias = "Text")]
pub fn text(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(58))
}
#[doc(alias = "EncodedTextLen")]
pub fn encoded_text_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(354))
}
#[doc(alias = "EncodedText")]
pub fn encoded_text(&self) -> Option<&[u8]> {
self.0.get(Tag(355))
}
#[doc(alias = "FutSettDate2")]
pub fn fut_sett_date2(&self) -> Result<Option<Date>, InvalidValue> {
self.0.get_date(Tag(193))
}
#[doc(alias = "OrderQty2")]
pub fn order_qty2(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(192))
}
#[doc(alias = "OpenClose")]
pub fn open_close(&self) -> Result<Option<OpenClose<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(77))?.map(OpenClose::from_value))
}
#[doc(alias = "CoveredOrUncovered")]
pub fn covered_or_uncovered(&self) -> Result<Option<CoveredOrUncovered>, InvalidValue> {
Ok(self.0.get_int(Tag(203))?.map(CoveredOrUncovered::from_value))
}
#[doc(alias = "CustomerOrFirm")]
pub fn customer_or_firm(&self) -> Result<Option<CustomerOrFirm>, InvalidValue> {
Ok(self.0.get_int(Tag(204))?.map(CustomerOrFirm::from_value))
}
#[doc(alias = "MaxShow")]
pub fn max_show(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(210))
}
#[doc(alias = "PegDifference")]
pub fn peg_difference(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(211))
}
#[doc(alias = "DiscretionInst")]
pub fn discretion_inst(&self) -> Result<Option<DiscretionInst<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(388))?.map(DiscretionInst::from_value))
}
#[doc(alias = "DiscretionOffset")]
pub fn discretion_offset(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(389))
}
#[doc(alias = "ClearingFirm")]
pub fn clearing_firm(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(439))
}
#[doc(alias = "ClearingAccount")]
pub fn clearing_account(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(440))
}
}
impl std::fmt::Debug for NewOrderSingle {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "NewOrderSingle({})", self.0)
}
}
impl std::fmt::Display for NewOrderSingle {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
std::fmt::Display::fmt(&self.0, f)
}
}
pub mod new_order_single {
pub mod allocs {
use super::super::*;
pub const TABLE: GroupTable<'static> = GroupTable::new(
Tag(78),
Tag(79),
&[Tag(79), Tag(80)],
&[],
);
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[Tag(79), Tag(80)]);
#[derive(Clone, Copy, Debug)]
pub struct Instance<'a>(refix_message::Scope<'a>);
impl<'a> From<refix_message::Scope<'a>> for Instance<'a> {
fn from(scope: refix_message::Scope<'a>) -> Self {
Self(scope)
}
}
impl<'a> Instance<'a> {
pub fn raw(&self) -> refix_message::Scope<'a> {
self.0
}
#[doc(alias = "AllocAccount")]
pub fn alloc_account(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(79))
}
#[doc(alias = "AllocShares")]
pub fn alloc_shares(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(80))
}
}
}
pub mod trading_sessions {
use super::super::*;
pub const TABLE: GroupTable<'static> = GroupTable::new(
Tag(386),
Tag(336),
&[Tag(336)],
&[],
);
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[Tag(336)]);
#[derive(Clone, Copy, Debug)]
pub struct Instance<'a>(refix_message::Scope<'a>);
impl<'a> From<refix_message::Scope<'a>> for Instance<'a> {
fn from(scope: refix_message::Scope<'a>) -> Self {
Self(scope)
}
}
impl<'a> Instance<'a> {
pub fn raw(&self) -> refix_message::Scope<'a> {
self.0
}
#[doc(alias = "TradingSessionID")]
pub fn trading_session_id(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(336))
}
}
}
}
pub struct NewOrderList(RawMessage);
impl NewOrderList {
pub const MSG_TYPE: &[u8] = b"E";
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(1), Tag(8), Tag(9), Tag(10), Tag(11), Tag(12), Tag(13), Tag(15), Tag(18), Tag(21),
Tag(22), Tag(23), Tag(34), Tag(35), Tag(38), Tag(40), Tag(43), Tag(44), Tag(47), Tag(48),
Tag(49), Tag(50), Tag(52), Tag(54), Tag(55), Tag(56), Tag(57), Tag(58), Tag(59), Tag(60),
Tag(63), Tag(64), Tag(65), Tag(66), Tag(67), Tag(68), Tag(69), Tag(73), Tag(76), Tag(77),
Tag(78), Tag(79), Tag(80), Tag(81), Tag(89), Tag(90), Tag(91), Tag(93), Tag(97), Tag(99),
Tag(100), Tag(106), Tag(107), Tag(109), Tag(110), Tag(111), Tag(114), Tag(115), Tag(116),
Tag(117), Tag(120), Tag(121), Tag(122), Tag(126), Tag(128), Tag(129), Tag(140), Tag(142),
Tag(143), Tag(144), Tag(145), Tag(152), Tag(160), Tag(167), Tag(168), Tag(192), Tag(193),
Tag(200), Tag(201), Tag(202), Tag(203), Tag(204), Tag(205), Tag(206), Tag(207), Tag(210),
Tag(211), Tag(212), Tag(213), Tag(223), Tag(231), Tag(336), Tag(347), Tag(348), Tag(349),
Tag(350), Tag(351), Tag(352), Tag(353), Tag(354), Tag(355), Tag(369), Tag(370), Tag(376),
Tag(377), Tag(386), Tag(388), Tag(389), Tag(390), Tag(391), Tag(394), Tag(401), Tag(414),
Tag(415), Tag(427), Tag(432), Tag(433), Tag(439), Tag(440),
]);
pub fn from_raw(raw: RawMessage) -> Self {
Self(raw)
}
pub fn raw(&self) -> &RawMessage {
&self.0
}
pub fn header(&self) -> Header<'_> {
Header(self.0.scope())
}
pub fn trailer(&self) -> Trailer<'_> {
Trailer(self.0.scope())
}
#[doc(alias = "ListID")]
pub fn list_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(66))
}
#[doc(alias = "BidID")]
pub fn bid_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(390))
}
#[doc(alias = "ClientBidID")]
pub fn client_bid_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(391))
}
#[doc(alias = "ProgRptReqs")]
pub fn prog_rpt_reqs(&self) -> Result<Option<ProgRptReqs>, InvalidValue> {
Ok(self.0.get_int(Tag(414))?.map(ProgRptReqs::from_value))
}
#[doc(alias = "BidType")]
pub fn bid_type(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(394))
}
#[doc(alias = "ProgPeriodInterval")]
pub fn prog_period_interval(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(415))
}
#[doc(alias = "ListExecInstType")]
pub fn list_exec_inst_type(&self) -> Result<Option<ListExecInstType<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(433))?.map(ListExecInstType::from_value))
}
#[doc(alias = "ListExecInst")]
pub fn list_exec_inst(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(69))
}
#[doc(alias = "EncodedListExecInstLen")]
pub fn encoded_list_exec_inst_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(352))
}
#[doc(alias = "EncodedListExecInst")]
pub fn encoded_list_exec_inst(&self) -> Option<&[u8]> {
self.0.get(Tag(353))
}
#[doc(alias = "TotNoOrders")]
pub fn tot_no_orders(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(68))
}
#[doc(alias = "NoOrders")]
pub fn orders(&self) -> Result<Instances<'_, new_order_list::orders::Instance<'_>>, InvalidValue> {
self.0.get_group(&new_order_list::orders::TABLE, &Self::KNOWN_TAGS).map(Instances::from)
}
}
impl std::fmt::Debug for NewOrderList {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "NewOrderList({})", self.0)
}
}
impl std::fmt::Display for NewOrderList {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
std::fmt::Display::fmt(&self.0, f)
}
}
pub mod new_order_list {
pub mod orders {
use super::super::*;
pub const TABLE: GroupTable<'static> = GroupTable::new(
Tag(73),
Tag(11),
&[
Tag(1), Tag(11), Tag(12), Tag(13), Tag(15), Tag(18), Tag(21), Tag(22), Tag(23),
Tag(38), Tag(40), Tag(44), Tag(47), Tag(48), Tag(54), Tag(55), Tag(58), Tag(59),
Tag(60), Tag(63), Tag(64), Tag(65), Tag(67), Tag(76), Tag(77), Tag(78), Tag(81),
Tag(99), Tag(100), Tag(106), Tag(107), Tag(109), Tag(110), Tag(111), Tag(114),
Tag(117), Tag(120), Tag(121), Tag(126), Tag(140), Tag(152), Tag(160), Tag(167),
Tag(168), Tag(192), Tag(193), Tag(200), Tag(201), Tag(202), Tag(203), Tag(204),
Tag(205), Tag(206), Tag(207), Tag(210), Tag(211), Tag(223), Tag(231), Tag(348),
Tag(349), Tag(350), Tag(351), Tag(354), Tag(355), Tag(376), Tag(377), Tag(386),
Tag(388), Tag(389), Tag(401), Tag(427), Tag(432), Tag(439), Tag(440),
],
&[
new_order_list::orders::allocs::TABLE,
new_order_list::orders::trading_sessions::TABLE,
],
);
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(1), Tag(11), Tag(12), Tag(13), Tag(15), Tag(18), Tag(21), Tag(22), Tag(23), Tag(38),
Tag(40), Tag(44), Tag(47), Tag(48), Tag(54), Tag(55), Tag(58), Tag(59), Tag(60),
Tag(63), Tag(64), Tag(65), Tag(67), Tag(76), Tag(77), Tag(78), Tag(79), Tag(80),
Tag(81), Tag(99), Tag(100), Tag(106), Tag(107), Tag(109), Tag(110), Tag(111), Tag(114),
Tag(117), Tag(120), Tag(121), Tag(126), Tag(140), Tag(152), Tag(160), Tag(167),
Tag(168), Tag(192), Tag(193), Tag(200), Tag(201), Tag(202), Tag(203), Tag(204),
Tag(205), Tag(206), Tag(207), Tag(210), Tag(211), Tag(223), Tag(231), Tag(336),
Tag(348), Tag(349), Tag(350), Tag(351), Tag(354), Tag(355), Tag(376), Tag(377),
Tag(386), Tag(388), Tag(389), Tag(401), Tag(427), Tag(432), Tag(439), Tag(440),
]);
#[derive(Clone, Copy, Debug)]
pub struct Instance<'a>(refix_message::Scope<'a>);
impl<'a> From<refix_message::Scope<'a>> for Instance<'a> {
fn from(scope: refix_message::Scope<'a>) -> Self {
Self(scope)
}
}
impl<'a> Instance<'a> {
pub fn raw(&self) -> refix_message::Scope<'a> {
self.0
}
#[doc(alias = "ClOrdID")]
pub fn cl_ord_id(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(11))
}
#[doc(alias = "ListSeqNo")]
pub fn list_seq_no(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(67))
}
#[doc(alias = "SettlInstMode")]
pub fn settl_inst_mode(&self) -> Result<Option<SettlInstMode<'a>>, InvalidValue> {
Ok(self.0.get_str(Tag(160))?.map(SettlInstMode::from_value))
}
#[doc(alias = "ClientID")]
pub fn client_id(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(109))
}
#[doc(alias = "ExecBroker")]
pub fn exec_broker(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(76))
}
#[doc(alias = "Account")]
pub fn account(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(1))
}
#[doc(alias = "NoAllocs")]
pub fn allocs(&self) -> Result<Instances<'a, new_order_list::orders::allocs::Instance<'a>>, InvalidValue> {
self.0.get_group(&new_order_list::orders::allocs::TABLE, &KNOWN_TAGS).map(Instances::from)
}
#[doc(alias = "SettlmntTyp")]
pub fn settlmnt_typ(&self) -> Result<Option<SettlmntTyp<'a>>, InvalidValue> {
Ok(self.0.get_str(Tag(63))?.map(SettlmntTyp::from_value))
}
#[doc(alias = "FutSettDate")]
pub fn fut_sett_date(&self) -> Result<Option<Date>, InvalidValue> {
self.0.get_date(Tag(64))
}
#[doc(alias = "HandlInst")]
pub fn handl_inst(&self) -> Result<Option<HandlInst<'a>>, InvalidValue> {
Ok(self.0.get_str(Tag(21))?.map(HandlInst::from_value))
}
#[doc(alias = "ExecInst")]
pub fn exec_inst(&self) -> Result<Option<MultipleValues<'a, ExecInst<'a>>>, InvalidValue> {
self.0.get_multiple_values(Tag(18))
}
#[doc(alias = "MinQty")]
pub fn min_qty(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(110))
}
#[doc(alias = "MaxFloor")]
pub fn max_floor(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(111))
}
#[doc(alias = "ExDestination")]
pub fn ex_destination(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(100))
}
#[doc(alias = "NoTradingSessions")]
pub fn trading_sessions(&self) -> Result<Instances<'a, new_order_list::orders::trading_sessions::Instance<'a>>, InvalidValue> {
self.0.get_group(&new_order_list::orders::trading_sessions::TABLE, &KNOWN_TAGS).map(Instances::from)
}
#[doc(alias = "ProcessCode")]
pub fn process_code(&self) -> Result<Option<ProcessCode<'a>>, InvalidValue> {
Ok(self.0.get_str(Tag(81))?.map(ProcessCode::from_value))
}
#[doc(alias = "Symbol")]
pub fn symbol(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(55))
}
#[doc(alias = "SymbolSfx")]
pub fn symbol_sfx(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(65))
}
#[doc(alias = "SecurityID")]
pub fn security_id(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(48))
}
#[doc(alias = "IDSource")]
pub fn id_source(&self) -> Result<Option<IDSource<'a>>, InvalidValue> {
Ok(self.0.get_str(Tag(22))?.map(IDSource::from_value))
}
#[doc(alias = "SecurityType")]
pub fn security_type(&self) -> Result<Option<SecurityType<'a>>, InvalidValue> {
Ok(self.0.get_str(Tag(167))?.map(SecurityType::from_value))
}
#[doc(alias = "MaturityMonthYear")]
pub fn maturity_month_year(&self) -> Result<Option<MonthYear>, InvalidValue> {
self.0.get_month_year(Tag(200))
}
#[doc(alias = "MaturityDay")]
pub fn maturity_day(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(205))
}
#[doc(alias = "PutOrCall")]
pub fn put_or_call(&self) -> Result<Option<PutOrCall>, InvalidValue> {
Ok(self.0.get_int(Tag(201))?.map(PutOrCall::from_value))
}
#[doc(alias = "StrikePrice")]
pub fn strike_price(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(202))
}
#[doc(alias = "OptAttribute")]
pub fn opt_attribute(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(206))
}
#[doc(alias = "ContractMultiplier")]
pub fn contract_multiplier(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(231))
}
#[doc(alias = "CouponRate")]
pub fn coupon_rate(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(223))
}
#[doc(alias = "SecurityExchange")]
pub fn security_exchange(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(207))
}
#[doc(alias = "Issuer")]
pub fn issuer(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(106))
}
#[doc(alias = "EncodedIssuerLen")]
pub fn encoded_issuer_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(348))
}
#[doc(alias = "EncodedIssuer")]
pub fn encoded_issuer(&self) -> Option<&'a [u8]> {
self.0.get(Tag(349))
}
#[doc(alias = "SecurityDesc")]
pub fn security_desc(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(107))
}
#[doc(alias = "EncodedSecurityDescLen")]
pub fn encoded_security_desc_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(350))
}
#[doc(alias = "EncodedSecurityDesc")]
pub fn encoded_security_desc(&self) -> Option<&'a [u8]> {
self.0.get(Tag(351))
}
#[doc(alias = "PrevClosePx")]
pub fn prev_close_px(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(140))
}
#[doc(alias = "Side")]
pub fn side(&self) -> Result<Option<Side<'a>>, InvalidValue> {
Ok(self.0.get_str(Tag(54))?.map(Side::from_value))
}
#[doc(alias = "SideValueInd")]
pub fn side_value_ind(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(401))
}
#[doc(alias = "LocateReqd")]
pub fn locate_reqd(&self) -> Result<Option<bool>, InvalidValue> {
self.0.get_bool(Tag(114))
}
#[doc(alias = "TransactTime")]
pub fn transact_time(&self) -> Result<Option<UtcTimestamp>, InvalidValue> {
self.0.get_utc_timestamp(Tag(60))
}
#[doc(alias = "OrderQty")]
pub fn order_qty(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(38))
}
#[doc(alias = "CashOrderQty")]
pub fn cash_order_qty(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(152))
}
#[doc(alias = "OrdType")]
pub fn ord_type(&self) -> Result<Option<OrdType<'a>>, InvalidValue> {
Ok(self.0.get_str(Tag(40))?.map(OrdType::from_value))
}
#[doc(alias = "Price")]
pub fn price(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(44))
}
#[doc(alias = "StopPx")]
pub fn stop_px(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(99))
}
#[doc(alias = "Currency")]
pub fn currency(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(15))
}
#[doc(alias = "ComplianceID")]
pub fn compliance_id(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(376))
}
#[doc(alias = "SolicitedFlag")]
pub fn solicited_flag(&self) -> Result<Option<bool>, InvalidValue> {
self.0.get_bool(Tag(377))
}
#[doc(alias = "IOIid")]
pub fn io_iid(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(23))
}
#[doc(alias = "QuoteID")]
pub fn quote_id(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(117))
}
#[doc(alias = "TimeInForce")]
pub fn time_in_force(&self) -> Result<Option<TimeInForce<'a>>, InvalidValue> {
Ok(self.0.get_str(Tag(59))?.map(TimeInForce::from_value))
}
#[doc(alias = "EffectiveTime")]
pub fn effective_time(&self) -> Result<Option<UtcTimestamp>, InvalidValue> {
self.0.get_utc_timestamp(Tag(168))
}
#[doc(alias = "ExpireDate")]
pub fn expire_date(&self) -> Result<Option<Date>, InvalidValue> {
self.0.get_date(Tag(432))
}
#[doc(alias = "ExpireTime")]
pub fn expire_time(&self) -> Result<Option<UtcTimestamp>, InvalidValue> {
self.0.get_utc_timestamp(Tag(126))
}
#[doc(alias = "GTBookingInst")]
pub fn gt_booking_inst(&self) -> Result<Option<GTBookingInst>, InvalidValue> {
Ok(self.0.get_int(Tag(427))?.map(GTBookingInst::from_value))
}
#[doc(alias = "Commission")]
pub fn commission(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(12))
}
#[doc(alias = "CommType")]
pub fn comm_type(&self) -> Result<Option<CommType<'a>>, InvalidValue> {
Ok(self.0.get_str(Tag(13))?.map(CommType::from_value))
}
#[doc(alias = "Rule80A")]
pub fn rule80_a(&self) -> Result<Option<Rule80A<'a>>, InvalidValue> {
Ok(self.0.get_str(Tag(47))?.map(Rule80A::from_value))
}
#[doc(alias = "ForexReq")]
pub fn forex_req(&self) -> Result<Option<bool>, InvalidValue> {
self.0.get_bool(Tag(121))
}
#[doc(alias = "SettlCurrency")]
pub fn settl_currency(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(120))
}
#[doc(alias = "Text")]
pub fn text(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(58))
}
#[doc(alias = "EncodedTextLen")]
pub fn encoded_text_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(354))
}
#[doc(alias = "EncodedText")]
pub fn encoded_text(&self) -> Option<&'a [u8]> {
self.0.get(Tag(355))
}
#[doc(alias = "FutSettDate2")]
pub fn fut_sett_date2(&self) -> Result<Option<Date>, InvalidValue> {
self.0.get_date(Tag(193))
}
#[doc(alias = "OrderQty2")]
pub fn order_qty2(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(192))
}
#[doc(alias = "OpenClose")]
pub fn open_close(&self) -> Result<Option<OpenClose<'a>>, InvalidValue> {
Ok(self.0.get_str(Tag(77))?.map(OpenClose::from_value))
}
#[doc(alias = "CoveredOrUncovered")]
pub fn covered_or_uncovered(&self) -> Result<Option<CoveredOrUncovered>, InvalidValue> {
Ok(self.0.get_int(Tag(203))?.map(CoveredOrUncovered::from_value))
}
#[doc(alias = "CustomerOrFirm")]
pub fn customer_or_firm(&self) -> Result<Option<CustomerOrFirm>, InvalidValue> {
Ok(self.0.get_int(Tag(204))?.map(CustomerOrFirm::from_value))
}
#[doc(alias = "MaxShow")]
pub fn max_show(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(210))
}
#[doc(alias = "PegDifference")]
pub fn peg_difference(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(211))
}
#[doc(alias = "DiscretionInst")]
pub fn discretion_inst(&self) -> Result<Option<DiscretionInst<'a>>, InvalidValue> {
Ok(self.0.get_str(Tag(388))?.map(DiscretionInst::from_value))
}
#[doc(alias = "DiscretionOffset")]
pub fn discretion_offset(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(389))
}
#[doc(alias = "ClearingFirm")]
pub fn clearing_firm(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(439))
}
#[doc(alias = "ClearingAccount")]
pub fn clearing_account(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(440))
}
}
pub mod allocs {
use super::super::super::*;
pub const TABLE: GroupTable<'static> = GroupTable::new(
Tag(78),
Tag(79),
&[Tag(79), Tag(80)],
&[],
);
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[Tag(79), Tag(80)]);
#[derive(Clone, Copy, Debug)]
pub struct Instance<'a>(refix_message::Scope<'a>);
impl<'a> From<refix_message::Scope<'a>> for Instance<'a> {
fn from(scope: refix_message::Scope<'a>) -> Self {
Self(scope)
}
}
impl<'a> Instance<'a> {
pub fn raw(&self) -> refix_message::Scope<'a> {
self.0
}
#[doc(alias = "AllocAccount")]
pub fn alloc_account(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(79))
}
#[doc(alias = "AllocShares")]
pub fn alloc_shares(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(80))
}
}
}
pub mod trading_sessions {
use super::super::super::*;
pub const TABLE: GroupTable<'static> = GroupTable::new(
Tag(386),
Tag(336),
&[Tag(336)],
&[],
);
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[Tag(336)]);
#[derive(Clone, Copy, Debug)]
pub struct Instance<'a>(refix_message::Scope<'a>);
impl<'a> From<refix_message::Scope<'a>> for Instance<'a> {
fn from(scope: refix_message::Scope<'a>) -> Self {
Self(scope)
}
}
impl<'a> Instance<'a> {
pub fn raw(&self) -> refix_message::Scope<'a> {
self.0
}
#[doc(alias = "TradingSessionID")]
pub fn trading_session_id(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(336))
}
}
}
}
}
pub struct OrderCancelRequest(RawMessage);
impl OrderCancelRequest {
pub const MSG_TYPE: &[u8] = b"F";
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(1), Tag(8), Tag(9), Tag(10), Tag(11), Tag(22), Tag(34), Tag(35), Tag(37), Tag(38),
Tag(41), Tag(43), Tag(48), Tag(49), Tag(50), Tag(52), Tag(54), Tag(55), Tag(56), Tag(57),
Tag(58), Tag(60), Tag(65), Tag(66), Tag(76), Tag(89), Tag(90), Tag(91), Tag(93), Tag(97),
Tag(106), Tag(107), Tag(109), Tag(115), Tag(116), Tag(122), Tag(128), Tag(129), Tag(142),
Tag(143), Tag(144), Tag(145), Tag(152), Tag(167), Tag(200), Tag(201), Tag(202), Tag(205),
Tag(206), Tag(207), Tag(212), Tag(213), Tag(223), Tag(231), Tag(347), Tag(348), Tag(349),
Tag(350), Tag(351), Tag(354), Tag(355), Tag(369), Tag(370), Tag(376), Tag(377),
]);
pub fn from_raw(raw: RawMessage) -> Self {
Self(raw)
}
pub fn raw(&self) -> &RawMessage {
&self.0
}
pub fn header(&self) -> Header<'_> {
Header(self.0.scope())
}
pub fn trailer(&self) -> Trailer<'_> {
Trailer(self.0.scope())
}
#[doc(alias = "OrigClOrdID")]
pub fn orig_cl_ord_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(41))
}
#[doc(alias = "OrderID")]
pub fn order_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(37))
}
#[doc(alias = "ClOrdID")]
pub fn cl_ord_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(11))
}
#[doc(alias = "ListID")]
pub fn list_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(66))
}
#[doc(alias = "Account")]
pub fn account(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(1))
}
#[doc(alias = "ClientID")]
pub fn client_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(109))
}
#[doc(alias = "ExecBroker")]
pub fn exec_broker(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(76))
}
#[doc(alias = "Symbol")]
pub fn symbol(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(55))
}
#[doc(alias = "SymbolSfx")]
pub fn symbol_sfx(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(65))
}
#[doc(alias = "SecurityID")]
pub fn security_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(48))
}
#[doc(alias = "IDSource")]
pub fn id_source(&self) -> Result<Option<IDSource<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(22))?.map(IDSource::from_value))
}
#[doc(alias = "SecurityType")]
pub fn security_type(&self) -> Result<Option<SecurityType<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(167))?.map(SecurityType::from_value))
}
#[doc(alias = "MaturityMonthYear")]
pub fn maturity_month_year(&self) -> Result<Option<MonthYear>, InvalidValue> {
self.0.get_month_year(Tag(200))
}
#[doc(alias = "MaturityDay")]
pub fn maturity_day(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(205))
}
#[doc(alias = "PutOrCall")]
pub fn put_or_call(&self) -> Result<Option<PutOrCall>, InvalidValue> {
Ok(self.0.get_int(Tag(201))?.map(PutOrCall::from_value))
}
#[doc(alias = "StrikePrice")]
pub fn strike_price(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(202))
}
#[doc(alias = "OptAttribute")]
pub fn opt_attribute(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(206))
}
#[doc(alias = "ContractMultiplier")]
pub fn contract_multiplier(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(231))
}
#[doc(alias = "CouponRate")]
pub fn coupon_rate(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(223))
}
#[doc(alias = "SecurityExchange")]
pub fn security_exchange(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(207))
}
#[doc(alias = "Issuer")]
pub fn issuer(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(106))
}
#[doc(alias = "EncodedIssuerLen")]
pub fn encoded_issuer_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(348))
}
#[doc(alias = "EncodedIssuer")]
pub fn encoded_issuer(&self) -> Option<&[u8]> {
self.0.get(Tag(349))
}
#[doc(alias = "SecurityDesc")]
pub fn security_desc(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(107))
}
#[doc(alias = "EncodedSecurityDescLen")]
pub fn encoded_security_desc_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(350))
}
#[doc(alias = "EncodedSecurityDesc")]
pub fn encoded_security_desc(&self) -> Option<&[u8]> {
self.0.get(Tag(351))
}
#[doc(alias = "Side")]
pub fn side(&self) -> Result<Option<Side<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(54))?.map(Side::from_value))
}
#[doc(alias = "TransactTime")]
pub fn transact_time(&self) -> Result<Option<UtcTimestamp>, InvalidValue> {
self.0.get_utc_timestamp(Tag(60))
}
#[doc(alias = "OrderQty")]
pub fn order_qty(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(38))
}
#[doc(alias = "CashOrderQty")]
pub fn cash_order_qty(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(152))
}
#[doc(alias = "ComplianceID")]
pub fn compliance_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(376))
}
#[doc(alias = "SolicitedFlag")]
pub fn solicited_flag(&self) -> Result<Option<bool>, InvalidValue> {
self.0.get_bool(Tag(377))
}
#[doc(alias = "Text")]
pub fn text(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(58))
}
#[doc(alias = "EncodedTextLen")]
pub fn encoded_text_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(354))
}
#[doc(alias = "EncodedText")]
pub fn encoded_text(&self) -> Option<&[u8]> {
self.0.get(Tag(355))
}
}
impl std::fmt::Debug for OrderCancelRequest {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "OrderCancelRequest({})", self.0)
}
}
impl std::fmt::Display for OrderCancelRequest {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
std::fmt::Display::fmt(&self.0, f)
}
}
pub struct OrderCancelReplaceRequest(RawMessage);
impl OrderCancelReplaceRequest {
pub const MSG_TYPE: &[u8] = b"G";
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(1), Tag(8), Tag(9), Tag(10), Tag(11), Tag(12), Tag(13), Tag(15), Tag(18), Tag(21),
Tag(22), Tag(34), Tag(35), Tag(37), Tag(38), Tag(40), Tag(41), Tag(43), Tag(44), Tag(47),
Tag(48), Tag(49), Tag(50), Tag(52), Tag(54), Tag(55), Tag(56), Tag(57), Tag(58), Tag(59),
Tag(60), Tag(63), Tag(64), Tag(65), Tag(66), Tag(76), Tag(77), Tag(78), Tag(79), Tag(80),
Tag(89), Tag(90), Tag(91), Tag(93), Tag(97), Tag(99), Tag(100), Tag(106), Tag(107),
Tag(109), Tag(110), Tag(111), Tag(114), Tag(115), Tag(116), Tag(120), Tag(121), Tag(122),
Tag(126), Tag(128), Tag(129), Tag(142), Tag(143), Tag(144), Tag(145), Tag(152), Tag(167),
Tag(168), Tag(192), Tag(193), Tag(200), Tag(201), Tag(202), Tag(203), Tag(204), Tag(205),
Tag(206), Tag(207), Tag(210), Tag(211), Tag(212), Tag(213), Tag(223), Tag(231), Tag(336),
Tag(347), Tag(348), Tag(349), Tag(350), Tag(351), Tag(354), Tag(355), Tag(369), Tag(370),
Tag(376), Tag(377), Tag(386), Tag(388), Tag(389), Tag(427), Tag(432), Tag(439), Tag(440),
]);
pub fn from_raw(raw: RawMessage) -> Self {
Self(raw)
}
pub fn raw(&self) -> &RawMessage {
&self.0
}
pub fn header(&self) -> Header<'_> {
Header(self.0.scope())
}
pub fn trailer(&self) -> Trailer<'_> {
Trailer(self.0.scope())
}
#[doc(alias = "OrderID")]
pub fn order_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(37))
}
#[doc(alias = "ClientID")]
pub fn client_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(109))
}
#[doc(alias = "ExecBroker")]
pub fn exec_broker(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(76))
}
#[doc(alias = "OrigClOrdID")]
pub fn orig_cl_ord_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(41))
}
#[doc(alias = "ClOrdID")]
pub fn cl_ord_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(11))
}
#[doc(alias = "ListID")]
pub fn list_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(66))
}
#[doc(alias = "Account")]
pub fn account(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(1))
}
#[doc(alias = "NoAllocs")]
pub fn allocs(&self) -> Result<Instances<'_, order_cancel_replace_request::allocs::Instance<'_>>, InvalidValue> {
self.0.get_group(&order_cancel_replace_request::allocs::TABLE, &Self::KNOWN_TAGS).map(Instances::from)
}
#[doc(alias = "SettlmntTyp")]
pub fn settlmnt_typ(&self) -> Result<Option<SettlmntTyp<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(63))?.map(SettlmntTyp::from_value))
}
#[doc(alias = "FutSettDate")]
pub fn fut_sett_date(&self) -> Result<Option<Date>, InvalidValue> {
self.0.get_date(Tag(64))
}
#[doc(alias = "HandlInst")]
pub fn handl_inst(&self) -> Result<Option<HandlInst<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(21))?.map(HandlInst::from_value))
}
#[doc(alias = "ExecInst")]
pub fn exec_inst(&self) -> Result<Option<MultipleValues<'_, ExecInst<'_>>>, InvalidValue> {
self.0.get_multiple_values(Tag(18))
}
#[doc(alias = "MinQty")]
pub fn min_qty(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(110))
}
#[doc(alias = "MaxFloor")]
pub fn max_floor(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(111))
}
#[doc(alias = "ExDestination")]
pub fn ex_destination(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(100))
}
#[doc(alias = "NoTradingSessions")]
pub fn trading_sessions(&self) -> Result<Instances<'_, order_cancel_replace_request::trading_sessions::Instance<'_>>, InvalidValue> {
self.0.get_group(&order_cancel_replace_request::trading_sessions::TABLE, &Self::KNOWN_TAGS).map(Instances::from)
}
#[doc(alias = "Symbol")]
pub fn symbol(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(55))
}
#[doc(alias = "SymbolSfx")]
pub fn symbol_sfx(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(65))
}
#[doc(alias = "SecurityID")]
pub fn security_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(48))
}
#[doc(alias = "IDSource")]
pub fn id_source(&self) -> Result<Option<IDSource<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(22))?.map(IDSource::from_value))
}
#[doc(alias = "SecurityType")]
pub fn security_type(&self) -> Result<Option<SecurityType<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(167))?.map(SecurityType::from_value))
}
#[doc(alias = "MaturityMonthYear")]
pub fn maturity_month_year(&self) -> Result<Option<MonthYear>, InvalidValue> {
self.0.get_month_year(Tag(200))
}
#[doc(alias = "MaturityDay")]
pub fn maturity_day(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(205))
}
#[doc(alias = "PutOrCall")]
pub fn put_or_call(&self) -> Result<Option<PutOrCall>, InvalidValue> {
Ok(self.0.get_int(Tag(201))?.map(PutOrCall::from_value))
}
#[doc(alias = "StrikePrice")]
pub fn strike_price(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(202))
}
#[doc(alias = "OptAttribute")]
pub fn opt_attribute(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(206))
}
#[doc(alias = "ContractMultiplier")]
pub fn contract_multiplier(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(231))
}
#[doc(alias = "CouponRate")]
pub fn coupon_rate(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(223))
}
#[doc(alias = "SecurityExchange")]
pub fn security_exchange(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(207))
}
#[doc(alias = "Issuer")]
pub fn issuer(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(106))
}
#[doc(alias = "EncodedIssuerLen")]
pub fn encoded_issuer_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(348))
}
#[doc(alias = "EncodedIssuer")]
pub fn encoded_issuer(&self) -> Option<&[u8]> {
self.0.get(Tag(349))
}
#[doc(alias = "SecurityDesc")]
pub fn security_desc(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(107))
}
#[doc(alias = "EncodedSecurityDescLen")]
pub fn encoded_security_desc_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(350))
}
#[doc(alias = "EncodedSecurityDesc")]
pub fn encoded_security_desc(&self) -> Option<&[u8]> {
self.0.get(Tag(351))
}
#[doc(alias = "Side")]
pub fn side(&self) -> Result<Option<Side<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(54))?.map(Side::from_value))
}
#[doc(alias = "TransactTime")]
pub fn transact_time(&self) -> Result<Option<UtcTimestamp>, InvalidValue> {
self.0.get_utc_timestamp(Tag(60))
}
#[doc(alias = "OrderQty")]
pub fn order_qty(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(38))
}
#[doc(alias = "CashOrderQty")]
pub fn cash_order_qty(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(152))
}
#[doc(alias = "OrdType")]
pub fn ord_type(&self) -> Result<Option<OrdType<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(40))?.map(OrdType::from_value))
}
#[doc(alias = "Price")]
pub fn price(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(44))
}
#[doc(alias = "StopPx")]
pub fn stop_px(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(99))
}
#[doc(alias = "PegDifference")]
pub fn peg_difference(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(211))
}
#[doc(alias = "DiscretionInst")]
pub fn discretion_inst(&self) -> Result<Option<DiscretionInst<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(388))?.map(DiscretionInst::from_value))
}
#[doc(alias = "DiscretionOffset")]
pub fn discretion_offset(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(389))
}
#[doc(alias = "ComplianceID")]
pub fn compliance_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(376))
}
#[doc(alias = "SolicitedFlag")]
pub fn solicited_flag(&self) -> Result<Option<bool>, InvalidValue> {
self.0.get_bool(Tag(377))
}
#[doc(alias = "Currency")]
pub fn currency(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(15))
}
#[doc(alias = "TimeInForce")]
pub fn time_in_force(&self) -> Result<Option<TimeInForce<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(59))?.map(TimeInForce::from_value))
}
#[doc(alias = "EffectiveTime")]
pub fn effective_time(&self) -> Result<Option<UtcTimestamp>, InvalidValue> {
self.0.get_utc_timestamp(Tag(168))
}
#[doc(alias = "ExpireDate")]
pub fn expire_date(&self) -> Result<Option<Date>, InvalidValue> {
self.0.get_date(Tag(432))
}
#[doc(alias = "ExpireTime")]
pub fn expire_time(&self) -> Result<Option<UtcTimestamp>, InvalidValue> {
self.0.get_utc_timestamp(Tag(126))
}
#[doc(alias = "GTBookingInst")]
pub fn gt_booking_inst(&self) -> Result<Option<GTBookingInst>, InvalidValue> {
Ok(self.0.get_int(Tag(427))?.map(GTBookingInst::from_value))
}
#[doc(alias = "Commission")]
pub fn commission(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(12))
}
#[doc(alias = "CommType")]
pub fn comm_type(&self) -> Result<Option<CommType<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(13))?.map(CommType::from_value))
}
#[doc(alias = "Rule80A")]
pub fn rule80_a(&self) -> Result<Option<Rule80A<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(47))?.map(Rule80A::from_value))
}
#[doc(alias = "ForexReq")]
pub fn forex_req(&self) -> Result<Option<bool>, InvalidValue> {
self.0.get_bool(Tag(121))
}
#[doc(alias = "SettlCurrency")]
pub fn settl_currency(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(120))
}
#[doc(alias = "Text")]
pub fn text(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(58))
}
#[doc(alias = "EncodedTextLen")]
pub fn encoded_text_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(354))
}
#[doc(alias = "EncodedText")]
pub fn encoded_text(&self) -> Option<&[u8]> {
self.0.get(Tag(355))
}
#[doc(alias = "FutSettDate2")]
pub fn fut_sett_date2(&self) -> Result<Option<Date>, InvalidValue> {
self.0.get_date(Tag(193))
}
#[doc(alias = "OrderQty2")]
pub fn order_qty2(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(192))
}
#[doc(alias = "OpenClose")]
pub fn open_close(&self) -> Result<Option<OpenClose<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(77))?.map(OpenClose::from_value))
}
#[doc(alias = "CoveredOrUncovered")]
pub fn covered_or_uncovered(&self) -> Result<Option<CoveredOrUncovered>, InvalidValue> {
Ok(self.0.get_int(Tag(203))?.map(CoveredOrUncovered::from_value))
}
#[doc(alias = "CustomerOrFirm")]
pub fn customer_or_firm(&self) -> Result<Option<CustomerOrFirm>, InvalidValue> {
Ok(self.0.get_int(Tag(204))?.map(CustomerOrFirm::from_value))
}
#[doc(alias = "MaxShow")]
pub fn max_show(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(210))
}
#[doc(alias = "LocateReqd")]
pub fn locate_reqd(&self) -> Result<Option<bool>, InvalidValue> {
self.0.get_bool(Tag(114))
}
#[doc(alias = "ClearingFirm")]
pub fn clearing_firm(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(439))
}
#[doc(alias = "ClearingAccount")]
pub fn clearing_account(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(440))
}
}
impl std::fmt::Debug for OrderCancelReplaceRequest {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "OrderCancelReplaceRequest({})", self.0)
}
}
impl std::fmt::Display for OrderCancelReplaceRequest {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
std::fmt::Display::fmt(&self.0, f)
}
}
pub mod order_cancel_replace_request {
pub mod allocs {
use super::super::*;
pub const TABLE: GroupTable<'static> = GroupTable::new(
Tag(78),
Tag(79),
&[Tag(79), Tag(80)],
&[],
);
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[Tag(79), Tag(80)]);
#[derive(Clone, Copy, Debug)]
pub struct Instance<'a>(refix_message::Scope<'a>);
impl<'a> From<refix_message::Scope<'a>> for Instance<'a> {
fn from(scope: refix_message::Scope<'a>) -> Self {
Self(scope)
}
}
impl<'a> Instance<'a> {
pub fn raw(&self) -> refix_message::Scope<'a> {
self.0
}
#[doc(alias = "AllocAccount")]
pub fn alloc_account(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(79))
}
#[doc(alias = "AllocShares")]
pub fn alloc_shares(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(80))
}
}
}
pub mod trading_sessions {
use super::super::*;
pub const TABLE: GroupTable<'static> = GroupTable::new(
Tag(386),
Tag(336),
&[Tag(336)],
&[],
);
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[Tag(336)]);
#[derive(Clone, Copy, Debug)]
pub struct Instance<'a>(refix_message::Scope<'a>);
impl<'a> From<refix_message::Scope<'a>> for Instance<'a> {
fn from(scope: refix_message::Scope<'a>) -> Self {
Self(scope)
}
}
impl<'a> Instance<'a> {
pub fn raw(&self) -> refix_message::Scope<'a> {
self.0
}
#[doc(alias = "TradingSessionID")]
pub fn trading_session_id(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(336))
}
}
}
}
pub struct OrderStatusRequest(RawMessage);
impl OrderStatusRequest {
pub const MSG_TYPE: &[u8] = b"H";
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(1), Tag(8), Tag(9), Tag(10), Tag(11), Tag(22), Tag(34), Tag(35), Tag(37), Tag(43),
Tag(48), Tag(49), Tag(50), Tag(52), Tag(54), Tag(55), Tag(56), Tag(57), Tag(65), Tag(76),
Tag(89), Tag(90), Tag(91), Tag(93), Tag(97), Tag(106), Tag(107), Tag(109), Tag(115),
Tag(116), Tag(122), Tag(128), Tag(129), Tag(142), Tag(143), Tag(144), Tag(145), Tag(167),
Tag(200), Tag(201), Tag(202), Tag(205), Tag(206), Tag(207), Tag(212), Tag(213), Tag(223),
Tag(231), Tag(347), Tag(348), Tag(349), Tag(350), Tag(351), Tag(369), Tag(370),
]);
pub fn from_raw(raw: RawMessage) -> Self {
Self(raw)
}
pub fn raw(&self) -> &RawMessage {
&self.0
}
pub fn header(&self) -> Header<'_> {
Header(self.0.scope())
}
pub fn trailer(&self) -> Trailer<'_> {
Trailer(self.0.scope())
}
#[doc(alias = "OrderID")]
pub fn order_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(37))
}
#[doc(alias = "ClOrdID")]
pub fn cl_ord_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(11))
}
#[doc(alias = "ClientID")]
pub fn client_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(109))
}
#[doc(alias = "Account")]
pub fn account(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(1))
}
#[doc(alias = "ExecBroker")]
pub fn exec_broker(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(76))
}
#[doc(alias = "Symbol")]
pub fn symbol(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(55))
}
#[doc(alias = "SymbolSfx")]
pub fn symbol_sfx(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(65))
}
#[doc(alias = "SecurityID")]
pub fn security_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(48))
}
#[doc(alias = "IDSource")]
pub fn id_source(&self) -> Result<Option<IDSource<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(22))?.map(IDSource::from_value))
}
#[doc(alias = "SecurityType")]
pub fn security_type(&self) -> Result<Option<SecurityType<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(167))?.map(SecurityType::from_value))
}
#[doc(alias = "MaturityMonthYear")]
pub fn maturity_month_year(&self) -> Result<Option<MonthYear>, InvalidValue> {
self.0.get_month_year(Tag(200))
}
#[doc(alias = "MaturityDay")]
pub fn maturity_day(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(205))
}
#[doc(alias = "PutOrCall")]
pub fn put_or_call(&self) -> Result<Option<PutOrCall>, InvalidValue> {
Ok(self.0.get_int(Tag(201))?.map(PutOrCall::from_value))
}
#[doc(alias = "StrikePrice")]
pub fn strike_price(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(202))
}
#[doc(alias = "OptAttribute")]
pub fn opt_attribute(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(206))
}
#[doc(alias = "ContractMultiplier")]
pub fn contract_multiplier(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(231))
}
#[doc(alias = "CouponRate")]
pub fn coupon_rate(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(223))
}
#[doc(alias = "SecurityExchange")]
pub fn security_exchange(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(207))
}
#[doc(alias = "Issuer")]
pub fn issuer(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(106))
}
#[doc(alias = "EncodedIssuerLen")]
pub fn encoded_issuer_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(348))
}
#[doc(alias = "EncodedIssuer")]
pub fn encoded_issuer(&self) -> Option<&[u8]> {
self.0.get(Tag(349))
}
#[doc(alias = "SecurityDesc")]
pub fn security_desc(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(107))
}
#[doc(alias = "EncodedSecurityDescLen")]
pub fn encoded_security_desc_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(350))
}
#[doc(alias = "EncodedSecurityDesc")]
pub fn encoded_security_desc(&self) -> Option<&[u8]> {
self.0.get(Tag(351))
}
#[doc(alias = "Side")]
pub fn side(&self) -> Result<Option<Side<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(54))?.map(Side::from_value))
}
}
impl std::fmt::Debug for OrderStatusRequest {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "OrderStatusRequest({})", self.0)
}
}
impl std::fmt::Display for OrderStatusRequest {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
std::fmt::Display::fmt(&self.0, f)
}
}
pub struct Allocation(RawMessage);
impl Allocation {
pub const MSG_TYPE: &[u8] = b"J";
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(6), Tag(8), Tag(9), Tag(10), Tag(11), Tag(12), Tag(13), Tag(15), Tag(17), Tag(22),
Tag(29), Tag(30), Tag(31), Tag(32), Tag(34), Tag(35), Tag(37), Tag(43), Tag(48), Tag(49),
Tag(50), Tag(52), Tag(53), Tag(54), Tag(55), Tag(56), Tag(57), Tag(58), Tag(60), Tag(63),
Tag(64), Tag(65), Tag(66), Tag(70), Tag(71), Tag(72), Tag(73), Tag(74), Tag(75), Tag(76),
Tag(77), Tag(78), Tag(79), Tag(80), Tag(81), Tag(89), Tag(90), Tag(91), Tag(92), Tag(93),
Tag(97), Tag(105), Tag(106), Tag(107), Tag(109), Tag(115), Tag(116), Tag(118), Tag(119),
Tag(120), Tag(122), Tag(124), Tag(128), Tag(129), Tag(136), Tag(137), Tag(138), Tag(139),
Tag(142), Tag(143), Tag(144), Tag(145), Tag(153), Tag(154), Tag(155), Tag(156), Tag(157),
Tag(158), Tag(159), Tag(160), Tag(161), Tag(167), Tag(196), Tag(197), Tag(198), Tag(200),
Tag(201), Tag(202), Tag(205), Tag(206), Tag(207), Tag(208), Tag(209), Tag(212), Tag(213),
Tag(223), Tag(231), Tag(336), Tag(347), Tag(348), Tag(349), Tag(350), Tag(351), Tag(354),
Tag(355), Tag(360), Tag(361), Tag(366), Tag(369), Tag(370), Tag(381),
]);
pub fn from_raw(raw: RawMessage) -> Self {
Self(raw)
}
pub fn raw(&self) -> &RawMessage {
&self.0
}
pub fn header(&self) -> Header<'_> {
Header(self.0.scope())
}
pub fn trailer(&self) -> Trailer<'_> {
Trailer(self.0.scope())
}
#[doc(alias = "AllocID")]
pub fn alloc_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(70))
}
#[doc(alias = "AllocTransType")]
pub fn alloc_trans_type(&self) -> Result<Option<AllocTransType<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(71))?.map(AllocTransType::from_value))
}
#[doc(alias = "RefAllocID")]
pub fn ref_alloc_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(72))
}
#[doc(alias = "AllocLinkID")]
pub fn alloc_link_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(196))
}
#[doc(alias = "AllocLinkType")]
pub fn alloc_link_type(&self) -> Result<Option<AllocLinkType>, InvalidValue> {
Ok(self.0.get_int(Tag(197))?.map(AllocLinkType::from_value))
}
#[doc(alias = "NoOrders")]
pub fn orders(&self) -> Result<Instances<'_, allocation::orders::Instance<'_>>, InvalidValue> {
self.0.get_group(&allocation::orders::TABLE, &Self::KNOWN_TAGS).map(Instances::from)
}
#[doc(alias = "NoExecs")]
pub fn execs(&self) -> Result<Instances<'_, allocation::execs::Instance<'_>>, InvalidValue> {
self.0.get_group(&allocation::execs::TABLE, &Self::KNOWN_TAGS).map(Instances::from)
}
#[doc(alias = "Side")]
pub fn side(&self) -> Result<Option<Side<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(54))?.map(Side::from_value))
}
#[doc(alias = "Symbol")]
pub fn symbol(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(55))
}
#[doc(alias = "SymbolSfx")]
pub fn symbol_sfx(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(65))
}
#[doc(alias = "SecurityID")]
pub fn security_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(48))
}
#[doc(alias = "IDSource")]
pub fn id_source(&self) -> Result<Option<IDSource<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(22))?.map(IDSource::from_value))
}
#[doc(alias = "SecurityType")]
pub fn security_type(&self) -> Result<Option<SecurityType<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(167))?.map(SecurityType::from_value))
}
#[doc(alias = "MaturityMonthYear")]
pub fn maturity_month_year(&self) -> Result<Option<MonthYear>, InvalidValue> {
self.0.get_month_year(Tag(200))
}
#[doc(alias = "MaturityDay")]
pub fn maturity_day(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(205))
}
#[doc(alias = "PutOrCall")]
pub fn put_or_call(&self) -> Result<Option<PutOrCall>, InvalidValue> {
Ok(self.0.get_int(Tag(201))?.map(PutOrCall::from_value))
}
#[doc(alias = "StrikePrice")]
pub fn strike_price(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(202))
}
#[doc(alias = "OptAttribute")]
pub fn opt_attribute(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(206))
}
#[doc(alias = "ContractMultiplier")]
pub fn contract_multiplier(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(231))
}
#[doc(alias = "CouponRate")]
pub fn coupon_rate(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(223))
}
#[doc(alias = "SecurityExchange")]
pub fn security_exchange(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(207))
}
#[doc(alias = "Issuer")]
pub fn issuer(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(106))
}
#[doc(alias = "EncodedIssuerLen")]
pub fn encoded_issuer_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(348))
}
#[doc(alias = "EncodedIssuer")]
pub fn encoded_issuer(&self) -> Option<&[u8]> {
self.0.get(Tag(349))
}
#[doc(alias = "SecurityDesc")]
pub fn security_desc(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(107))
}
#[doc(alias = "EncodedSecurityDescLen")]
pub fn encoded_security_desc_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(350))
}
#[doc(alias = "EncodedSecurityDesc")]
pub fn encoded_security_desc(&self) -> Option<&[u8]> {
self.0.get(Tag(351))
}
#[doc(alias = "Shares")]
pub fn shares(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(53))
}
#[doc(alias = "LastMkt")]
pub fn last_mkt(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(30))
}
#[doc(alias = "TradingSessionID")]
pub fn trading_session_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(336))
}
#[doc(alias = "AvgPx")]
pub fn avg_px(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(6))
}
#[doc(alias = "Currency")]
pub fn currency(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(15))
}
#[doc(alias = "AvgPrxPrecision")]
pub fn avg_prx_precision(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(74))
}
#[doc(alias = "TradeDate")]
pub fn trade_date(&self) -> Result<Option<Date>, InvalidValue> {
self.0.get_date(Tag(75))
}
#[doc(alias = "TransactTime")]
pub fn transact_time(&self) -> Result<Option<UtcTimestamp>, InvalidValue> {
self.0.get_utc_timestamp(Tag(60))
}
#[doc(alias = "SettlmntTyp")]
pub fn settlmnt_typ(&self) -> Result<Option<SettlmntTyp<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(63))?.map(SettlmntTyp::from_value))
}
#[doc(alias = "FutSettDate")]
pub fn fut_sett_date(&self) -> Result<Option<Date>, InvalidValue> {
self.0.get_date(Tag(64))
}
#[doc(alias = "GrossTradeAmt")]
pub fn gross_trade_amt(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(381))
}
#[doc(alias = "NetMoney")]
pub fn net_money(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(118))
}
#[doc(alias = "OpenClose")]
pub fn open_close(&self) -> Result<Option<OpenClose<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(77))?.map(OpenClose::from_value))
}
#[doc(alias = "Text")]
pub fn text(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(58))
}
#[doc(alias = "EncodedTextLen")]
pub fn encoded_text_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(354))
}
#[doc(alias = "EncodedText")]
pub fn encoded_text(&self) -> Option<&[u8]> {
self.0.get(Tag(355))
}
#[doc(alias = "NumDaysInterest")]
pub fn num_days_interest(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(157))
}
#[doc(alias = "AccruedInterestRate")]
pub fn accrued_interest_rate(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(158))
}
#[doc(alias = "NoAllocs")]
pub fn allocs(&self) -> Result<Instances<'_, allocation::allocs::Instance<'_>>, InvalidValue> {
self.0.get_group(&allocation::allocs::TABLE, &Self::KNOWN_TAGS).map(Instances::from)
}
}
impl std::fmt::Debug for Allocation {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "Allocation({})", self.0)
}
}
impl std::fmt::Display for Allocation {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
std::fmt::Display::fmt(&self.0, f)
}
}
pub mod allocation {
pub mod orders {
use super::super::*;
pub const TABLE: GroupTable<'static> = GroupTable::new(
Tag(73),
Tag(11),
&[Tag(11), Tag(37), Tag(66), Tag(105), Tag(198)],
&[],
);
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(11), Tag(37), Tag(66), Tag(105), Tag(198),
]);
#[derive(Clone, Copy, Debug)]
pub struct Instance<'a>(refix_message::Scope<'a>);
impl<'a> From<refix_message::Scope<'a>> for Instance<'a> {
fn from(scope: refix_message::Scope<'a>) -> Self {
Self(scope)
}
}
impl<'a> Instance<'a> {
pub fn raw(&self) -> refix_message::Scope<'a> {
self.0
}
#[doc(alias = "ClOrdID")]
pub fn cl_ord_id(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(11))
}
#[doc(alias = "OrderID")]
pub fn order_id(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(37))
}
#[doc(alias = "SecondaryOrderID")]
pub fn secondary_order_id(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(198))
}
#[doc(alias = "ListID")]
pub fn list_id(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(66))
}
#[doc(alias = "WaveNo")]
pub fn wave_no(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(105))
}
}
}
pub mod execs {
use super::super::*;
pub const TABLE: GroupTable<'static> = GroupTable::new(
Tag(124),
Tag(32),
&[Tag(17), Tag(29), Tag(31), Tag(32)],
&[],
);
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(17), Tag(29), Tag(31), Tag(32),
]);
#[derive(Clone, Copy, Debug)]
pub struct Instance<'a>(refix_message::Scope<'a>);
impl<'a> From<refix_message::Scope<'a>> for Instance<'a> {
fn from(scope: refix_message::Scope<'a>) -> Self {
Self(scope)
}
}
impl<'a> Instance<'a> {
pub fn raw(&self) -> refix_message::Scope<'a> {
self.0
}
#[doc(alias = "LastShares")]
pub fn last_shares(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(32))
}
#[doc(alias = "ExecID")]
pub fn exec_id(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(17))
}
#[doc(alias = "LastPx")]
pub fn last_px(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(31))
}
#[doc(alias = "LastCapacity")]
pub fn last_capacity(&self) -> Result<Option<LastCapacity<'a>>, InvalidValue> {
Ok(self.0.get_str(Tag(29))?.map(LastCapacity::from_value))
}
}
}
pub mod allocs {
use super::super::*;
pub const TABLE: GroupTable<'static> = GroupTable::new(
Tag(78),
Tag(79),
&[
Tag(12), Tag(13), Tag(76), Tag(79), Tag(80), Tag(81), Tag(92), Tag(109), Tag(119),
Tag(120), Tag(136), Tag(153), Tag(154), Tag(155), Tag(156), Tag(159), Tag(160),
Tag(161), Tag(208), Tag(209), Tag(360), Tag(361), Tag(366),
],
&[allocation::allocs::misc_fees::TABLE],
);
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(12), Tag(13), Tag(76), Tag(79), Tag(80), Tag(81), Tag(92), Tag(109), Tag(119),
Tag(120), Tag(136), Tag(137), Tag(138), Tag(139), Tag(153), Tag(154), Tag(155),
Tag(156), Tag(159), Tag(160), Tag(161), Tag(208), Tag(209), Tag(360), Tag(361),
Tag(366),
]);
#[derive(Clone, Copy, Debug)]
pub struct Instance<'a>(refix_message::Scope<'a>);
impl<'a> From<refix_message::Scope<'a>> for Instance<'a> {
fn from(scope: refix_message::Scope<'a>) -> Self {
Self(scope)
}
}
impl<'a> Instance<'a> {
pub fn raw(&self) -> refix_message::Scope<'a> {
self.0
}
#[doc(alias = "AllocAccount")]
pub fn alloc_account(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(79))
}
#[doc(alias = "AllocPrice")]
pub fn alloc_price(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(366))
}
#[doc(alias = "AllocShares")]
pub fn alloc_shares(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(80))
}
#[doc(alias = "ProcessCode")]
pub fn process_code(&self) -> Result<Option<ProcessCode<'a>>, InvalidValue> {
Ok(self.0.get_str(Tag(81))?.map(ProcessCode::from_value))
}
#[doc(alias = "BrokerOfCredit")]
pub fn broker_of_credit(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(92))
}
#[doc(alias = "NotifyBrokerOfCredit")]
pub fn notify_broker_of_credit(&self) -> Result<Option<bool>, InvalidValue> {
self.0.get_bool(Tag(208))
}
#[doc(alias = "AllocHandlInst")]
pub fn alloc_handl_inst(&self) -> Result<Option<AllocHandlInst>, InvalidValue> {
Ok(self.0.get_int(Tag(209))?.map(AllocHandlInst::from_value))
}
#[doc(alias = "AllocText")]
pub fn alloc_text(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(161))
}
#[doc(alias = "EncodedAllocTextLen")]
pub fn encoded_alloc_text_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(360))
}
#[doc(alias = "EncodedAllocText")]
pub fn encoded_alloc_text(&self) -> Option<&'a [u8]> {
self.0.get(Tag(361))
}
#[doc(alias = "ExecBroker")]
pub fn exec_broker(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(76))
}
#[doc(alias = "ClientID")]
pub fn client_id(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(109))
}
#[doc(alias = "Commission")]
pub fn commission(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(12))
}
#[doc(alias = "CommType")]
pub fn comm_type(&self) -> Result<Option<CommType<'a>>, InvalidValue> {
Ok(self.0.get_str(Tag(13))?.map(CommType::from_value))
}
#[doc(alias = "AllocAvgPx")]
pub fn alloc_avg_px(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(153))
}
#[doc(alias = "AllocNetMoney")]
pub fn alloc_net_money(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(154))
}
#[doc(alias = "SettlCurrAmt")]
pub fn settl_curr_amt(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(119))
}
#[doc(alias = "SettlCurrency")]
pub fn settl_currency(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(120))
}
#[doc(alias = "SettlCurrFxRate")]
pub fn settl_curr_fx_rate(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(155))
}
#[doc(alias = "SettlCurrFxRateCalc")]
pub fn settl_curr_fx_rate_calc(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(156))
}
#[doc(alias = "AccruedInterestAmt")]
pub fn accrued_interest_amt(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(159))
}
#[doc(alias = "SettlInstMode")]
pub fn settl_inst_mode(&self) -> Result<Option<SettlInstMode<'a>>, InvalidValue> {
Ok(self.0.get_str(Tag(160))?.map(SettlInstMode::from_value))
}
#[doc(alias = "NoMiscFees")]
pub fn misc_fees(&self) -> Result<Instances<'a, allocation::allocs::misc_fees::Instance<'a>>, InvalidValue> {
self.0.get_group(&allocation::allocs::misc_fees::TABLE, &KNOWN_TAGS).map(Instances::from)
}
}
pub mod misc_fees {
use super::super::super::*;
pub const TABLE: GroupTable<'static> = GroupTable::new(
Tag(136),
Tag(137),
&[Tag(137), Tag(138), Tag(139)],
&[],
);
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(137), Tag(138), Tag(139),
]);
#[derive(Clone, Copy, Debug)]
pub struct Instance<'a>(refix_message::Scope<'a>);
impl<'a> From<refix_message::Scope<'a>> for Instance<'a> {
fn from(scope: refix_message::Scope<'a>) -> Self {
Self(scope)
}
}
impl<'a> Instance<'a> {
pub fn raw(&self) -> refix_message::Scope<'a> {
self.0
}
#[doc(alias = "MiscFeeAmt")]
pub fn misc_fee_amt(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(137))
}
#[doc(alias = "MiscFeeCurr")]
pub fn misc_fee_curr(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(138))
}
#[doc(alias = "MiscFeeType")]
pub fn misc_fee_type(&self) -> Result<Option<MiscFeeType<'a>>, InvalidValue> {
Ok(self.0.get_str(Tag(139))?.map(MiscFeeType::from_value))
}
}
}
}
}
pub struct ListCancelRequest(RawMessage);
impl ListCancelRequest {
pub const MSG_TYPE: &[u8] = b"K";
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(8), Tag(9), Tag(10), Tag(34), Tag(35), Tag(43), Tag(49), Tag(50), Tag(52), Tag(56),
Tag(57), Tag(58), Tag(60), Tag(66), Tag(89), Tag(90), Tag(91), Tag(93), Tag(97), Tag(115),
Tag(116), Tag(122), Tag(128), Tag(129), Tag(142), Tag(143), Tag(144), Tag(145), Tag(212),
Tag(213), Tag(347), Tag(354), Tag(355), Tag(369), Tag(370),
]);
pub fn from_raw(raw: RawMessage) -> Self {
Self(raw)
}
pub fn raw(&self) -> &RawMessage {
&self.0
}
pub fn header(&self) -> Header<'_> {
Header(self.0.scope())
}
pub fn trailer(&self) -> Trailer<'_> {
Trailer(self.0.scope())
}
#[doc(alias = "ListID")]
pub fn list_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(66))
}
#[doc(alias = "TransactTime")]
pub fn transact_time(&self) -> Result<Option<UtcTimestamp>, InvalidValue> {
self.0.get_utc_timestamp(Tag(60))
}
#[doc(alias = "Text")]
pub fn text(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(58))
}
#[doc(alias = "EncodedTextLen")]
pub fn encoded_text_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(354))
}
#[doc(alias = "EncodedText")]
pub fn encoded_text(&self) -> Option<&[u8]> {
self.0.get(Tag(355))
}
}
impl std::fmt::Debug for ListCancelRequest {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "ListCancelRequest({})", self.0)
}
}
impl std::fmt::Display for ListCancelRequest {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
std::fmt::Display::fmt(&self.0, f)
}
}
pub struct ListExecute(RawMessage);
impl ListExecute {
pub const MSG_TYPE: &[u8] = b"L";
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(8), Tag(9), Tag(10), Tag(34), Tag(35), Tag(43), Tag(49), Tag(50), Tag(52), Tag(56),
Tag(57), Tag(58), Tag(60), Tag(66), Tag(89), Tag(90), Tag(91), Tag(93), Tag(97), Tag(115),
Tag(116), Tag(122), Tag(128), Tag(129), Tag(142), Tag(143), Tag(144), Tag(145), Tag(212),
Tag(213), Tag(347), Tag(354), Tag(355), Tag(369), Tag(370), Tag(390), Tag(391),
]);
pub fn from_raw(raw: RawMessage) -> Self {
Self(raw)
}
pub fn raw(&self) -> &RawMessage {
&self.0
}
pub fn header(&self) -> Header<'_> {
Header(self.0.scope())
}
pub fn trailer(&self) -> Trailer<'_> {
Trailer(self.0.scope())
}
#[doc(alias = "ListID")]
pub fn list_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(66))
}
#[doc(alias = "ClientBidID")]
pub fn client_bid_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(391))
}
#[doc(alias = "BidID")]
pub fn bid_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(390))
}
#[doc(alias = "TransactTime")]
pub fn transact_time(&self) -> Result<Option<UtcTimestamp>, InvalidValue> {
self.0.get_utc_timestamp(Tag(60))
}
#[doc(alias = "Text")]
pub fn text(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(58))
}
#[doc(alias = "EncodedTextLen")]
pub fn encoded_text_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(354))
}
#[doc(alias = "EncodedText")]
pub fn encoded_text(&self) -> Option<&[u8]> {
self.0.get(Tag(355))
}
}
impl std::fmt::Debug for ListExecute {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "ListExecute({})", self.0)
}
}
impl std::fmt::Display for ListExecute {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
std::fmt::Display::fmt(&self.0, f)
}
}
pub struct ListStatusRequest(RawMessage);
impl ListStatusRequest {
pub const MSG_TYPE: &[u8] = b"M";
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(8), Tag(9), Tag(10), Tag(34), Tag(35), Tag(43), Tag(49), Tag(50), Tag(52), Tag(56),
Tag(57), Tag(58), Tag(66), Tag(89), Tag(90), Tag(91), Tag(93), Tag(97), Tag(115), Tag(116),
Tag(122), Tag(128), Tag(129), Tag(142), Tag(143), Tag(144), Tag(145), Tag(212), Tag(213),
Tag(347), Tag(354), Tag(355), Tag(369), Tag(370),
]);
pub fn from_raw(raw: RawMessage) -> Self {
Self(raw)
}
pub fn raw(&self) -> &RawMessage {
&self.0
}
pub fn header(&self) -> Header<'_> {
Header(self.0.scope())
}
pub fn trailer(&self) -> Trailer<'_> {
Trailer(self.0.scope())
}
#[doc(alias = "ListID")]
pub fn list_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(66))
}
#[doc(alias = "Text")]
pub fn text(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(58))
}
#[doc(alias = "EncodedTextLen")]
pub fn encoded_text_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(354))
}
#[doc(alias = "EncodedText")]
pub fn encoded_text(&self) -> Option<&[u8]> {
self.0.get(Tag(355))
}
}
impl std::fmt::Debug for ListStatusRequest {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "ListStatusRequest({})", self.0)
}
}
impl std::fmt::Display for ListStatusRequest {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
std::fmt::Display::fmt(&self.0, f)
}
}
pub struct ListStatus(RawMessage);
impl ListStatus {
pub const MSG_TYPE: &[u8] = b"N";
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(6), Tag(8), Tag(9), Tag(10), Tag(11), Tag(14), Tag(34), Tag(35), Tag(39), Tag(43),
Tag(49), Tag(50), Tag(52), Tag(56), Tag(57), Tag(58), Tag(60), Tag(66), Tag(68), Tag(73),
Tag(82), Tag(83), Tag(84), Tag(89), Tag(90), Tag(91), Tag(93), Tag(97), Tag(103), Tag(115),
Tag(116), Tag(122), Tag(128), Tag(129), Tag(142), Tag(143), Tag(144), Tag(145), Tag(151),
Tag(212), Tag(213), Tag(347), Tag(354), Tag(355), Tag(369), Tag(370), Tag(429), Tag(431),
Tag(444), Tag(445), Tag(446),
]);
pub fn from_raw(raw: RawMessage) -> Self {
Self(raw)
}
pub fn raw(&self) -> &RawMessage {
&self.0
}
pub fn header(&self) -> Header<'_> {
Header(self.0.scope())
}
pub fn trailer(&self) -> Trailer<'_> {
Trailer(self.0.scope())
}
#[doc(alias = "ListID")]
pub fn list_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(66))
}
#[doc(alias = "ListStatusType")]
pub fn list_status_type(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(429))
}
#[doc(alias = "NoRpts")]
pub fn no_rpts(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(82))
}
#[doc(alias = "ListOrderStatus")]
pub fn list_order_status(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(431))
}
#[doc(alias = "RptSeq")]
pub fn rpt_seq(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(83))
}
#[doc(alias = "ListStatusText")]
pub fn list_status_text(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(444))
}
#[doc(alias = "EncodedListStatusTextLen")]
pub fn encoded_list_status_text_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(445))
}
#[doc(alias = "EncodedListStatusText")]
pub fn encoded_list_status_text(&self) -> Option<&[u8]> {
self.0.get(Tag(446))
}
#[doc(alias = "TransactTime")]
pub fn transact_time(&self) -> Result<Option<UtcTimestamp>, InvalidValue> {
self.0.get_utc_timestamp(Tag(60))
}
#[doc(alias = "TotNoOrders")]
pub fn tot_no_orders(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(68))
}
#[doc(alias = "NoOrders")]
pub fn orders(&self) -> Result<Instances<'_, list_status::orders::Instance<'_>>, InvalidValue> {
self.0.get_group(&list_status::orders::TABLE, &Self::KNOWN_TAGS).map(Instances::from)
}
}
impl std::fmt::Debug for ListStatus {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "ListStatus({})", self.0)
}
}
impl std::fmt::Display for ListStatus {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
std::fmt::Display::fmt(&self.0, f)
}
}
pub mod list_status {
pub mod orders {
use super::super::*;
pub const TABLE: GroupTable<'static> = GroupTable::new(
Tag(73),
Tag(11),
&[
Tag(6), Tag(11), Tag(14), Tag(39), Tag(58), Tag(84), Tag(103), Tag(151), Tag(354),
Tag(355),
],
&[],
);
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(6), Tag(11), Tag(14), Tag(39), Tag(58), Tag(84), Tag(103), Tag(151), Tag(354),
Tag(355),
]);
#[derive(Clone, Copy, Debug)]
pub struct Instance<'a>(refix_message::Scope<'a>);
impl<'a> From<refix_message::Scope<'a>> for Instance<'a> {
fn from(scope: refix_message::Scope<'a>) -> Self {
Self(scope)
}
}
impl<'a> Instance<'a> {
pub fn raw(&self) -> refix_message::Scope<'a> {
self.0
}
#[doc(alias = "ClOrdID")]
pub fn cl_ord_id(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(11))
}
#[doc(alias = "CumQty")]
pub fn cum_qty(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(14))
}
#[doc(alias = "OrdStatus")]
pub fn ord_status(&self) -> Result<Option<OrdStatus<'a>>, InvalidValue> {
Ok(self.0.get_str(Tag(39))?.map(OrdStatus::from_value))
}
#[doc(alias = "LeavesQty")]
pub fn leaves_qty(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(151))
}
#[doc(alias = "CxlQty")]
pub fn cxl_qty(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(84))
}
#[doc(alias = "AvgPx")]
pub fn avg_px(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(6))
}
#[doc(alias = "OrdRejReason")]
pub fn ord_rej_reason(&self) -> Result<Option<OrdRejReason>, InvalidValue> {
Ok(self.0.get_int(Tag(103))?.map(OrdRejReason::from_value))
}
#[doc(alias = "Text")]
pub fn text(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(58))
}
#[doc(alias = "EncodedTextLen")]
pub fn encoded_text_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(354))
}
#[doc(alias = "EncodedText")]
pub fn encoded_text(&self) -> Option<&'a [u8]> {
self.0.get(Tag(355))
}
}
}
}
pub struct AllocationInstructionAck(RawMessage);
impl AllocationInstructionAck {
pub const MSG_TYPE: &[u8] = b"P";
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(8), Tag(9), Tag(10), Tag(34), Tag(35), Tag(43), Tag(49), Tag(50), Tag(52), Tag(56),
Tag(57), Tag(58), Tag(60), Tag(70), Tag(75), Tag(76), Tag(87), Tag(88), Tag(89), Tag(90),
Tag(91), Tag(93), Tag(97), Tag(109), Tag(115), Tag(116), Tag(122), Tag(128), Tag(129),
Tag(142), Tag(143), Tag(144), Tag(145), Tag(212), Tag(213), Tag(347), Tag(354), Tag(355),
Tag(369), Tag(370),
]);
pub fn from_raw(raw: RawMessage) -> Self {
Self(raw)
}
pub fn raw(&self) -> &RawMessage {
&self.0
}
pub fn header(&self) -> Header<'_> {
Header(self.0.scope())
}
pub fn trailer(&self) -> Trailer<'_> {
Trailer(self.0.scope())
}
#[doc(alias = "ClientID")]
pub fn client_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(109))
}
#[doc(alias = "ExecBroker")]
pub fn exec_broker(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(76))
}
#[doc(alias = "AllocID")]
pub fn alloc_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(70))
}
#[doc(alias = "TradeDate")]
pub fn trade_date(&self) -> Result<Option<Date>, InvalidValue> {
self.0.get_date(Tag(75))
}
#[doc(alias = "TransactTime")]
pub fn transact_time(&self) -> Result<Option<UtcTimestamp>, InvalidValue> {
self.0.get_utc_timestamp(Tag(60))
}
#[doc(alias = "AllocStatus")]
pub fn alloc_status(&self) -> Result<Option<AllocStatus>, InvalidValue> {
Ok(self.0.get_int(Tag(87))?.map(AllocStatus::from_value))
}
#[doc(alias = "AllocRejCode")]
pub fn alloc_rej_code(&self) -> Result<Option<AllocRejCode>, InvalidValue> {
Ok(self.0.get_int(Tag(88))?.map(AllocRejCode::from_value))
}
#[doc(alias = "Text")]
pub fn text(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(58))
}
#[doc(alias = "EncodedTextLen")]
pub fn encoded_text_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(354))
}
#[doc(alias = "EncodedText")]
pub fn encoded_text(&self) -> Option<&[u8]> {
self.0.get(Tag(355))
}
}
impl std::fmt::Debug for AllocationInstructionAck {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "AllocationInstructionAck({})", self.0)
}
}
impl std::fmt::Display for AllocationInstructionAck {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
std::fmt::Display::fmt(&self.0, f)
}
}
pub struct DontKnowTrade(RawMessage);
impl DontKnowTrade {
pub const MSG_TYPE: &[u8] = b"Q";
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(8), Tag(9), Tag(10), Tag(17), Tag(22), Tag(31), Tag(32), Tag(34), Tag(35), Tag(37),
Tag(38), Tag(43), Tag(48), Tag(49), Tag(50), Tag(52), Tag(54), Tag(55), Tag(56), Tag(57),
Tag(58), Tag(65), Tag(89), Tag(90), Tag(91), Tag(93), Tag(97), Tag(106), Tag(107), Tag(115),
Tag(116), Tag(122), Tag(127), Tag(128), Tag(129), Tag(142), Tag(143), Tag(144), Tag(145),
Tag(152), Tag(167), Tag(200), Tag(201), Tag(202), Tag(205), Tag(206), Tag(207), Tag(212),
Tag(213), Tag(223), Tag(231), Tag(347), Tag(348), Tag(349), Tag(350), Tag(351), Tag(354),
Tag(355), Tag(369), Tag(370),
]);
pub fn from_raw(raw: RawMessage) -> Self {
Self(raw)
}
pub fn raw(&self) -> &RawMessage {
&self.0
}
pub fn header(&self) -> Header<'_> {
Header(self.0.scope())
}
pub fn trailer(&self) -> Trailer<'_> {
Trailer(self.0.scope())
}
#[doc(alias = "OrderID")]
pub fn order_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(37))
}
#[doc(alias = "ExecID")]
pub fn exec_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(17))
}
#[doc(alias = "DKReason")]
pub fn dk_reason(&self) -> Result<Option<DKReason<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(127))?.map(DKReason::from_value))
}
#[doc(alias = "Symbol")]
pub fn symbol(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(55))
}
#[doc(alias = "SymbolSfx")]
pub fn symbol_sfx(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(65))
}
#[doc(alias = "SecurityID")]
pub fn security_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(48))
}
#[doc(alias = "IDSource")]
pub fn id_source(&self) -> Result<Option<IDSource<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(22))?.map(IDSource::from_value))
}
#[doc(alias = "SecurityType")]
pub fn security_type(&self) -> Result<Option<SecurityType<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(167))?.map(SecurityType::from_value))
}
#[doc(alias = "MaturityMonthYear")]
pub fn maturity_month_year(&self) -> Result<Option<MonthYear>, InvalidValue> {
self.0.get_month_year(Tag(200))
}
#[doc(alias = "MaturityDay")]
pub fn maturity_day(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(205))
}
#[doc(alias = "PutOrCall")]
pub fn put_or_call(&self) -> Result<Option<PutOrCall>, InvalidValue> {
Ok(self.0.get_int(Tag(201))?.map(PutOrCall::from_value))
}
#[doc(alias = "StrikePrice")]
pub fn strike_price(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(202))
}
#[doc(alias = "OptAttribute")]
pub fn opt_attribute(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(206))
}
#[doc(alias = "ContractMultiplier")]
pub fn contract_multiplier(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(231))
}
#[doc(alias = "CouponRate")]
pub fn coupon_rate(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(223))
}
#[doc(alias = "SecurityExchange")]
pub fn security_exchange(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(207))
}
#[doc(alias = "Issuer")]
pub fn issuer(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(106))
}
#[doc(alias = "EncodedIssuerLen")]
pub fn encoded_issuer_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(348))
}
#[doc(alias = "EncodedIssuer")]
pub fn encoded_issuer(&self) -> Option<&[u8]> {
self.0.get(Tag(349))
}
#[doc(alias = "SecurityDesc")]
pub fn security_desc(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(107))
}
#[doc(alias = "EncodedSecurityDescLen")]
pub fn encoded_security_desc_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(350))
}
#[doc(alias = "EncodedSecurityDesc")]
pub fn encoded_security_desc(&self) -> Option<&[u8]> {
self.0.get(Tag(351))
}
#[doc(alias = "Side")]
pub fn side(&self) -> Result<Option<Side<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(54))?.map(Side::from_value))
}
#[doc(alias = "OrderQty")]
pub fn order_qty(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(38))
}
#[doc(alias = "CashOrderQty")]
pub fn cash_order_qty(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(152))
}
#[doc(alias = "LastShares")]
pub fn last_shares(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(32))
}
#[doc(alias = "LastPx")]
pub fn last_px(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(31))
}
#[doc(alias = "Text")]
pub fn text(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(58))
}
#[doc(alias = "EncodedTextLen")]
pub fn encoded_text_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(354))
}
#[doc(alias = "EncodedText")]
pub fn encoded_text(&self) -> Option<&[u8]> {
self.0.get(Tag(355))
}
}
impl std::fmt::Debug for DontKnowTrade {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "DontKnowTrade({})", self.0)
}
}
impl std::fmt::Display for DontKnowTrade {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
std::fmt::Display::fmt(&self.0, f)
}
}
pub struct QuoteRequest(RawMessage);
impl QuoteRequest {
pub const MSG_TYPE: &[u8] = b"R";
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(8), Tag(9), Tag(10), Tag(15), Tag(22), Tag(34), Tag(35), Tag(38), Tag(40), Tag(43),
Tag(48), Tag(49), Tag(50), Tag(52), Tag(54), Tag(55), Tag(56), Tag(57), Tag(60), Tag(64),
Tag(65), Tag(89), Tag(90), Tag(91), Tag(93), Tag(97), Tag(106), Tag(107), Tag(115),
Tag(116), Tag(122), Tag(126), Tag(128), Tag(129), Tag(131), Tag(140), Tag(142), Tag(143),
Tag(144), Tag(145), Tag(146), Tag(167), Tag(192), Tag(193), Tag(200), Tag(201), Tag(202),
Tag(205), Tag(206), Tag(207), Tag(212), Tag(213), Tag(223), Tag(231), Tag(303), Tag(336),
Tag(347), Tag(348), Tag(349), Tag(350), Tag(351), Tag(369), Tag(370),
]);
pub fn from_raw(raw: RawMessage) -> Self {
Self(raw)
}
pub fn raw(&self) -> &RawMessage {
&self.0
}
pub fn header(&self) -> Header<'_> {
Header(self.0.scope())
}
pub fn trailer(&self) -> Trailer<'_> {
Trailer(self.0.scope())
}
#[doc(alias = "QuoteReqID")]
pub fn quote_req_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(131))
}
#[doc(alias = "NoRelatedSym")]
pub fn related_sym(&self) -> Result<Instances<'_, quote_request::related_sym::Instance<'_>>, InvalidValue> {
self.0.get_group("e_request::related_sym::TABLE, &Self::KNOWN_TAGS).map(Instances::from)
}
}
impl std::fmt::Debug for QuoteRequest {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "QuoteRequest({})", self.0)
}
}
impl std::fmt::Display for QuoteRequest {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
std::fmt::Display::fmt(&self.0, f)
}
}
pub mod quote_request {
pub mod related_sym {
use super::super::*;
pub const TABLE: GroupTable<'static> = GroupTable::new(
Tag(146),
Tag(55),
&[
Tag(15), Tag(22), Tag(38), Tag(40), Tag(48), Tag(54), Tag(55), Tag(60), Tag(64),
Tag(65), Tag(106), Tag(107), Tag(126), Tag(140), Tag(167), Tag(192), Tag(193),
Tag(200), Tag(201), Tag(202), Tag(205), Tag(206), Tag(207), Tag(223), Tag(231),
Tag(303), Tag(336), Tag(348), Tag(349), Tag(350), Tag(351),
],
&[],
);
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(15), Tag(22), Tag(38), Tag(40), Tag(48), Tag(54), Tag(55), Tag(60), Tag(64),
Tag(65), Tag(106), Tag(107), Tag(126), Tag(140), Tag(167), Tag(192), Tag(193), Tag(200),
Tag(201), Tag(202), Tag(205), Tag(206), Tag(207), Tag(223), Tag(231), Tag(303),
Tag(336), Tag(348), Tag(349), Tag(350), Tag(351),
]);
#[derive(Clone, Copy, Debug)]
pub struct Instance<'a>(refix_message::Scope<'a>);
impl<'a> From<refix_message::Scope<'a>> for Instance<'a> {
fn from(scope: refix_message::Scope<'a>) -> Self {
Self(scope)
}
}
impl<'a> Instance<'a> {
pub fn raw(&self) -> refix_message::Scope<'a> {
self.0
}
#[doc(alias = "Symbol")]
pub fn symbol(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(55))
}
#[doc(alias = "SymbolSfx")]
pub fn symbol_sfx(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(65))
}
#[doc(alias = "SecurityID")]
pub fn security_id(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(48))
}
#[doc(alias = "IDSource")]
pub fn id_source(&self) -> Result<Option<IDSource<'a>>, InvalidValue> {
Ok(self.0.get_str(Tag(22))?.map(IDSource::from_value))
}
#[doc(alias = "SecurityType")]
pub fn security_type(&self) -> Result<Option<SecurityType<'a>>, InvalidValue> {
Ok(self.0.get_str(Tag(167))?.map(SecurityType::from_value))
}
#[doc(alias = "MaturityMonthYear")]
pub fn maturity_month_year(&self) -> Result<Option<MonthYear>, InvalidValue> {
self.0.get_month_year(Tag(200))
}
#[doc(alias = "MaturityDay")]
pub fn maturity_day(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(205))
}
#[doc(alias = "PutOrCall")]
pub fn put_or_call(&self) -> Result<Option<PutOrCall>, InvalidValue> {
Ok(self.0.get_int(Tag(201))?.map(PutOrCall::from_value))
}
#[doc(alias = "StrikePrice")]
pub fn strike_price(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(202))
}
#[doc(alias = "OptAttribute")]
pub fn opt_attribute(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(206))
}
#[doc(alias = "ContractMultiplier")]
pub fn contract_multiplier(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(231))
}
#[doc(alias = "CouponRate")]
pub fn coupon_rate(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(223))
}
#[doc(alias = "SecurityExchange")]
pub fn security_exchange(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(207))
}
#[doc(alias = "Issuer")]
pub fn issuer(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(106))
}
#[doc(alias = "EncodedIssuerLen")]
pub fn encoded_issuer_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(348))
}
#[doc(alias = "EncodedIssuer")]
pub fn encoded_issuer(&self) -> Option<&'a [u8]> {
self.0.get(Tag(349))
}
#[doc(alias = "SecurityDesc")]
pub fn security_desc(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(107))
}
#[doc(alias = "EncodedSecurityDescLen")]
pub fn encoded_security_desc_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(350))
}
#[doc(alias = "EncodedSecurityDesc")]
pub fn encoded_security_desc(&self) -> Option<&'a [u8]> {
self.0.get(Tag(351))
}
#[doc(alias = "PrevClosePx")]
pub fn prev_close_px(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(140))
}
#[doc(alias = "QuoteRequestType")]
pub fn quote_request_type(&self) -> Result<Option<QuoteRequestType>, InvalidValue> {
Ok(self.0.get_int(Tag(303))?.map(QuoteRequestType::from_value))
}
#[doc(alias = "TradingSessionID")]
pub fn trading_session_id(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(336))
}
#[doc(alias = "Side")]
pub fn side(&self) -> Result<Option<Side<'a>>, InvalidValue> {
Ok(self.0.get_str(Tag(54))?.map(Side::from_value))
}
#[doc(alias = "OrderQty")]
pub fn order_qty(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(38))
}
#[doc(alias = "FutSettDate")]
pub fn fut_sett_date(&self) -> Result<Option<Date>, InvalidValue> {
self.0.get_date(Tag(64))
}
#[doc(alias = "OrdType")]
pub fn ord_type(&self) -> Result<Option<OrdType<'a>>, InvalidValue> {
Ok(self.0.get_str(Tag(40))?.map(OrdType::from_value))
}
#[doc(alias = "FutSettDate2")]
pub fn fut_sett_date2(&self) -> Result<Option<Date>, InvalidValue> {
self.0.get_date(Tag(193))
}
#[doc(alias = "OrderQty2")]
pub fn order_qty2(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(192))
}
#[doc(alias = "ExpireTime")]
pub fn expire_time(&self) -> Result<Option<UtcTimestamp>, InvalidValue> {
self.0.get_utc_timestamp(Tag(126))
}
#[doc(alias = "TransactTime")]
pub fn transact_time(&self) -> Result<Option<UtcTimestamp>, InvalidValue> {
self.0.get_utc_timestamp(Tag(60))
}
#[doc(alias = "Currency")]
pub fn currency(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(15))
}
}
}
}
pub struct Quote(RawMessage);
impl Quote {
pub const MSG_TYPE: &[u8] = b"S";
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(8), Tag(9), Tag(10), Tag(15), Tag(22), Tag(34), Tag(35), Tag(40), Tag(43), Tag(48),
Tag(49), Tag(50), Tag(52), Tag(55), Tag(56), Tag(57), Tag(60), Tag(62), Tag(64), Tag(65),
Tag(89), Tag(90), Tag(91), Tag(93), Tag(97), Tag(106), Tag(107), Tag(115), Tag(116),
Tag(117), Tag(122), Tag(128), Tag(129), Tag(131), Tag(132), Tag(133), Tag(134), Tag(135),
Tag(142), Tag(143), Tag(144), Tag(145), Tag(167), Tag(188), Tag(189), Tag(190), Tag(191),
Tag(192), Tag(193), Tag(200), Tag(201), Tag(202), Tag(205), Tag(206), Tag(207), Tag(212),
Tag(213), Tag(223), Tag(231), Tag(301), Tag(336), Tag(347), Tag(348), Tag(349), Tag(350),
Tag(351), Tag(369), Tag(370),
]);
pub fn from_raw(raw: RawMessage) -> Self {
Self(raw)
}
pub fn raw(&self) -> &RawMessage {
&self.0
}
pub fn header(&self) -> Header<'_> {
Header(self.0.scope())
}
pub fn trailer(&self) -> Trailer<'_> {
Trailer(self.0.scope())
}
#[doc(alias = "QuoteReqID")]
pub fn quote_req_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(131))
}
#[doc(alias = "QuoteID")]
pub fn quote_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(117))
}
#[doc(alias = "QuoteResponseLevel")]
pub fn quote_response_level(&self) -> Result<Option<QuoteResponseLevel>, InvalidValue> {
Ok(self.0.get_int(Tag(301))?.map(QuoteResponseLevel::from_value))
}
#[doc(alias = "TradingSessionID")]
pub fn trading_session_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(336))
}
#[doc(alias = "Symbol")]
pub fn symbol(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(55))
}
#[doc(alias = "SymbolSfx")]
pub fn symbol_sfx(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(65))
}
#[doc(alias = "SecurityID")]
pub fn security_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(48))
}
#[doc(alias = "IDSource")]
pub fn id_source(&self) -> Result<Option<IDSource<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(22))?.map(IDSource::from_value))
}
#[doc(alias = "SecurityType")]
pub fn security_type(&self) -> Result<Option<SecurityType<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(167))?.map(SecurityType::from_value))
}
#[doc(alias = "MaturityMonthYear")]
pub fn maturity_month_year(&self) -> Result<Option<MonthYear>, InvalidValue> {
self.0.get_month_year(Tag(200))
}
#[doc(alias = "MaturityDay")]
pub fn maturity_day(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(205))
}
#[doc(alias = "PutOrCall")]
pub fn put_or_call(&self) -> Result<Option<PutOrCall>, InvalidValue> {
Ok(self.0.get_int(Tag(201))?.map(PutOrCall::from_value))
}
#[doc(alias = "StrikePrice")]
pub fn strike_price(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(202))
}
#[doc(alias = "OptAttribute")]
pub fn opt_attribute(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(206))
}
#[doc(alias = "ContractMultiplier")]
pub fn contract_multiplier(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(231))
}
#[doc(alias = "CouponRate")]
pub fn coupon_rate(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(223))
}
#[doc(alias = "SecurityExchange")]
pub fn security_exchange(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(207))
}
#[doc(alias = "Issuer")]
pub fn issuer(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(106))
}
#[doc(alias = "EncodedIssuerLen")]
pub fn encoded_issuer_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(348))
}
#[doc(alias = "EncodedIssuer")]
pub fn encoded_issuer(&self) -> Option<&[u8]> {
self.0.get(Tag(349))
}
#[doc(alias = "SecurityDesc")]
pub fn security_desc(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(107))
}
#[doc(alias = "EncodedSecurityDescLen")]
pub fn encoded_security_desc_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(350))
}
#[doc(alias = "EncodedSecurityDesc")]
pub fn encoded_security_desc(&self) -> Option<&[u8]> {
self.0.get(Tag(351))
}
#[doc(alias = "BidPx")]
pub fn bid_px(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(132))
}
#[doc(alias = "OfferPx")]
pub fn offer_px(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(133))
}
#[doc(alias = "BidSize")]
pub fn bid_size(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(134))
}
#[doc(alias = "OfferSize")]
pub fn offer_size(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(135))
}
#[doc(alias = "ValidUntilTime")]
pub fn valid_until_time(&self) -> Result<Option<UtcTimestamp>, InvalidValue> {
self.0.get_utc_timestamp(Tag(62))
}
#[doc(alias = "BidSpotRate")]
pub fn bid_spot_rate(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(188))
}
#[doc(alias = "OfferSpotRate")]
pub fn offer_spot_rate(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(190))
}
#[doc(alias = "BidForwardPoints")]
pub fn bid_forward_points(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(189))
}
#[doc(alias = "OfferForwardPoints")]
pub fn offer_forward_points(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(191))
}
#[doc(alias = "TransactTime")]
pub fn transact_time(&self) -> Result<Option<UtcTimestamp>, InvalidValue> {
self.0.get_utc_timestamp(Tag(60))
}
#[doc(alias = "FutSettDate")]
pub fn fut_sett_date(&self) -> Result<Option<Date>, InvalidValue> {
self.0.get_date(Tag(64))
}
#[doc(alias = "OrdType")]
pub fn ord_type(&self) -> Result<Option<OrdType<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(40))?.map(OrdType::from_value))
}
#[doc(alias = "FutSettDate2")]
pub fn fut_sett_date2(&self) -> Result<Option<Date>, InvalidValue> {
self.0.get_date(Tag(193))
}
#[doc(alias = "OrderQty2")]
pub fn order_qty2(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(192))
}
#[doc(alias = "Currency")]
pub fn currency(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(15))
}
}
impl std::fmt::Debug for Quote {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "Quote({})", self.0)
}
}
impl std::fmt::Display for Quote {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
std::fmt::Display::fmt(&self.0, f)
}
}
pub struct SettlementInstructions(RawMessage);
impl SettlementInstructions {
pub const MSG_TYPE: &[u8] = b"T";
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(8), Tag(9), Tag(10), Tag(30), Tag(34), Tag(35), Tag(43), Tag(49), Tag(50), Tag(52),
Tag(54), Tag(56), Tag(57), Tag(60), Tag(70), Tag(75), Tag(76), Tag(79), Tag(89), Tag(90),
Tag(91), Tag(93), Tag(97), Tag(109), Tag(115), Tag(116), Tag(122), Tag(128), Tag(129),
Tag(142), Tag(143), Tag(144), Tag(145), Tag(160), Tag(162), Tag(163), Tag(165), Tag(166),
Tag(167), Tag(168), Tag(169), Tag(170), Tag(171), Tag(172), Tag(173), Tag(174), Tag(175),
Tag(176), Tag(177), Tag(178), Tag(179), Tag(180), Tag(181), Tag(182), Tag(183), Tag(184),
Tag(185), Tag(186), Tag(187), Tag(212), Tag(213), Tag(214), Tag(336), Tag(347), Tag(369),
Tag(370),
]);
pub fn from_raw(raw: RawMessage) -> Self {
Self(raw)
}
pub fn raw(&self) -> &RawMessage {
&self.0
}
pub fn header(&self) -> Header<'_> {
Header(self.0.scope())
}
pub fn trailer(&self) -> Trailer<'_> {
Trailer(self.0.scope())
}
#[doc(alias = "SettlInstID")]
pub fn settl_inst_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(162))
}
#[doc(alias = "SettlInstTransType")]
pub fn settl_inst_trans_type(&self) -> Result<Option<SettlInstTransType<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(163))?.map(SettlInstTransType::from_value))
}
#[doc(alias = "SettlInstRefID")]
pub fn settl_inst_ref_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(214))
}
#[doc(alias = "SettlInstMode")]
pub fn settl_inst_mode(&self) -> Result<Option<SettlInstMode<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(160))?.map(SettlInstMode::from_value))
}
#[doc(alias = "SettlInstSource")]
pub fn settl_inst_source(&self) -> Result<Option<SettlInstSource<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(165))?.map(SettlInstSource::from_value))
}
#[doc(alias = "AllocAccount")]
pub fn alloc_account(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(79))
}
#[doc(alias = "SettlLocation")]
pub fn settl_location(&self) -> Result<Option<SettlLocation<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(166))?.map(SettlLocation::from_value))
}
#[doc(alias = "TradeDate")]
pub fn trade_date(&self) -> Result<Option<Date>, InvalidValue> {
self.0.get_date(Tag(75))
}
#[doc(alias = "AllocID")]
pub fn alloc_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(70))
}
#[doc(alias = "LastMkt")]
pub fn last_mkt(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(30))
}
#[doc(alias = "TradingSessionID")]
pub fn trading_session_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(336))
}
#[doc(alias = "Side")]
pub fn side(&self) -> Result<Option<Side<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(54))?.map(Side::from_value))
}
#[doc(alias = "SecurityType")]
pub fn security_type(&self) -> Result<Option<SecurityType<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(167))?.map(SecurityType::from_value))
}
#[doc(alias = "EffectiveTime")]
pub fn effective_time(&self) -> Result<Option<UtcTimestamp>, InvalidValue> {
self.0.get_utc_timestamp(Tag(168))
}
#[doc(alias = "TransactTime")]
pub fn transact_time(&self) -> Result<Option<UtcTimestamp>, InvalidValue> {
self.0.get_utc_timestamp(Tag(60))
}
#[doc(alias = "ClientID")]
pub fn client_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(109))
}
#[doc(alias = "ExecBroker")]
pub fn exec_broker(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(76))
}
#[doc(alias = "StandInstDbType")]
pub fn stand_inst_db_type(&self) -> Result<Option<StandInstDbType>, InvalidValue> {
Ok(self.0.get_int(Tag(169))?.map(StandInstDbType::from_value))
}
#[doc(alias = "StandInstDbName")]
pub fn stand_inst_db_name(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(170))
}
#[doc(alias = "StandInstDbID")]
pub fn stand_inst_db_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(171))
}
#[doc(alias = "SettlDeliveryType")]
pub fn settl_delivery_type(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(172))
}
#[doc(alias = "SettlDepositoryCode")]
pub fn settl_depository_code(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(173))
}
#[doc(alias = "SettlBrkrCode")]
pub fn settl_brkr_code(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(174))
}
#[doc(alias = "SettlInstCode")]
pub fn settl_inst_code(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(175))
}
#[doc(alias = "SecuritySettlAgentName")]
pub fn security_settl_agent_name(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(176))
}
#[doc(alias = "SecuritySettlAgentCode")]
pub fn security_settl_agent_code(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(177))
}
#[doc(alias = "SecuritySettlAgentAcctNum")]
pub fn security_settl_agent_acct_num(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(178))
}
#[doc(alias = "SecuritySettlAgentAcctName")]
pub fn security_settl_agent_acct_name(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(179))
}
#[doc(alias = "SecuritySettlAgentContactName")]
pub fn security_settl_agent_contact_name(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(180))
}
#[doc(alias = "SecuritySettlAgentContactPhone")]
pub fn security_settl_agent_contact_phone(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(181))
}
#[doc(alias = "CashSettlAgentName")]
pub fn cash_settl_agent_name(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(182))
}
#[doc(alias = "CashSettlAgentCode")]
pub fn cash_settl_agent_code(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(183))
}
#[doc(alias = "CashSettlAgentAcctNum")]
pub fn cash_settl_agent_acct_num(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(184))
}
#[doc(alias = "CashSettlAgentAcctName")]
pub fn cash_settl_agent_acct_name(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(185))
}
#[doc(alias = "CashSettlAgentContactName")]
pub fn cash_settl_agent_contact_name(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(186))
}
#[doc(alias = "CashSettlAgentContactPhone")]
pub fn cash_settl_agent_contact_phone(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(187))
}
}
impl std::fmt::Debug for SettlementInstructions {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "SettlementInstructions({})", self.0)
}
}
impl std::fmt::Display for SettlementInstructions {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
std::fmt::Display::fmt(&self.0, f)
}
}
pub struct MarketDataRequest(RawMessage);
impl MarketDataRequest {
pub const MSG_TYPE: &[u8] = b"V";
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(8), Tag(9), Tag(10), Tag(22), Tag(34), Tag(35), Tag(43), Tag(48), Tag(49), Tag(50),
Tag(52), Tag(55), Tag(56), Tag(57), Tag(65), Tag(89), Tag(90), Tag(91), Tag(93), Tag(97),
Tag(106), Tag(107), Tag(115), Tag(116), Tag(122), Tag(128), Tag(129), Tag(142), Tag(143),
Tag(144), Tag(145), Tag(146), Tag(167), Tag(200), Tag(201), Tag(202), Tag(205), Tag(206),
Tag(207), Tag(212), Tag(213), Tag(223), Tag(231), Tag(262), Tag(263), Tag(264), Tag(265),
Tag(266), Tag(267), Tag(269), Tag(336), Tag(347), Tag(348), Tag(349), Tag(350), Tag(351),
Tag(369), Tag(370),
]);
pub fn from_raw(raw: RawMessage) -> Self {
Self(raw)
}
pub fn raw(&self) -> &RawMessage {
&self.0
}
pub fn header(&self) -> Header<'_> {
Header(self.0.scope())
}
pub fn trailer(&self) -> Trailer<'_> {
Trailer(self.0.scope())
}
#[doc(alias = "MDReqID")]
pub fn md_req_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(262))
}
#[doc(alias = "SubscriptionRequestType")]
pub fn subscription_request_type(&self) -> Result<Option<SubscriptionRequestType<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(263))?.map(SubscriptionRequestType::from_value))
}
#[doc(alias = "MarketDepth")]
pub fn market_depth(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(264))
}
#[doc(alias = "MDUpdateType")]
pub fn md_update_type(&self) -> Result<Option<MDUpdateType>, InvalidValue> {
Ok(self.0.get_int(Tag(265))?.map(MDUpdateType::from_value))
}
#[doc(alias = "AggregatedBook")]
pub fn aggregated_book(&self) -> Result<Option<bool>, InvalidValue> {
self.0.get_bool(Tag(266))
}
#[doc(alias = "NoMDEntryTypes")]
pub fn md_entry_types(&self) -> Result<Instances<'_, market_data_request::md_entry_types::Instance<'_>>, InvalidValue> {
self.0.get_group(&market_data_request::md_entry_types::TABLE, &Self::KNOWN_TAGS).map(Instances::from)
}
#[doc(alias = "NoRelatedSym")]
pub fn related_sym(&self) -> Result<Instances<'_, market_data_request::related_sym::Instance<'_>>, InvalidValue> {
self.0.get_group(&market_data_request::related_sym::TABLE, &Self::KNOWN_TAGS).map(Instances::from)
}
}
impl std::fmt::Debug for MarketDataRequest {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "MarketDataRequest({})", self.0)
}
}
impl std::fmt::Display for MarketDataRequest {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
std::fmt::Display::fmt(&self.0, f)
}
}
pub mod market_data_request {
pub mod md_entry_types {
use super::super::*;
pub const TABLE: GroupTable<'static> = GroupTable::new(
Tag(267),
Tag(269),
&[Tag(269)],
&[],
);
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[Tag(269)]);
#[derive(Clone, Copy, Debug)]
pub struct Instance<'a>(refix_message::Scope<'a>);
impl<'a> From<refix_message::Scope<'a>> for Instance<'a> {
fn from(scope: refix_message::Scope<'a>) -> Self {
Self(scope)
}
}
impl<'a> Instance<'a> {
pub fn raw(&self) -> refix_message::Scope<'a> {
self.0
}
#[doc(alias = "MDEntryType")]
pub fn md_entry_type(&self) -> Result<Option<MDEntryType<'a>>, InvalidValue> {
Ok(self.0.get_str(Tag(269))?.map(MDEntryType::from_value))
}
}
}
pub mod related_sym {
use super::super::*;
pub const TABLE: GroupTable<'static> = GroupTable::new(
Tag(146),
Tag(55),
&[
Tag(22), Tag(48), Tag(55), Tag(65), Tag(106), Tag(107), Tag(167), Tag(200),
Tag(201), Tag(202), Tag(205), Tag(206), Tag(207), Tag(223), Tag(231), Tag(336),
Tag(348), Tag(349), Tag(350), Tag(351),
],
&[],
);
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(22), Tag(48), Tag(55), Tag(65), Tag(106), Tag(107), Tag(167), Tag(200), Tag(201),
Tag(202), Tag(205), Tag(206), Tag(207), Tag(223), Tag(231), Tag(336), Tag(348),
Tag(349), Tag(350), Tag(351),
]);
#[derive(Clone, Copy, Debug)]
pub struct Instance<'a>(refix_message::Scope<'a>);
impl<'a> From<refix_message::Scope<'a>> for Instance<'a> {
fn from(scope: refix_message::Scope<'a>) -> Self {
Self(scope)
}
}
impl<'a> Instance<'a> {
pub fn raw(&self) -> refix_message::Scope<'a> {
self.0
}
#[doc(alias = "Symbol")]
pub fn symbol(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(55))
}
#[doc(alias = "SymbolSfx")]
pub fn symbol_sfx(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(65))
}
#[doc(alias = "SecurityID")]
pub fn security_id(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(48))
}
#[doc(alias = "IDSource")]
pub fn id_source(&self) -> Result<Option<IDSource<'a>>, InvalidValue> {
Ok(self.0.get_str(Tag(22))?.map(IDSource::from_value))
}
#[doc(alias = "SecurityType")]
pub fn security_type(&self) -> Result<Option<SecurityType<'a>>, InvalidValue> {
Ok(self.0.get_str(Tag(167))?.map(SecurityType::from_value))
}
#[doc(alias = "MaturityMonthYear")]
pub fn maturity_month_year(&self) -> Result<Option<MonthYear>, InvalidValue> {
self.0.get_month_year(Tag(200))
}
#[doc(alias = "MaturityDay")]
pub fn maturity_day(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(205))
}
#[doc(alias = "PutOrCall")]
pub fn put_or_call(&self) -> Result<Option<PutOrCall>, InvalidValue> {
Ok(self.0.get_int(Tag(201))?.map(PutOrCall::from_value))
}
#[doc(alias = "StrikePrice")]
pub fn strike_price(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(202))
}
#[doc(alias = "OptAttribute")]
pub fn opt_attribute(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(206))
}
#[doc(alias = "ContractMultiplier")]
pub fn contract_multiplier(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(231))
}
#[doc(alias = "CouponRate")]
pub fn coupon_rate(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(223))
}
#[doc(alias = "SecurityExchange")]
pub fn security_exchange(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(207))
}
#[doc(alias = "Issuer")]
pub fn issuer(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(106))
}
#[doc(alias = "EncodedIssuerLen")]
pub fn encoded_issuer_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(348))
}
#[doc(alias = "EncodedIssuer")]
pub fn encoded_issuer(&self) -> Option<&'a [u8]> {
self.0.get(Tag(349))
}
#[doc(alias = "SecurityDesc")]
pub fn security_desc(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(107))
}
#[doc(alias = "EncodedSecurityDescLen")]
pub fn encoded_security_desc_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(350))
}
#[doc(alias = "EncodedSecurityDesc")]
pub fn encoded_security_desc(&self) -> Option<&'a [u8]> {
self.0.get(Tag(351))
}
#[doc(alias = "TradingSessionID")]
pub fn trading_session_id(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(336))
}
}
}
}
pub struct MarketDataSnapshotFullRefresh(RawMessage);
impl MarketDataSnapshotFullRefresh {
pub const MSG_TYPE: &[u8] = b"W";
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(8), Tag(9), Tag(10), Tag(15), Tag(18), Tag(22), Tag(34), Tag(35), Tag(37), Tag(43),
Tag(48), Tag(49), Tag(50), Tag(52), Tag(55), Tag(56), Tag(57), Tag(58), Tag(59), Tag(65),
Tag(89), Tag(90), Tag(91), Tag(93), Tag(97), Tag(106), Tag(107), Tag(110), Tag(115),
Tag(116), Tag(122), Tag(126), Tag(128), Tag(129), Tag(142), Tag(143), Tag(144), Tag(145),
Tag(167), Tag(200), Tag(201), Tag(202), Tag(205), Tag(206), Tag(207), Tag(212), Tag(213),
Tag(223), Tag(231), Tag(262), Tag(268), Tag(269), Tag(270), Tag(271), Tag(272), Tag(273),
Tag(274), Tag(275), Tag(276), Tag(277), Tag(282), Tag(283), Tag(284), Tag(286), Tag(287),
Tag(288), Tag(289), Tag(290), Tag(291), Tag(292), Tag(299), Tag(336), Tag(346), Tag(347),
Tag(348), Tag(349), Tag(350), Tag(351), Tag(354), Tag(355), Tag(369), Tag(370), Tag(387),
Tag(432),
]);
pub fn from_raw(raw: RawMessage) -> Self {
Self(raw)
}
pub fn raw(&self) -> &RawMessage {
&self.0
}
pub fn header(&self) -> Header<'_> {
Header(self.0.scope())
}
pub fn trailer(&self) -> Trailer<'_> {
Trailer(self.0.scope())
}
#[doc(alias = "MDReqID")]
pub fn md_req_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(262))
}
#[doc(alias = "Symbol")]
pub fn symbol(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(55))
}
#[doc(alias = "SymbolSfx")]
pub fn symbol_sfx(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(65))
}
#[doc(alias = "SecurityID")]
pub fn security_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(48))
}
#[doc(alias = "IDSource")]
pub fn id_source(&self) -> Result<Option<IDSource<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(22))?.map(IDSource::from_value))
}
#[doc(alias = "SecurityType")]
pub fn security_type(&self) -> Result<Option<SecurityType<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(167))?.map(SecurityType::from_value))
}
#[doc(alias = "MaturityMonthYear")]
pub fn maturity_month_year(&self) -> Result<Option<MonthYear>, InvalidValue> {
self.0.get_month_year(Tag(200))
}
#[doc(alias = "MaturityDay")]
pub fn maturity_day(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(205))
}
#[doc(alias = "PutOrCall")]
pub fn put_or_call(&self) -> Result<Option<PutOrCall>, InvalidValue> {
Ok(self.0.get_int(Tag(201))?.map(PutOrCall::from_value))
}
#[doc(alias = "StrikePrice")]
pub fn strike_price(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(202))
}
#[doc(alias = "OptAttribute")]
pub fn opt_attribute(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(206))
}
#[doc(alias = "ContractMultiplier")]
pub fn contract_multiplier(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(231))
}
#[doc(alias = "CouponRate")]
pub fn coupon_rate(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(223))
}
#[doc(alias = "SecurityExchange")]
pub fn security_exchange(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(207))
}
#[doc(alias = "Issuer")]
pub fn issuer(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(106))
}
#[doc(alias = "EncodedIssuerLen")]
pub fn encoded_issuer_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(348))
}
#[doc(alias = "EncodedIssuer")]
pub fn encoded_issuer(&self) -> Option<&[u8]> {
self.0.get(Tag(349))
}
#[doc(alias = "SecurityDesc")]
pub fn security_desc(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(107))
}
#[doc(alias = "EncodedSecurityDescLen")]
pub fn encoded_security_desc_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(350))
}
#[doc(alias = "EncodedSecurityDesc")]
pub fn encoded_security_desc(&self) -> Option<&[u8]> {
self.0.get(Tag(351))
}
#[doc(alias = "FinancialStatus")]
pub fn financial_status(&self) -> Result<Option<FinancialStatus<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(291))?.map(FinancialStatus::from_value))
}
#[doc(alias = "CorporateAction")]
pub fn corporate_action(&self) -> Result<Option<CorporateAction<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(292))?.map(CorporateAction::from_value))
}
#[doc(alias = "TotalVolumeTraded")]
pub fn total_volume_traded(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(387))
}
#[doc(alias = "NoMDEntries")]
pub fn md_entries(&self) -> Result<Instances<'_, market_data_snapshot_full_refresh::md_entries::Instance<'_>>, InvalidValue> {
self.0.get_group(&market_data_snapshot_full_refresh::md_entries::TABLE, &Self::KNOWN_TAGS).map(Instances::from)
}
}
impl std::fmt::Debug for MarketDataSnapshotFullRefresh {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "MarketDataSnapshotFullRefresh({})", self.0)
}
}
impl std::fmt::Display for MarketDataSnapshotFullRefresh {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
std::fmt::Display::fmt(&self.0, f)
}
}
pub mod market_data_snapshot_full_refresh {
pub mod md_entries {
use super::super::*;
pub const TABLE: GroupTable<'static> = GroupTable::new(
Tag(268),
Tag(269),
&[
Tag(15), Tag(18), Tag(37), Tag(58), Tag(59), Tag(110), Tag(126), Tag(269), Tag(270),
Tag(271), Tag(272), Tag(273), Tag(274), Tag(275), Tag(276), Tag(277), Tag(282),
Tag(283), Tag(284), Tag(286), Tag(287), Tag(288), Tag(289), Tag(290), Tag(299),
Tag(336), Tag(346), Tag(354), Tag(355), Tag(432),
],
&[],
);
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(15), Tag(18), Tag(37), Tag(58), Tag(59), Tag(110), Tag(126), Tag(269), Tag(270),
Tag(271), Tag(272), Tag(273), Tag(274), Tag(275), Tag(276), Tag(277), Tag(282),
Tag(283), Tag(284), Tag(286), Tag(287), Tag(288), Tag(289), Tag(290), Tag(299),
Tag(336), Tag(346), Tag(354), Tag(355), Tag(432),
]);
#[derive(Clone, Copy, Debug)]
pub struct Instance<'a>(refix_message::Scope<'a>);
impl<'a> From<refix_message::Scope<'a>> for Instance<'a> {
fn from(scope: refix_message::Scope<'a>) -> Self {
Self(scope)
}
}
impl<'a> Instance<'a> {
pub fn raw(&self) -> refix_message::Scope<'a> {
self.0
}
#[doc(alias = "MDEntryType")]
pub fn md_entry_type(&self) -> Result<Option<MDEntryType<'a>>, InvalidValue> {
Ok(self.0.get_str(Tag(269))?.map(MDEntryType::from_value))
}
#[doc(alias = "MDEntryPx")]
pub fn md_entry_px(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(270))
}
#[doc(alias = "Currency")]
pub fn currency(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(15))
}
#[doc(alias = "MDEntrySize")]
pub fn md_entry_size(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(271))
}
#[doc(alias = "MDEntryDate")]
pub fn md_entry_date(&self) -> Result<Option<Date>, InvalidValue> {
self.0.get_date(Tag(272))
}
#[doc(alias = "MDEntryTime")]
pub fn md_entry_time(&self) -> Result<Option<Time>, InvalidValue> {
self.0.get_time(Tag(273))
}
#[doc(alias = "TickDirection")]
pub fn tick_direction(&self) -> Result<Option<TickDirection<'a>>, InvalidValue> {
Ok(self.0.get_str(Tag(274))?.map(TickDirection::from_value))
}
#[doc(alias = "MDMkt")]
pub fn md_mkt(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(275))
}
#[doc(alias = "TradingSessionID")]
pub fn trading_session_id(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(336))
}
#[doc(alias = "QuoteCondition")]
pub fn quote_condition(&self) -> Result<Option<MultipleValues<'a, QuoteCondition<'a>>>, InvalidValue> {
self.0.get_multiple_values(Tag(276))
}
#[doc(alias = "TradeCondition")]
pub fn trade_condition(&self) -> Result<Option<MultipleValues<'a, TradeCondition<'a>>>, InvalidValue> {
self.0.get_multiple_values(Tag(277))
}
#[doc(alias = "MDEntryOriginator")]
pub fn md_entry_originator(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(282))
}
#[doc(alias = "LocationID")]
pub fn location_id(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(283))
}
#[doc(alias = "DeskID")]
pub fn desk_id(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(284))
}
#[doc(alias = "OpenCloseSettleFlag")]
pub fn open_close_settle_flag(&self) -> Result<Option<OpenCloseSettleFlag<'a>>, InvalidValue> {
Ok(self.0.get_str(Tag(286))?.map(OpenCloseSettleFlag::from_value))
}
#[doc(alias = "TimeInForce")]
pub fn time_in_force(&self) -> Result<Option<TimeInForce<'a>>, InvalidValue> {
Ok(self.0.get_str(Tag(59))?.map(TimeInForce::from_value))
}
#[doc(alias = "ExpireDate")]
pub fn expire_date(&self) -> Result<Option<Date>, InvalidValue> {
self.0.get_date(Tag(432))
}
#[doc(alias = "ExpireTime")]
pub fn expire_time(&self) -> Result<Option<UtcTimestamp>, InvalidValue> {
self.0.get_utc_timestamp(Tag(126))
}
#[doc(alias = "MinQty")]
pub fn min_qty(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(110))
}
#[doc(alias = "ExecInst")]
pub fn exec_inst(&self) -> Result<Option<MultipleValues<'a, ExecInst<'a>>>, InvalidValue> {
self.0.get_multiple_values(Tag(18))
}
#[doc(alias = "SellerDays")]
pub fn seller_days(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(287))
}
#[doc(alias = "OrderID")]
pub fn order_id(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(37))
}
#[doc(alias = "QuoteEntryID")]
pub fn quote_entry_id(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(299))
}
#[doc(alias = "MDEntryBuyer")]
pub fn md_entry_buyer(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(288))
}
#[doc(alias = "MDEntrySeller")]
pub fn md_entry_seller(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(289))
}
#[doc(alias = "NumberOfOrders")]
pub fn number_of_orders(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(346))
}
#[doc(alias = "MDEntryPositionNo")]
pub fn md_entry_position_no(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(290))
}
#[doc(alias = "Text")]
pub fn text(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(58))
}
#[doc(alias = "EncodedTextLen")]
pub fn encoded_text_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(354))
}
#[doc(alias = "EncodedText")]
pub fn encoded_text(&self) -> Option<&'a [u8]> {
self.0.get(Tag(355))
}
}
}
}
pub struct MarketDataIncrementalRefresh(RawMessage);
impl MarketDataIncrementalRefresh {
pub const MSG_TYPE: &[u8] = b"X";
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(8), Tag(9), Tag(10), Tag(15), Tag(18), Tag(22), Tag(34), Tag(35), Tag(37), Tag(43),
Tag(48), Tag(49), Tag(50), Tag(52), Tag(55), Tag(56), Tag(57), Tag(58), Tag(59), Tag(65),
Tag(89), Tag(90), Tag(91), Tag(93), Tag(97), Tag(106), Tag(107), Tag(110), Tag(115),
Tag(116), Tag(122), Tag(126), Tag(128), Tag(129), Tag(142), Tag(143), Tag(144), Tag(145),
Tag(167), Tag(200), Tag(201), Tag(202), Tag(205), Tag(206), Tag(207), Tag(212), Tag(213),
Tag(223), Tag(231), Tag(262), Tag(268), Tag(269), Tag(270), Tag(271), Tag(272), Tag(273),
Tag(274), Tag(275), Tag(276), Tag(277), Tag(278), Tag(279), Tag(280), Tag(282), Tag(283),
Tag(284), Tag(285), Tag(286), Tag(287), Tag(288), Tag(289), Tag(290), Tag(291), Tag(292),
Tag(299), Tag(336), Tag(346), Tag(347), Tag(348), Tag(349), Tag(350), Tag(351), Tag(354),
Tag(355), Tag(369), Tag(370), Tag(387), Tag(432),
]);
pub fn from_raw(raw: RawMessage) -> Self {
Self(raw)
}
pub fn raw(&self) -> &RawMessage {
&self.0
}
pub fn header(&self) -> Header<'_> {
Header(self.0.scope())
}
pub fn trailer(&self) -> Trailer<'_> {
Trailer(self.0.scope())
}
#[doc(alias = "MDReqID")]
pub fn md_req_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(262))
}
#[doc(alias = "NoMDEntries")]
pub fn md_entries(&self) -> Result<Instances<'_, market_data_incremental_refresh::md_entries::Instance<'_>>, InvalidValue> {
self.0.get_group(&market_data_incremental_refresh::md_entries::TABLE, &Self::KNOWN_TAGS).map(Instances::from)
}
}
impl std::fmt::Debug for MarketDataIncrementalRefresh {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "MarketDataIncrementalRefresh({})", self.0)
}
}
impl std::fmt::Display for MarketDataIncrementalRefresh {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
std::fmt::Display::fmt(&self.0, f)
}
}
pub mod market_data_incremental_refresh {
pub mod md_entries {
use super::super::*;
pub const TABLE: GroupTable<'static> = GroupTable::new(
Tag(268),
Tag(279),
&[
Tag(15), Tag(18), Tag(22), Tag(37), Tag(48), Tag(55), Tag(58), Tag(59), Tag(65),
Tag(106), Tag(107), Tag(110), Tag(126), Tag(167), Tag(200), Tag(201), Tag(202),
Tag(205), Tag(206), Tag(207), Tag(223), Tag(231), Tag(269), Tag(270), Tag(271),
Tag(272), Tag(273), Tag(274), Tag(275), Tag(276), Tag(277), Tag(278), Tag(279),
Tag(280), Tag(282), Tag(283), Tag(284), Tag(285), Tag(286), Tag(287), Tag(288),
Tag(289), Tag(290), Tag(291), Tag(292), Tag(299), Tag(336), Tag(346), Tag(348),
Tag(349), Tag(350), Tag(351), Tag(354), Tag(355), Tag(387), Tag(432),
],
&[],
);
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(15), Tag(18), Tag(22), Tag(37), Tag(48), Tag(55), Tag(58), Tag(59), Tag(65),
Tag(106), Tag(107), Tag(110), Tag(126), Tag(167), Tag(200), Tag(201), Tag(202),
Tag(205), Tag(206), Tag(207), Tag(223), Tag(231), Tag(269), Tag(270), Tag(271),
Tag(272), Tag(273), Tag(274), Tag(275), Tag(276), Tag(277), Tag(278), Tag(279),
Tag(280), Tag(282), Tag(283), Tag(284), Tag(285), Tag(286), Tag(287), Tag(288),
Tag(289), Tag(290), Tag(291), Tag(292), Tag(299), Tag(336), Tag(346), Tag(348),
Tag(349), Tag(350), Tag(351), Tag(354), Tag(355), Tag(387), Tag(432),
]);
#[derive(Clone, Copy, Debug)]
pub struct Instance<'a>(refix_message::Scope<'a>);
impl<'a> From<refix_message::Scope<'a>> for Instance<'a> {
fn from(scope: refix_message::Scope<'a>) -> Self {
Self(scope)
}
}
impl<'a> Instance<'a> {
pub fn raw(&self) -> refix_message::Scope<'a> {
self.0
}
#[doc(alias = "MDUpdateAction")]
pub fn md_update_action(&self) -> Result<Option<MDUpdateAction<'a>>, InvalidValue> {
Ok(self.0.get_str(Tag(279))?.map(MDUpdateAction::from_value))
}
#[doc(alias = "DeleteReason")]
pub fn delete_reason(&self) -> Result<Option<DeleteReason<'a>>, InvalidValue> {
Ok(self.0.get_str(Tag(285))?.map(DeleteReason::from_value))
}
#[doc(alias = "MDEntryType")]
pub fn md_entry_type(&self) -> Result<Option<MDEntryType<'a>>, InvalidValue> {
Ok(self.0.get_str(Tag(269))?.map(MDEntryType::from_value))
}
#[doc(alias = "MDEntryID")]
pub fn md_entry_id(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(278))
}
#[doc(alias = "MDEntryRefID")]
pub fn md_entry_ref_id(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(280))
}
#[doc(alias = "Symbol")]
pub fn symbol(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(55))
}
#[doc(alias = "SymbolSfx")]
pub fn symbol_sfx(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(65))
}
#[doc(alias = "SecurityID")]
pub fn security_id(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(48))
}
#[doc(alias = "IDSource")]
pub fn id_source(&self) -> Result<Option<IDSource<'a>>, InvalidValue> {
Ok(self.0.get_str(Tag(22))?.map(IDSource::from_value))
}
#[doc(alias = "SecurityType")]
pub fn security_type(&self) -> Result<Option<SecurityType<'a>>, InvalidValue> {
Ok(self.0.get_str(Tag(167))?.map(SecurityType::from_value))
}
#[doc(alias = "MaturityMonthYear")]
pub fn maturity_month_year(&self) -> Result<Option<MonthYear>, InvalidValue> {
self.0.get_month_year(Tag(200))
}
#[doc(alias = "MaturityDay")]
pub fn maturity_day(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(205))
}
#[doc(alias = "PutOrCall")]
pub fn put_or_call(&self) -> Result<Option<PutOrCall>, InvalidValue> {
Ok(self.0.get_int(Tag(201))?.map(PutOrCall::from_value))
}
#[doc(alias = "StrikePrice")]
pub fn strike_price(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(202))
}
#[doc(alias = "OptAttribute")]
pub fn opt_attribute(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(206))
}
#[doc(alias = "ContractMultiplier")]
pub fn contract_multiplier(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(231))
}
#[doc(alias = "CouponRate")]
pub fn coupon_rate(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(223))
}
#[doc(alias = "SecurityExchange")]
pub fn security_exchange(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(207))
}
#[doc(alias = "Issuer")]
pub fn issuer(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(106))
}
#[doc(alias = "EncodedIssuerLen")]
pub fn encoded_issuer_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(348))
}
#[doc(alias = "EncodedIssuer")]
pub fn encoded_issuer(&self) -> Option<&'a [u8]> {
self.0.get(Tag(349))
}
#[doc(alias = "SecurityDesc")]
pub fn security_desc(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(107))
}
#[doc(alias = "EncodedSecurityDescLen")]
pub fn encoded_security_desc_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(350))
}
#[doc(alias = "EncodedSecurityDesc")]
pub fn encoded_security_desc(&self) -> Option<&'a [u8]> {
self.0.get(Tag(351))
}
#[doc(alias = "FinancialStatus")]
pub fn financial_status(&self) -> Result<Option<FinancialStatus<'a>>, InvalidValue> {
Ok(self.0.get_str(Tag(291))?.map(FinancialStatus::from_value))
}
#[doc(alias = "CorporateAction")]
pub fn corporate_action(&self) -> Result<Option<CorporateAction<'a>>, InvalidValue> {
Ok(self.0.get_str(Tag(292))?.map(CorporateAction::from_value))
}
#[doc(alias = "MDEntryPx")]
pub fn md_entry_px(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(270))
}
#[doc(alias = "Currency")]
pub fn currency(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(15))
}
#[doc(alias = "MDEntrySize")]
pub fn md_entry_size(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(271))
}
#[doc(alias = "MDEntryDate")]
pub fn md_entry_date(&self) -> Result<Option<Date>, InvalidValue> {
self.0.get_date(Tag(272))
}
#[doc(alias = "MDEntryTime")]
pub fn md_entry_time(&self) -> Result<Option<Time>, InvalidValue> {
self.0.get_time(Tag(273))
}
#[doc(alias = "TickDirection")]
pub fn tick_direction(&self) -> Result<Option<TickDirection<'a>>, InvalidValue> {
Ok(self.0.get_str(Tag(274))?.map(TickDirection::from_value))
}
#[doc(alias = "MDMkt")]
pub fn md_mkt(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(275))
}
#[doc(alias = "TradingSessionID")]
pub fn trading_session_id(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(336))
}
#[doc(alias = "QuoteCondition")]
pub fn quote_condition(&self) -> Result<Option<MultipleValues<'a, QuoteCondition<'a>>>, InvalidValue> {
self.0.get_multiple_values(Tag(276))
}
#[doc(alias = "TradeCondition")]
pub fn trade_condition(&self) -> Result<Option<MultipleValues<'a, TradeCondition<'a>>>, InvalidValue> {
self.0.get_multiple_values(Tag(277))
}
#[doc(alias = "MDEntryOriginator")]
pub fn md_entry_originator(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(282))
}
#[doc(alias = "LocationID")]
pub fn location_id(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(283))
}
#[doc(alias = "DeskID")]
pub fn desk_id(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(284))
}
#[doc(alias = "OpenCloseSettleFlag")]
pub fn open_close_settle_flag(&self) -> Result<Option<OpenCloseSettleFlag<'a>>, InvalidValue> {
Ok(self.0.get_str(Tag(286))?.map(OpenCloseSettleFlag::from_value))
}
#[doc(alias = "TimeInForce")]
pub fn time_in_force(&self) -> Result<Option<TimeInForce<'a>>, InvalidValue> {
Ok(self.0.get_str(Tag(59))?.map(TimeInForce::from_value))
}
#[doc(alias = "ExpireDate")]
pub fn expire_date(&self) -> Result<Option<Date>, InvalidValue> {
self.0.get_date(Tag(432))
}
#[doc(alias = "ExpireTime")]
pub fn expire_time(&self) -> Result<Option<UtcTimestamp>, InvalidValue> {
self.0.get_utc_timestamp(Tag(126))
}
#[doc(alias = "MinQty")]
pub fn min_qty(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(110))
}
#[doc(alias = "ExecInst")]
pub fn exec_inst(&self) -> Result<Option<MultipleValues<'a, ExecInst<'a>>>, InvalidValue> {
self.0.get_multiple_values(Tag(18))
}
#[doc(alias = "SellerDays")]
pub fn seller_days(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(287))
}
#[doc(alias = "OrderID")]
pub fn order_id(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(37))
}
#[doc(alias = "QuoteEntryID")]
pub fn quote_entry_id(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(299))
}
#[doc(alias = "MDEntryBuyer")]
pub fn md_entry_buyer(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(288))
}
#[doc(alias = "MDEntrySeller")]
pub fn md_entry_seller(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(289))
}
#[doc(alias = "NumberOfOrders")]
pub fn number_of_orders(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(346))
}
#[doc(alias = "MDEntryPositionNo")]
pub fn md_entry_position_no(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(290))
}
#[doc(alias = "TotalVolumeTraded")]
pub fn total_volume_traded(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(387))
}
#[doc(alias = "Text")]
pub fn text(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(58))
}
#[doc(alias = "EncodedTextLen")]
pub fn encoded_text_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(354))
}
#[doc(alias = "EncodedText")]
pub fn encoded_text(&self) -> Option<&'a [u8]> {
self.0.get(Tag(355))
}
}
}
}
pub struct MarketDataRequestReject(RawMessage);
impl MarketDataRequestReject {
pub const MSG_TYPE: &[u8] = b"Y";
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(8), Tag(9), Tag(10), Tag(34), Tag(35), Tag(43), Tag(49), Tag(50), Tag(52), Tag(56),
Tag(57), Tag(58), Tag(89), Tag(90), Tag(91), Tag(93), Tag(97), Tag(115), Tag(116), Tag(122),
Tag(128), Tag(129), Tag(142), Tag(143), Tag(144), Tag(145), Tag(212), Tag(213), Tag(262),
Tag(281), Tag(347), Tag(354), Tag(355), Tag(369), Tag(370),
]);
pub fn from_raw(raw: RawMessage) -> Self {
Self(raw)
}
pub fn raw(&self) -> &RawMessage {
&self.0
}
pub fn header(&self) -> Header<'_> {
Header(self.0.scope())
}
pub fn trailer(&self) -> Trailer<'_> {
Trailer(self.0.scope())
}
#[doc(alias = "MDReqID")]
pub fn md_req_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(262))
}
#[doc(alias = "MDReqRejReason")]
pub fn md_req_rej_reason(&self) -> Result<Option<MDReqRejReason<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(281))?.map(MDReqRejReason::from_value))
}
#[doc(alias = "Text")]
pub fn text(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(58))
}
#[doc(alias = "EncodedTextLen")]
pub fn encoded_text_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(354))
}
#[doc(alias = "EncodedText")]
pub fn encoded_text(&self) -> Option<&[u8]> {
self.0.get(Tag(355))
}
}
impl std::fmt::Debug for MarketDataRequestReject {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "MarketDataRequestReject({})", self.0)
}
}
impl std::fmt::Display for MarketDataRequestReject {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
std::fmt::Display::fmt(&self.0, f)
}
}
pub struct QuoteCancel(RawMessage);
impl QuoteCancel {
pub const MSG_TYPE: &[u8] = b"Z";
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(8), Tag(9), Tag(10), Tag(22), Tag(34), Tag(35), Tag(43), Tag(48), Tag(49), Tag(50),
Tag(52), Tag(55), Tag(56), Tag(57), Tag(65), Tag(89), Tag(90), Tag(91), Tag(93), Tag(97),
Tag(106), Tag(107), Tag(115), Tag(116), Tag(117), Tag(122), Tag(128), Tag(129), Tag(131),
Tag(142), Tag(143), Tag(144), Tag(145), Tag(167), Tag(200), Tag(201), Tag(202), Tag(205),
Tag(206), Tag(207), Tag(212), Tag(213), Tag(223), Tag(231), Tag(295), Tag(298), Tag(301),
Tag(311), Tag(336), Tag(347), Tag(348), Tag(349), Tag(350), Tag(351), Tag(369), Tag(370),
]);
pub fn from_raw(raw: RawMessage) -> Self {
Self(raw)
}
pub fn raw(&self) -> &RawMessage {
&self.0
}
pub fn header(&self) -> Header<'_> {
Header(self.0.scope())
}
pub fn trailer(&self) -> Trailer<'_> {
Trailer(self.0.scope())
}
#[doc(alias = "QuoteReqID")]
pub fn quote_req_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(131))
}
#[doc(alias = "QuoteID")]
pub fn quote_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(117))
}
#[doc(alias = "QuoteCancelType")]
pub fn quote_cancel_type(&self) -> Result<Option<QuoteCancelType>, InvalidValue> {
Ok(self.0.get_int(Tag(298))?.map(QuoteCancelType::from_value))
}
#[doc(alias = "QuoteResponseLevel")]
pub fn quote_response_level(&self) -> Result<Option<QuoteResponseLevel>, InvalidValue> {
Ok(self.0.get_int(Tag(301))?.map(QuoteResponseLevel::from_value))
}
#[doc(alias = "TradingSessionID")]
pub fn trading_session_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(336))
}
#[doc(alias = "NoQuoteEntries")]
pub fn quote_entries(&self) -> Result<Instances<'_, quote_cancel::quote_entries::Instance<'_>>, InvalidValue> {
self.0.get_group("e_cancel::quote_entries::TABLE, &Self::KNOWN_TAGS).map(Instances::from)
}
}
impl std::fmt::Debug for QuoteCancel {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "QuoteCancel({})", self.0)
}
}
impl std::fmt::Display for QuoteCancel {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
std::fmt::Display::fmt(&self.0, f)
}
}
pub mod quote_cancel {
pub mod quote_entries {
use super::super::*;
pub const TABLE: GroupTable<'static> = GroupTable::new(
Tag(295),
Tag(55),
&[
Tag(22), Tag(48), Tag(55), Tag(65), Tag(106), Tag(107), Tag(167), Tag(200),
Tag(201), Tag(202), Tag(205), Tag(206), Tag(207), Tag(223), Tag(231), Tag(311),
Tag(348), Tag(349), Tag(350), Tag(351),
],
&[],
);
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(22), Tag(48), Tag(55), Tag(65), Tag(106), Tag(107), Tag(167), Tag(200), Tag(201),
Tag(202), Tag(205), Tag(206), Tag(207), Tag(223), Tag(231), Tag(311), Tag(348),
Tag(349), Tag(350), Tag(351),
]);
#[derive(Clone, Copy, Debug)]
pub struct Instance<'a>(refix_message::Scope<'a>);
impl<'a> From<refix_message::Scope<'a>> for Instance<'a> {
fn from(scope: refix_message::Scope<'a>) -> Self {
Self(scope)
}
}
impl<'a> Instance<'a> {
pub fn raw(&self) -> refix_message::Scope<'a> {
self.0
}
#[doc(alias = "Symbol")]
pub fn symbol(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(55))
}
#[doc(alias = "SymbolSfx")]
pub fn symbol_sfx(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(65))
}
#[doc(alias = "SecurityID")]
pub fn security_id(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(48))
}
#[doc(alias = "IDSource")]
pub fn id_source(&self) -> Result<Option<IDSource<'a>>, InvalidValue> {
Ok(self.0.get_str(Tag(22))?.map(IDSource::from_value))
}
#[doc(alias = "SecurityType")]
pub fn security_type(&self) -> Result<Option<SecurityType<'a>>, InvalidValue> {
Ok(self.0.get_str(Tag(167))?.map(SecurityType::from_value))
}
#[doc(alias = "MaturityMonthYear")]
pub fn maturity_month_year(&self) -> Result<Option<MonthYear>, InvalidValue> {
self.0.get_month_year(Tag(200))
}
#[doc(alias = "MaturityDay")]
pub fn maturity_day(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(205))
}
#[doc(alias = "PutOrCall")]
pub fn put_or_call(&self) -> Result<Option<PutOrCall>, InvalidValue> {
Ok(self.0.get_int(Tag(201))?.map(PutOrCall::from_value))
}
#[doc(alias = "StrikePrice")]
pub fn strike_price(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(202))
}
#[doc(alias = "OptAttribute")]
pub fn opt_attribute(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(206))
}
#[doc(alias = "ContractMultiplier")]
pub fn contract_multiplier(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(231))
}
#[doc(alias = "CouponRate")]
pub fn coupon_rate(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(223))
}
#[doc(alias = "SecurityExchange")]
pub fn security_exchange(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(207))
}
#[doc(alias = "Issuer")]
pub fn issuer(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(106))
}
#[doc(alias = "EncodedIssuerLen")]
pub fn encoded_issuer_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(348))
}
#[doc(alias = "EncodedIssuer")]
pub fn encoded_issuer(&self) -> Option<&'a [u8]> {
self.0.get(Tag(349))
}
#[doc(alias = "SecurityDesc")]
pub fn security_desc(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(107))
}
#[doc(alias = "EncodedSecurityDescLen")]
pub fn encoded_security_desc_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(350))
}
#[doc(alias = "EncodedSecurityDesc")]
pub fn encoded_security_desc(&self) -> Option<&'a [u8]> {
self.0.get(Tag(351))
}
#[doc(alias = "UnderlyingSymbol")]
pub fn underlying_symbol(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(311))
}
}
}
}
pub struct QuoteStatusRequest(RawMessage);
impl QuoteStatusRequest {
pub const MSG_TYPE: &[u8] = b"a";
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(8), Tag(9), Tag(10), Tag(22), Tag(34), Tag(35), Tag(43), Tag(48), Tag(49), Tag(50),
Tag(52), Tag(54), Tag(55), Tag(56), Tag(57), Tag(65), Tag(89), Tag(90), Tag(91), Tag(93),
Tag(97), Tag(106), Tag(107), Tag(115), Tag(116), Tag(117), Tag(122), Tag(128), Tag(129),
Tag(142), Tag(143), Tag(144), Tag(145), Tag(167), Tag(200), Tag(201), Tag(202), Tag(205),
Tag(206), Tag(207), Tag(212), Tag(213), Tag(223), Tag(231), Tag(336), Tag(347), Tag(348),
Tag(349), Tag(350), Tag(351), Tag(369), Tag(370),
]);
pub fn from_raw(raw: RawMessage) -> Self {
Self(raw)
}
pub fn raw(&self) -> &RawMessage {
&self.0
}
pub fn header(&self) -> Header<'_> {
Header(self.0.scope())
}
pub fn trailer(&self) -> Trailer<'_> {
Trailer(self.0.scope())
}
#[doc(alias = "QuoteID")]
pub fn quote_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(117))
}
#[doc(alias = "Symbol")]
pub fn symbol(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(55))
}
#[doc(alias = "SymbolSfx")]
pub fn symbol_sfx(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(65))
}
#[doc(alias = "SecurityID")]
pub fn security_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(48))
}
#[doc(alias = "IDSource")]
pub fn id_source(&self) -> Result<Option<IDSource<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(22))?.map(IDSource::from_value))
}
#[doc(alias = "SecurityType")]
pub fn security_type(&self) -> Result<Option<SecurityType<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(167))?.map(SecurityType::from_value))
}
#[doc(alias = "MaturityMonthYear")]
pub fn maturity_month_year(&self) -> Result<Option<MonthYear>, InvalidValue> {
self.0.get_month_year(Tag(200))
}
#[doc(alias = "MaturityDay")]
pub fn maturity_day(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(205))
}
#[doc(alias = "PutOrCall")]
pub fn put_or_call(&self) -> Result<Option<PutOrCall>, InvalidValue> {
Ok(self.0.get_int(Tag(201))?.map(PutOrCall::from_value))
}
#[doc(alias = "StrikePrice")]
pub fn strike_price(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(202))
}
#[doc(alias = "OptAttribute")]
pub fn opt_attribute(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(206))
}
#[doc(alias = "ContractMultiplier")]
pub fn contract_multiplier(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(231))
}
#[doc(alias = "CouponRate")]
pub fn coupon_rate(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(223))
}
#[doc(alias = "SecurityExchange")]
pub fn security_exchange(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(207))
}
#[doc(alias = "Issuer")]
pub fn issuer(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(106))
}
#[doc(alias = "EncodedIssuerLen")]
pub fn encoded_issuer_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(348))
}
#[doc(alias = "EncodedIssuer")]
pub fn encoded_issuer(&self) -> Option<&[u8]> {
self.0.get(Tag(349))
}
#[doc(alias = "SecurityDesc")]
pub fn security_desc(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(107))
}
#[doc(alias = "EncodedSecurityDescLen")]
pub fn encoded_security_desc_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(350))
}
#[doc(alias = "EncodedSecurityDesc")]
pub fn encoded_security_desc(&self) -> Option<&[u8]> {
self.0.get(Tag(351))
}
#[doc(alias = "Side")]
pub fn side(&self) -> Result<Option<Side<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(54))?.map(Side::from_value))
}
#[doc(alias = "TradingSessionID")]
pub fn trading_session_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(336))
}
}
impl std::fmt::Debug for QuoteStatusRequest {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "QuoteStatusRequest({})", self.0)
}
}
impl std::fmt::Display for QuoteStatusRequest {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
std::fmt::Display::fmt(&self.0, f)
}
}
pub struct QuoteAcknowledgement(RawMessage);
impl QuoteAcknowledgement {
pub const MSG_TYPE: &[u8] = b"b";
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(8), Tag(9), Tag(10), Tag(22), Tag(34), Tag(35), Tag(43), Tag(48), Tag(49), Tag(50),
Tag(52), Tag(55), Tag(56), Tag(57), Tag(58), Tag(65), Tag(89), Tag(90), Tag(91), Tag(93),
Tag(97), Tag(106), Tag(107), Tag(115), Tag(116), Tag(117), Tag(122), Tag(128), Tag(129),
Tag(131), Tag(142), Tag(143), Tag(144), Tag(145), Tag(167), Tag(200), Tag(201), Tag(202),
Tag(205), Tag(206), Tag(207), Tag(212), Tag(213), Tag(223), Tag(231), Tag(295), Tag(296),
Tag(297), Tag(299), Tag(300), Tag(301), Tag(302), Tag(304), Tag(305), Tag(306), Tag(307),
Tag(308), Tag(309), Tag(310), Tag(311), Tag(312), Tag(313), Tag(314), Tag(315), Tag(316),
Tag(317), Tag(336), Tag(347), Tag(348), Tag(349), Tag(350), Tag(351), Tag(362), Tag(363),
Tag(364), Tag(365), Tag(368), Tag(369), Tag(370), Tag(435), Tag(436),
]);
pub fn from_raw(raw: RawMessage) -> Self {
Self(raw)
}
pub fn raw(&self) -> &RawMessage {
&self.0
}
pub fn header(&self) -> Header<'_> {
Header(self.0.scope())
}
pub fn trailer(&self) -> Trailer<'_> {
Trailer(self.0.scope())
}
#[doc(alias = "QuoteReqID")]
pub fn quote_req_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(131))
}
#[doc(alias = "QuoteID")]
pub fn quote_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(117))
}
#[doc(alias = "QuoteStatus")]
pub fn quote_status(&self) -> Result<Option<QuoteStatus>, InvalidValue> {
Ok(self.0.get_int(Tag(297))?.map(QuoteStatus::from_value))
}
#[doc(alias = "QuoteRejectReason")]
pub fn quote_reject_reason(&self) -> Result<Option<QuoteRejectReason>, InvalidValue> {
Ok(self.0.get_int(Tag(300))?.map(QuoteRejectReason::from_value))
}
#[doc(alias = "QuoteResponseLevel")]
pub fn quote_response_level(&self) -> Result<Option<QuoteResponseLevel>, InvalidValue> {
Ok(self.0.get_int(Tag(301))?.map(QuoteResponseLevel::from_value))
}
#[doc(alias = "TradingSessionID")]
pub fn trading_session_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(336))
}
#[doc(alias = "Text")]
pub fn text(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(58))
}
#[doc(alias = "NoQuoteSets")]
pub fn quote_sets(&self) -> Result<Instances<'_, quote_acknowledgement::quote_sets::Instance<'_>>, InvalidValue> {
self.0.get_group("e_acknowledgement::quote_sets::TABLE, &Self::KNOWN_TAGS).map(Instances::from)
}
}
impl std::fmt::Debug for QuoteAcknowledgement {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "QuoteAcknowledgement({})", self.0)
}
}
impl std::fmt::Display for QuoteAcknowledgement {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
std::fmt::Display::fmt(&self.0, f)
}
}
pub mod quote_acknowledgement {
pub mod quote_sets {
use super::super::*;
pub const TABLE: GroupTable<'static> = GroupTable::new(
Tag(296),
Tag(302),
&[
Tag(295), Tag(302), Tag(304), Tag(305), Tag(306), Tag(307), Tag(308), Tag(309),
Tag(310), Tag(311), Tag(312), Tag(313), Tag(314), Tag(315), Tag(316), Tag(317),
Tag(362), Tag(363), Tag(364), Tag(365), Tag(435), Tag(436),
],
&[quote_acknowledgement::quote_sets::quote_entries::TABLE],
);
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(22), Tag(48), Tag(55), Tag(65), Tag(106), Tag(107), Tag(167), Tag(200), Tag(201),
Tag(202), Tag(205), Tag(206), Tag(207), Tag(223), Tag(231), Tag(295), Tag(299),
Tag(302), Tag(304), Tag(305), Tag(306), Tag(307), Tag(308), Tag(309), Tag(310),
Tag(311), Tag(312), Tag(313), Tag(314), Tag(315), Tag(316), Tag(317), Tag(348),
Tag(349), Tag(350), Tag(351), Tag(362), Tag(363), Tag(364), Tag(365), Tag(368),
Tag(435), Tag(436),
]);
#[derive(Clone, Copy, Debug)]
pub struct Instance<'a>(refix_message::Scope<'a>);
impl<'a> From<refix_message::Scope<'a>> for Instance<'a> {
fn from(scope: refix_message::Scope<'a>) -> Self {
Self(scope)
}
}
impl<'a> Instance<'a> {
pub fn raw(&self) -> refix_message::Scope<'a> {
self.0
}
#[doc(alias = "QuoteSetID")]
pub fn quote_set_id(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(302))
}
#[doc(alias = "UnderlyingSymbol")]
pub fn underlying_symbol(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(311))
}
#[doc(alias = "UnderlyingSymbolSfx")]
pub fn underlying_symbol_sfx(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(312))
}
#[doc(alias = "UnderlyingSecurityID")]
pub fn underlying_security_id(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(309))
}
#[doc(alias = "UnderlyingIDSource")]
pub fn underlying_id_source(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(305))
}
#[doc(alias = "UnderlyingSecurityType")]
pub fn underlying_security_type(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(310))
}
#[doc(alias = "UnderlyingMaturityMonthYear")]
pub fn underlying_maturity_month_year(&self) -> Result<Option<MonthYear>, InvalidValue> {
self.0.get_month_year(Tag(313))
}
#[doc(alias = "UnderlyingMaturityDay")]
pub fn underlying_maturity_day(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(314))
}
#[doc(alias = "UnderlyingPutOrCall")]
pub fn underlying_put_or_call(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(315))
}
#[doc(alias = "UnderlyingStrikePrice")]
pub fn underlying_strike_price(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(316))
}
#[doc(alias = "UnderlyingOptAttribute")]
pub fn underlying_opt_attribute(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(317))
}
#[doc(alias = "UnderlyingContractMultiplier")]
pub fn underlying_contract_multiplier(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(436))
}
#[doc(alias = "UnderlyingCouponRate")]
pub fn underlying_coupon_rate(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(435))
}
#[doc(alias = "UnderlyingSecurityExchange")]
pub fn underlying_security_exchange(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(308))
}
#[doc(alias = "UnderlyingIssuer")]
pub fn underlying_issuer(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(306))
}
#[doc(alias = "EncodedUnderlyingIssuerLen")]
pub fn encoded_underlying_issuer_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(362))
}
#[doc(alias = "EncodedUnderlyingIssuer")]
pub fn encoded_underlying_issuer(&self) -> Option<&'a [u8]> {
self.0.get(Tag(363))
}
#[doc(alias = "UnderlyingSecurityDesc")]
pub fn underlying_security_desc(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(307))
}
#[doc(alias = "EncodedUnderlyingSecurityDescLen")]
pub fn encoded_underlying_security_desc_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(364))
}
#[doc(alias = "EncodedUnderlyingSecurityDesc")]
pub fn encoded_underlying_security_desc(&self) -> Option<&'a [u8]> {
self.0.get(Tag(365))
}
#[doc(alias = "TotQuoteEntries")]
pub fn tot_quote_entries(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(304))
}
#[doc(alias = "NoQuoteEntries")]
pub fn quote_entries(&self) -> Result<Instances<'a, quote_acknowledgement::quote_sets::quote_entries::Instance<'a>>, InvalidValue> {
self.0.get_group("e_acknowledgement::quote_sets::quote_entries::TABLE, &KNOWN_TAGS).map(Instances::from)
}
}
pub mod quote_entries {
use super::super::super::*;
pub const TABLE: GroupTable<'static> = GroupTable::new(
Tag(295),
Tag(299),
&[
Tag(22), Tag(48), Tag(55), Tag(65), Tag(106), Tag(107), Tag(167), Tag(200),
Tag(201), Tag(202), Tag(205), Tag(206), Tag(207), Tag(223), Tag(231), Tag(299),
Tag(348), Tag(349), Tag(350), Tag(351), Tag(368),
],
&[],
);
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(22), Tag(48), Tag(55), Tag(65), Tag(106), Tag(107), Tag(167), Tag(200),
Tag(201), Tag(202), Tag(205), Tag(206), Tag(207), Tag(223), Tag(231), Tag(299),
Tag(348), Tag(349), Tag(350), Tag(351), Tag(368),
]);
#[derive(Clone, Copy, Debug)]
pub struct Instance<'a>(refix_message::Scope<'a>);
impl<'a> From<refix_message::Scope<'a>> for Instance<'a> {
fn from(scope: refix_message::Scope<'a>) -> Self {
Self(scope)
}
}
impl<'a> Instance<'a> {
pub fn raw(&self) -> refix_message::Scope<'a> {
self.0
}
#[doc(alias = "QuoteEntryID")]
pub fn quote_entry_id(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(299))
}
#[doc(alias = "Symbol")]
pub fn symbol(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(55))
}
#[doc(alias = "SymbolSfx")]
pub fn symbol_sfx(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(65))
}
#[doc(alias = "SecurityID")]
pub fn security_id(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(48))
}
#[doc(alias = "IDSource")]
pub fn id_source(&self) -> Result<Option<IDSource<'a>>, InvalidValue> {
Ok(self.0.get_str(Tag(22))?.map(IDSource::from_value))
}
#[doc(alias = "SecurityType")]
pub fn security_type(&self) -> Result<Option<SecurityType<'a>>, InvalidValue> {
Ok(self.0.get_str(Tag(167))?.map(SecurityType::from_value))
}
#[doc(alias = "MaturityMonthYear")]
pub fn maturity_month_year(&self) -> Result<Option<MonthYear>, InvalidValue> {
self.0.get_month_year(Tag(200))
}
#[doc(alias = "MaturityDay")]
pub fn maturity_day(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(205))
}
#[doc(alias = "PutOrCall")]
pub fn put_or_call(&self) -> Result<Option<PutOrCall>, InvalidValue> {
Ok(self.0.get_int(Tag(201))?.map(PutOrCall::from_value))
}
#[doc(alias = "StrikePrice")]
pub fn strike_price(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(202))
}
#[doc(alias = "OptAttribute")]
pub fn opt_attribute(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(206))
}
#[doc(alias = "ContractMultiplier")]
pub fn contract_multiplier(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(231))
}
#[doc(alias = "CouponRate")]
pub fn coupon_rate(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(223))
}
#[doc(alias = "SecurityExchange")]
pub fn security_exchange(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(207))
}
#[doc(alias = "Issuer")]
pub fn issuer(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(106))
}
#[doc(alias = "EncodedIssuerLen")]
pub fn encoded_issuer_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(348))
}
#[doc(alias = "EncodedIssuer")]
pub fn encoded_issuer(&self) -> Option<&'a [u8]> {
self.0.get(Tag(349))
}
#[doc(alias = "SecurityDesc")]
pub fn security_desc(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(107))
}
#[doc(alias = "EncodedSecurityDescLen")]
pub fn encoded_security_desc_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(350))
}
#[doc(alias = "EncodedSecurityDesc")]
pub fn encoded_security_desc(&self) -> Option<&'a [u8]> {
self.0.get(Tag(351))
}
#[doc(alias = "QuoteEntryRejectReason")]
pub fn quote_entry_reject_reason(&self) -> Result<Option<QuoteEntryRejectReason>, InvalidValue> {
Ok(self.0.get_int(Tag(368))?.map(QuoteEntryRejectReason::from_value))
}
}
}
}
}
pub struct SecurityDefinitionRequest(RawMessage);
impl SecurityDefinitionRequest {
pub const MSG_TYPE: &[u8] = b"c";
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(8), Tag(9), Tag(10), Tag(15), Tag(22), Tag(34), Tag(35), Tag(43), Tag(48), Tag(49),
Tag(50), Tag(52), Tag(54), Tag(55), Tag(56), Tag(57), Tag(58), Tag(65), Tag(89), Tag(90),
Tag(91), Tag(93), Tag(97), Tag(106), Tag(107), Tag(115), Tag(116), Tag(122), Tag(128),
Tag(129), Tag(142), Tag(143), Tag(144), Tag(145), Tag(146), Tag(167), Tag(200), Tag(201),
Tag(202), Tag(205), Tag(206), Tag(207), Tag(212), Tag(213), Tag(223), Tag(231), Tag(305),
Tag(306), Tag(307), Tag(308), Tag(309), Tag(310), Tag(311), Tag(312), Tag(313), Tag(314),
Tag(315), Tag(316), Tag(317), Tag(318), Tag(319), Tag(320), Tag(321), Tag(336), Tag(347),
Tag(348), Tag(349), Tag(350), Tag(351), Tag(354), Tag(355), Tag(362), Tag(363), Tag(364),
Tag(365), Tag(369), Tag(370), Tag(435), Tag(436),
]);
pub fn from_raw(raw: RawMessage) -> Self {
Self(raw)
}
pub fn raw(&self) -> &RawMessage {
&self.0
}
pub fn header(&self) -> Header<'_> {
Header(self.0.scope())
}
pub fn trailer(&self) -> Trailer<'_> {
Trailer(self.0.scope())
}
#[doc(alias = "SecurityReqID")]
pub fn security_req_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(320))
}
#[doc(alias = "SecurityRequestType")]
pub fn security_request_type(&self) -> Result<Option<SecurityRequestType>, InvalidValue> {
Ok(self.0.get_int(Tag(321))?.map(SecurityRequestType::from_value))
}
#[doc(alias = "Symbol")]
pub fn symbol(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(55))
}
#[doc(alias = "SymbolSfx")]
pub fn symbol_sfx(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(65))
}
#[doc(alias = "SecurityID")]
pub fn security_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(48))
}
#[doc(alias = "IDSource")]
pub fn id_source(&self) -> Result<Option<IDSource<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(22))?.map(IDSource::from_value))
}
#[doc(alias = "SecurityType")]
pub fn security_type(&self) -> Result<Option<SecurityType<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(167))?.map(SecurityType::from_value))
}
#[doc(alias = "MaturityMonthYear")]
pub fn maturity_month_year(&self) -> Result<Option<MonthYear>, InvalidValue> {
self.0.get_month_year(Tag(200))
}
#[doc(alias = "MaturityDay")]
pub fn maturity_day(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(205))
}
#[doc(alias = "PutOrCall")]
pub fn put_or_call(&self) -> Result<Option<PutOrCall>, InvalidValue> {
Ok(self.0.get_int(Tag(201))?.map(PutOrCall::from_value))
}
#[doc(alias = "StrikePrice")]
pub fn strike_price(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(202))
}
#[doc(alias = "OptAttribute")]
pub fn opt_attribute(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(206))
}
#[doc(alias = "ContractMultiplier")]
pub fn contract_multiplier(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(231))
}
#[doc(alias = "CouponRate")]
pub fn coupon_rate(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(223))
}
#[doc(alias = "SecurityExchange")]
pub fn security_exchange(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(207))
}
#[doc(alias = "Issuer")]
pub fn issuer(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(106))
}
#[doc(alias = "EncodedIssuerLen")]
pub fn encoded_issuer_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(348))
}
#[doc(alias = "EncodedIssuer")]
pub fn encoded_issuer(&self) -> Option<&[u8]> {
self.0.get(Tag(349))
}
#[doc(alias = "SecurityDesc")]
pub fn security_desc(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(107))
}
#[doc(alias = "EncodedSecurityDescLen")]
pub fn encoded_security_desc_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(350))
}
#[doc(alias = "EncodedSecurityDesc")]
pub fn encoded_security_desc(&self) -> Option<&[u8]> {
self.0.get(Tag(351))
}
#[doc(alias = "Currency")]
pub fn currency(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(15))
}
#[doc(alias = "Text")]
pub fn text(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(58))
}
#[doc(alias = "EncodedTextLen")]
pub fn encoded_text_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(354))
}
#[doc(alias = "EncodedText")]
pub fn encoded_text(&self) -> Option<&[u8]> {
self.0.get(Tag(355))
}
#[doc(alias = "TradingSessionID")]
pub fn trading_session_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(336))
}
#[doc(alias = "NoRelatedSym")]
pub fn related_sym(&self) -> Result<Instances<'_, security_definition_request::related_sym::Instance<'_>>, InvalidValue> {
self.0.get_group(&security_definition_request::related_sym::TABLE, &Self::KNOWN_TAGS).map(Instances::from)
}
}
impl std::fmt::Debug for SecurityDefinitionRequest {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "SecurityDefinitionRequest({})", self.0)
}
}
impl std::fmt::Display for SecurityDefinitionRequest {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
std::fmt::Display::fmt(&self.0, f)
}
}
pub mod security_definition_request {
pub mod related_sym {
use super::super::*;
pub const TABLE: GroupTable<'static> = GroupTable::new(
Tag(146),
Tag(311),
&[
Tag(54), Tag(305), Tag(306), Tag(307), Tag(308), Tag(309), Tag(310), Tag(311),
Tag(312), Tag(313), Tag(314), Tag(315), Tag(316), Tag(317), Tag(318), Tag(319),
Tag(362), Tag(363), Tag(364), Tag(365), Tag(435), Tag(436),
],
&[],
);
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(54), Tag(305), Tag(306), Tag(307), Tag(308), Tag(309), Tag(310), Tag(311), Tag(312),
Tag(313), Tag(314), Tag(315), Tag(316), Tag(317), Tag(318), Tag(319), Tag(362),
Tag(363), Tag(364), Tag(365), Tag(435), Tag(436),
]);
#[derive(Clone, Copy, Debug)]
pub struct Instance<'a>(refix_message::Scope<'a>);
impl<'a> From<refix_message::Scope<'a>> for Instance<'a> {
fn from(scope: refix_message::Scope<'a>) -> Self {
Self(scope)
}
}
impl<'a> Instance<'a> {
pub fn raw(&self) -> refix_message::Scope<'a> {
self.0
}
#[doc(alias = "UnderlyingSymbol")]
pub fn underlying_symbol(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(311))
}
#[doc(alias = "UnderlyingSymbolSfx")]
pub fn underlying_symbol_sfx(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(312))
}
#[doc(alias = "UnderlyingSecurityID")]
pub fn underlying_security_id(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(309))
}
#[doc(alias = "UnderlyingIDSource")]
pub fn underlying_id_source(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(305))
}
#[doc(alias = "UnderlyingSecurityType")]
pub fn underlying_security_type(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(310))
}
#[doc(alias = "UnderlyingMaturityMonthYear")]
pub fn underlying_maturity_month_year(&self) -> Result<Option<MonthYear>, InvalidValue> {
self.0.get_month_year(Tag(313))
}
#[doc(alias = "UnderlyingMaturityDay")]
pub fn underlying_maturity_day(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(314))
}
#[doc(alias = "UnderlyingPutOrCall")]
pub fn underlying_put_or_call(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(315))
}
#[doc(alias = "UnderlyingStrikePrice")]
pub fn underlying_strike_price(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(316))
}
#[doc(alias = "UnderlyingOptAttribute")]
pub fn underlying_opt_attribute(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(317))
}
#[doc(alias = "UnderlyingContractMultiplier")]
pub fn underlying_contract_multiplier(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(436))
}
#[doc(alias = "UnderlyingCouponRate")]
pub fn underlying_coupon_rate(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(435))
}
#[doc(alias = "UnderlyingSecurityExchange")]
pub fn underlying_security_exchange(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(308))
}
#[doc(alias = "UnderlyingIssuer")]
pub fn underlying_issuer(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(306))
}
#[doc(alias = "EncodedUnderlyingIssuerLen")]
pub fn encoded_underlying_issuer_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(362))
}
#[doc(alias = "EncodedUnderlyingIssuer")]
pub fn encoded_underlying_issuer(&self) -> Option<&'a [u8]> {
self.0.get(Tag(363))
}
#[doc(alias = "UnderlyingSecurityDesc")]
pub fn underlying_security_desc(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(307))
}
#[doc(alias = "EncodedUnderlyingSecurityDescLen")]
pub fn encoded_underlying_security_desc_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(364))
}
#[doc(alias = "EncodedUnderlyingSecurityDesc")]
pub fn encoded_underlying_security_desc(&self) -> Option<&'a [u8]> {
self.0.get(Tag(365))
}
#[doc(alias = "RatioQty")]
pub fn ratio_qty(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(319))
}
#[doc(alias = "Side")]
pub fn side(&self) -> Result<Option<Side<'a>>, InvalidValue> {
Ok(self.0.get_str(Tag(54))?.map(Side::from_value))
}
#[doc(alias = "UnderlyingCurrency")]
pub fn underlying_currency(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(318))
}
}
}
}
pub struct SecurityDefinition(RawMessage);
impl SecurityDefinition {
pub const MSG_TYPE: &[u8] = b"d";
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(8), Tag(9), Tag(10), Tag(15), Tag(22), Tag(34), Tag(35), Tag(43), Tag(48), Tag(49),
Tag(50), Tag(52), Tag(54), Tag(55), Tag(56), Tag(57), Tag(58), Tag(65), Tag(89), Tag(90),
Tag(91), Tag(93), Tag(97), Tag(106), Tag(107), Tag(115), Tag(116), Tag(122), Tag(128),
Tag(129), Tag(142), Tag(143), Tag(144), Tag(145), Tag(146), Tag(167), Tag(200), Tag(201),
Tag(202), Tag(205), Tag(206), Tag(207), Tag(212), Tag(213), Tag(223), Tag(231), Tag(305),
Tag(306), Tag(307), Tag(308), Tag(309), Tag(310), Tag(311), Tag(312), Tag(313), Tag(314),
Tag(315), Tag(316), Tag(317), Tag(318), Tag(319), Tag(320), Tag(322), Tag(323), Tag(336),
Tag(347), Tag(348), Tag(349), Tag(350), Tag(351), Tag(354), Tag(355), Tag(362), Tag(363),
Tag(364), Tag(365), Tag(369), Tag(370), Tag(393), Tag(435), Tag(436),
]);
pub fn from_raw(raw: RawMessage) -> Self {
Self(raw)
}
pub fn raw(&self) -> &RawMessage {
&self.0
}
pub fn header(&self) -> Header<'_> {
Header(self.0.scope())
}
pub fn trailer(&self) -> Trailer<'_> {
Trailer(self.0.scope())
}
#[doc(alias = "SecurityReqID")]
pub fn security_req_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(320))
}
#[doc(alias = "SecurityResponseID")]
pub fn security_response_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(322))
}
#[doc(alias = "SecurityResponseType")]
pub fn security_response_type(&self) -> Result<Option<SecurityResponseType>, InvalidValue> {
Ok(self.0.get_int(Tag(323))?.map(SecurityResponseType::from_value))
}
#[doc(alias = "TotalNumSecurities")]
pub fn total_num_securities(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(393))
}
#[doc(alias = "Symbol")]
pub fn symbol(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(55))
}
#[doc(alias = "SymbolSfx")]
pub fn symbol_sfx(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(65))
}
#[doc(alias = "SecurityID")]
pub fn security_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(48))
}
#[doc(alias = "IDSource")]
pub fn id_source(&self) -> Result<Option<IDSource<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(22))?.map(IDSource::from_value))
}
#[doc(alias = "SecurityType")]
pub fn security_type(&self) -> Result<Option<SecurityType<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(167))?.map(SecurityType::from_value))
}
#[doc(alias = "MaturityMonthYear")]
pub fn maturity_month_year(&self) -> Result<Option<MonthYear>, InvalidValue> {
self.0.get_month_year(Tag(200))
}
#[doc(alias = "MaturityDay")]
pub fn maturity_day(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(205))
}
#[doc(alias = "PutOrCall")]
pub fn put_or_call(&self) -> Result<Option<PutOrCall>, InvalidValue> {
Ok(self.0.get_int(Tag(201))?.map(PutOrCall::from_value))
}
#[doc(alias = "StrikePrice")]
pub fn strike_price(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(202))
}
#[doc(alias = "OptAttribute")]
pub fn opt_attribute(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(206))
}
#[doc(alias = "ContractMultiplier")]
pub fn contract_multiplier(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(231))
}
#[doc(alias = "CouponRate")]
pub fn coupon_rate(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(223))
}
#[doc(alias = "SecurityExchange")]
pub fn security_exchange(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(207))
}
#[doc(alias = "Issuer")]
pub fn issuer(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(106))
}
#[doc(alias = "EncodedIssuerLen")]
pub fn encoded_issuer_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(348))
}
#[doc(alias = "EncodedIssuer")]
pub fn encoded_issuer(&self) -> Option<&[u8]> {
self.0.get(Tag(349))
}
#[doc(alias = "SecurityDesc")]
pub fn security_desc(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(107))
}
#[doc(alias = "EncodedSecurityDescLen")]
pub fn encoded_security_desc_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(350))
}
#[doc(alias = "EncodedSecurityDesc")]
pub fn encoded_security_desc(&self) -> Option<&[u8]> {
self.0.get(Tag(351))
}
#[doc(alias = "Currency")]
pub fn currency(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(15))
}
#[doc(alias = "TradingSessionID")]
pub fn trading_session_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(336))
}
#[doc(alias = "Text")]
pub fn text(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(58))
}
#[doc(alias = "EncodedTextLen")]
pub fn encoded_text_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(354))
}
#[doc(alias = "EncodedText")]
pub fn encoded_text(&self) -> Option<&[u8]> {
self.0.get(Tag(355))
}
#[doc(alias = "NoRelatedSym")]
pub fn related_sym(&self) -> Result<Instances<'_, security_definition::related_sym::Instance<'_>>, InvalidValue> {
self.0.get_group(&security_definition::related_sym::TABLE, &Self::KNOWN_TAGS).map(Instances::from)
}
}
impl std::fmt::Debug for SecurityDefinition {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "SecurityDefinition({})", self.0)
}
}
impl std::fmt::Display for SecurityDefinition {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
std::fmt::Display::fmt(&self.0, f)
}
}
pub mod security_definition {
pub mod related_sym {
use super::super::*;
pub const TABLE: GroupTable<'static> = GroupTable::new(
Tag(146),
Tag(311),
&[
Tag(54), Tag(305), Tag(306), Tag(307), Tag(308), Tag(309), Tag(310), Tag(311),
Tag(312), Tag(313), Tag(314), Tag(315), Tag(316), Tag(317), Tag(318), Tag(319),
Tag(362), Tag(363), Tag(364), Tag(365), Tag(435), Tag(436),
],
&[],
);
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(54), Tag(305), Tag(306), Tag(307), Tag(308), Tag(309), Tag(310), Tag(311), Tag(312),
Tag(313), Tag(314), Tag(315), Tag(316), Tag(317), Tag(318), Tag(319), Tag(362),
Tag(363), Tag(364), Tag(365), Tag(435), Tag(436),
]);
#[derive(Clone, Copy, Debug)]
pub struct Instance<'a>(refix_message::Scope<'a>);
impl<'a> From<refix_message::Scope<'a>> for Instance<'a> {
fn from(scope: refix_message::Scope<'a>) -> Self {
Self(scope)
}
}
impl<'a> Instance<'a> {
pub fn raw(&self) -> refix_message::Scope<'a> {
self.0
}
#[doc(alias = "UnderlyingSymbol")]
pub fn underlying_symbol(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(311))
}
#[doc(alias = "UnderlyingSymbolSfx")]
pub fn underlying_symbol_sfx(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(312))
}
#[doc(alias = "UnderlyingSecurityID")]
pub fn underlying_security_id(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(309))
}
#[doc(alias = "UnderlyingIDSource")]
pub fn underlying_id_source(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(305))
}
#[doc(alias = "UnderlyingSecurityType")]
pub fn underlying_security_type(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(310))
}
#[doc(alias = "UnderlyingMaturityMonthYear")]
pub fn underlying_maturity_month_year(&self) -> Result<Option<MonthYear>, InvalidValue> {
self.0.get_month_year(Tag(313))
}
#[doc(alias = "UnderlyingMaturityDay")]
pub fn underlying_maturity_day(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(314))
}
#[doc(alias = "UnderlyingPutOrCall")]
pub fn underlying_put_or_call(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(315))
}
#[doc(alias = "UnderlyingStrikePrice")]
pub fn underlying_strike_price(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(316))
}
#[doc(alias = "UnderlyingOptAttribute")]
pub fn underlying_opt_attribute(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(317))
}
#[doc(alias = "UnderlyingContractMultiplier")]
pub fn underlying_contract_multiplier(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(436))
}
#[doc(alias = "UnderlyingCouponRate")]
pub fn underlying_coupon_rate(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(435))
}
#[doc(alias = "UnderlyingSecurityExchange")]
pub fn underlying_security_exchange(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(308))
}
#[doc(alias = "UnderlyingIssuer")]
pub fn underlying_issuer(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(306))
}
#[doc(alias = "EncodedUnderlyingIssuerLen")]
pub fn encoded_underlying_issuer_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(362))
}
#[doc(alias = "EncodedUnderlyingIssuer")]
pub fn encoded_underlying_issuer(&self) -> Option<&'a [u8]> {
self.0.get(Tag(363))
}
#[doc(alias = "UnderlyingSecurityDesc")]
pub fn underlying_security_desc(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(307))
}
#[doc(alias = "EncodedUnderlyingSecurityDescLen")]
pub fn encoded_underlying_security_desc_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(364))
}
#[doc(alias = "EncodedUnderlyingSecurityDesc")]
pub fn encoded_underlying_security_desc(&self) -> Option<&'a [u8]> {
self.0.get(Tag(365))
}
#[doc(alias = "RatioQty")]
pub fn ratio_qty(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(319))
}
#[doc(alias = "Side")]
pub fn side(&self) -> Result<Option<Side<'a>>, InvalidValue> {
Ok(self.0.get_str(Tag(54))?.map(Side::from_value))
}
#[doc(alias = "UnderlyingCurrency")]
pub fn underlying_currency(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(318))
}
}
}
}
pub struct SecurityStatusRequest(RawMessage);
impl SecurityStatusRequest {
pub const MSG_TYPE: &[u8] = b"e";
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(8), Tag(9), Tag(10), Tag(15), Tag(22), Tag(34), Tag(35), Tag(43), Tag(48), Tag(49),
Tag(50), Tag(52), Tag(55), Tag(56), Tag(57), Tag(65), Tag(89), Tag(90), Tag(91), Tag(93),
Tag(97), Tag(106), Tag(107), Tag(115), Tag(116), Tag(122), Tag(128), Tag(129), Tag(142),
Tag(143), Tag(144), Tag(145), Tag(167), Tag(200), Tag(201), Tag(202), Tag(205), Tag(206),
Tag(207), Tag(212), Tag(213), Tag(223), Tag(231), Tag(263), Tag(324), Tag(336), Tag(347),
Tag(348), Tag(349), Tag(350), Tag(351), Tag(369), Tag(370),
]);
pub fn from_raw(raw: RawMessage) -> Self {
Self(raw)
}
pub fn raw(&self) -> &RawMessage {
&self.0
}
pub fn header(&self) -> Header<'_> {
Header(self.0.scope())
}
pub fn trailer(&self) -> Trailer<'_> {
Trailer(self.0.scope())
}
#[doc(alias = "SecurityStatusReqID")]
pub fn security_status_req_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(324))
}
#[doc(alias = "Symbol")]
pub fn symbol(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(55))
}
#[doc(alias = "SymbolSfx")]
pub fn symbol_sfx(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(65))
}
#[doc(alias = "SecurityID")]
pub fn security_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(48))
}
#[doc(alias = "IDSource")]
pub fn id_source(&self) -> Result<Option<IDSource<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(22))?.map(IDSource::from_value))
}
#[doc(alias = "SecurityType")]
pub fn security_type(&self) -> Result<Option<SecurityType<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(167))?.map(SecurityType::from_value))
}
#[doc(alias = "MaturityMonthYear")]
pub fn maturity_month_year(&self) -> Result<Option<MonthYear>, InvalidValue> {
self.0.get_month_year(Tag(200))
}
#[doc(alias = "MaturityDay")]
pub fn maturity_day(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(205))
}
#[doc(alias = "PutOrCall")]
pub fn put_or_call(&self) -> Result<Option<PutOrCall>, InvalidValue> {
Ok(self.0.get_int(Tag(201))?.map(PutOrCall::from_value))
}
#[doc(alias = "StrikePrice")]
pub fn strike_price(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(202))
}
#[doc(alias = "OptAttribute")]
pub fn opt_attribute(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(206))
}
#[doc(alias = "ContractMultiplier")]
pub fn contract_multiplier(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(231))
}
#[doc(alias = "CouponRate")]
pub fn coupon_rate(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(223))
}
#[doc(alias = "SecurityExchange")]
pub fn security_exchange(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(207))
}
#[doc(alias = "Issuer")]
pub fn issuer(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(106))
}
#[doc(alias = "EncodedIssuerLen")]
pub fn encoded_issuer_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(348))
}
#[doc(alias = "EncodedIssuer")]
pub fn encoded_issuer(&self) -> Option<&[u8]> {
self.0.get(Tag(349))
}
#[doc(alias = "SecurityDesc")]
pub fn security_desc(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(107))
}
#[doc(alias = "EncodedSecurityDescLen")]
pub fn encoded_security_desc_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(350))
}
#[doc(alias = "EncodedSecurityDesc")]
pub fn encoded_security_desc(&self) -> Option<&[u8]> {
self.0.get(Tag(351))
}
#[doc(alias = "Currency")]
pub fn currency(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(15))
}
#[doc(alias = "SubscriptionRequestType")]
pub fn subscription_request_type(&self) -> Result<Option<SubscriptionRequestType<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(263))?.map(SubscriptionRequestType::from_value))
}
#[doc(alias = "TradingSessionID")]
pub fn trading_session_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(336))
}
}
impl std::fmt::Debug for SecurityStatusRequest {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "SecurityStatusRequest({})", self.0)
}
}
impl std::fmt::Display for SecurityStatusRequest {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
std::fmt::Display::fmt(&self.0, f)
}
}
pub struct SecurityStatus(RawMessage);
impl SecurityStatus {
pub const MSG_TYPE: &[u8] = b"f";
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(8), Tag(9), Tag(10), Tag(15), Tag(22), Tag(31), Tag(34), Tag(35), Tag(43), Tag(48),
Tag(49), Tag(50), Tag(52), Tag(55), Tag(56), Tag(57), Tag(60), Tag(65), Tag(89), Tag(90),
Tag(91), Tag(93), Tag(97), Tag(106), Tag(107), Tag(115), Tag(116), Tag(122), Tag(128),
Tag(129), Tag(142), Tag(143), Tag(144), Tag(145), Tag(167), Tag(200), Tag(201), Tag(202),
Tag(205), Tag(206), Tag(207), Tag(212), Tag(213), Tag(223), Tag(231), Tag(291), Tag(292),
Tag(324), Tag(325), Tag(326), Tag(327), Tag(328), Tag(329), Tag(330), Tag(331), Tag(332),
Tag(333), Tag(334), Tag(336), Tag(347), Tag(348), Tag(349), Tag(350), Tag(351), Tag(369),
Tag(370),
]);
pub fn from_raw(raw: RawMessage) -> Self {
Self(raw)
}
pub fn raw(&self) -> &RawMessage {
&self.0
}
pub fn header(&self) -> Header<'_> {
Header(self.0.scope())
}
pub fn trailer(&self) -> Trailer<'_> {
Trailer(self.0.scope())
}
#[doc(alias = "SecurityStatusReqID")]
pub fn security_status_req_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(324))
}
#[doc(alias = "Symbol")]
pub fn symbol(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(55))
}
#[doc(alias = "SymbolSfx")]
pub fn symbol_sfx(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(65))
}
#[doc(alias = "SecurityID")]
pub fn security_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(48))
}
#[doc(alias = "IDSource")]
pub fn id_source(&self) -> Result<Option<IDSource<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(22))?.map(IDSource::from_value))
}
#[doc(alias = "SecurityType")]
pub fn security_type(&self) -> Result<Option<SecurityType<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(167))?.map(SecurityType::from_value))
}
#[doc(alias = "MaturityMonthYear")]
pub fn maturity_month_year(&self) -> Result<Option<MonthYear>, InvalidValue> {
self.0.get_month_year(Tag(200))
}
#[doc(alias = "MaturityDay")]
pub fn maturity_day(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(205))
}
#[doc(alias = "PutOrCall")]
pub fn put_or_call(&self) -> Result<Option<PutOrCall>, InvalidValue> {
Ok(self.0.get_int(Tag(201))?.map(PutOrCall::from_value))
}
#[doc(alias = "StrikePrice")]
pub fn strike_price(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(202))
}
#[doc(alias = "OptAttribute")]
pub fn opt_attribute(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(206))
}
#[doc(alias = "ContractMultiplier")]
pub fn contract_multiplier(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(231))
}
#[doc(alias = "CouponRate")]
pub fn coupon_rate(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(223))
}
#[doc(alias = "SecurityExchange")]
pub fn security_exchange(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(207))
}
#[doc(alias = "Issuer")]
pub fn issuer(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(106))
}
#[doc(alias = "EncodedIssuerLen")]
pub fn encoded_issuer_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(348))
}
#[doc(alias = "EncodedIssuer")]
pub fn encoded_issuer(&self) -> Option<&[u8]> {
self.0.get(Tag(349))
}
#[doc(alias = "SecurityDesc")]
pub fn security_desc(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(107))
}
#[doc(alias = "EncodedSecurityDescLen")]
pub fn encoded_security_desc_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(350))
}
#[doc(alias = "EncodedSecurityDesc")]
pub fn encoded_security_desc(&self) -> Option<&[u8]> {
self.0.get(Tag(351))
}
#[doc(alias = "Currency")]
pub fn currency(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(15))
}
#[doc(alias = "TradingSessionID")]
pub fn trading_session_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(336))
}
#[doc(alias = "UnsolicitedIndicator")]
pub fn unsolicited_indicator(&self) -> Result<Option<bool>, InvalidValue> {
self.0.get_bool(Tag(325))
}
#[doc(alias = "SecurityTradingStatus")]
pub fn security_trading_status(&self) -> Result<Option<SecurityTradingStatus>, InvalidValue> {
Ok(self.0.get_int(Tag(326))?.map(SecurityTradingStatus::from_value))
}
#[doc(alias = "FinancialStatus")]
pub fn financial_status(&self) -> Result<Option<FinancialStatus<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(291))?.map(FinancialStatus::from_value))
}
#[doc(alias = "CorporateAction")]
pub fn corporate_action(&self) -> Result<Option<CorporateAction<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(292))?.map(CorporateAction::from_value))
}
#[doc(alias = "HaltReasonChar")]
pub fn halt_reason_char(&self) -> Result<Option<HaltReasonChar<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(327))?.map(HaltReasonChar::from_value))
}
#[doc(alias = "InViewOfCommon")]
pub fn in_view_of_common(&self) -> Result<Option<bool>, InvalidValue> {
self.0.get_bool(Tag(328))
}
#[doc(alias = "DueToRelated")]
pub fn due_to_related(&self) -> Result<Option<bool>, InvalidValue> {
self.0.get_bool(Tag(329))
}
#[doc(alias = "BuyVolume")]
pub fn buy_volume(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(330))
}
#[doc(alias = "SellVolume")]
pub fn sell_volume(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(331))
}
#[doc(alias = "HighPx")]
pub fn high_px(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(332))
}
#[doc(alias = "LowPx")]
pub fn low_px(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(333))
}
#[doc(alias = "LastPx")]
pub fn last_px(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(31))
}
#[doc(alias = "TransactTime")]
pub fn transact_time(&self) -> Result<Option<UtcTimestamp>, InvalidValue> {
self.0.get_utc_timestamp(Tag(60))
}
#[doc(alias = "Adjustment")]
pub fn adjustment(&self) -> Result<Option<Adjustment>, InvalidValue> {
Ok(self.0.get_int(Tag(334))?.map(Adjustment::from_value))
}
}
impl std::fmt::Debug for SecurityStatus {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "SecurityStatus({})", self.0)
}
}
impl std::fmt::Display for SecurityStatus {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
std::fmt::Display::fmt(&self.0, f)
}
}
pub struct TradingSessionStatusRequest(RawMessage);
impl TradingSessionStatusRequest {
pub const MSG_TYPE: &[u8] = b"g";
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(8), Tag(9), Tag(10), Tag(34), Tag(35), Tag(43), Tag(49), Tag(50), Tag(52), Tag(56),
Tag(57), Tag(89), Tag(90), Tag(91), Tag(93), Tag(97), Tag(115), Tag(116), Tag(122),
Tag(128), Tag(129), Tag(142), Tag(143), Tag(144), Tag(145), Tag(212), Tag(213), Tag(263),
Tag(335), Tag(336), Tag(338), Tag(339), Tag(347), Tag(369), Tag(370),
]);
pub fn from_raw(raw: RawMessage) -> Self {
Self(raw)
}
pub fn raw(&self) -> &RawMessage {
&self.0
}
pub fn header(&self) -> Header<'_> {
Header(self.0.scope())
}
pub fn trailer(&self) -> Trailer<'_> {
Trailer(self.0.scope())
}
#[doc(alias = "TradSesReqID")]
pub fn trad_ses_req_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(335))
}
#[doc(alias = "TradingSessionID")]
pub fn trading_session_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(336))
}
#[doc(alias = "TradSesMethod")]
pub fn trad_ses_method(&self) -> Result<Option<TradSesMethod>, InvalidValue> {
Ok(self.0.get_int(Tag(338))?.map(TradSesMethod::from_value))
}
#[doc(alias = "TradSesMode")]
pub fn trad_ses_mode(&self) -> Result<Option<TradSesMode>, InvalidValue> {
Ok(self.0.get_int(Tag(339))?.map(TradSesMode::from_value))
}
#[doc(alias = "SubscriptionRequestType")]
pub fn subscription_request_type(&self) -> Result<Option<SubscriptionRequestType<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(263))?.map(SubscriptionRequestType::from_value))
}
}
impl std::fmt::Debug for TradingSessionStatusRequest {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "TradingSessionStatusRequest({})", self.0)
}
}
impl std::fmt::Display for TradingSessionStatusRequest {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
std::fmt::Display::fmt(&self.0, f)
}
}
pub struct TradingSessionStatus(RawMessage);
impl TradingSessionStatus {
pub const MSG_TYPE: &[u8] = b"h";
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(8), Tag(9), Tag(10), Tag(34), Tag(35), Tag(43), Tag(49), Tag(50), Tag(52), Tag(56),
Tag(57), Tag(58), Tag(89), Tag(90), Tag(91), Tag(93), Tag(97), Tag(115), Tag(116), Tag(122),
Tag(128), Tag(129), Tag(142), Tag(143), Tag(144), Tag(145), Tag(212), Tag(213), Tag(325),
Tag(335), Tag(336), Tag(338), Tag(339), Tag(340), Tag(341), Tag(342), Tag(343), Tag(344),
Tag(345), Tag(347), Tag(354), Tag(355), Tag(369), Tag(370), Tag(387),
]);
pub fn from_raw(raw: RawMessage) -> Self {
Self(raw)
}
pub fn raw(&self) -> &RawMessage {
&self.0
}
pub fn header(&self) -> Header<'_> {
Header(self.0.scope())
}
pub fn trailer(&self) -> Trailer<'_> {
Trailer(self.0.scope())
}
#[doc(alias = "TradSesReqID")]
pub fn trad_ses_req_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(335))
}
#[doc(alias = "TradingSessionID")]
pub fn trading_session_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(336))
}
#[doc(alias = "TradSesMethod")]
pub fn trad_ses_method(&self) -> Result<Option<TradSesMethod>, InvalidValue> {
Ok(self.0.get_int(Tag(338))?.map(TradSesMethod::from_value))
}
#[doc(alias = "TradSesMode")]
pub fn trad_ses_mode(&self) -> Result<Option<TradSesMode>, InvalidValue> {
Ok(self.0.get_int(Tag(339))?.map(TradSesMode::from_value))
}
#[doc(alias = "UnsolicitedIndicator")]
pub fn unsolicited_indicator(&self) -> Result<Option<bool>, InvalidValue> {
self.0.get_bool(Tag(325))
}
#[doc(alias = "TradSesStatus")]
pub fn trad_ses_status(&self) -> Result<Option<TradSesStatus>, InvalidValue> {
Ok(self.0.get_int(Tag(340))?.map(TradSesStatus::from_value))
}
#[doc(alias = "TradSesStartTime")]
pub fn trad_ses_start_time(&self) -> Result<Option<UtcTimestamp>, InvalidValue> {
self.0.get_utc_timestamp(Tag(341))
}
#[doc(alias = "TradSesOpenTime")]
pub fn trad_ses_open_time(&self) -> Result<Option<UtcTimestamp>, InvalidValue> {
self.0.get_utc_timestamp(Tag(342))
}
#[doc(alias = "TradSesPreCloseTime")]
pub fn trad_ses_pre_close_time(&self) -> Result<Option<UtcTimestamp>, InvalidValue> {
self.0.get_utc_timestamp(Tag(343))
}
#[doc(alias = "TradSesCloseTime")]
pub fn trad_ses_close_time(&self) -> Result<Option<UtcTimestamp>, InvalidValue> {
self.0.get_utc_timestamp(Tag(344))
}
#[doc(alias = "TradSesEndTime")]
pub fn trad_ses_end_time(&self) -> Result<Option<UtcTimestamp>, InvalidValue> {
self.0.get_utc_timestamp(Tag(345))
}
#[doc(alias = "TotalVolumeTraded")]
pub fn total_volume_traded(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(387))
}
#[doc(alias = "Text")]
pub fn text(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(58))
}
#[doc(alias = "EncodedTextLen")]
pub fn encoded_text_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(354))
}
#[doc(alias = "EncodedText")]
pub fn encoded_text(&self) -> Option<&[u8]> {
self.0.get(Tag(355))
}
}
impl std::fmt::Debug for TradingSessionStatus {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "TradingSessionStatus({})", self.0)
}
}
impl std::fmt::Display for TradingSessionStatus {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
std::fmt::Display::fmt(&self.0, f)
}
}
pub struct MassQuote(RawMessage);
impl MassQuote {
pub const MSG_TYPE: &[u8] = b"i";
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(8), Tag(9), Tag(10), Tag(15), Tag(22), Tag(34), Tag(35), Tag(40), Tag(43), Tag(48),
Tag(49), Tag(50), Tag(52), Tag(55), Tag(56), Tag(57), Tag(60), Tag(62), Tag(64), Tag(65),
Tag(89), Tag(90), Tag(91), Tag(93), Tag(97), Tag(106), Tag(107), Tag(115), Tag(116),
Tag(117), Tag(122), Tag(128), Tag(129), Tag(131), Tag(132), Tag(133), Tag(134), Tag(135),
Tag(142), Tag(143), Tag(144), Tag(145), Tag(167), Tag(188), Tag(189), Tag(190), Tag(191),
Tag(192), Tag(193), Tag(200), Tag(201), Tag(202), Tag(205), Tag(206), Tag(207), Tag(212),
Tag(213), Tag(223), Tag(231), Tag(293), Tag(294), Tag(295), Tag(296), Tag(299), Tag(301),
Tag(302), Tag(304), Tag(305), Tag(306), Tag(307), Tag(308), Tag(309), Tag(310), Tag(311),
Tag(312), Tag(313), Tag(314), Tag(315), Tag(316), Tag(317), Tag(336), Tag(347), Tag(348),
Tag(349), Tag(350), Tag(351), Tag(362), Tag(363), Tag(364), Tag(365), Tag(367), Tag(369),
Tag(370), Tag(435), Tag(436),
]);
pub fn from_raw(raw: RawMessage) -> Self {
Self(raw)
}
pub fn raw(&self) -> &RawMessage {
&self.0
}
pub fn header(&self) -> Header<'_> {
Header(self.0.scope())
}
pub fn trailer(&self) -> Trailer<'_> {
Trailer(self.0.scope())
}
#[doc(alias = "QuoteReqID")]
pub fn quote_req_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(131))
}
#[doc(alias = "QuoteID")]
pub fn quote_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(117))
}
#[doc(alias = "QuoteResponseLevel")]
pub fn quote_response_level(&self) -> Result<Option<QuoteResponseLevel>, InvalidValue> {
Ok(self.0.get_int(Tag(301))?.map(QuoteResponseLevel::from_value))
}
#[doc(alias = "DefBidSize")]
pub fn def_bid_size(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(293))
}
#[doc(alias = "DefOfferSize")]
pub fn def_offer_size(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(294))
}
#[doc(alias = "NoQuoteSets")]
pub fn quote_sets(&self) -> Result<Instances<'_, mass_quote::quote_sets::Instance<'_>>, InvalidValue> {
self.0.get_group(&mass_quote::quote_sets::TABLE, &Self::KNOWN_TAGS).map(Instances::from)
}
}
impl std::fmt::Debug for MassQuote {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "MassQuote({})", self.0)
}
}
impl std::fmt::Display for MassQuote {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
std::fmt::Display::fmt(&self.0, f)
}
}
pub mod mass_quote {
pub mod quote_sets {
use super::super::*;
pub const TABLE: GroupTable<'static> = GroupTable::new(
Tag(296),
Tag(302),
&[
Tag(295), Tag(302), Tag(304), Tag(305), Tag(306), Tag(307), Tag(308), Tag(309),
Tag(310), Tag(311), Tag(312), Tag(313), Tag(314), Tag(315), Tag(316), Tag(317),
Tag(362), Tag(363), Tag(364), Tag(365), Tag(367), Tag(435), Tag(436),
],
&[mass_quote::quote_sets::quote_entries::TABLE],
);
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(15), Tag(22), Tag(40), Tag(48), Tag(55), Tag(60), Tag(62), Tag(64), Tag(65),
Tag(106), Tag(107), Tag(132), Tag(133), Tag(134), Tag(135), Tag(167), Tag(188),
Tag(189), Tag(190), Tag(191), Tag(192), Tag(193), Tag(200), Tag(201), Tag(202),
Tag(205), Tag(206), Tag(207), Tag(223), Tag(231), Tag(295), Tag(299), Tag(302),
Tag(304), Tag(305), Tag(306), Tag(307), Tag(308), Tag(309), Tag(310), Tag(311),
Tag(312), Tag(313), Tag(314), Tag(315), Tag(316), Tag(317), Tag(336), Tag(348),
Tag(349), Tag(350), Tag(351), Tag(362), Tag(363), Tag(364), Tag(365), Tag(367),
Tag(435), Tag(436),
]);
#[derive(Clone, Copy, Debug)]
pub struct Instance<'a>(refix_message::Scope<'a>);
impl<'a> From<refix_message::Scope<'a>> for Instance<'a> {
fn from(scope: refix_message::Scope<'a>) -> Self {
Self(scope)
}
}
impl<'a> Instance<'a> {
pub fn raw(&self) -> refix_message::Scope<'a> {
self.0
}
#[doc(alias = "QuoteSetID")]
pub fn quote_set_id(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(302))
}
#[doc(alias = "UnderlyingSymbol")]
pub fn underlying_symbol(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(311))
}
#[doc(alias = "UnderlyingSymbolSfx")]
pub fn underlying_symbol_sfx(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(312))
}
#[doc(alias = "UnderlyingSecurityID")]
pub fn underlying_security_id(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(309))
}
#[doc(alias = "UnderlyingIDSource")]
pub fn underlying_id_source(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(305))
}
#[doc(alias = "UnderlyingSecurityType")]
pub fn underlying_security_type(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(310))
}
#[doc(alias = "UnderlyingMaturityMonthYear")]
pub fn underlying_maturity_month_year(&self) -> Result<Option<MonthYear>, InvalidValue> {
self.0.get_month_year(Tag(313))
}
#[doc(alias = "UnderlyingMaturityDay")]
pub fn underlying_maturity_day(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(314))
}
#[doc(alias = "UnderlyingPutOrCall")]
pub fn underlying_put_or_call(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(315))
}
#[doc(alias = "UnderlyingStrikePrice")]
pub fn underlying_strike_price(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(316))
}
#[doc(alias = "UnderlyingOptAttribute")]
pub fn underlying_opt_attribute(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(317))
}
#[doc(alias = "UnderlyingContractMultiplier")]
pub fn underlying_contract_multiplier(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(436))
}
#[doc(alias = "UnderlyingCouponRate")]
pub fn underlying_coupon_rate(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(435))
}
#[doc(alias = "UnderlyingSecurityExchange")]
pub fn underlying_security_exchange(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(308))
}
#[doc(alias = "UnderlyingIssuer")]
pub fn underlying_issuer(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(306))
}
#[doc(alias = "EncodedUnderlyingIssuerLen")]
pub fn encoded_underlying_issuer_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(362))
}
#[doc(alias = "EncodedUnderlyingIssuer")]
pub fn encoded_underlying_issuer(&self) -> Option<&'a [u8]> {
self.0.get(Tag(363))
}
#[doc(alias = "UnderlyingSecurityDesc")]
pub fn underlying_security_desc(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(307))
}
#[doc(alias = "EncodedUnderlyingSecurityDescLen")]
pub fn encoded_underlying_security_desc_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(364))
}
#[doc(alias = "EncodedUnderlyingSecurityDesc")]
pub fn encoded_underlying_security_desc(&self) -> Option<&'a [u8]> {
self.0.get(Tag(365))
}
#[doc(alias = "QuoteSetValidUntilTime")]
pub fn quote_set_valid_until_time(&self) -> Result<Option<UtcTimestamp>, InvalidValue> {
self.0.get_utc_timestamp(Tag(367))
}
#[doc(alias = "TotQuoteEntries")]
pub fn tot_quote_entries(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(304))
}
#[doc(alias = "NoQuoteEntries")]
pub fn quote_entries(&self) -> Result<Instances<'a, mass_quote::quote_sets::quote_entries::Instance<'a>>, InvalidValue> {
self.0.get_group(&mass_quote::quote_sets::quote_entries::TABLE, &KNOWN_TAGS).map(Instances::from)
}
}
pub mod quote_entries {
use super::super::super::*;
pub const TABLE: GroupTable<'static> = GroupTable::new(
Tag(295),
Tag(299),
&[
Tag(15), Tag(22), Tag(40), Tag(48), Tag(55), Tag(60), Tag(62), Tag(64), Tag(65),
Tag(106), Tag(107), Tag(132), Tag(133), Tag(134), Tag(135), Tag(167), Tag(188),
Tag(189), Tag(190), Tag(191), Tag(192), Tag(193), Tag(200), Tag(201), Tag(202),
Tag(205), Tag(206), Tag(207), Tag(223), Tag(231), Tag(299), Tag(336), Tag(348),
Tag(349), Tag(350), Tag(351),
],
&[],
);
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(15), Tag(22), Tag(40), Tag(48), Tag(55), Tag(60), Tag(62), Tag(64), Tag(65),
Tag(106), Tag(107), Tag(132), Tag(133), Tag(134), Tag(135), Tag(167), Tag(188),
Tag(189), Tag(190), Tag(191), Tag(192), Tag(193), Tag(200), Tag(201), Tag(202),
Tag(205), Tag(206), Tag(207), Tag(223), Tag(231), Tag(299), Tag(336), Tag(348),
Tag(349), Tag(350), Tag(351),
]);
#[derive(Clone, Copy, Debug)]
pub struct Instance<'a>(refix_message::Scope<'a>);
impl<'a> From<refix_message::Scope<'a>> for Instance<'a> {
fn from(scope: refix_message::Scope<'a>) -> Self {
Self(scope)
}
}
impl<'a> Instance<'a> {
pub fn raw(&self) -> refix_message::Scope<'a> {
self.0
}
#[doc(alias = "QuoteEntryID")]
pub fn quote_entry_id(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(299))
}
#[doc(alias = "Symbol")]
pub fn symbol(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(55))
}
#[doc(alias = "SymbolSfx")]
pub fn symbol_sfx(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(65))
}
#[doc(alias = "SecurityID")]
pub fn security_id(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(48))
}
#[doc(alias = "IDSource")]
pub fn id_source(&self) -> Result<Option<IDSource<'a>>, InvalidValue> {
Ok(self.0.get_str(Tag(22))?.map(IDSource::from_value))
}
#[doc(alias = "SecurityType")]
pub fn security_type(&self) -> Result<Option<SecurityType<'a>>, InvalidValue> {
Ok(self.0.get_str(Tag(167))?.map(SecurityType::from_value))
}
#[doc(alias = "MaturityMonthYear")]
pub fn maturity_month_year(&self) -> Result<Option<MonthYear>, InvalidValue> {
self.0.get_month_year(Tag(200))
}
#[doc(alias = "MaturityDay")]
pub fn maturity_day(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(205))
}
#[doc(alias = "PutOrCall")]
pub fn put_or_call(&self) -> Result<Option<PutOrCall>, InvalidValue> {
Ok(self.0.get_int(Tag(201))?.map(PutOrCall::from_value))
}
#[doc(alias = "StrikePrice")]
pub fn strike_price(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(202))
}
#[doc(alias = "OptAttribute")]
pub fn opt_attribute(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(206))
}
#[doc(alias = "ContractMultiplier")]
pub fn contract_multiplier(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(231))
}
#[doc(alias = "CouponRate")]
pub fn coupon_rate(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(223))
}
#[doc(alias = "SecurityExchange")]
pub fn security_exchange(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(207))
}
#[doc(alias = "Issuer")]
pub fn issuer(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(106))
}
#[doc(alias = "EncodedIssuerLen")]
pub fn encoded_issuer_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(348))
}
#[doc(alias = "EncodedIssuer")]
pub fn encoded_issuer(&self) -> Option<&'a [u8]> {
self.0.get(Tag(349))
}
#[doc(alias = "SecurityDesc")]
pub fn security_desc(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(107))
}
#[doc(alias = "EncodedSecurityDescLen")]
pub fn encoded_security_desc_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(350))
}
#[doc(alias = "EncodedSecurityDesc")]
pub fn encoded_security_desc(&self) -> Option<&'a [u8]> {
self.0.get(Tag(351))
}
#[doc(alias = "BidPx")]
pub fn bid_px(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(132))
}
#[doc(alias = "OfferPx")]
pub fn offer_px(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(133))
}
#[doc(alias = "BidSize")]
pub fn bid_size(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(134))
}
#[doc(alias = "OfferSize")]
pub fn offer_size(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(135))
}
#[doc(alias = "ValidUntilTime")]
pub fn valid_until_time(&self) -> Result<Option<UtcTimestamp>, InvalidValue> {
self.0.get_utc_timestamp(Tag(62))
}
#[doc(alias = "BidSpotRate")]
pub fn bid_spot_rate(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(188))
}
#[doc(alias = "OfferSpotRate")]
pub fn offer_spot_rate(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(190))
}
#[doc(alias = "BidForwardPoints")]
pub fn bid_forward_points(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(189))
}
#[doc(alias = "OfferForwardPoints")]
pub fn offer_forward_points(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(191))
}
#[doc(alias = "TransactTime")]
pub fn transact_time(&self) -> Result<Option<UtcTimestamp>, InvalidValue> {
self.0.get_utc_timestamp(Tag(60))
}
#[doc(alias = "TradingSessionID")]
pub fn trading_session_id(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(336))
}
#[doc(alias = "FutSettDate")]
pub fn fut_sett_date(&self) -> Result<Option<Date>, InvalidValue> {
self.0.get_date(Tag(64))
}
#[doc(alias = "OrdType")]
pub fn ord_type(&self) -> Result<Option<OrdType<'a>>, InvalidValue> {
Ok(self.0.get_str(Tag(40))?.map(OrdType::from_value))
}
#[doc(alias = "FutSettDate2")]
pub fn fut_sett_date2(&self) -> Result<Option<Date>, InvalidValue> {
self.0.get_date(Tag(193))
}
#[doc(alias = "OrderQty2")]
pub fn order_qty2(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(192))
}
#[doc(alias = "Currency")]
pub fn currency(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(15))
}
}
}
}
}
pub struct BusinessMessageReject(RawMessage);
impl BusinessMessageReject {
pub const MSG_TYPE: &[u8] = b"j";
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(8), Tag(9), Tag(10), Tag(34), Tag(35), Tag(43), Tag(45), Tag(49), Tag(50), Tag(52),
Tag(56), Tag(57), Tag(58), Tag(89), Tag(90), Tag(91), Tag(93), Tag(97), Tag(115), Tag(116),
Tag(122), Tag(128), Tag(129), Tag(142), Tag(143), Tag(144), Tag(145), Tag(212), Tag(213),
Tag(347), Tag(354), Tag(355), Tag(369), Tag(370), Tag(372), Tag(379), Tag(380),
]);
pub fn from_raw(raw: RawMessage) -> Self {
Self(raw)
}
pub fn raw(&self) -> &RawMessage {
&self.0
}
pub fn header(&self) -> Header<'_> {
Header(self.0.scope())
}
pub fn trailer(&self) -> Trailer<'_> {
Trailer(self.0.scope())
}
#[doc(alias = "RefSeqNum")]
pub fn ref_seq_num(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(45))
}
#[doc(alias = "RefMsgType")]
pub fn ref_msg_type(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(372))
}
#[doc(alias = "BusinessRejectRefID")]
pub fn business_reject_ref_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(379))
}
#[doc(alias = "BusinessRejectReason")]
pub fn business_reject_reason(&self) -> Result<Option<BusinessRejectReason>, InvalidValue> {
Ok(self.0.get_int(Tag(380))?.map(BusinessRejectReason::from_value))
}
#[doc(alias = "Text")]
pub fn text(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(58))
}
#[doc(alias = "EncodedTextLen")]
pub fn encoded_text_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(354))
}
#[doc(alias = "EncodedText")]
pub fn encoded_text(&self) -> Option<&[u8]> {
self.0.get(Tag(355))
}
}
impl std::fmt::Debug for BusinessMessageReject {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "BusinessMessageReject({})", self.0)
}
}
impl std::fmt::Display for BusinessMessageReject {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
std::fmt::Display::fmt(&self.0, f)
}
}
pub struct BidRequest(RawMessage);
impl BidRequest {
pub const MSG_TYPE: &[u8] = b"k";
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(1), Tag(8), Tag(9), Tag(10), Tag(15), Tag(34), Tag(35), Tag(43), Tag(49), Tag(50),
Tag(52), Tag(54), Tag(56), Tag(57), Tag(58), Tag(63), Tag(64), Tag(66), Tag(75), Tag(89),
Tag(90), Tag(91), Tag(93), Tag(97), Tag(115), Tag(116), Tag(121), Tag(122), Tag(128),
Tag(129), Tag(142), Tag(143), Tag(144), Tag(145), Tag(212), Tag(213), Tag(336), Tag(347),
Tag(354), Tag(355), Tag(369), Tag(370), Tag(374), Tag(390), Tag(391), Tag(392), Tag(393),
Tag(394), Tag(395), Tag(396), Tag(397), Tag(398), Tag(399), Tag(400), Tag(401), Tag(402),
Tag(403), Tag(404), Tag(405), Tag(406), Tag(407), Tag(408), Tag(409), Tag(410), Tag(411),
Tag(412), Tag(413), Tag(414), Tag(415), Tag(416), Tag(417), Tag(418), Tag(419), Tag(420),
Tag(430), Tag(441), Tag(443),
]);
pub fn from_raw(raw: RawMessage) -> Self {
Self(raw)
}
pub fn raw(&self) -> &RawMessage {
&self.0
}
pub fn header(&self) -> Header<'_> {
Header(self.0.scope())
}
pub fn trailer(&self) -> Trailer<'_> {
Trailer(self.0.scope())
}
#[doc(alias = "BidID")]
pub fn bid_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(390))
}
#[doc(alias = "ClientBidID")]
pub fn client_bid_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(391))
}
#[doc(alias = "BidRequestTransType")]
pub fn bid_request_trans_type(&self) -> Result<Option<BidRequestTransType<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(374))?.map(BidRequestTransType::from_value))
}
#[doc(alias = "ListName")]
pub fn list_name(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(392))
}
#[doc(alias = "TotalNumSecurities")]
pub fn total_num_securities(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(393))
}
#[doc(alias = "BidType")]
pub fn bid_type(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(394))
}
#[doc(alias = "NumTickets")]
pub fn num_tickets(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(395))
}
#[doc(alias = "Currency")]
pub fn currency(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(15))
}
#[doc(alias = "SideValue1")]
pub fn side_value1(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(396))
}
#[doc(alias = "SideValue2")]
pub fn side_value2(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(397))
}
#[doc(alias = "NoBidDescriptors")]
pub fn bid_descriptors(&self) -> Result<Instances<'_, bid_request::bid_descriptors::Instance<'_>>, InvalidValue> {
self.0.get_group(&bid_request::bid_descriptors::TABLE, &Self::KNOWN_TAGS).map(Instances::from)
}
#[doc(alias = "NoBidComponents")]
pub fn bid_components(&self) -> Result<Instances<'_, bid_request::bid_components::Instance<'_>>, InvalidValue> {
self.0.get_group(&bid_request::bid_components::TABLE, &Self::KNOWN_TAGS).map(Instances::from)
}
#[doc(alias = "LiquidityIndType")]
pub fn liquidity_ind_type(&self) -> Result<Option<LiquidityIndType>, InvalidValue> {
Ok(self.0.get_int(Tag(409))?.map(LiquidityIndType::from_value))
}
#[doc(alias = "WtAverageLiquidity")]
pub fn wt_average_liquidity(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(410))
}
#[doc(alias = "ExchangeForPhysical")]
pub fn exchange_for_physical(&self) -> Result<Option<bool>, InvalidValue> {
self.0.get_bool(Tag(411))
}
#[doc(alias = "OutMainCntryUIndex")]
pub fn out_main_cntry_u_index(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(412))
}
#[doc(alias = "CrossPercent")]
pub fn cross_percent(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(413))
}
#[doc(alias = "ProgRptReqs")]
pub fn prog_rpt_reqs(&self) -> Result<Option<ProgRptReqs>, InvalidValue> {
Ok(self.0.get_int(Tag(414))?.map(ProgRptReqs::from_value))
}
#[doc(alias = "ProgPeriodInterval")]
pub fn prog_period_interval(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(415))
}
#[doc(alias = "IncTaxInd")]
pub fn inc_tax_ind(&self) -> Result<Option<IncTaxInd>, InvalidValue> {
Ok(self.0.get_int(Tag(416))?.map(IncTaxInd::from_value))
}
#[doc(alias = "ForexReq")]
pub fn forex_req(&self) -> Result<Option<bool>, InvalidValue> {
self.0.get_bool(Tag(121))
}
#[doc(alias = "NumBidders")]
pub fn num_bidders(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(417))
}
#[doc(alias = "TradeDate")]
pub fn trade_date(&self) -> Result<Option<Date>, InvalidValue> {
self.0.get_date(Tag(75))
}
#[doc(alias = "TradeType")]
pub fn trade_type(&self) -> Result<Option<TradeType<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(418))?.map(TradeType::from_value))
}
#[doc(alias = "BasisPxType")]
pub fn basis_px_type(&self) -> Result<Option<BasisPxType<'_>>, InvalidValue> {
Ok(self.0.get_str(Tag(419))?.map(BasisPxType::from_value))
}
#[doc(alias = "StrikeTime")]
pub fn strike_time(&self) -> Result<Option<UtcTimestamp>, InvalidValue> {
self.0.get_utc_timestamp(Tag(443))
}
#[doc(alias = "Text")]
pub fn text(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(58))
}
#[doc(alias = "EncodedTextLen")]
pub fn encoded_text_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(354))
}
#[doc(alias = "EncodedText")]
pub fn encoded_text(&self) -> Option<&[u8]> {
self.0.get(Tag(355))
}
}
impl std::fmt::Debug for BidRequest {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "BidRequest({})", self.0)
}
}
impl std::fmt::Display for BidRequest {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
std::fmt::Display::fmt(&self.0, f)
}
}
pub mod bid_request {
pub mod bid_descriptors {
use super::super::*;
pub const TABLE: GroupTable<'static> = GroupTable::new(
Tag(398),
Tag(399),
&[
Tag(399), Tag(400), Tag(401), Tag(402), Tag(403), Tag(404), Tag(405), Tag(406),
Tag(407), Tag(408), Tag(441),
],
&[],
);
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(399), Tag(400), Tag(401), Tag(402), Tag(403), Tag(404), Tag(405), Tag(406),
Tag(407), Tag(408), Tag(441),
]);
#[derive(Clone, Copy, Debug)]
pub struct Instance<'a>(refix_message::Scope<'a>);
impl<'a> From<refix_message::Scope<'a>> for Instance<'a> {
fn from(scope: refix_message::Scope<'a>) -> Self {
Self(scope)
}
}
impl<'a> Instance<'a> {
pub fn raw(&self) -> refix_message::Scope<'a> {
self.0
}
#[doc(alias = "BidDescriptorType")]
pub fn bid_descriptor_type(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(399))
}
#[doc(alias = "BidDescriptor")]
pub fn bid_descriptor(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(400))
}
#[doc(alias = "SideValueInd")]
pub fn side_value_ind(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(401))
}
#[doc(alias = "LiquidityValue")]
pub fn liquidity_value(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(404))
}
#[doc(alias = "LiquidityNumSecurities")]
pub fn liquidity_num_securities(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(441))
}
#[doc(alias = "LiquidityPctLow")]
pub fn liquidity_pct_low(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(402))
}
#[doc(alias = "LiquidityPctHigh")]
pub fn liquidity_pct_high(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(403))
}
#[doc(alias = "EFPTrackingError")]
pub fn efp_tracking_error(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(405))
}
#[doc(alias = "FairValue")]
pub fn fair_value(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(406))
}
#[doc(alias = "OutsideIndexPct")]
pub fn outside_index_pct(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(407))
}
#[doc(alias = "ValueOfFutures")]
pub fn value_of_futures(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(408))
}
}
}
pub mod bid_components {
use super::super::*;
pub const TABLE: GroupTable<'static> = GroupTable::new(
Tag(420),
Tag(66),
&[Tag(1), Tag(54), Tag(63), Tag(64), Tag(66), Tag(336), Tag(430)],
&[],
);
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(1), Tag(54), Tag(63), Tag(64), Tag(66), Tag(336), Tag(430),
]);
#[derive(Clone, Copy, Debug)]
pub struct Instance<'a>(refix_message::Scope<'a>);
impl<'a> From<refix_message::Scope<'a>> for Instance<'a> {
fn from(scope: refix_message::Scope<'a>) -> Self {
Self(scope)
}
}
impl<'a> Instance<'a> {
pub fn raw(&self) -> refix_message::Scope<'a> {
self.0
}
#[doc(alias = "ListID")]
pub fn list_id(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(66))
}
#[doc(alias = "Side")]
pub fn side(&self) -> Result<Option<Side<'a>>, InvalidValue> {
Ok(self.0.get_str(Tag(54))?.map(Side::from_value))
}
#[doc(alias = "TradingSessionID")]
pub fn trading_session_id(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(336))
}
#[doc(alias = "NetGrossInd")]
pub fn net_gross_ind(&self) -> Result<Option<NetGrossInd>, InvalidValue> {
Ok(self.0.get_int(Tag(430))?.map(NetGrossInd::from_value))
}
#[doc(alias = "SettlmntTyp")]
pub fn settlmnt_typ(&self) -> Result<Option<SettlmntTyp<'a>>, InvalidValue> {
Ok(self.0.get_str(Tag(63))?.map(SettlmntTyp::from_value))
}
#[doc(alias = "FutSettDate")]
pub fn fut_sett_date(&self) -> Result<Option<Date>, InvalidValue> {
self.0.get_date(Tag(64))
}
#[doc(alias = "Account")]
pub fn account(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(1))
}
}
}
}
pub struct BidResponse(RawMessage);
impl BidResponse {
pub const MSG_TYPE: &[u8] = b"l";
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(8), Tag(9), Tag(10), Tag(12), Tag(13), Tag(34), Tag(35), Tag(43), Tag(44), Tag(49),
Tag(50), Tag(52), Tag(54), Tag(56), Tag(57), Tag(58), Tag(63), Tag(64), Tag(66), Tag(89),
Tag(90), Tag(91), Tag(93), Tag(97), Tag(115), Tag(116), Tag(122), Tag(128), Tag(129),
Tag(142), Tag(143), Tag(144), Tag(145), Tag(212), Tag(213), Tag(336), Tag(347), Tag(354),
Tag(355), Tag(369), Tag(370), Tag(390), Tag(391), Tag(406), Tag(420), Tag(421), Tag(423),
Tag(430),
]);
pub fn from_raw(raw: RawMessage) -> Self {
Self(raw)
}
pub fn raw(&self) -> &RawMessage {
&self.0
}
pub fn header(&self) -> Header<'_> {
Header(self.0.scope())
}
pub fn trailer(&self) -> Trailer<'_> {
Trailer(self.0.scope())
}
#[doc(alias = "BidID")]
pub fn bid_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(390))
}
#[doc(alias = "ClientBidID")]
pub fn client_bid_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(391))
}
#[doc(alias = "NoBidComponents")]
pub fn bid_components(&self) -> Result<Instances<'_, bid_response::bid_components::Instance<'_>>, InvalidValue> {
self.0.get_group(&bid_response::bid_components::TABLE, &Self::KNOWN_TAGS).map(Instances::from)
}
}
impl std::fmt::Debug for BidResponse {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "BidResponse({})", self.0)
}
}
impl std::fmt::Display for BidResponse {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
std::fmt::Display::fmt(&self.0, f)
}
}
pub mod bid_response {
pub mod bid_components {
use super::super::*;
pub const TABLE: GroupTable<'static> = GroupTable::new(
Tag(420),
Tag(12),
&[
Tag(12), Tag(13), Tag(44), Tag(54), Tag(58), Tag(63), Tag(64), Tag(66), Tag(336),
Tag(354), Tag(355), Tag(406), Tag(421), Tag(423), Tag(430),
],
&[],
);
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(12), Tag(13), Tag(44), Tag(54), Tag(58), Tag(63), Tag(64), Tag(66), Tag(336),
Tag(354), Tag(355), Tag(406), Tag(421), Tag(423), Tag(430),
]);
#[derive(Clone, Copy, Debug)]
pub struct Instance<'a>(refix_message::Scope<'a>);
impl<'a> From<refix_message::Scope<'a>> for Instance<'a> {
fn from(scope: refix_message::Scope<'a>) -> Self {
Self(scope)
}
}
impl<'a> Instance<'a> {
pub fn raw(&self) -> refix_message::Scope<'a> {
self.0
}
#[doc(alias = "Commission")]
pub fn commission(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(12))
}
#[doc(alias = "CommType")]
pub fn comm_type(&self) -> Result<Option<CommType<'a>>, InvalidValue> {
Ok(self.0.get_str(Tag(13))?.map(CommType::from_value))
}
#[doc(alias = "ListID")]
pub fn list_id(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(66))
}
#[doc(alias = "Country")]
pub fn country(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(421))
}
#[doc(alias = "Side")]
pub fn side(&self) -> Result<Option<Side<'a>>, InvalidValue> {
Ok(self.0.get_str(Tag(54))?.map(Side::from_value))
}
#[doc(alias = "Price")]
pub fn price(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(44))
}
#[doc(alias = "PriceType")]
pub fn price_type(&self) -> Result<Option<PriceType>, InvalidValue> {
Ok(self.0.get_int(Tag(423))?.map(PriceType::from_value))
}
#[doc(alias = "FairValue")]
pub fn fair_value(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(406))
}
#[doc(alias = "NetGrossInd")]
pub fn net_gross_ind(&self) -> Result<Option<NetGrossInd>, InvalidValue> {
Ok(self.0.get_int(Tag(430))?.map(NetGrossInd::from_value))
}
#[doc(alias = "SettlmntTyp")]
pub fn settlmnt_typ(&self) -> Result<Option<SettlmntTyp<'a>>, InvalidValue> {
Ok(self.0.get_str(Tag(63))?.map(SettlmntTyp::from_value))
}
#[doc(alias = "FutSettDate")]
pub fn fut_sett_date(&self) -> Result<Option<Date>, InvalidValue> {
self.0.get_date(Tag(64))
}
#[doc(alias = "TradingSessionID")]
pub fn trading_session_id(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(336))
}
#[doc(alias = "Text")]
pub fn text(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(58))
}
#[doc(alias = "EncodedTextLen")]
pub fn encoded_text_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(354))
}
#[doc(alias = "EncodedText")]
pub fn encoded_text(&self) -> Option<&'a [u8]> {
self.0.get(Tag(355))
}
}
}
}
pub struct ListStrikePrice(RawMessage);
impl ListStrikePrice {
pub const MSG_TYPE: &[u8] = b"m";
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(8), Tag(9), Tag(10), Tag(11), Tag(15), Tag(22), Tag(34), Tag(35), Tag(43), Tag(44),
Tag(48), Tag(49), Tag(50), Tag(52), Tag(54), Tag(55), Tag(56), Tag(57), Tag(58), Tag(65),
Tag(66), Tag(89), Tag(90), Tag(91), Tag(93), Tag(97), Tag(106), Tag(107), Tag(115),
Tag(116), Tag(122), Tag(128), Tag(129), Tag(140), Tag(142), Tag(143), Tag(144), Tag(145),
Tag(167), Tag(200), Tag(201), Tag(202), Tag(205), Tag(206), Tag(207), Tag(212), Tag(213),
Tag(223), Tag(231), Tag(347), Tag(348), Tag(349), Tag(350), Tag(351), Tag(354), Tag(355),
Tag(369), Tag(370), Tag(422), Tag(428),
]);
pub fn from_raw(raw: RawMessage) -> Self {
Self(raw)
}
pub fn raw(&self) -> &RawMessage {
&self.0
}
pub fn header(&self) -> Header<'_> {
Header(self.0.scope())
}
pub fn trailer(&self) -> Trailer<'_> {
Trailer(self.0.scope())
}
#[doc(alias = "ListID")]
pub fn list_id(&self) -> Result<Option<&str>, InvalidValue> {
self.0.get_str(Tag(66))
}
#[doc(alias = "TotNoStrikes")]
pub fn tot_no_strikes(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(422))
}
#[doc(alias = "NoStrikes")]
pub fn strikes(&self) -> Result<Instances<'_, list_strike_price::strikes::Instance<'_>>, InvalidValue> {
self.0.get_group(&list_strike_price::strikes::TABLE, &Self::KNOWN_TAGS).map(Instances::from)
}
}
impl std::fmt::Debug for ListStrikePrice {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "ListStrikePrice({})", self.0)
}
}
impl std::fmt::Display for ListStrikePrice {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
std::fmt::Display::fmt(&self.0, f)
}
}
pub mod list_strike_price {
pub mod strikes {
use super::super::*;
pub const TABLE: GroupTable<'static> = GroupTable::new(
Tag(428),
Tag(55),
&[
Tag(11), Tag(15), Tag(22), Tag(44), Tag(48), Tag(54), Tag(55), Tag(58), Tag(65),
Tag(106), Tag(107), Tag(140), Tag(167), Tag(200), Tag(201), Tag(202), Tag(205),
Tag(206), Tag(207), Tag(223), Tag(231), Tag(348), Tag(349), Tag(350), Tag(351),
Tag(354), Tag(355),
],
&[],
);
pub const KNOWN_TAGS: KnownTags<'static> = KnownTags::new(&[
Tag(11), Tag(15), Tag(22), Tag(44), Tag(48), Tag(54), Tag(55), Tag(58), Tag(65),
Tag(106), Tag(107), Tag(140), Tag(167), Tag(200), Tag(201), Tag(202), Tag(205),
Tag(206), Tag(207), Tag(223), Tag(231), Tag(348), Tag(349), Tag(350), Tag(351),
Tag(354), Tag(355),
]);
#[derive(Clone, Copy, Debug)]
pub struct Instance<'a>(refix_message::Scope<'a>);
impl<'a> From<refix_message::Scope<'a>> for Instance<'a> {
fn from(scope: refix_message::Scope<'a>) -> Self {
Self(scope)
}
}
impl<'a> Instance<'a> {
pub fn raw(&self) -> refix_message::Scope<'a> {
self.0
}
#[doc(alias = "Symbol")]
pub fn symbol(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(55))
}
#[doc(alias = "SymbolSfx")]
pub fn symbol_sfx(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(65))
}
#[doc(alias = "SecurityID")]
pub fn security_id(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(48))
}
#[doc(alias = "IDSource")]
pub fn id_source(&self) -> Result<Option<IDSource<'a>>, InvalidValue> {
Ok(self.0.get_str(Tag(22))?.map(IDSource::from_value))
}
#[doc(alias = "SecurityType")]
pub fn security_type(&self) -> Result<Option<SecurityType<'a>>, InvalidValue> {
Ok(self.0.get_str(Tag(167))?.map(SecurityType::from_value))
}
#[doc(alias = "MaturityMonthYear")]
pub fn maturity_month_year(&self) -> Result<Option<MonthYear>, InvalidValue> {
self.0.get_month_year(Tag(200))
}
#[doc(alias = "MaturityDay")]
pub fn maturity_day(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(205))
}
#[doc(alias = "PutOrCall")]
pub fn put_or_call(&self) -> Result<Option<PutOrCall>, InvalidValue> {
Ok(self.0.get_int(Tag(201))?.map(PutOrCall::from_value))
}
#[doc(alias = "StrikePrice")]
pub fn strike_price(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(202))
}
#[doc(alias = "OptAttribute")]
pub fn opt_attribute(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(206))
}
#[doc(alias = "ContractMultiplier")]
pub fn contract_multiplier(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(231))
}
#[doc(alias = "CouponRate")]
pub fn coupon_rate(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(223))
}
#[doc(alias = "SecurityExchange")]
pub fn security_exchange(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(207))
}
#[doc(alias = "Issuer")]
pub fn issuer(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(106))
}
#[doc(alias = "EncodedIssuerLen")]
pub fn encoded_issuer_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(348))
}
#[doc(alias = "EncodedIssuer")]
pub fn encoded_issuer(&self) -> Option<&'a [u8]> {
self.0.get(Tag(349))
}
#[doc(alias = "SecurityDesc")]
pub fn security_desc(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(107))
}
#[doc(alias = "EncodedSecurityDescLen")]
pub fn encoded_security_desc_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(350))
}
#[doc(alias = "EncodedSecurityDesc")]
pub fn encoded_security_desc(&self) -> Option<&'a [u8]> {
self.0.get(Tag(351))
}
#[doc(alias = "PrevClosePx")]
pub fn prev_close_px(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(140))
}
#[doc(alias = "ClOrdID")]
pub fn cl_ord_id(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(11))
}
#[doc(alias = "Side")]
pub fn side(&self) -> Result<Option<Side<'a>>, InvalidValue> {
Ok(self.0.get_str(Tag(54))?.map(Side::from_value))
}
#[doc(alias = "Price")]
pub fn price(&self) -> Result<Option<Decimal>, InvalidValue> {
self.0.get_decimal(Tag(44))
}
#[doc(alias = "Currency")]
pub fn currency(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(15))
}
#[doc(alias = "Text")]
pub fn text(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(58))
}
#[doc(alias = "EncodedTextLen")]
pub fn encoded_text_len(&self) -> Result<Option<i64>, InvalidValue> {
self.0.get_int(Tag(354))
}
#[doc(alias = "EncodedText")]
pub fn encoded_text(&self) -> Option<&'a [u8]> {
self.0.get(Tag(355))
}
}
}
}
pub enum Message {
Heartbeat(Heartbeat),
TestRequest(TestRequest),
ResendRequest(ResendRequest),
Reject(Reject),
SequenceReset(SequenceReset),
Logout(Logout),
IOI(IOI),
Advertisement(Advertisement),
ExecutionReport(ExecutionReport),
OrderCancelReject(OrderCancelReject),
Logon(Logon),
News(News),
Email(Email),
NewOrderSingle(NewOrderSingle),
NewOrderList(NewOrderList),
OrderCancelRequest(OrderCancelRequest),
OrderCancelReplaceRequest(OrderCancelReplaceRequest),
OrderStatusRequest(OrderStatusRequest),
Allocation(Allocation),
ListCancelRequest(ListCancelRequest),
ListExecute(ListExecute),
ListStatusRequest(ListStatusRequest),
ListStatus(ListStatus),
AllocationInstructionAck(AllocationInstructionAck),
DontKnowTrade(DontKnowTrade),
QuoteRequest(QuoteRequest),
Quote(Quote),
SettlementInstructions(SettlementInstructions),
MarketDataRequest(MarketDataRequest),
MarketDataSnapshotFullRefresh(MarketDataSnapshotFullRefresh),
MarketDataIncrementalRefresh(MarketDataIncrementalRefresh),
MarketDataRequestReject(MarketDataRequestReject),
QuoteCancel(QuoteCancel),
QuoteStatusRequest(QuoteStatusRequest),
QuoteAcknowledgement(QuoteAcknowledgement),
SecurityDefinitionRequest(SecurityDefinitionRequest),
SecurityDefinition(SecurityDefinition),
SecurityStatusRequest(SecurityStatusRequest),
SecurityStatus(SecurityStatus),
TradingSessionStatusRequest(TradingSessionStatusRequest),
TradingSessionStatus(TradingSessionStatus),
MassQuote(MassQuote),
BusinessMessageReject(BusinessMessageReject),
BidRequest(BidRequest),
BidResponse(BidResponse),
ListStrikePrice(ListStrikePrice),
Unrecognized(RawMessage),
}
impl Message {
pub fn from_raw(raw: RawMessage) -> Self {
match raw.get(Tag(35)) {
Some(Heartbeat::MSG_TYPE) => Self::Heartbeat(Heartbeat::from_raw(raw)),
Some(TestRequest::MSG_TYPE) => Self::TestRequest(TestRequest::from_raw(raw)),
Some(ResendRequest::MSG_TYPE) => Self::ResendRequest(ResendRequest::from_raw(raw)),
Some(Reject::MSG_TYPE) => Self::Reject(Reject::from_raw(raw)),
Some(SequenceReset::MSG_TYPE) => Self::SequenceReset(SequenceReset::from_raw(raw)),
Some(Logout::MSG_TYPE) => Self::Logout(Logout::from_raw(raw)),
Some(IOI::MSG_TYPE) => Self::IOI(IOI::from_raw(raw)),
Some(Advertisement::MSG_TYPE) => Self::Advertisement(Advertisement::from_raw(raw)),
Some(ExecutionReport::MSG_TYPE) => Self::ExecutionReport(ExecutionReport::from_raw(raw)),
Some(OrderCancelReject::MSG_TYPE) => Self::OrderCancelReject(OrderCancelReject::from_raw(raw)),
Some(Logon::MSG_TYPE) => Self::Logon(Logon::from_raw(raw)),
Some(News::MSG_TYPE) => Self::News(News::from_raw(raw)),
Some(Email::MSG_TYPE) => Self::Email(Email::from_raw(raw)),
Some(NewOrderSingle::MSG_TYPE) => Self::NewOrderSingle(NewOrderSingle::from_raw(raw)),
Some(NewOrderList::MSG_TYPE) => Self::NewOrderList(NewOrderList::from_raw(raw)),
Some(OrderCancelRequest::MSG_TYPE) => Self::OrderCancelRequest(OrderCancelRequest::from_raw(raw)),
Some(OrderCancelReplaceRequest::MSG_TYPE) => Self::OrderCancelReplaceRequest(OrderCancelReplaceRequest::from_raw(raw)),
Some(OrderStatusRequest::MSG_TYPE) => Self::OrderStatusRequest(OrderStatusRequest::from_raw(raw)),
Some(Allocation::MSG_TYPE) => Self::Allocation(Allocation::from_raw(raw)),
Some(ListCancelRequest::MSG_TYPE) => Self::ListCancelRequest(ListCancelRequest::from_raw(raw)),
Some(ListExecute::MSG_TYPE) => Self::ListExecute(ListExecute::from_raw(raw)),
Some(ListStatusRequest::MSG_TYPE) => Self::ListStatusRequest(ListStatusRequest::from_raw(raw)),
Some(ListStatus::MSG_TYPE) => Self::ListStatus(ListStatus::from_raw(raw)),
Some(AllocationInstructionAck::MSG_TYPE) => Self::AllocationInstructionAck(AllocationInstructionAck::from_raw(raw)),
Some(DontKnowTrade::MSG_TYPE) => Self::DontKnowTrade(DontKnowTrade::from_raw(raw)),
Some(QuoteRequest::MSG_TYPE) => Self::QuoteRequest(QuoteRequest::from_raw(raw)),
Some(Quote::MSG_TYPE) => Self::Quote(Quote::from_raw(raw)),
Some(SettlementInstructions::MSG_TYPE) => Self::SettlementInstructions(SettlementInstructions::from_raw(raw)),
Some(MarketDataRequest::MSG_TYPE) => Self::MarketDataRequest(MarketDataRequest::from_raw(raw)),
Some(MarketDataSnapshotFullRefresh::MSG_TYPE) => Self::MarketDataSnapshotFullRefresh(MarketDataSnapshotFullRefresh::from_raw(raw)),
Some(MarketDataIncrementalRefresh::MSG_TYPE) => Self::MarketDataIncrementalRefresh(MarketDataIncrementalRefresh::from_raw(raw)),
Some(MarketDataRequestReject::MSG_TYPE) => Self::MarketDataRequestReject(MarketDataRequestReject::from_raw(raw)),
Some(QuoteCancel::MSG_TYPE) => Self::QuoteCancel(QuoteCancel::from_raw(raw)),
Some(QuoteStatusRequest::MSG_TYPE) => Self::QuoteStatusRequest(QuoteStatusRequest::from_raw(raw)),
Some(QuoteAcknowledgement::MSG_TYPE) => Self::QuoteAcknowledgement(QuoteAcknowledgement::from_raw(raw)),
Some(SecurityDefinitionRequest::MSG_TYPE) => Self::SecurityDefinitionRequest(SecurityDefinitionRequest::from_raw(raw)),
Some(SecurityDefinition::MSG_TYPE) => Self::SecurityDefinition(SecurityDefinition::from_raw(raw)),
Some(SecurityStatusRequest::MSG_TYPE) => Self::SecurityStatusRequest(SecurityStatusRequest::from_raw(raw)),
Some(SecurityStatus::MSG_TYPE) => Self::SecurityStatus(SecurityStatus::from_raw(raw)),
Some(TradingSessionStatusRequest::MSG_TYPE) => Self::TradingSessionStatusRequest(TradingSessionStatusRequest::from_raw(raw)),
Some(TradingSessionStatus::MSG_TYPE) => Self::TradingSessionStatus(TradingSessionStatus::from_raw(raw)),
Some(MassQuote::MSG_TYPE) => Self::MassQuote(MassQuote::from_raw(raw)),
Some(BusinessMessageReject::MSG_TYPE) => Self::BusinessMessageReject(BusinessMessageReject::from_raw(raw)),
Some(BidRequest::MSG_TYPE) => Self::BidRequest(BidRequest::from_raw(raw)),
Some(BidResponse::MSG_TYPE) => Self::BidResponse(BidResponse::from_raw(raw)),
Some(ListStrikePrice::MSG_TYPE) => Self::ListStrikePrice(ListStrikePrice::from_raw(raw)),
_ => Self::Unrecognized(raw),
}
}
}
impl std::fmt::Debug for Message {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match self {
Self::Heartbeat(message) => std::fmt::Debug::fmt(message, f),
Self::TestRequest(message) => std::fmt::Debug::fmt(message, f),
Self::ResendRequest(message) => std::fmt::Debug::fmt(message, f),
Self::Reject(message) => std::fmt::Debug::fmt(message, f),
Self::SequenceReset(message) => std::fmt::Debug::fmt(message, f),
Self::Logout(message) => std::fmt::Debug::fmt(message, f),
Self::IOI(message) => std::fmt::Debug::fmt(message, f),
Self::Advertisement(message) => std::fmt::Debug::fmt(message, f),
Self::ExecutionReport(message) => std::fmt::Debug::fmt(message, f),
Self::OrderCancelReject(message) => std::fmt::Debug::fmt(message, f),
Self::Logon(message) => std::fmt::Debug::fmt(message, f),
Self::News(message) => std::fmt::Debug::fmt(message, f),
Self::Email(message) => std::fmt::Debug::fmt(message, f),
Self::NewOrderSingle(message) => std::fmt::Debug::fmt(message, f),
Self::NewOrderList(message) => std::fmt::Debug::fmt(message, f),
Self::OrderCancelRequest(message) => std::fmt::Debug::fmt(message, f),
Self::OrderCancelReplaceRequest(message) => std::fmt::Debug::fmt(message, f),
Self::OrderStatusRequest(message) => std::fmt::Debug::fmt(message, f),
Self::Allocation(message) => std::fmt::Debug::fmt(message, f),
Self::ListCancelRequest(message) => std::fmt::Debug::fmt(message, f),
Self::ListExecute(message) => std::fmt::Debug::fmt(message, f),
Self::ListStatusRequest(message) => std::fmt::Debug::fmt(message, f),
Self::ListStatus(message) => std::fmt::Debug::fmt(message, f),
Self::AllocationInstructionAck(message) => std::fmt::Debug::fmt(message, f),
Self::DontKnowTrade(message) => std::fmt::Debug::fmt(message, f),
Self::QuoteRequest(message) => std::fmt::Debug::fmt(message, f),
Self::Quote(message) => std::fmt::Debug::fmt(message, f),
Self::SettlementInstructions(message) => std::fmt::Debug::fmt(message, f),
Self::MarketDataRequest(message) => std::fmt::Debug::fmt(message, f),
Self::MarketDataSnapshotFullRefresh(message) => std::fmt::Debug::fmt(message, f),
Self::MarketDataIncrementalRefresh(message) => std::fmt::Debug::fmt(message, f),
Self::MarketDataRequestReject(message) => std::fmt::Debug::fmt(message, f),
Self::QuoteCancel(message) => std::fmt::Debug::fmt(message, f),
Self::QuoteStatusRequest(message) => std::fmt::Debug::fmt(message, f),
Self::QuoteAcknowledgement(message) => std::fmt::Debug::fmt(message, f),
Self::SecurityDefinitionRequest(message) => std::fmt::Debug::fmt(message, f),
Self::SecurityDefinition(message) => std::fmt::Debug::fmt(message, f),
Self::SecurityStatusRequest(message) => std::fmt::Debug::fmt(message, f),
Self::SecurityStatus(message) => std::fmt::Debug::fmt(message, f),
Self::TradingSessionStatusRequest(message) => std::fmt::Debug::fmt(message, f),
Self::TradingSessionStatus(message) => std::fmt::Debug::fmt(message, f),
Self::MassQuote(message) => std::fmt::Debug::fmt(message, f),
Self::BusinessMessageReject(message) => std::fmt::Debug::fmt(message, f),
Self::BidRequest(message) => std::fmt::Debug::fmt(message, f),
Self::BidResponse(message) => std::fmt::Debug::fmt(message, f),
Self::ListStrikePrice(message) => std::fmt::Debug::fmt(message, f),
Self::Unrecognized(raw) => write!(f, "Unrecognized({raw})"),
}
}
}
impl std::fmt::Display for Message {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match self {
Self::Heartbeat(message) => std::fmt::Display::fmt(message, f),
Self::TestRequest(message) => std::fmt::Display::fmt(message, f),
Self::ResendRequest(message) => std::fmt::Display::fmt(message, f),
Self::Reject(message) => std::fmt::Display::fmt(message, f),
Self::SequenceReset(message) => std::fmt::Display::fmt(message, f),
Self::Logout(message) => std::fmt::Display::fmt(message, f),
Self::IOI(message) => std::fmt::Display::fmt(message, f),
Self::Advertisement(message) => std::fmt::Display::fmt(message, f),
Self::ExecutionReport(message) => std::fmt::Display::fmt(message, f),
Self::OrderCancelReject(message) => std::fmt::Display::fmt(message, f),
Self::Logon(message) => std::fmt::Display::fmt(message, f),
Self::News(message) => std::fmt::Display::fmt(message, f),
Self::Email(message) => std::fmt::Display::fmt(message, f),
Self::NewOrderSingle(message) => std::fmt::Display::fmt(message, f),
Self::NewOrderList(message) => std::fmt::Display::fmt(message, f),
Self::OrderCancelRequest(message) => std::fmt::Display::fmt(message, f),
Self::OrderCancelReplaceRequest(message) => std::fmt::Display::fmt(message, f),
Self::OrderStatusRequest(message) => std::fmt::Display::fmt(message, f),
Self::Allocation(message) => std::fmt::Display::fmt(message, f),
Self::ListCancelRequest(message) => std::fmt::Display::fmt(message, f),
Self::ListExecute(message) => std::fmt::Display::fmt(message, f),
Self::ListStatusRequest(message) => std::fmt::Display::fmt(message, f),
Self::ListStatus(message) => std::fmt::Display::fmt(message, f),
Self::AllocationInstructionAck(message) => std::fmt::Display::fmt(message, f),
Self::DontKnowTrade(message) => std::fmt::Display::fmt(message, f),
Self::QuoteRequest(message) => std::fmt::Display::fmt(message, f),
Self::Quote(message) => std::fmt::Display::fmt(message, f),
Self::SettlementInstructions(message) => std::fmt::Display::fmt(message, f),
Self::MarketDataRequest(message) => std::fmt::Display::fmt(message, f),
Self::MarketDataSnapshotFullRefresh(message) => std::fmt::Display::fmt(message, f),
Self::MarketDataIncrementalRefresh(message) => std::fmt::Display::fmt(message, f),
Self::MarketDataRequestReject(message) => std::fmt::Display::fmt(message, f),
Self::QuoteCancel(message) => std::fmt::Display::fmt(message, f),
Self::QuoteStatusRequest(message) => std::fmt::Display::fmt(message, f),
Self::QuoteAcknowledgement(message) => std::fmt::Display::fmt(message, f),
Self::SecurityDefinitionRequest(message) => std::fmt::Display::fmt(message, f),
Self::SecurityDefinition(message) => std::fmt::Display::fmt(message, f),
Self::SecurityStatusRequest(message) => std::fmt::Display::fmt(message, f),
Self::SecurityStatus(message) => std::fmt::Display::fmt(message, f),
Self::TradingSessionStatusRequest(message) => std::fmt::Display::fmt(message, f),
Self::TradingSessionStatus(message) => std::fmt::Display::fmt(message, f),
Self::MassQuote(message) => std::fmt::Display::fmt(message, f),
Self::BusinessMessageReject(message) => std::fmt::Display::fmt(message, f),
Self::BidRequest(message) => std::fmt::Display::fmt(message, f),
Self::BidResponse(message) => std::fmt::Display::fmt(message, f),
Self::ListStrikePrice(message) => std::fmt::Display::fmt(message, f),
Self::Unrecognized(raw) => std::fmt::Display::fmt(raw, f),
}
}
}