pub enum WirePosition {
Member,
Element,
Sentinel,
ExtendedMarker,
}Expand description
Where the value being written or read sits.
The byte-layer half of zerodds_ast_layout::WirePosition. It is an
argument to Writer::write_wchar,
crate::reader::Reader::read_wchar and to PidFlagPolicy
rather than a field of any of them, for the reason ParameterRole
is an argument: one stream carries several positions at once, so a
setting made once at construction could not answer for all of them.
Two axes read it, and each reads a different pair of variants:
WcharFraming tells Self::Member from Self::Element, and
PidFlagPolicy tells Self::Member from Self::Sentinel.
Variants§
Member
A member of a structure, a union branch, or the whole value.
For PidFlagPolicy this is a member’s own parameter id in a
PL_CDR1 list.
Element
An element of an array or a sequence.
Sentinel
The PID_LIST_END that closes a PL_CDR1 parameter list.
Read by PidFlagPolicy, which carries the measurement that
makes it a position rather than a property of the list.
ExtendedMarker
The PID_EXTENDED marker that opens a parameter’s extended
header.
Read by PidFlagPolicy. It was a field of
zerodds_ast_layout::PlCdr1HeaderPolicy on the argument that the
marker exists only under the always-extended form; it does not —
a member id above PID_SHORT_MAX_ID reaches it under the
specification’s form too, and RTI sets the bit there.