Loading...
Searching...
No Matches
SDDataDescHandler.h
Go to the documentation of this file.
//# SDDataDescFiller.h: fills the DATA_DESCRIPTION table for the SDFITS filler
//# Copyright (C) 2000
//# Associated Universities, Inc. Washington DC, USA.
//#
//# This library is free software; you can redistribute it and/or modify it
//# under the terms of the GNU Library General Public License as published by
//# the Free Software Foundation; either version 2 of the License, or (at your
//# option) any later version.
//#
//# This library is distributed in the hope that it will be useful, but WITHOUT
//# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
//# FITNESS FOR A PARTICULAR PURPOSE. See the GNU Library General Public
//# License for more details.
//#
//# You should have received a copy of the GNU Library General Public License
//# along with this library; if not, write to the Free Software Foundation,
//# Inc., 675 Massachusetts Ave, Cambridge, MA 02139, USA.
//#
//# Correspondence concerning AIPS++ should be addressed as follows:
//# Internet email: casa-feedback@nrao.edu.
//# Postal address: AIPS++ Project Office
//# National Radio Astronomy Observatory
//# 520 Edgemont Road
//# Charlottesville, VA 22903-2475 USA
#ifndef MS_SDDATADESCHANDLER_H
#define MS_SDDATADESCHANDLER_H
#include <casacore/casa/aips.h>
#include <casacore/casa/Containers/RecordField.h>
#include <casacore/casa/Arrays/ArrayFwd.h>
namespace casacore { //# NAMESPACE CASACORE - BEGIN
//# Forward Declarations
class ColumnsIndex;
class MeasurementSet;
class MSDataDescription;
class MSDataDescColumns;
class Record;
// <summary>
// </summary>
// <use visibility=local> or <use visibility=export>
// <reviewed reviewer="" date="yyyy/mm/dd" tests="" demos="">
// </reviewed>
// <prerequisite>
// <li> SomeClass
// <li> SomeOtherClass
// <li> some concept
// </prerequisite>
//
// <etymology>
// </etymology>
//
// <synopsis>
// </synopsis>
//
// <example>
// </example>
//
// <motivation>
// </motivation>
//
// <templating arg=T>
// <li>
// <li>
// </templating>
//
// <thrown>
// <li>
// <li>
// </thrown>
//
// <todo asof="yyyy/mm/dd">
// <li> add this feature
// <li> fix this bug
// <li> start discussion of this possible extension
// </todo>
class SDDataDescHandler
{
public:
// default ctor is not attached to a MS and hence is useless until attached
SDDataDescHandler();
// attach this to a MS - no columns are explicitly handled here
SDDataDescHandler(MeasurementSet &ms);
// copy ctor
SDDataDescHandler(const SDDataDescHandler &other);
~SDDataDescHandler() {clearAll();}
// assignment operator, uses copy semantics
SDDataDescHandler &operator=(const SDDataDescHandler &other);
// attach to a MS, the handledCols and row arguments are ignored here
void attach(MeasurementSet &ms, Vector<Bool> &handledCols, const Record &row);
// reset internals given indicated row, use the same MS; just resets the id pointer
void resetRow(const Record &) {rownr_p=-1;}
// fill - a new row is added only when necessary
void fill(const Record &row, Int spwinId, Int polId);
// get the current dataDesc ID
Int dataDescId() {return rownr_p;}
private:
RecordFieldPtr<Int> spwinIdKey_p, polIdKey_p;
ColumnsIndex *index_p;
MSDataDescription *msDataDesc_p;
MSDataDescColumns *msDataDescCols_p;
Int rownr_p;
// cleanup everything
void clearAll();
// initialize everything
void initAll(MeasurementSet &ms);
};
} //# NAMESPACE CASACORE - END
#endif
casacore::ColumnsIndex
Definition ColumnsIndex.h:226
casacore::MSDataDescColumns
Definition MSDataDescColumns.h:73
casacore::MSDataDescription
Definition MSDataDescription.h:78
casacore::MeasurementSet
Definition MeasurementSet.h:278
casacore::RecordFieldPtr
Definition ColumnsIndex.h:42
casacore::SDDataDescHandler::~SDDataDescHandler
~SDDataDescHandler()
Definition SDDataDescHandler.h:96
casacore::SDDataDescHandler::msDataDesc_p
MSDataDescription * msDataDesc_p
Definition SDDataDescHandler.h:115
casacore::SDDataDescHandler::rownr_p
Int rownr_p
Definition SDDataDescHandler.h:118
casacore::SDDataDescHandler::SDDataDescHandler
SDDataDescHandler(MeasurementSet &ms)
attach this to a MS - no columns are explicitly handled here
casacore::SDDataDescHandler::SDDataDescHandler
SDDataDescHandler(const SDDataDescHandler &other)
copy ctor
casacore::SDDataDescHandler::index_p
ColumnsIndex * index_p
Definition SDDataDescHandler.h:114
casacore::SDDataDescHandler::initAll
void initAll(MeasurementSet &ms)
initialize everything
casacore::SDDataDescHandler::polIdKey_p
RecordFieldPtr< Int > polIdKey_p
Definition SDDataDescHandler.h:113
casacore::SDDataDescHandler::clearAll
void clearAll()
cleanup everything
casacore::SDDataDescHandler::dataDescId
Int dataDescId()
get the current dataDesc ID
Definition SDDataDescHandler.h:111
casacore::SDDataDescHandler::SDDataDescHandler
SDDataDescHandler()
default ctor is not attached to a MS and hence is useless until attached
casacore::SDDataDescHandler::operator=
SDDataDescHandler & operator=(const SDDataDescHandler &other)
assignment operator, uses copy semantics
casacore::SDDataDescHandler::spwinIdKey_p
RecordFieldPtr< Int > spwinIdKey_p
Definition SDDataDescHandler.h:113
casacore::SDDataDescHandler::msDataDescCols_p
MSDataDescColumns * msDataDescCols_p
Definition SDDataDescHandler.h:116
casacore::SDDataDescHandler::attach
void attach(MeasurementSet &ms, Vector< Bool > &handledCols, const Record &row)
attach to a MS, the handledCols and row arguments are ignored here
casacore::SDDataDescHandler::resetRow
void resetRow(const Record &)
reset internals given indicated row, use the same MS; just resets the id pointer
Definition SDDataDescHandler.h:105
casacore::SDDataDescHandler::fill
void fill(const Record &row, Int spwinId, Int polId)
fill - a new row is added only when necessary
casacore::Vector
Definition Vector.h:82
casacore::Record
Record()
casacore
this file contains all the compiler specific defines
Definition mainpage.dox:28
casacore::Int
int Int
Definition aipstype.h:48