DUNE: Uniform Navigational Environment  2016.05.0
DUNE::Algorithms::Base64 Class Reference

Detailed Description

Base64 encoding and decoding as defined by RFC 2045.

Static Public Member Functions

static std::string encode (const std::string &str)
 
static std::string encode (const char *str, size_t len)
 
static std::string encode (const unsigned char *bytes, size_t len)
 
static std::string decode (const std::string &str)
 
static std::string decode (const char *str, size_t len)
 
static std::string decode (const unsigned char *bytes, size_t len)
 

Member Function Documentation

static std::string DUNE::Algorithms::Base64::decode ( const std::string &  str)
inlinestatic

Decode a sequence of bytes in Base64.

Parameters
[in]strsource string.
Returns
Base64 decoded string.

Referenced by decode().

static std::string DUNE::Algorithms::Base64::decode ( const char *  str,
size_t  len 
)
inlinestatic

Decode a sequence of bytes in Base64.

Parameters
[in]strsource string.
[in]lenlength of the string.
Returns
Base64 encoded string.

References decode().

std::string DUNE::Algorithms::Base64::decode ( const unsigned char *  bytes,
size_t  len 
)
static

Decode a sequence of bytes in Base64.

Parameters
[in]bytesunsigned char.
[in]lenlength of the string.
Returns
Base64 encoded string.
static std::string DUNE::Algorithms::Base64::encode ( const std::string &  str)
inlinestatic

Encode a sequence of bytes in Base64.

Parameters
[in]strsource string.
Returns
Base64 encoded string.

Referenced by encode().

static std::string DUNE::Algorithms::Base64::encode ( const char *  str,
size_t  len 
)
inlinestatic

Encode a sequence of bytes in Base64.

Parameters
[in]strsource string.
[in]lenlength of the string.
Returns
Base64 encoded string.

References encode().

std::string DUNE::Algorithms::Base64::encode ( const unsigned char *  bytes,
size_t  len 
)
static

Encode a sequence of bytes in Base64.

Parameters
[in]bytesunsigned char.
[in]lenlength of the string.
Returns
Base64 encoded string.
Collaboration diagram for DUNE::Algorithms::Base64:
Collaboration graph