blob: d039c73fc5313b5b877f6bebf15dabb31c8d0fc3 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
|
#pragma once
#include <Exceptions.h>
namespace Balau {
class Base64 {
public:
static String encode(const uint8_t * data, int len);
static int decode(const String & str_in, uint8_t * data_out);
static const double ratio;
private:
static void encode_block(unsigned char in_tab[3], int len, char out[4]);
static int stri(char);
static int decode_block(char s1, char s2, char s3, char s4, unsigned char * out_tab);
};
};
|