Logo ROOT   6.08/07
Reference Guide
TBase64.h
Go to the documentation of this file.
1 // @(#)root/base:$Id$
2 // Author: Gerardo Ganis + Fons Rademakers 15/5/2009
3 
4 /*************************************************************************
5  * Copyright (C) 1995-2009, Rene Brun and Fons Rademakers. *
6  * All rights reserved. *
7  * *
8  * For the licensing terms see $ROOTSYS/LICENSE. *
9  * For the list of contributors see $ROOTSYS/README/CREDITS. *
10  *************************************************************************/
11 
12 #ifndef ROOT_TBase64
13 #define ROOT_TBase64
14 
15 //////////////////////////////////////////////////////////////////////////
16 // //
17 // TBase64 //
18 // //
19 // This code implements the Base64 encoding and decoding. //
20 // Base64 encoded messages are typically used in authentication //
21 // protocols and to pack binary data in HTTP messages. //
22 // //
23 //////////////////////////////////////////////////////////////////////////
24 
25 #ifndef ROOT_Rtypes
26 #include "Rtypes.h"
27 #endif
28 #ifndef ROOT_TString
29 #include "TString.h"
30 #endif
31 
32 
33 class TBase64 {
34 
35 public:
36  virtual ~TBase64() { }
37 
38  static TString Encode(const char *data);
39  static TString Encode(const char *data, Int_t len);
40  static TString Decode(const char *data);
41 
42  ClassDef(TBase64,0) // Base64 encoding/decoding
43 };
44 
45 #endif
This code implements the Base64 encoding and decoding.
Definition: TBase64.h:33
virtual ~TBase64()
Definition: TBase64.h:36
static TString Decode(const char *data)
Decode a base64 string date into a generic TString.
Definition: TBase64.cxx:142
Basic string class.
Definition: TString.h:137
int Int_t
Definition: RtypesCore.h:41
static TString Encode(const char *data)
Transform data into a null terminated base64 string.
Definition: TBase64.cxx:115
#define ClassDef(name, id)
Definition: Rtypes.h:254