#![cfg_attr(rustfmt, rustfmt::skip)]
use refix_message::{GroupTable, InvalidValue, LazyKnownTags, Tag};
#[derive(Clone, Copy)]
pub struct LegStipulations<'a>(refix_message::Scope<'a>);
impl<'a> From<refix_message::Scope<'a>> for LegStipulations<'a> {
fn from(scope: refix_message::Scope<'a>) -> Self {
Self(scope)
}
}
impl<'a> LegStipulations<'a> {
pub(in super::super) const TABLE: GroupTable<'static> = GroupTable::new(
Tag(683),
Tag(688),
&[Tag(688), Tag(689)],
&[],
);
pub(in super::super) const fn known_tags() -> &'static LazyKnownTags {
static TAGS: LazyKnownTags = LazyKnownTags::new(&[Tag(688), Tag(689)], &[]);
&TAGS
}
pub fn raw(&self) -> refix_message::Scope<'a> {
self.0
}
#[doc(alias = "LegStipulationType")]
pub fn leg_stipulation_type(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(688))
}
#[doc(alias = "LegStipulationValue")]
pub fn leg_stipulation_value(&self) -> Result<Option<&'a str>, InvalidValue> {
self.0.get_str(Tag(689))
}
}
impl std::fmt::Debug for LegStipulations<'_> {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "LegStipulations({})", self.0)
}
}