Samchon Framework for CPP  1.0.0
samchon::library::Base64 Class Reference

Utility class for base64 format's en-decoding. More...

#include <Base64.hpp>

Static Public Member Functions

static auto encode (const ByteArray &) -> std::string
 Encode from binary data to base64-string. More...
 
static auto decode (const std::string &) -> ByteArray
 Decode from base64-string to binary data. More...
 

Detailed Description

Utility class for base64 format's en-decoding.

Base64 supports

  • Encoding from binary data to base64-string
  • Decoding from base64-string to binary data
library_string.png
See also
samchon::library
Author
Jeongho Nam http://samchon.org

Definition at line 25 of file Base64.hpp.

Member Function Documentation

auto Base64::encode ( const ByteArray byteArray) -> std::string
static

Encode from binary data to base64-string.

Encodes a binary data to base64-string

Parameters
byteArraybinary data you want to encode
Returns
A base64-string encoded from binary data

Definition at line 12 of file Base64.cpp.

auto Base64::decode ( const std::string &  str) -> ByteArray
static

Decode from base64-string to binary data.

Decodes a base64 encoded string to binary data

Note
If the encoded string is not whole but a part of the binary data, Base64Decoder will be better
Parameters
strA encoded string representing binary data as base64 format
Returns
A binary data decoded from string

Definition at line 76 of file Base64.cpp.


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