rasdaman complete source
chartype.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, 2004, 2005, 2006, 2007, 2008, 2009 Peter Baumann /
18 rasdaman GmbH.
19 *
20 * For more information please see <http://www.rasdaman.org>
21 * or contact Peter Baumann via <baumann@rasdaman.com>.
22 */
23 // -*-C++-*- (for Emacs)
24 
25 /*************************************************************
26  *
27  *
28  * PURPOSE:
29  * The CharType class represents unsigned char.
30  *
31  *
32  * COMMENTS:
33  *
34  ************************************************************/
35 
36 #ifndef _CHARTYPE_HH_
37 #define _CHARTYPE_HH_
38 
39 #include <iostream>
40 #include "raslib/odmgtypes.hh"
41 #include "uintegraltype.hh"
42 #include "catalogmgr/ops.hh"
43 
44 class OId;
45 
46 //@ManMemo: Module: {\bf relcatalogif}.
47 
48 /*@Doc:
49 
50 CharType is the base type used for unsigned char cell values (e.g.
51 result of comparison operations, see \Ref{Ops}). The value of a Char
52 is stored in one char. CharType is a persistence capable class.
53 */
54 
58 class CharType : public UIntegralType
59 {
60 public:
61  CharType();
62  /*@Doc:
63  default constructor, no initialization needed for CharType.
64  */
65 
66  CharType(const OId& id) throw (r_Error);
67  /*@Doc:
68  */
69 
70  CharType(const CharType& old);
71  /*@Doc:
72  copy constructor.
73  */
74 
75  CharType& operator=(const CharType& old);
76  /*@Doc:
77  assignment operator.
78  */
79 
80  virtual ~CharType();
81  /*@Doc:
82  virtual destructor.
83  */
84 
85  virtual void printCell(ostream& stream, const char* cell) const;
86  /*@Doc:
87  */
88 
89  virtual r_ULong* convertToCULong(const char* cell, r_ULong* value) const;
90  /*@Doc:
91  */
92 
93  virtual char* makeFromCULong(char* cell, const r_ULong* value) const;
94  /*@Doc:
95  */
96 
97  static const char* Name;
98 
99 protected:
100 
101  virtual void readFromDb() throw (r_Error);
102  /*@Doc:
103  initializes the attributes of this type.
104  there is no database activity. this is hard coded.
105  */
106 
107 };
108 
109 #endif
virtual ~CharType()
unsigned int r_ULong
Definition: odmgtypes.hh:114
virtual void readFromDb()
Definition: chartype.hh:58
Definition: error.hh:88
virtual char * makeFromCULong(char *cell, const r_ULong *value) const
virtual r_ULong * convertToCULong(const char *cell, r_ULong *value) const
Definition: oidif.hh:67
Definition: uintegraltype.hh:54
CharType & operator=(const CharType &old)
virtual void printCell(ostream &stream, const char *cell) const
static const char * Name
Definition: chartype.hh:97