DCL 4.0
Loading...
Searching...
No Matches
TransferEncoding.h
Go to the documentation of this file.
1#ifndef __DCL_TRANSFER_ENCODING_H__
2#define __DCL_TRANSFER_ENCODING_H__ 1
3
4#ifndef __DCL_CONFIG_H__
5#include <dcl/_Config.h>
6#endif
7#ifndef __DCL_STRING_H__
8#include <dcl/String.h>
9#endif
10
11/*
12 References
13 http://www.faqs.org/rfcs/rfc1521.html
14 Multipurpose Internet Mail Extensions
15 (MIME) Part One:
16 Format of Internet Message Bodies
17
18 RFC 2045, 1590, 1522, 1521
19*/
20
21__DCL_BEGIN_NAMESPACE
22
23// 5.1. Quoted-Printable Content-Transfer-Encoding
25{
26public:
27 // convert 8bit string to quoted-printable string
28 static ByteString encode(const ByteString& _str);
29};
30
32{
33public:
34 // convert quoted-printable string to 8bit string
35 static ByteString decode(const ByteString& _str);
36};
37
38// 5.2. Base64 Content-Transfer-Encoding
40{
41public:
42 // binary to base64 string
43 static ByteString encode(const ByteString& _str);
44};
45
47{
48 // base64 string to binary
49 // RETURN s.cstr(), s.length()
50 static ByteString decode(const ByteString& _str);
51};
52
53__DCL_END_NAMESPACE
54
55#endif // __DCL_TRANSFER_ENCODING_H__
#define DCLCAPI
Definition Config.h:100
static ByteString encode(const ByteString &_str)
static ByteString decode(const ByteString &_str)
static ByteString encode(const ByteString &_str)