|
C++ Utilities 5.37.0
Useful C++ classes and routines such as argument parser, IO and conversion utilities
|
Encapsulates binary conversion functions using the little endian byte order. More...
Functions | |
| CPP_UTILITIES_WARNING_PUSH CPP_UTILITIES_EXPORT constexpr std::int16_t | toInt16 (const char *value) |
| Returns a 16-bit signed integer converted from two bytes at a specified position in a char array. | |
| CPP_UTILITIES_EXPORT constexpr std::uint16_t | toUInt16 (const char *value) |
| Returns a 16-bit unsigned integer converted from two bytes at a specified position in a char array. | |
| CPP_UTILITIES_EXPORT constexpr std::int32_t | toInt32 (const char *value) |
| Returns a 32-bit signed integer converted from four bytes at a specified position in a char array. | |
| CPP_UTILITIES_EXPORT constexpr std::uint32_t | toUInt24 (const char *value) |
| Returns a 32-bit unsigned integer converted from three bytes at a specified position in a char array. | |
| CPP_UTILITIES_EXPORT constexpr std::uint32_t | toUInt32 (const char *value) |
| Returns a 32-bit unsigned integer converted from four bytes at a specified position in a char array. | |
| CPP_UTILITIES_EXPORT constexpr std::int64_t | toInt64 (const char *value) |
| Returns a 64-bit signed integer converted from eight bytes at a specified position in a char array. | |
| CPP_UTILITIES_EXPORT constexpr std::uint64_t | toUInt64 (const char *value) |
| Returns a 64-bit unsigned integer converted from eight bytes at a specified position in a char array. | |
| CPP_UTILITIES_EXPORT float | toFloat32 (const char *value) |
| Returns a 32-bit floating point number converted from four bytes at a specified position in a char array. | |
| CPP_UTILITIES_EXPORT double | toFloat64 (const char *value) |
| Returns a 64-bit floating point number converted from eight bytes at a specified position in a char array. | |
| template<class T, Traits::EnableIf< std::is_integral< T > > * = nullptr> | |
| CPP_UTILITIES_EXPORT T | toInt (const char *value) |
| Returns the specified (unsigned) integer converted from the specified char array. | |
| CPP_UTILITIES_EXPORT void | getBytes24 (std::uint32_t value, char *outputbuffer) |
| Stores the specified 24-bit unsigned integer value at a specified position in a char array. | |
| template<class T, Traits::EnableIf< std::is_integral< T > > * = nullptr> | |
| CPP_UTILITIES_EXPORT void | getBytes (T value, char *outputbuffer) |
| Stores the specified (unsigned) integer value in a char array. | |
| CPP_UTILITIES_EXPORT void | getBytes (float value, char *outputbuffer) |
| Stores the specified 32-bit floating point value at a specified position in a char array. | |
| CPP_UTILITIES_EXPORT void | getBytes (double value, char *outputbuffer) |
| Stores the specified 64-bit floating point value at a specified position in a char array. | |
Encapsulates binary conversion functions using the little endian byte order.
|
inline |
Stores the specified 64-bit floating point value at a specified position in a char array.
Definition at line 206 of file binaryconversion.h.
|
inline |
Stores the specified 32-bit floating point value at a specified position in a char array.
Definition at line 196 of file binaryconversion.h.
|
inline |
Stores the specified (unsigned) integer value in a char array.
Definition at line 185 of file binaryconversion.h.
|
inline |
Stores the specified 24-bit unsigned integer value at a specified position in a char array.
Definition at line 165 of file binaryconversion.h.
|
inline |
Returns a 32-bit floating point number converted from four bytes at a specified position in a char array.
Definition at line 126 of file binaryconversion.h.
|
inline |
Returns a 64-bit floating point number converted from eight bytes at a specified position in a char array.
Definition at line 136 of file binaryconversion.h.
|
inline |
Returns the specified (unsigned) integer converted from the specified char array.
Definition at line 151 of file binaryconversion.h.
|
constexpr |
Returns a 16-bit signed integer converted from two bytes at a specified position in a char array.
Definition at line 22 of file binaryconversion.h.
|
constexpr |
Returns a 32-bit signed integer converted from four bytes at a specified position in a char array.
Definition at line 46 of file binaryconversion.h.
|
constexpr |
Returns a 64-bit signed integer converted from eight bytes at a specified position in a char array.
Definition at line 90 of file binaryconversion.h.
|
constexpr |
Returns a 16-bit unsigned integer converted from two bytes at a specified position in a char array.
Definition at line 34 of file binaryconversion.h.
|
constexpr |
Returns a 32-bit unsigned integer converted from three bytes at a specified position in a char array.
Definition at line 62 of file binaryconversion.h.
|
constexpr |
Returns a 32-bit unsigned integer converted from four bytes at a specified position in a char array.
Definition at line 76 of file binaryconversion.h.
|
constexpr |
Returns a 64-bit unsigned integer converted from eight bytes at a specified position in a char array.
Definition at line 108 of file binaryconversion.h.