Base Framework
Static Public Member Functions | List of all members
Bytes Class Reference

#include <base/security/Bytes.h>

Static Public Member Functions

template<typename TYPE >
static void convertWordsToBytes (uint8 *dest, const TYPE *words, MemorySize size)
 
template<typename TYPE , MemorySize SIZE>
static void convertWordsToBytes (uint8 *dest, const TYPE(&words)[SIZE])
 
template<typename TYPE >
static void convertWordsToBytesBigEndian (uint8 *dest, const TYPE *words, MemorySize size)
 
template<typename TYPE , MemorySize SIZE>
static void convertWordsToBytesBigEndian (uint8 *dest, const TYPE(&words)[SIZE])
 
static String getAsHex (const uint8 *src, MemorySize size)
 
static String getAsBase64 (const uint8 *src, MemorySize size)
 

Detailed Description

Byte helpers.

Member Function Documentation

◆ convertWordsToBytes() [1/2]

template<typename TYPE >
static void Bytes::convertWordsToBytes ( uint8 *  dest,
const TYPE *  words,
MemorySize  size 
)
inlinestatic

Converts words to byte sequence.

◆ convertWordsToBytes() [2/2]

template<typename TYPE , MemorySize SIZE>
static void Bytes::convertWordsToBytes ( uint8 *  dest,
const TYPE(&)  words[SIZE] 
)
inlinestatic

Converts words to byte sequence.

◆ convertWordsToBytesBigEndian() [1/2]

template<typename TYPE >
static void Bytes::convertWordsToBytesBigEndian ( uint8 *  dest,
const TYPE *  words,
MemorySize  size 
)
inlinestatic

Converts words in big endian to byte sequence.

◆ convertWordsToBytesBigEndian() [2/2]

template<typename TYPE , MemorySize SIZE>
static void Bytes::convertWordsToBytesBigEndian ( uint8 *  dest,
const TYPE(&)  words[SIZE] 
)
inlinestatic

Converts words in big endian to byte sequence.

◆ getAsBase64()

static String Bytes::getAsBase64 ( const uint8 *  src,
MemorySize  size 
)
static

Returns bytes as Base64 string.

◆ getAsHex()

static String Bytes::getAsHex ( const uint8 *  src,
MemorySize  size 
)
static

Returns bytes as hex string.