Zserio C++ runtime library  1.1.0
Built for Zserio 2.15.0
zserio::BasicBitBufferArrayTraits< ALLOC > Struct Template Reference

#include <ArrayTraits.h>

Public Types

using ElementType = BasicBitBuffer< ALLOC< uint8_t > >
 
using allocator_type = typename ElementType::allocator_type
 

Static Public Member Functions

static size_t bitSizeOf (size_t, const ElementType &element)
 
static size_t initializeOffsets (size_t bitPosition, const ElementType &element)
 
template<typename RAW_ARRAY >
static void read (RAW_ARRAY &rawArray, BitStreamReader &in, size_t=0)
 
static void write (BitStreamWriter &out, const ElementType &element)
 

Static Public Attributes

static constexpr bool IS_BITSIZEOF_CONSTANT = false
 

Detailed Description

template<template< typename > class ALLOC = std::allocator>
struct zserio::BasicBitBufferArrayTraits< ALLOC >

Array traits for Zserio extern bit buffer type.

Definition at line 1543 of file ArrayTraits.h.

Member Typedef Documentation

◆ allocator_type

template<template< typename > class ALLOC = std::allocator>
using zserio::BasicBitBufferArrayTraits< ALLOC >::allocator_type = typename ElementType::allocator_type

Allocator type.

Definition at line 1549 of file ArrayTraits.h.

◆ ElementType

template<template< typename > class ALLOC = std::allocator>
using zserio::BasicBitBufferArrayTraits< ALLOC >::ElementType = BasicBitBuffer<ALLOC<uint8_t> >

Element type.

Definition at line 1546 of file ArrayTraits.h.

Member Function Documentation

◆ bitSizeOf()

template<template< typename > class ALLOC = std::allocator>
static size_t zserio::BasicBitBufferArrayTraits< ALLOC >::bitSizeOf ( size_t  ,
const ElementType element 
)
inlinestatic

Calculates bit size of the array element.

Parameters
elementElement to use for calculation.
Returns
Bit size of the array element.

Definition at line 1558 of file ArrayTraits.h.

◆ initializeOffsets()

template<template< typename > class ALLOC = std::allocator>
static size_t zserio::BasicBitBufferArrayTraits< ALLOC >::initializeOffsets ( size_t  bitPosition,
const ElementType element 
)
inlinestatic

Initializes indexed offsets of the single array element.

Parameters
bitPositionCurrent bit position.
elementElement to use for calculation.
Returns
Updated bit position which points to the first bit after the array element.

Definition at line 1571 of file ArrayTraits.h.

◆ read()

template<template< typename > class ALLOC = std::allocator>
template<typename RAW_ARRAY >
static void zserio::BasicBitBufferArrayTraits< ALLOC >::read ( RAW_ARRAY &  rawArray,
BitStreamReader in,
size_t  = 0 
)
inlinestatic

Reads the single array element.

Parameters
rawArrayRaw array to use.
inBit stream reader.

Definition at line 1583 of file ArrayTraits.h.

◆ write()

template<template< typename > class ALLOC = std::allocator>
static void zserio::BasicBitBufferArrayTraits< ALLOC >::write ( BitStreamWriter out,
const ElementType element 
)
inlinestatic

Writes the single array element.

Parameters
outBit stream writer to use.
elementElement to write.

Definition at line 1594 of file ArrayTraits.h.

Member Data Documentation

◆ IS_BITSIZEOF_CONSTANT

template<template< typename > class ALLOC = std::allocator>
constexpr bool zserio::BasicBitBufferArrayTraits< ALLOC >::IS_BITSIZEOF_CONSTANT = false
staticconstexpr

Determines whether the bit size of the single element is constant.

Definition at line 1600 of file ArrayTraits.h.


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