Aleph-w 3.0
A C++ Library for Data Structures and Algorithms
Loading...
Searching...
No Matches
Aleph::detail::Paged_Value_Codec< T > Struct Template Reference

#include <tpl_paged_value_codec.H>

Collaboration diagram for Aleph::detail::Paged_Value_Codec< T >:
[legend]

Public Types

using unsigned_type = std::make_unsigned_t< T >
 
using underlying_type = std::underlying_type_t< T >
 
using underlying_codec = Paged_Value_Codec< underlying_type >
 
using unsigned_type = std::conditional_t< sizeof(T)==4, std::uint32_t, std::uint64_t >
 

Static Public Member Functions

static void encode (const T value, unsigned char *out) noexcept
 
static T decode (const unsigned char *in) noexcept
 
static std::uint32_t add_to_crc (const std::uint32_t crc, const T value) noexcept
 
static void encode (const T value, unsigned char *out) noexcept
 
static T decode (const unsigned char *in) noexcept
 
static std::uint32_t add_to_crc (const std::uint32_t crc, const T value) noexcept
 
static void encode (const T value, unsigned char *out) noexcept
 
static T decode (const unsigned char *in) noexcept
 
static std::uint32_t add_to_crc (const std::uint32_t crc, const T value) noexcept
 
static void encode (const T value, unsigned char *out) noexcept
 
static T decode (const unsigned char *in) noexcept
 
static std::uint32_t add_to_crc (const std::uint32_t crc, const T value) noexcept
 

Static Public Attributes

static constexpr std::uint32_t storage_id
 
static constexpr size_t encoded_size = 1
 

Detailed Description

template<typename T>
requires (std::is_integral_v<T> and sizeof(T) == 1)
struct Aleph::detail::Paged_Value_Codec< T >

Definition at line 105 of file tpl_paged_value_codec.H.

Member Typedef Documentation

◆ underlying_codec

Definition at line 175 of file tpl_paged_value_codec.H.

◆ underlying_type

template<typename T >
using Aleph::detail::Paged_Value_Codec< T >::underlying_type = std::underlying_type_t<T>

Definition at line 174 of file tpl_paged_value_codec.H.

◆ unsigned_type [1/2]

template<typename T >
using Aleph::detail::Paged_Value_Codec< T >::unsigned_type = std::make_unsigned_t<T>

Definition at line 138 of file tpl_paged_value_codec.H.

◆ unsigned_type [2/2]

template<typename T >
using Aleph::detail::Paged_Value_Codec< T >::unsigned_type = std::conditional_t<sizeof(T) == 4, std::uint32_t, std::uint64_t>

Definition at line 205 of file tpl_paged_value_codec.H.

Member Function Documentation

◆ add_to_crc() [1/4]

template<typename T >
static std::uint32_t Aleph::detail::Paged_Value_Codec< T >::add_to_crc ( const std::uint32_t  crc,
const T  value 
)
inlinestaticnoexcept

◆ add_to_crc() [2/4]

template<typename T >
static std::uint32_t Aleph::detail::Paged_Value_Codec< T >::add_to_crc ( const std::uint32_t  crc,
const T  value 
)
inlinestaticnoexcept

◆ add_to_crc() [3/4]

template<typename T >
static std::uint32_t Aleph::detail::Paged_Value_Codec< T >::add_to_crc ( const std::uint32_t  crc,
const T  value 
)
inlinestaticnoexcept

Definition at line 191 of file tpl_paged_value_codec.H.

References Aleph::divide_and_conquer_partition_dp().

◆ add_to_crc() [4/4]

template<typename T >
static std::uint32_t Aleph::detail::Paged_Value_Codec< T >::add_to_crc ( const std::uint32_t  crc,
const T  value 
)
inlinestaticnoexcept

◆ decode() [1/4]

template<typename T >
static T Aleph::detail::Paged_Value_Codec< T >::decode ( const unsigned char in)
inlinestaticnoexcept

Definition at line 116 of file tpl_paged_value_codec.H.

References Aleph::divide_and_conquer_partition_dp().

◆ decode() [2/4]

template<typename T >
static T Aleph::detail::Paged_Value_Codec< T >::decode ( const unsigned char in)
inlinestaticnoexcept

Definition at line 152 of file tpl_paged_value_codec.H.

References Aleph::divide_and_conquer_partition_dp().

◆ decode() [3/4]

template<typename T >
static T Aleph::detail::Paged_Value_Codec< T >::decode ( const unsigned char in)
inlinestaticnoexcept

Definition at line 186 of file tpl_paged_value_codec.H.

References Aleph::divide_and_conquer_partition_dp().

◆ decode() [4/4]

template<typename T >
static T Aleph::detail::Paged_Value_Codec< T >::decode ( const unsigned char in)
inlinestaticnoexcept

Definition at line 218 of file tpl_paged_value_codec.H.

References Aleph::divide_and_conquer_partition_dp().

◆ encode() [1/4]

template<typename T >
static void Aleph::detail::Paged_Value_Codec< T >::encode ( const T  value,
unsigned char out 
)
inlinestaticnoexcept

Definition at line 111 of file tpl_paged_value_codec.H.

References Aleph::divide_and_conquer_partition_dp().

◆ encode() [2/4]

template<typename T >
static void Aleph::detail::Paged_Value_Codec< T >::encode ( const T  value,
unsigned char out 
)
inlinestaticnoexcept

◆ encode() [3/4]

template<typename T >
static void Aleph::detail::Paged_Value_Codec< T >::encode ( const T  value,
unsigned char out 
)
inlinestaticnoexcept

Definition at line 181 of file tpl_paged_value_codec.H.

References Aleph::divide_and_conquer_partition_dp().

◆ encode() [4/4]

template<typename T >
static void Aleph::detail::Paged_Value_Codec< T >::encode ( const T  value,
unsigned char out 
)
inlinestaticnoexcept

Member Data Documentation

◆ encoded_size

template<typename T >
static constexpr size_t Aleph::detail::Paged_Value_Codec< T >::encoded_size = 1
staticconstexpr

Definition at line 109 of file tpl_paged_value_codec.H.

◆ storage_id

template<typename T >
static constexpr std::uint32_t Aleph::detail::Paged_Value_Codec< T >::storage_id
staticconstexpr
Initial value:
=
0x11000000u | (std::is_signed_v<T> ? 1u : 0u)

Definition at line 107 of file tpl_paged_value_codec.H.


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