LCOV - code coverage report
Current view: top level - flagging/Flagging - FlagAgentManual.cc (source / functions) Hit Total Coverage
Test: casa_coverage.info Lines: 18 18 100.0 %
Date: 2023-10-25 08:47:59 Functions: 5 5 100.0 %

          Line data    Source code
       1             : //# FlagAgentManual.cc: This file contains the implementation of the FlagAgentManual class.
       2             : //#
       3             : //#  CASA - Common Astronomy Software Applications (http://casa.nrao.edu/)
       4             : //#  Copyright (C) Associated Universities, Inc. Washington DC, USA 2011, All rights reserved.
       5             : //#  Copyright (C) European Southern Observatory, 2011, All rights reserved.
       6             : //#
       7             : //#  This library is free software; you can redistribute it and/or
       8             : //#  modify it under the terms of the GNU Lesser General Public
       9             : //#  License as published by the Free software Foundation; either
      10             : //#  version 2.1 of the License, or (at your option) any later version.
      11             : //#
      12             : //#  This library is distributed in the hope that it will be useful,
      13             : //#  but WITHOUT ANY WARRANTY, without even the implied warranty of
      14             : //#  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
      15             : //#  Lesser General Public License for more details.
      16             : //#
      17             : //#  You should have received a copy of the GNU Lesser General Public
      18             : //#  License along with this library; if not, write to the Free Software
      19             : //#  Foundation, Inc., 59 Temple Place, Suite 330, Boston,
      20             : //#  MA 02111-1307  USA
      21             : //# $Id: $
      22             : 
      23             : #include <flagging/Flagging/FlagAgentManual.h>
      24             : 
      25             : using namespace casacore;
      26             : namespace casa { //# NAMESPACE CASA - BEGIN
      27             : 
      28        1522 : FlagAgentManual::FlagAgentManual(FlagDataHandler *dh, Record config, Bool writePrivateFlagCube, Bool flag):
      29        1525 :                 FlagAgentBase(dh,config,ROWS,writePrivateFlagCube,flag)
      30             : {
      31        1519 :         initialize(config);
      32        1519 : }
      33             : 
      34        3038 : FlagAgentManual::~FlagAgentManual()
      35             : {
      36             :         // Compiler automagically calls FlagAgentBase::~FlagAgentBase()
      37        3038 : }
      38             : 
      39             : void
      40        1519 : FlagAgentManual::initialize(Record config)
      41             : {
      42             : 
      43             :         int exists;
      44        1519 :         bool autocorr = false;
      45             : 
      46        1519 :         exists = config.fieldNumber ("autocorr");
      47        1519 :         if (exists >= 0)
      48         137 :                 autocorr = config.asBool("autocorr");
      49             : 
      50             :         // For the auto-correlation flagging
      51        1519 :         if (flagDataHandler_p->tableTye_p == FlagDataHandler::MEASUREMENT_SET
      52        1413 :                         and autocorr){
      53           8 :                 flagDataHandler_p->preLoadColumn(VisBufferComponent2::ProcessorId);
      54           8 :                 flagDataHandler_p->loadProcessorTable_p = true;
      55             :         }
      56             : 
      57        1519 : }
      58             : 
      59             : bool
      60     8397831 : FlagAgentManual::computeRowFlags(const vi::VisBuffer2 &/*visBuffer*/, FlagMapper &/*flags*/, uInt /*row*/)
      61             : {
      62     8397831 :         return true;
      63             : 
      64             : }
      65             : 
      66             : 
      67             : } //# NAMESPACE CASA - END
      68             : 
      69             : 

Generated by: LCOV version 1.16