base64Data.h
Go to the documentation of this file.
00001 /******************************************************************************
00002 ** Copyright (c) 1992-2010 VT MAK
00003 ** All rights reserved.
00004 ******************************************************************************/
00005 
00008 
00009 #ifndef base64Data_H_
00010 #define base64Data_H_
00011 
00012 #include "lgrUtil.h"
00013 #include <vlutil/vlString.h>
00014 
00015 namespace MAKLogger
00016 {
00021    class DT_DLL_LGRUTIL DtBase64Data
00022    {
00023    public:
00024 
00026       DtBase64Data();
00027 
00030       DtBase64Data(const DtString& base64String);
00031 
00034       DtBase64Data(char* data,size_t len);
00035 
00037       DtBase64Data(const DtBase64Data& rhs);
00038 
00040       DtBase64Data& operator=(const DtBase64Data& rhs);
00041 
00043       virtual ~DtBase64Data();
00044 
00046       virtual DtString base64Data() const;
00047 
00049 
00050       virtual char* binaryData(size_t& len);
00051       virtual const char* binaryData(size_t& len) const;
00053 
00055       static DtString encode(char* data,size_t len);
00056 
00059       static char* decode(const DtString&,size_t& len);
00060 
00061    protected:
00062 
00064       static char valueToBase64(unsigned char value);
00066       static int base64ToValue(char c);
00067 
00068       char* myData;
00069       size_t mySize;
00070       //DtString myBase64Data;
00071 
00072    };
00073 }
00074 
00075 #endif

Document ID: Generated on Tue Oct 11 19:41:03 EDT 2011 from SVN revision 107422
Copyright © 2005-2011 VT MÄK Inc. All Rights Reserved (www.mak.com)