Expand description
Draft-14 data streams: subgroup streams, fetch streams, datagrams.
Draft-14 carries object data in three wire shapes:
-
Subgroup stream: starts with a Type byte
0x10..=0x1Dwhose bit-flags determine whether a Subgroup ID field is present, whether the subgroup ID is zero or the first Object ID, whether extension headers are present, and whether the stream ends at a group boundary. Object IDs are delta-encoded relative to the previous Object ID in the same stream. -
Fetch stream: Type
0x05, Request ID, then a sequence of self-describing objects until FIN. -
Datagram: Type byte
0x00..=0x07or0x20..=0x21with bit-flags for End of Group, Extensions Present, Object ID Present, and Status vs Payload.
Re-exportsยง
use bytes::Buf;๐use bytes::BufMut;๐use super::types::ObjectStatus;๐use crate::error::CodecError;๐use crate::object_properties::ObjectProperty;๐use crate::object_properties::PropertyValue;๐use crate::varint::VarInt;๐
Structsยง
- Datagram
Object - Datagram carrying a single object.
- Datagram
Type - Datagram type byte.
- Fetch
Gaps - The Prior Group ID Gap and Prior Object ID Gap conditions of draft-14 Section 11.1 and draft-14 Section 11.3 that one fetch stream shows.
- Fetch
Header - Fetch stream header: the type byte
0x05followed by the Request ID. - Fetch
Object - One object carried on a fetch stream.
- Fetch
Object Meta - The framing of one fetch object, without its payload.
- Prior
Gaps - The Prior Group ID Gap and Prior Object ID Gap one Object carries.
- Subgroup
Header - Subgroup stream header.
- Subgroup
Object - One object within a subgroup stream, with the Object ID already resolved from its delta encoding.
- Subgroup
Object Meta - The framing of one subgroup object, without its payload.
- Subgroup
Object Reader - Stateful reader for the object fields on a subgroup stream.
- Subgroup
Stream Type - Subgroup stream type byte.
Enumsยง
- Payload
Permission - Whether an object carrying a given status may hold a non-empty payload.
Constantsยง
- FETCH_
STREAM_ TYPE - Draft-14 fetch stream type byte.
- PRIOR_
GROUP_ ID_ GAP - Prior Group ID Gap, Extension Header Type 0x3C (Section 11.1).
- PRIOR_
OBJECT_ ID_ GAP - Prior Object ID Gap, Extension Header Type 0x3E (Section 11.3).
Functionsยง
- check_
extensions_ ๐against_ status - Hold an object to the rule binding extension headers to Object Status.
- collect_
gaps ๐ - skip ๐
- Advance
bufpastlenbytes without copying them. - stream_
type_ ๐error - Which failure a leading unidirectional stream type that is not the one a reader wants is.