casacore
Loading...
Searching...
No Matches
TSMIdColumn.h
Go to the documentation of this file.
1//# TSMIdColumn.h: An id column in Tiled Storage Manager
2//# Copyright (C) 1995,1996,1997,1999
3//# Associated Universities, Inc. Washington DC, USA.
4//#
5//# This library is free software; you can redistribute it and/or modify it
6//# under the terms of the GNU Library General Public License as published by
7//# the Free Software Foundation; either version 2 of the License, or (at your
8//# option) any later version.
9//#
10//# This library is distributed in the hope that it will be useful, but WITHOUT
11//# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
12//# FITNESS FOR A PARTICULAR PURPOSE. See the GNU Library General Public
13//# License for more details.
14//#
15//# You should have received a copy of the GNU Library General Public License
16//# along with this library; if not, write to the Free Software Foundation,
17//# Inc., 675 Massachusetts Ave, Cambridge, MA 02139, USA.
18//#
19//# Correspondence concerning AIPS++ should be addressed as follows:
20//# Internet email: casa-feedback@nrao.edu.
21//# Postal address: AIPS++ Project Office
22//# National Radio Astronomy Observatory
23//# 520 Edgemont Road
24//# Charlottesville, VA 22903-2475 USA
25
26#ifndef TABLES_TSMIDCOLUMN_H
27#define TABLES_TSMIDCOLUMN_H
28
29//# Includes
30#include <casacore/casa/aips.h>
31#include <casacore/tables/DataMan/TSMColumn.h>
32#include <casacore/casa/Arrays/IPosition.h>
33#include <casacore/casa/BasicSL/String.h>
34
35namespace casacore { //# NAMESPACE CASACORE - BEGIN
36
37//# Forward Declarations
38
39
40// <summary>
41// An id column in Tiled Storage Manager.
42// </summary>
43
44// <use visibility=local>
45
46// <reviewed reviewer="UNKNOWN" date="before2004/08/25" tests="">
47// </reviewed>
48
49// <prerequisite>
50//# Classes you should understand before using this one.
51// <li> <linkto class=TSMColumn>TSMColumn</linkto>
52// <li> <linkto class=TSMCube>TSMCube</linkto>
53// <li> <linkto class=Record>Record</linkto>
54// </prerequisite>
55
56// <etymology>
57// TSMIdColumn handles an id column for a Tiled
58// Storage Manager.
59// </etymology>
60
61// <synopsis>
62// TSMIdColumn is used by
63// <linkto class=TiledStMan>TiledStMan</linkto>
64// to handle the access to
65// a table column containing an id value of a tiled hypercube.
66// Explicitly putting an id value is not possible. The only way to
67// define the value is by specifying it when adding a hypercube
68// in <linkto class=TiledDataStMan>TiledDataStMan</linkto>.
69// <p>
70// The id values are held in a TSMCube object. The row number
71// determines which TSMCube object has to be accessed.
72// <p>
73// The creation of a TSMIdColumn object is done by a TSMColumn object.
74// This process is described in more detail in the class
75// <linkto class=TSMColumn>TSMColumn</linkto>.
76// </synopsis>
77
78// <motivation>
79// Handling coordinate columns in the Tiled Storage Manager is
80// different from other columns.
81// </motivation>
82
83//# <todo asof="$DATE:$">
84//# A List of bugs, limitations, extensions or planned refinements.
85//# </todo>
86
87
88class TSMIdColumn : public TSMColumn
89{
90public:
91
92 // Create an id column from the given column.
93 TSMIdColumn (const TSMColumn& column);
94
95 // Frees up the storage.
96 virtual ~TSMIdColumn();
97
98 // Forbid copy constructor.
99 TSMIdColumn (const TSMIdColumn&) = delete;
100
101 // Forbid assignment.
103
104 // Get a scalar value in the given row.
105 // The buffer pointed to by dataPtr has to have the correct length
106 // (which is guaranteed by the ScalarColumn get function).
107 // <group>
108 virtual void getBool (rownr_t rownr, Bool* dataPtr);
109 virtual void getInt (rownr_t rownr, Int* dataPtr);
110 virtual void getuInt (rownr_t rownr, uInt* dataPtr);
111 virtual void getInt64 (rownr_t rownr, Int64* dataPtr);
112 virtual void getfloat (rownr_t rownr, float* dataPtr);
113 virtual void getdouble (rownr_t rownr, double* dataPtr);
114 virtual void getComplex (rownr_t rownr, Complex* dataPtr);
115 virtual void getDComplex (rownr_t rownr, DComplex* dataPtr);
116 virtual void getString (rownr_t rownr, String* dataPtr);
117 // </group>
118
119 // Put a scalar value in the given row.
120 // The buffer pointed to by dataPtr has to have the correct length
121 // (which is guaranteed by the ScalarColumn get function).
122 // The value to be put must match the value which has already
123 // been inserted by the TiledStMan::addHypercube function.
124 // The put function is only there to be fully orthogonal.
125 // <group>
126 virtual void putBool (rownr_t rownr, const Bool* dataPtr);
127 virtual void putInt (rownr_t rownr, const Int* dataPtr);
128 virtual void putuInt (rownr_t rownr, const uInt* dataPtr);
129 virtual void putInt64 (rownr_t rownr, const Int64* dataPtr);
130 virtual void putfloat (rownr_t rownr, const float* dataPtr);
131 virtual void putdouble (rownr_t rownr, const double* dataPtr);
132 virtual void putComplex (rownr_t rownr, const Complex* dataPtr);
133 virtual void putDComplex (rownr_t rownr, const DComplex* dataPtr);
134 virtual void putString (rownr_t rownr, const String* dataPtr);
135 // </group>
136};
137
138
139
140
141} //# NAMESPACE CASACORE - END
142
143#endif
String: the storage and methods of handling collections of characters.
Definition String.h:223
virtual void putString(rownr_t rownr, const String *dataPtr)
virtual void putInt64(rownr_t rownr, const Int64 *dataPtr)
TSMIdColumn & operator=(const TSMIdColumn &)=delete
Forbid assignment.
virtual void getInt(rownr_t rownr, Int *dataPtr)
virtual void putdouble(rownr_t rownr, const double *dataPtr)
virtual void getdouble(rownr_t rownr, double *dataPtr)
virtual void getDComplex(rownr_t rownr, DComplex *dataPtr)
virtual void putfloat(rownr_t rownr, const float *dataPtr)
virtual void getuInt(rownr_t rownr, uInt *dataPtr)
virtual void putInt(rownr_t rownr, const Int *dataPtr)
virtual void getInt64(rownr_t rownr, Int64 *dataPtr)
virtual void putComplex(rownr_t rownr, const Complex *dataPtr)
virtual void getBool(rownr_t rownr, Bool *dataPtr)
Get a scalar value in the given row.
virtual void getString(rownr_t rownr, String *dataPtr)
TSMIdColumn(const TSMIdColumn &)=delete
Forbid copy constructor.
virtual ~TSMIdColumn()
Frees up the storage.
virtual void getComplex(rownr_t rownr, Complex *dataPtr)
virtual void putDComplex(rownr_t rownr, const DComplex *dataPtr)
virtual void putuInt(rownr_t rownr, const uInt *dataPtr)
virtual void getfloat(rownr_t rownr, float *dataPtr)
TSMIdColumn(const TSMColumn &column)
Create an id column from the given column.
virtual void putBool(rownr_t rownr, const Bool *dataPtr)
Put a scalar value in the given row.
this file contains all the compiler specific defines
Definition mainpage.dox:28
unsigned int uInt
Definition aipstype.h:49
long long Int64
Define the extra non-standard types used by Casacore (like proposed uSize, Size)
Definition aipsxtype.h:36
int Int
Definition aipstype.h:48
bool Bool
Define the standard types used by Casacore.
Definition aipstype.h:40
uInt64 rownr_t
Define the type of a row number in a table.
Definition aipsxtype.h:44