Struct GroupSize16Encoding
pub struct GroupSize16Encoding {
pub block_length: u16,
pub num_in_group: u16,
}Expand description
Re-exported generic varString/group decoders shared across SBE adapters. Compact group header encoding (u16 block length + u16 count).
Fields§
§block_length: u16Encoded block length of each group entry.
num_in_group: u16Number of entries in the group.
Implementations§
§impl GroupSize16Encoding
impl GroupSize16Encoding
pub const ENCODED_LENGTH: usize = 4
pub const ENCODED_LENGTH: usize = 4
Encoded length in bytes.
pub fn decode(buf: &[u8]) -> Result<GroupSize16Encoding, SbeDecodeError>
pub fn decode(buf: &[u8]) -> Result<GroupSize16Encoding, SbeDecodeError>
Decodes a compact group header from buf.
§Errors
Returns BufferTooShort if fewer than 4 bytes are available and
GroupSizeTooLarge when num_in_group exceeds MAX_GROUP_SIZE.
Trait Implementations§
§impl Clone for GroupSize16Encoding
impl Clone for GroupSize16Encoding
§fn clone(&self) -> GroupSize16Encoding
fn clone(&self) -> GroupSize16Encoding
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read more§impl Debug for GroupSize16Encoding
impl Debug for GroupSize16Encoding
§impl PartialEq for GroupSize16Encoding
impl PartialEq for GroupSize16Encoding
impl Copy for GroupSize16Encoding
impl Eq for GroupSize16Encoding
impl StructuralPartialEq for GroupSize16Encoding
Auto Trait Implementations§
impl Freeze for GroupSize16Encoding
impl RefUnwindSafe for GroupSize16Encoding
impl Send for GroupSize16Encoding
impl Sync for GroupSize16Encoding
impl Unpin for GroupSize16Encoding
impl UnsafeUnpin for GroupSize16Encoding
impl UnwindSafe for GroupSize16Encoding
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Checks if this value is equivalent to the given key. Read more
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Checks if this value is equivalent to the given key. Read more
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more