MistServer  2.5.3-Pro-19-gf5e75b1 ( Generic_64)
Static Public Member Functions | Static Private Member Functions | Static Private Attributes
Base64 Class Reference

Holds base64 decoding and encoding functions. More...

#include <base64.h>

Static Public Member Functions

static std::string decode (std::string const &encoded_string)
 Used to base64 decode data. More...
 
static std::string decode (std::string const &encoded_string)
 
static std::string encode (std::string const input)
 
static std::string encode (std::string const input)
 Used to base64 encode data. More...
 

Static Private Member Functions

static bool is_base64 (unsigned char c)
 Helper for base64_decode function. More...
 
static bool is_base64 (unsigned char c)
 

Static Private Attributes

static const std::string chars = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"
 Needed for base64_encode function. More...
 

Detailed Description

Holds base64 decoding and encoding functions.

Member Function Documentation

std::string Base64::decode ( std::string const &  encoded_string)
static

Used to base64 decode data.

Input is the encoded data as std::string, output is the plaintext data as std::string.

Parameters
encoded_stringBase64 encoded data to decode.
Returns
Plaintext decoded data.
static std::string Base64::decode ( std::string const &  encoded_string)
static
static std::string Base64::encode ( std::string const  input)
static
std::string Base64::encode ( std::string const  input)
static

Used to base64 encode data.

Input is the plaintext as std::string, output is the encoded data as std::string.

Parameters
inputPlaintext data to encode.
Returns
Base64 encoded data.
static bool Base64::is_base64 ( unsigned char  c)
inlinestaticprivate
bool Base64::is_base64 ( unsigned char  c)
inlinestaticprivate

Helper for base64_decode function.

Field Documentation

static const std::string Base64::chars = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"
staticprivate

Needed for base64_encode function.


The documentation for this class was generated from the following files: