LibQuicR
quicr::messages::StreamHeaderProperties Struct Reference

#include <message_serialisation.h>

Public Member Functions

constexpr StreamHeaderProperties (const std::uint64_t type)
 
constexpr StreamHeaderProperties (const bool extensions, const SubgroupIdType subgroup_id_mode, const bool end_of_group, const bool default_priority, const bool first_object)
 
constexpr std::uint64_t GetType () const
 

Static Public Member Functions

static constexpr bool IsValid (const std::uint64_t type) noexcept
 

Public Attributes

const bool extensions
 Whether every subgroup object carries an extension-block length, possibly zero. More...
 
const SubgroupIdType subgroup_id_mode
 Subgroup-ID omission/serialization mode. More...
 
const bool end_of_group
 Whether this subgroup contains the largest object in its group. More...
 
const bool default_priority
 Whether priority is omitted and inherited from the publisher. More...
 
const bool first_object
 Whether this is the subgroup's original first object rather than a resumed stream. More...
 

Static Public Attributes

static constexpr std::uint8_t kExtensionsBit = 0x01
 Bit indicating extension lengths are present. More...
 
static constexpr std::uint8_t kSubgroupIdMask = 0x06
 Two-bit subgroup-ID mode mask. More...
 
static constexpr std::uint8_t kEndOfGroupBit = 0x08
 Bit indicating end of group. More...
 
static constexpr std::uint8_t kTypeBit = 0x10
 Required subgroup-stream type bit. More...
 
static constexpr std::uint8_t kDefaultPriorityBit = 0x20
 Bit indicating inherited publisher priority. More...
 
static constexpr std::uint8_t kFirstObjectBit = 0x40
 Bit indicating the original first object. More...
 
static constexpr std::uint64_t kAllowedBitsMask
 Mask of all recognized stream-header bits. More...
 

Detailed Description

Describes the properties of a stream header type.

Constructor & Destructor Documentation

◆ StreamHeaderProperties() [1/2]

constexpr quicr::messages::StreamHeaderProperties::StreamHeaderProperties ( const std::uint64_t  type)
inlineexplicitconstexpr

Decodes properties from a wire type.

Parameters
typeWire-format stream-header bitfield.
Exceptions
ProtocolViolationExceptionif reserved bits, the type bit, or subgroup mode are invalid.

◆ StreamHeaderProperties() [2/2]

constexpr quicr::messages::StreamHeaderProperties::StreamHeaderProperties ( const bool  extensions,
const SubgroupIdType  subgroup_id_mode,
const bool  end_of_group,
const bool  default_priority,
const bool  first_object 
)
inlineconstexpr

Constructs properties from fields.

Parameters
extensionsWhether an extension block is present.
subgroup_id_modeSubgroup-ID omission/serialization mode.
end_of_groupWhether this subgroup contains the group's largest object.
default_priorityWhether publisher priority is inherited.
first_objectWhether this is the subgroup's original first object.
Exceptions
ProtocolViolationExceptionif subgroup_id_mode is kReserved.

Member Function Documentation

◆ GetType()

constexpr std::uint64_t quicr::messages::StreamHeaderProperties::GetType ( ) const
inlineconstexpr
Returns
Encoded stream-header type bitfield.

◆ IsValid()

static constexpr bool quicr::messages::StreamHeaderProperties::IsValid ( const std::uint64_t  type)
inlinestaticconstexprnoexcept
Parameters
typeStream-header type bitfield to validate.
Returns
Whether type uses only allowed bits, has the type bit, and has a nonreserved subgroup mode.

Member Data Documentation

◆ default_priority

const bool quicr::messages::StreamHeaderProperties::default_priority

Whether priority is omitted and inherited from the publisher.

◆ end_of_group

const bool quicr::messages::StreamHeaderProperties::end_of_group

Whether this subgroup contains the largest object in its group.

◆ extensions

const bool quicr::messages::StreamHeaderProperties::extensions

Whether every subgroup object carries an extension-block length, possibly zero.

◆ first_object

const bool quicr::messages::StreamHeaderProperties::first_object

Whether this is the subgroup's original first object rather than a resumed stream.

◆ kAllowedBitsMask

constexpr std::uint64_t quicr::messages::StreamHeaderProperties::kAllowedBitsMask
staticconstexpr
Initial value:
=
static constexpr std::uint8_t kExtensionsBit
Bit indicating extension lengths are present.
Definition: message_serialisation.h:130
static constexpr std::uint8_t kSubgroupIdMask
Two-bit subgroup-ID mode mask.
Definition: message_serialisation.h:131
static constexpr std::uint8_t kTypeBit
Required subgroup-stream type bit.
Definition: message_serialisation.h:135
static constexpr std::uint8_t kFirstObjectBit
Bit indicating the original first object.
Definition: message_serialisation.h:137
static constexpr std::uint8_t kEndOfGroupBit
Bit indicating end of group.
Definition: message_serialisation.h:132
static constexpr std::uint8_t kDefaultPriorityBit
Bit indicating inherited publisher priority.
Definition: message_serialisation.h:136

Mask of all recognized stream-header bits.

◆ kDefaultPriorityBit

constexpr std::uint8_t quicr::messages::StreamHeaderProperties::kDefaultPriorityBit = 0x20
staticconstexpr

Bit indicating inherited publisher priority.

◆ kEndOfGroupBit

constexpr std::uint8_t quicr::messages::StreamHeaderProperties::kEndOfGroupBit = 0x08
staticconstexpr

Bit indicating end of group.

◆ kExtensionsBit

constexpr std::uint8_t quicr::messages::StreamHeaderProperties::kExtensionsBit = 0x01
staticconstexpr

Bit indicating extension lengths are present.

◆ kFirstObjectBit

constexpr std::uint8_t quicr::messages::StreamHeaderProperties::kFirstObjectBit = 0x40
staticconstexpr

Bit indicating the original first object.

◆ kSubgroupIdMask

constexpr std::uint8_t quicr::messages::StreamHeaderProperties::kSubgroupIdMask = 0x06
staticconstexpr

Two-bit subgroup-ID mode mask.

◆ kTypeBit

constexpr std::uint8_t quicr::messages::StreamHeaderProperties::kTypeBit = 0x10
staticconstexpr

Required subgroup-stream type bit.

◆ subgroup_id_mode

const SubgroupIdType quicr::messages::StreamHeaderProperties::subgroup_id_mode

Subgroup-ID omission/serialization mode.


The documentation for this struct was generated from the following file: