JAPAn
Just Another Parity Analyzer
Loading...
Searching...
No Matches
QwBlindDetectorArray.cc
Go to the documentation of this file.
1/*!
2 * \file QwBlindDetectorArray.cc
3 * \brief Blinded detector array implementation for PMT analysis
4 * \author P. M. King
5 * \date 2007-05-08
6 */
7
9
10/**
11 * Virtual destructor to ensure creation of VTT
12 */
14
15/**
16 * Blind the asymmetry
17 * @param blinder Blinder
18 */
20{
21 for (size_t i = 0; i < fIntegrationPMT.size(); i++)
22 fIntegrationPMT[i].Blind(blinder);
23 for (size_t i = 0; i < fCombinedPMT.size(); i++)
24 fCombinedPMT[i].Blind(blinder);
25}
26
27/**
28 * Blind the difference using the yield
29 * @param blinder Blinder
30 * @param subsys Subsystem
31 */
32
33void QwBlindDetectorArray::Blind(const QwBlinder *blinder, const VQwSubsystemParity* subsys)
34{
35 /// \todo TODO (wdc) At some point we should introduce const-correctness in
36 /// the Compare() routine to ensure nothing funny happens. This const_casting
37 /// is just an ugly stop-gap measure.
38 if (Compare(const_cast<VQwSubsystemParity*>(subsys))) {
39
40 const QwBlindDetectorArray* yield = dynamic_cast<const QwBlindDetectorArray*>(subsys);
41 if (yield == 0) return;
42
43 for (size_t i = 0; i < fIntegrationPMT.size(); i++)
44 fIntegrationPMT[i].Blind(blinder, yield->fIntegrationPMT[i]);
45 for (size_t i = 0; i < fCombinedPMT.size(); i++)
46 fCombinedPMT[i].Blind(blinder, yield->fCombinedPMT[i]);
47 }
48}
Blinded detector array for PMT analysis.
~QwBlindDetectorArray() override
Virtual destructor.
QwBlindDetectorArray()
Private default constructor (not implemented, will throw linker error on use)
void Blind(const QwBlinder *blinder) override
Blind the asymmetry.
Data blinding utilities for parity violation analysis.
Definition QwBlinder.h:57
std::vector< QwIntegrationPMT > fIntegrationPMT
Bool_t Compare(VQwSubsystem *source)
std::vector< QwCombinedPMT > fCombinedPMT
VQwSubsystemParity()
Private default constructor (not implemented, will throw linker error on use)