rasdaman complete source
uintegraltype.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 /*************************************************************
24  *
25  *
26  * PURPOSE:
27  * The UIntegralType class is the superclass for all unsigned
28  * integral types (Char, Short, Long) describing the type of a
29  * cell
30  *
31  *
32  * COMMENTS:
33  *
34  ************************************************************/
35 
36 #ifndef _UINTEGRALTYPE_HH_
37 #define _UINTEGRALTYPE_HH_
38 
39 #include "atomictype.hh"
40 
41 //@ManMemo: Module: {\bf relcatalogif}.
42 
43 /*@Doc:
44 UIntegralType is the abstract base class for all integral
45 \Ref{BaseType} subclasses, i.e. base types like \Ref{ULongType} or
46 \Ref{BoolType}. It provides conversions to/from long and
47 double. It's subclasses must implement conversions to/from unsigned
48 long.
49 */
50 
54 class UIntegralType : public AtomicType
55 {
56 public:
57  UIntegralType(unsigned int newSize):
58  AtomicType(newSize) {}
59  /*@Doc:
60  constructor.
61  */
62 
64  AtomicType(old) {}
65  /*@Doc:
66  copy constructor.
67  */
68 
69  UIntegralType(const OId& id) throw (r_Error):
70  AtomicType(id) {}
71  /*@Doc:
72  */
73 
74  virtual ~UIntegralType() {}
75  /*@Doc:
76  */
77 
78  virtual r_Long* convertToCLong(const char*, r_Long*) const;
79  virtual char* makeFromCLong(char*, const r_Long*) const;
80 
81  virtual double* convertToCDouble(const char*, double*) const;
82  virtual char* makeFromCDouble(char*, const double*) const;
83 
84 protected:
85  UIntegralType(const char* name, unsigned int newSize):
86  AtomicType(name, newSize) {}
87  /*@Doc:
88  */
89 
90 };
91 
92 #include "uintegraltype.icc"
93 
94 #endif
virtual ~UIntegralType()
Definition: uintegraltype.hh:74
UIntegralType(const OId &id)
Definition: uintegraltype.hh:69
AtomicType(unsigned int newSize)
virtual char * makeFromCLong(char *, const r_Long *) const
virtual r_Long * convertToCLong(const char *, r_Long *) const
Definition: oidif.hh:67
Definition: uintegraltype.hh:54
Definition: atomictype.hh:59
UIntegralType(const char *name, unsigned int newSize)
Definition: uintegraltype.hh:85
virtual double * convertToCDouble(const char *, double *) const
UIntegralType(const UIntegralType &old)
Definition: uintegraltype.hh:63
virtual char * makeFromCDouble(char *, const double *) const
UIntegralType(unsigned int newSize)
Definition: uintegraltype.hh:57