LCOV - code coverage report
Current view: top level - synthesis/TransformMachines2 - CFStore.h (source / functions) Hit Total Coverage
Test: casacpp_coverage.info Lines: 4 12 33.3 %
Date: 2024-10-10 15:00:01 Functions: 1 4 25.0 %

          Line data    Source code
       1             : // -*- C++ -*-
       2             : //# CFStore.h: Definition of the CFStore class
       3             : //# Copyright (C) 1997,1998,1999,2000,2001,2002,2003
       4             : //# Associated Universities, Inc. Washington DC, USA.
       5             : //#
       6             : //# This library is free software; you can redistribute it and/or modify it
       7             : //# under the terms of the GNU Library General Public License as published by
       8             : //# the Free Software Foundation; either version 2 of the License, or (at your
       9             : //# option) any later version.
      10             : //#
      11             : //# This library is distributed in the hope that it will be useful, but WITHOUT
      12             : //# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
      13             : //# FITNESS FOR A PARTICULAR PURPOSE.  See the GNU Library General Public
      14             : //# License for more details.
      15             : //#
      16             : //# You should have received a copy of the GNU Library General Public License
      17             : //# along with this library; if not, write to the Free Software Foundation,
      18             : //# Inc., 675 Massachusetts Ave, Cambridge, MA 02139, USA.
      19             : //#
      20             : //# Correspondence concerning AIPS++ should be addressed as follows:
      21             : //#        Internet email: casa-feedback@nrao.edu.
      22             : //#        Postal address: AIPS++ Project Office
      23             : //#                        National Radio Astronomy Observatory
      24             : //#                        520 Edgemont Road
      25             : //#                        Charlottesville, VA 22903-2475 USA
      26             : //#
      27             : //# $Id$
      28             : #ifndef SYNTHESIS_TRANSFORM2_CFSTORE_H
      29             : #define SYNTHESIS_TRANSFORM2_CFSTORE_H
      30             : #include <synthesis/TransformMachines2/CFDefs.h>
      31             : #include <synthesis/TransformMachines/SynthesisError.h>
      32             : #include <casacore/coordinates/Coordinates/CoordinateSystem.h>
      33             : #include <casacore/casa/Logging/LogIO.h>
      34             : #include <casacore/casa/Logging/LogSink.h>
      35             : #include <casacore/casa/Logging/LogOrigin.h>
      36             : #include <casacore/casa/Utilities/CountedPtr.h>
      37             : #include <casacore/images/Images/ImageInterface.h>
      38             : #include <msvis/MSVis/VisBuffer2.h>
      39             : namespace casa { //# NAMESPACE CASA - BEGIN
      40             :   using namespace vi;
      41             :   namespace refim{
      42             :   using namespace CFDefs;
      43             :   class CFStore
      44             :   {
      45             :   public:
      46           6 :     CFStore():data(), rdata(), coordSys(), sampling(), 
      47           6 :               xSupport(), ySupport(), 
      48           6 :               maxXSupport(-1), maxYSupport(-1),
      49           6 :               pa(), mosPointingPos(0) {};
      50             : 
      51           0 :     CFStore(CFType *dataPtr, casacore::CoordinateSystem& cs, casacore::Vector<casacore::Float>& samp,
      52             :             casacore::Vector<casacore::Int>& xsup, casacore::Vector<casacore::Int>& ysup, casacore::Int maxXSup, casacore::Int maxYSup,
      53           0 :             casacore::Quantity PA, casacore::Int mosPointing):
      54           0 :       data(),rdata(), coordSys(cs), sampling(samp),
      55           0 :       xSupport(xsup), ySupport(ysup), maxXSupport(maxXSup),
      56           0 :       maxYSupport(maxYSup), pa(PA), mosPointingPos(mosPointing)
      57           0 :     {data = new CFType(*dataPtr);};
      58             : 
      59           0 :     ~CFStore() {};
      60             : 
      61             :     CFStore& operator=(const CFStore& other);
      62             :     void show(const char *Mesg=NULL,std::ostream &os=std::cerr);
      63           0 :     casacore::Bool null() {return data.null();};
      64             :     void set(const CFStore& other)
      65             :     {
      66             :       coordSys = other.coordSys; sampling.assign(other.sampling); 
      67             :       xSupport.assign(other.xSupport); ySupport.assign(other.ySupport);
      68             :       maxXSupport=other.maxXSupport;  maxYSupport=other.maxYSupport; pa=other.pa;
      69             :       mosPointingPos = other.mosPointingPos;
      70             :     }
      71             :     void set(CFType *dataPtr, casacore::CoordinateSystem& cs, casacore::Vector<casacore::Float>& samp,
      72             :              casacore::Vector<casacore::Int>& xsup, casacore::Vector<casacore::Int>& ysup, casacore::Int maxXSup, casacore::Int maxYSup,
      73             :              casacore::Quantity PA, const casacore::Int mosPointing=0)
      74             :     {
      75             :       data=dataPtr; coordSys=cs; sampling.assign(samp); 
      76             :       xSupport.assign(xsup); ySupport.assign(ysup);
      77             :       maxXSupport=maxXSup;maxYSupport=maxYSup;
      78             :       pa=PA;
      79             :       mosPointingPos = mosPointing;
      80             :     }
      81             : 
      82             :     void resize(casacore::Int nw, casacore::Bool retainValues=false);
      83             :     void resize(casacore::IPosition imShape, casacore::Bool retainValues=false);
      84             : 
      85             : 
      86             :     casacore::CountedPtr<CFType> data;
      87             :     casacore::CountedPtr<CFTypeReal> rdata;
      88             :     casacore::CoordinateSystem coordSys;
      89             :     casacore::Vector<casacore::Float> sampling;
      90             :     casacore::Vector<casacore::Int> xSupport,ySupport;
      91             :     casacore::Int maxXSupport, maxYSupport;
      92             :     casacore::Quantity pa;
      93             :     casacore::Int mosPointingPos;
      94             :   };
      95             : } //# NAMESPACE CASA - END
      96             : }
      97             : #endif

Generated by: LCOV version 1.16