pub struct ObjectMeta {
pub draft: DraftVersion,
pub stream_kind: DataStreamType,
pub track_alias: Option<u64>,
pub group_id: u64,
pub subgroup_id: Option<u64>,
pub object_id: u64,
pub publisher_priority: Option<u8>,
pub index_in_stream: u64,
pub payload_len: u64,
pub status: Option<u64>,
pub end_of_range: Option<AnyFetchEndOfRange>,
}Expand description
A framed object’s identity and framing, without its payload.
Every field is a primitive, so an observer never has to name a
per-draft codec type to key on an object. Produced by
ObjectFramer.
Fields§
§draft: DraftVersionThe draft this stream was parsed as.
stream_kind: DataStreamTypeWhether this object came from a subgroup or a fetch stream.
track_alias: Option<u64>Track alias from the stream header. None on fetch streams, whose
headers carry a request ID instead.
group_id: u64Group ID: from the stream header on subgroup streams, from the object itself on fetch streams.
subgroup_id: Option<u64>Subgroup ID. None when the frame has none to report, which
happens two ways.
On a subgroup stream, when the stream type encodes an implicit subgroup
ID that this draft never resolves — drafts 11 through 23 define a
subgroup ID is the first object’s ID mode that the codec stores as
zero, and reporting that zero would mis-key any matcher.
On a fetch stream, when the frame carried no Subgroup ID at all:
from draft-15 a fetch object may be marked as having been forwarded
over a datagram, which has no subgroup, and an End of Range
indicator names a Location rather than an object. Both cases reach
this crate as has_subgroup_id: false on the codec’s meta, behind
a subgroup ID field that holds a placeholder — the same zero, and
the same mis-keying if it were forwarded.
object_id: u64Absolute Object ID, resolved from delta encoding on drafts 14-23.
publisher_priority: Option<u8>Publisher priority. None when the header set a default-priority
flag and omitted the field (drafts 15+).
index_in_stream: u64Zero-based index of this object within its stream.
payload_len: u64Declared payload length in bytes.
status: Option<u64>Object Status wire code; None when a non-empty payload followed.
end_of_range: Option<AnyFetchEndOfRange>Which indicator this frame is, or None for an object.
Drafts 16-23 let a fetch stream state that a run of Objects was not
serialized instead of sending them, and draft-23 adds End of Group and
End of Track, which say the Object before them ends its Group or the
Track and carry that Object’s Location. These frames arrive through
the same reader call as objects do. They are not objects: they
carry no payload and no content, and one of them standing in a
count of objects is a count that is wrong. An observer that means
“objects” filters on this being None; one that means “frames”
does not.
Always None on a subgroup stream, and on every fetch stream of
drafts 07-15, which have no such frame.