Source
//# FreqAxisTVI.h: This file contains the interface definition of the MSTransformManager class.
//#
//# CASA - Common Astronomy Software Applications (http://casa.nrao.edu/)
//# Copyright (C) Associated Universities, Inc. Washington DC, USA 2011, All rights reserved.
//# Copyright (C) European Southern Observatory, 2011, All rights reserved.
//#
//# This library is free software; you can redistribute it and/or
//# modify it under the terms of the GNU Lesser General Public
//# License as published by the Free software Foundation; either
//# version 2.1 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
//# Lesser General Public License for more details.
//#
//# You should have received a copy of the GNU Lesser General Public
//# License along with this library; if not, write to the Free Software
//# Foundation, Inc., 59 Temple Place, Suite 330, Boston,
//# MA 02111-1307 USA
//# $Id: $
// Base class
// VI/VB framework
// TVI framework
// Measurement Set
// NOTE: See implementation include below
namespace casa { //# NAMESPACE CASA - BEGIN
namespace vi { //# NAMESPACE VI - BEGIN
//////////////////////////////////////////////////////////////////////////
// FreqAxisTVI class
//////////////////////////////////////////////////////////////////////////
template<class T> class FreqAxisTransformEngine; // Forward declaration
template<class T> class FreqAxisTransformEngine2; // Forward declaration
class FreqAxisTVI : public TransformingVi2
{
public:
// Lifecycle
FreqAxisTVI(ViImplementation2 * inputVii);
~FreqAxisTVI();
// Navigation methods
virtual void origin ();
virtual void next ();
// General TVI info (common for all sub-classes)
casacore::Bool existsColumn (VisBufferComponent2 id) const;
casacore::Bool flagCategoryExists () const {return false;}
// casacore::List of methods that should be implemented by derived classes
// virtual void flag(casacore::Cube<casacore::Bool>& flagCube) const = 0;
// virtual void floatData (casacore::Cube<casacore::Float> & vis) const = 0;
// virtual void visibilityObserved (casacore::Cube<casacore::Complex> & vis) const = 0;
// virtual void visibilityCorrected (casacore::Cube<casacore::Complex> & vis) const = 0;
// virtual void visibilityModel (casacore::Cube<casacore::Complex> & vis) const = 0;
// virtual void weightSpectrum(casacore::Cube<casacore::Float> &weightSp) const = 0;
// virtual void sigmaSpectrum (casacore::Cube<casacore::Float> &sigmaSp) const = 0;
// virtual casacore::Vector<casacore::Double> getFrequencies ( casacore::Double time, casacore::Int frameOfReference,casacore::Int spectralWindowId, casacore::Int msId) const = 0;
// virtual void writeFlag (const casacore::Cube<casacore::Bool> & flagCube) = 0;
// Common transformation for all sub-classes
void writeFlagRow (const casacore::Vector<casacore::Bool> & flag);
casacore::Vector<casacore::Int> getChannels ( casacore::Double time, casacore::Int frameOfReference,
casacore::Int spectralWindowId, casacore::Int msId) const;
void flagRow (casacore::Vector<casacore::Bool> & flagRow) const;
void weight (casacore::Matrix<casacore::Float> & weight) const;
void sigma (casacore::Matrix<casacore::Float> & sigma) const;
protected:
// Method implementing main loop (with auxiliary data)