MaskTimes.h
1 //-*-C++-*-
2 /***************************************************************************
3  *
4  * Copyright (C) 2023 by Willem van Straten
5  * Licensed under the Academic Free License version 2.1
6  *
7  ***************************************************************************/
8 
9 #ifndef __dsp_Signal_General_MaskTimes_h
10 #define __dsp_Signal_General_MaskTimes_h
11 
12 #include "dsp/Mask.h"
13 #include "TimeInterval.h"
14 
15 namespace dsp {
16 
18 
19  class MaskTimes: public Mask {
20 
21  public:
22 
25 
27  ~MaskTimes ();
28 
30  void load (const std::string& filename);
31 
32  protected:
33 
35  void mask_data();
36 
38 
39  std::vector<TimeInterval> interval;
40 
42  unsigned current_interval{0};
43  };
44 
45 }
46 
47 #endif // !defined(__dsp_Signal_General_MaskTimes_h)
Contains all Baseband Data Reduction Library classes.
Definition: ASCIIObservation.h:17
Masks samples in the input TimeSeries by setting them to zero.
Definition: Mask.h:25
Checks for expected string in a data file.
Definition: Expect.h:17
A time TimeInterval.
Definition: TimeInterval.h:17
void mask_data()
Mask any time samples spanned by an interval.
Definition: MaskTimes.C:27
std::vector< TimeInterval > interval
List of time intervals to be masked.
Definition: MaskTimes.h:49
static bool verbose
Global verbosity flag.
Definition: Operation.h:48
~MaskTimes()
Destructor.
Definition: MaskTimes.C:21
bool expect(const std::string &text)
Return true if the next string read from file matches text.
Definition: Expect.C:23
void load(const std::string &filename)
Load intervals to be masked from file.
Definition: MaskTimes.C:65
MaskTimes()
Default constructor.
Definition: MaskTimes.C:14
unsigned current_interval
The current time interval.
Definition: MaskTimes.h:52

Generated using doxygen 1.8.17