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 1544 : FlagAgentManual::FlagAgentManual(FlagDataHandler *dh, Record config, Bool writePrivateFlagCube, Bool flag): 29 1551 : FlagAgentBase(dh,config,ROWS,writePrivateFlagCube,flag) 30 : { 31 1537 : initialize(config); 32 1537 : } 33 : 34 3074 : FlagAgentManual::~FlagAgentManual() 35 : { 36 : // Compiler automagically calls FlagAgentBase::~FlagAgentBase() 37 3074 : } 38 : 39 : void 40 1537 : FlagAgentManual::initialize(Record config) 41 : { 42 : 43 : int exists; 44 1537 : bool autocorr = false; 45 : 46 1537 : exists = config.fieldNumber ("autocorr"); 47 1537 : if (exists >= 0) 48 148 : autocorr = config.asBool("autocorr"); 49 : 50 : // For the auto-correlation flagging 51 1537 : if (flagDataHandler_p->tableTye_p == FlagDataHandler::MEASUREMENT_SET 52 1427 : and autocorr){ 53 8 : flagDataHandler_p->preLoadColumn(VisBufferComponent2::ProcessorId); 54 8 : flagDataHandler_p->loadProcessorTable_p = true; 55 : } 56 : 57 1537 : } 58 : 59 : bool 60 8490903 : FlagAgentManual::computeRowFlags(const vi::VisBuffer2 &/*visBuffer*/, FlagMapper &/*flags*/, uInt /*row*/) 61 : { 62 8490903 : return true; 63 : 64 : } 65 : 66 : 67 : } //# NAMESPACE CASA - END 68 : 69 :