#include <BeamMonSwicPeds.h>
Inheritance diagram for BeamMonSwicPeds:

Public Member Functions | |
| BeamMonSwicPeds (const char *devicename="") | |
| virtual DbiTableRow * | CreateTableRow () const |
| DbiTableRow API. | |
| void | Fill (DbiResultSet &rs, const DbiValidityRec *vrec) |
| DbiTableRow API. | |
| virtual void | Store (DbiOutRowStream &ors, const DbiValidityRec *vrec) const |
| DbiTableRow API. | |
| void | SetDeviceName (const char *devicename) |
| Routines to load data. Typically used for BeamMonSwicPedsDbuModule. | |
| void | SetNsamples (int nsamp) |
| std::vector< float > & | GetChannelMeans () |
| std::vector< float > & | GetChannelSigmas () |
| void | SetChannelMeans (const std::vector< double > &means) |
| void | SetChannelSigmas (const std::vector< double > &sigmas) |
| void | SetChannelMeans (const std::vector< float > &means) |
| void | SetChannelSigmas (const std::vector< float > &sigmas) |
| void | ClearData () |
| Clear all data except device name. | |
| const char * | GetDeviceName () const |
| int | GetNsamples () const |
| const std::vector< float > & | GetMeans () const |
| const std::vector< float > & | GetSigmas () const |
| std::vector< double > | GetMeansAsDoubles () const |
| std::vector< double > | GetSigmasAsDoubles () const |
Private Attributes | |
| std::string | fDeviceName |
| int | fNsamples |
| std::vector< float > | fMean |
| std::vector< float > | fSigma |
Created on: Wed Apr 13 18:18:44 2005
Definition at line 40 of file BeamMonSwicPeds.h.
|
|
Definition at line 8 of file BeamMonSwicPeds.cxx. 00009 : fDeviceName(devicename), fMean(96,0), fSigma(96,0) 00010 { 00011 }
|
|
|
Clear all data except device name.
Definition at line 45 of file BeamMonSwicPeds.cxx. References fMean, fNsamples, and fSigma. Referenced by Fill(). 00046 {
00047 for (int ind=0; ind<96; ++ind) fMean[ind] = fSigma[ind] = 0.0;
00048 fNsamples = 0;
00049 }
|
|
|
DbiTableRow API.
Implements DbiTableRow. Definition at line 14 of file BeamMonSwicPeds.cxx. 00015 {
00016 return new BeamMonSwicPeds;
00017 }
|
|
||||||||||||
|
DbiTableRow API.
Implements DbiTableRow. Definition at line 20 of file BeamMonSwicPeds.cxx. References ClearData(), fDeviceName, fMean, and fSigma. 00021 {
00022 this->ClearData();
00023
00024 rs >> fDeviceName >> fNsamples;
00025 for (int ind=0; ind<96; ++ind) {
00026 float tmp=0;
00027 rs >> tmp;
00028 fMean[ind] = tmp;
00029 }
00030 for (int ind=0; ind<96; ++ind) {
00031 float tmp=0;
00032 rs >> tmp;
00033 fSigma[ind] = tmp;
00034 }
00035 }
|
|
|
Definition at line 56 of file BeamMonSwicPeds.h. 00056 { return fMean; }
|
|
|
Definition at line 57 of file BeamMonSwicPeds.h. 00057 { return fSigma; }
|
|
|
Definition at line 66 of file BeamMonSwicPeds.h. References fDeviceName. Referenced by BDSwicPedAccessor::SetSpillTime(), PlotPeds::Update(), and PlotAllPedsImp::Update(). 00066 { return fDeviceName.c_str(); }
|
|
|
Get the mean pedestals. This returns a 96 element vector. Units are ADC counts Definition at line 70 of file BeamMonSwicPeds.h. Referenced by PlotPeds::Update(), and PlotAllPedsImp::Update(). 00070 { return fMean; }
|
|
|
Definition at line 62 of file BeamMonSwicPeds.cxx. References fMean. Referenced by BDSwicPedAccessor::SetSpillTime(). 00063 {
00064 vector<double> ret(96,0);
00065 for (size_t ind=0; ind<96; ++ind) ret[ind] = fMean[ind];
00066 return ret;
00067 }
|
|
|
Definition at line 67 of file BeamMonSwicPeds.h. Referenced by BDSwicPedAccessor::SetSpillTime(), PlotPeds::Update(), and PlotAllPedsImp::Update(). 00067 { return fNsamples; }
|
|
|
Definition at line 71 of file BeamMonSwicPeds.h. Referenced by PlotAllPedsImp::Update(). 00071 { return fSigma; }
|
|
|
Definition at line 69 of file BeamMonSwicPeds.cxx. References fSigma. Referenced by BDSwicPedAccessor::SetSpillTime(). 00070 {
00071 vector<double> ret(96,0);
00072 for (size_t ind=0; ind<96; ++ind) ret[ind] = fSigma[ind];
00073 return ret;
00074 }
|
|
|
Definition at line 60 of file BeamMonSwicPeds.h. References fMean. 00060 { fMean = means; }
|
|
|
Definition at line 51 of file BeamMonSwicPeds.cxx. References fMean. 00052 {
00053 if (means.size() != 96) return; // shouldn't happen
00054 for (size_t ind=0; ind<96; ++ind) fMean[ind] = (float)means[ind];
00055 }
|
|
|
Definition at line 61 of file BeamMonSwicPeds.h. References fSigma. 00061 { fSigma = sigmas; }
|
|
|
Definition at line 56 of file BeamMonSwicPeds.cxx. References fSigma. 00057 {
00058 if (sigmas.size() != 96) return; // shouldn't happen
00059 for (size_t ind=0; ind<96; ++ind) fSigma[ind] = (float)sigmas[ind];
00060 }
|
|
|
Routines to load data. Typically used for BeamMonSwicPedsDbuModule.
Definition at line 53 of file BeamMonSwicPeds.h. References fDeviceName. 00053 { fDeviceName=devicename; }
|
|
|
Definition at line 54 of file BeamMonSwicPeds.h. References fNsamples. 00054 { fNsamples = nsamp; }
|
|
||||||||||||
|
DbiTableRow API.
Reimplemented from DbiTableRow. Definition at line 38 of file BeamMonSwicPeds.cxx. References fDeviceName, fMean, and fSigma. 00039 {
00040 ors << fDeviceName<< fNsamples;
00041 for (int ind=0; ind<96; ++ind) ors << fMean[ind];
00042 for (int ind=0; ind<96; ++ind) ors << fSigma[ind];
00043 }
|
|
|
Definition at line 78 of file BeamMonSwicPeds.h. Referenced by Fill(), GetDeviceName(), SetDeviceName(), and Store(). |
|
|
Definition at line 80 of file BeamMonSwicPeds.h. Referenced by ClearData(), Fill(), GetMeansAsDoubles(), SetChannelMeans(), and Store(). |
|
|
Definition at line 79 of file BeamMonSwicPeds.h. Referenced by ClearData(), and SetNsamples(). |
|
|
Definition at line 81 of file BeamMonSwicPeds.h. Referenced by ClearData(), Fill(), GetSigmasAsDoubles(), SetChannelSigmas(), and Store(). |
1.3.9.1