MDBX Containers
Loading...
Searching...
No Matches
mdbxc::has_from_bytes< T > Struct Template Reference

Trait to check if a type provides a static from_bytes() method. More...

#include <utils.hpp>

Static Public Attributes

static const bool value = decltype(check<T>(0))::value
 

Static Private Member Functions

template<typename U>
static auto check (U *) -> decltype(U::from_bytes((const void *) 0, size_t(0)), std::true_type())
 
template<typename>
static std::false_type check (...)
 

Detailed Description

template<typename T>
struct mdbxc::has_from_bytes< T >

Trait to check if a type provides a static from_bytes() method.

Template Parameters
TType under inspection.

Definition at line 42 of file utils.hpp.

Member Function Documentation

◆ check() [1/2]

template<typename T>
template<typename>
static std::false_type mdbxc::has_from_bytes< T >::check ( ...)
staticprivate

◆ check() [2/2]

template<typename T>
template<typename U>
static auto mdbxc::has_from_bytes< T >::check ( U * ) -> decltype(U::from_bytes((const void *) 0, size_t(0)), std::true_type())
staticprivate

Member Data Documentation

◆ value

template<typename T>
const bool mdbxc::has_from_bytes< T >::value = decltype(check<T>(0))::value
static

Definition at line 49 of file utils.hpp.


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