rasdaman complete source
hexcodec.hh
Go to the documentation of this file.
1 /*
2  * This file is part of rasdaman community.
3  *
4  * Rasdaman community is free software: you can redistribute it and/or modify
5  * it under the terms of the GNU General Public License as published by
6  * the Free Software Foundation, either version 3 of the License, or
7  * (at your option) any later version.
8  *
9  * Rasdaman community is distributed in the hope that it will be useful,
10  * but WITHOUT ANY WARRANTY; without even the implied warranty of
11  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12  * GNU General Public License for more details.
13  *
14  * You should have received a copy of the GNU General Public License
15  * along with rasdaman community. If not, see <http://www.gnu.org/licenses/>.
16  *
17  * Copyright 2003 - 2011 Peter Baumann / rasdaman GmbH.
18  *
19  * For more information please see <http://www.rasdaman.org>
20  * or contact Peter Baumann via <baumann@rasdaman.com>.
21  */
22 
23 #ifndef __HEXCODEC_HH__
24 #define __HEXCODEC_HH__
25 
26 #include <string>
27 #include <iosfwd>
28 
29 using std::string;
30 using std::ostream;
31 
32 #include "mymalloc/mymalloc.h"
33 #include "import_error.hh"
34 
35 class HexCodec
36 {
37 public:
38  static string convertTo(const string& figureStr) throw(ImportError);
39  static string convertFrom(const string& hexaStr) throw(ImportError);
40  void printStatus(ostream& s);
41 
42 private:
43  //class members
44  static char hexVal[16];
45  static const string hexFig;
46  static const string hexId;
47  static const string emptyStr;
48  static const char hexBase;
49  static const char hexPerByte;
50  static string hexStr;
51  static string figStr;
52 
53 };
54 
55 #endif
static string convertTo(const string &figureStr)
static string convertFrom(const string &hexaStr)
void printStatus(ostream &s)
Definition: import_error.hh:131
Definition: hexcodec.hh:35