LArSoft
v07_13_02
Liquid Argon Software toolkit - http://larsoft.org/
|
Class providing information about the quality of channels. More...
#include "SIOVChannelStatusProvider.h"
Public Member Functions | |
SIOVChannelStatusProvider (fhicl::ParameterSet const &pset) | |
Constructor. More... | |
virtual | ~SIOVChannelStatusProvider ()=default |
Default destructor. More... | |
const ChannelStatus & | GetChannelStatus (raw::ChannelID_t channel) const |
Returns Channel Status. More... | |
Status_t | Status (raw::ChannelID_t channel) const override |
void | UpdateTimeStamp (DBTimeStamp_t ts) |
Update event time stamp. More... | |
virtual void | Reconfigure (fhicl::ParameterSet const &p) |
Configure using fhicl::ParameterSet. More... | |
bool | UpdateFolder (DBTimeStamp_t ts) |
Return true if fFolder is successfully updated. More... | |
const std::string & | URL () const |
Get connection information. More... | |
const std::string & | FolderName () const |
const std::string & | Tag () const |
const IOVTimeStamp & | Begin () const |
Get Timestamp information. More... | |
const IOVTimeStamp & | End () const |
Single channel queries | |
Returns whether the specified channel is physical and connected to wire | |
bool | IsPresent (raw::ChannelID_t channel) const override |
Returns whether the specified channel is bad in the current run. More... | |
bool | IsBad (raw::ChannelID_t channel) const override |
Returns whether the specified channel is bad in the current run. More... | |
bool | IsNoisy (raw::ChannelID_t channel) const override |
Returns whether the specified channel is noisy in the current run. More... | |
bool | IsGood (raw::ChannelID_t channel) const override |
Returns whether the specified channel is physical and good. More... | |
Global channel queries | |
Returns a copy of set of good channel IDs for the current run | |
ChannelSet_t | GoodChannels () const override |
Returns a copy of set of bad channel IDs for the current run. More... | |
ChannelSet_t | BadChannels () const override |
Returns a copy of set of bad channel IDs for the current run. More... | |
ChannelSet_t | NoisyChannels () const override |
Returns a copy of set of noisy channel IDs for the current run. More... | |
Configuration functions | |
Prepares the object to provide information about the specified time | |
bool | Update (DBTimeStamp_t) |
Allows a service to add to the list of noisy channels. More... | |
void | AddNoisyChannel (raw::ChannelID_t ch) |
Allows a service to add to the list of noisy channels. More... | |
Static Public Member Functions | |
static DBChannelID_t | rawToDBChannel (raw::ChannelID_t channel) |
Converts LArSoft channel ID in the one proper for the DB. More... | |
Protected Attributes | |
std::unique_ptr< DBFolder > | fFolder |
Private Member Functions | |
bool | DBUpdate () const |
Do actual database updates. More... | |
bool | DBUpdate (DBTimeStamp_t ts) const |
ChannelSet_t | GetChannelsWithStatus (chStatus status) const |
Private Attributes | |
DBTimeStamp_t | fEventTimeStamp |
DBTimeStamp_t | fCurrentTimeStamp |
DataSource::ds | fDataSource |
Snapshot< ChannelStatus > | fData |
Snapshot< ChannelStatus > | fNewNoisy |
ChannelStatus | fDefault |
Class providing information about the quality of channels.
This class serves information read from a FHiCL configuration file and/or a database.
LArSoft interface to this class is through the service SIOVChannelStatusService.
Definition at line 35 of file SIOVChannelStatusProvider.h.
lariov::SIOVChannelStatusProvider::SIOVChannelStatusProvider | ( | fhicl::ParameterSet const & | pset | ) |
Constructor.
Definition at line 34 of file SIOVChannelStatusProvider.cxx.
References fData, fDataSource, fDefault, file, and fhicl::ParameterSet::get().
|
virtualdefault |
Default destructor.
void lariov::SIOVChannelStatusProvider::AddNoisyChannel | ( | raw::ChannelID_t | ch | ) |
Allows a service to add to the list of noisy channels.
Definition at line 210 of file SIOVChannelStatusProvider.cxx.
References fNewNoisy, IsBad(), IsPresent(), and rawToDBChannel().
Referenced by Status().
|
override |
Returns a copy of set of bad channel IDs for the current run.
Definition at line 194 of file SIOVChannelStatusProvider.cxx.
References GetChannelsWithStatus().
Referenced by Status().
|
inlineinherited |
Get Timestamp information.
Definition at line 59 of file DatabaseRetrievalAlg.h.
References lariov::DatabaseRetrievalAlg::fFolder.
Referenced by lariov::SIOVPmtGainProvider::DBUpdate(), lariov::SIOVElectronicsCalibProvider::DBUpdate(), lariov::DetPedestalRetrievalAlg::DBUpdate(), and DBUpdate().
|
private |
Do actual database updates.
Definition at line 100 of file SIOVChannelStatusProvider.cxx.
References fEventTimeStamp.
Referenced by GetChannelStatus(), rawToDBChannel(), and Update().
|
private |
Definition at line 107 of file SIOVChannelStatusProvider.cxx.
References lariov::DatabaseRetrievalAlg::Begin(), lariov::DatabaseRetrievalAlg::End(), fCurrentTimeStamp, fData, fDataSource, lariov::DatabaseRetrievalAlg::fFolder, and lariov::DatabaseRetrievalAlg::UpdateFolder().
|
inlineinherited |
Definition at line 60 of file DatabaseRetrievalAlg.h.
References lariov::DatabaseRetrievalAlg::fFolder.
Referenced by lariov::SIOVPmtGainProvider::DBUpdate(), lariov::SIOVElectronicsCalibProvider::DBUpdate(), lariov::DetPedestalRetrievalAlg::DBUpdate(), and DBUpdate().
|
inlineinherited |
Definition at line 55 of file DatabaseRetrievalAlg.h.
References lariov::DatabaseRetrievalAlg::fFolder.
const ChannelStatus & lariov::SIOVChannelStatusProvider::GetChannelStatus | ( | raw::ChannelID_t | channel | ) | const |
Returns Channel Status.
Definition at line 143 of file SIOVChannelStatusProvider.cxx.
References DBUpdate(), fData, fDataSource, fDefault, fNewNoisy, and rawToDBChannel().
Referenced by GetChannelsWithStatus(), IsBad(), IsGood(), IsNoisy(), IsPresent(), and Status().
|
private |
Definition at line 159 of file SIOVChannelStatusProvider.cxx.
References fDataSource, fDefault, and GetChannelStatus().
Referenced by BadChannels(), GoodChannels(), and NoisyChannels().
|
override |
Returns a copy of set of bad channel IDs for the current run.
Definition at line 187 of file SIOVChannelStatusProvider.cxx.
References GetChannelsWithStatus().
Referenced by Status().
|
inlineoverride |
Returns whether the specified channel is bad in the current run.
Definition at line 63 of file SIOVChannelStatusProvider.h.
References GetChannelStatus(), and IsPresent().
Referenced by AddNoisyChannel().
|
inlineoverride |
Returns whether the specified channel is physical and good.
Definition at line 73 of file SIOVChannelStatusProvider.h.
References GetChannelStatus().
|
inlineoverride |
Returns whether the specified channel is noisy in the current run.
Definition at line 68 of file SIOVChannelStatusProvider.h.
References GetChannelStatus().
|
inlineoverride |
Returns whether the specified channel is bad in the current run.
Definition at line 58 of file SIOVChannelStatusProvider.h.
References GetChannelStatus().
Referenced by AddNoisyChannel(), and IsBad().
|
override |
Returns a copy of set of noisy channel IDs for the current run.
Definition at line 204 of file SIOVChannelStatusProvider.cxx.
References GetChannelsWithStatus().
Referenced by Status().
|
inlinestatic |
Converts LArSoft channel ID in the one proper for the DB.
Definition at line 110 of file SIOVChannelStatusProvider.h.
References DBUpdate().
Referenced by AddNoisyChannel(), and GetChannelStatus().
|
virtualinherited |
Configure using fhicl::ParameterSet.
Reimplemented in lariov::DetPedestalRetrievalAlg, lariov::SIOVElectronicsCalibProvider, and lariov::SIOVPmtGainProvider.
Definition at line 9 of file DatabaseRetrievalAlg.cxx.
References lariov::DatabaseRetrievalAlg::fFolder, and fhicl::ParameterSet::get().
Referenced by lariov::DatabaseRetrievalAlg::DatabaseRetrievalAlg(), lariov::SIOVPmtGainProvider::Reconfigure(), lariov::SIOVElectronicsCalibProvider::Reconfigure(), lariov::DetPedestalRetrievalAlg::Reconfigure(), and lariov::DatabaseRetrievalAlg::~DatabaseRetrievalAlg().
|
inlineoverride |
Definition at line 78 of file SIOVChannelStatusProvider.h.
References AddNoisyChannel(), BadChannels(), GetChannelStatus(), GoodChannels(), NoisyChannels(), Update(), and UpdateTimeStamp().
|
inlineinherited |
Definition at line 56 of file DatabaseRetrievalAlg.h.
References lariov::DatabaseRetrievalAlg::fFolder.
bool lariov::SIOVChannelStatusProvider::Update | ( | DBTimeStamp_t | ts | ) |
Allows a service to add to the list of noisy channels.
Definition at line 91 of file SIOVChannelStatusProvider.cxx.
References DBUpdate(), fEventTimeStamp, and fNewNoisy.
Referenced by Status().
|
inlineinherited |
Return true if fFolder is successfully updated.
Definition at line 49 of file DatabaseRetrievalAlg.h.
References lariov::DatabaseRetrievalAlg::fFolder.
Referenced by lariov::SIOVPmtGainProvider::DBUpdate(), lariov::SIOVElectronicsCalibProvider::DBUpdate(), lariov::DetPedestalRetrievalAlg::DBUpdate(), and DBUpdate().
void lariov::SIOVChannelStatusProvider::UpdateTimeStamp | ( | DBTimeStamp_t | ts | ) |
Update event time stamp.
Definition at line 83 of file SIOVChannelStatusProvider.cxx.
References fEventTimeStamp, and fNewNoisy.
Referenced by lariov::SIOVChannelStatusService::PreProcessEvent(), and Status().
|
inlineinherited |
Get connection information.
Definition at line 54 of file DatabaseRetrievalAlg.h.
References lariov::DatabaseRetrievalAlg::fFolder.
|
mutableprivate |
Definition at line 123 of file SIOVChannelStatusProvider.h.
Referenced by DBUpdate().
|
mutableprivate |
Definition at line 126 of file SIOVChannelStatusProvider.h.
Referenced by DBUpdate(), GetChannelStatus(), and SIOVChannelStatusProvider().
|
private |
Definition at line 125 of file SIOVChannelStatusProvider.h.
Referenced by DBUpdate(), GetChannelStatus(), GetChannelsWithStatus(), and SIOVChannelStatusProvider().
|
private |
Definition at line 128 of file SIOVChannelStatusProvider.h.
Referenced by GetChannelStatus(), GetChannelsWithStatus(), and SIOVChannelStatusProvider().
|
private |
Definition at line 122 of file SIOVChannelStatusProvider.h.
Referenced by DBUpdate(), Update(), and UpdateTimeStamp().
|
protectedinherited |
Definition at line 65 of file DatabaseRetrievalAlg.h.
Referenced by lariov::DatabaseRetrievalAlg::Begin(), lariov::SIOVPmtGainProvider::DBUpdate(), lariov::SIOVElectronicsCalibProvider::DBUpdate(), lariov::DetPedestalRetrievalAlg::DBUpdate(), DBUpdate(), lariov::DatabaseRetrievalAlg::End(), lariov::DatabaseRetrievalAlg::FolderName(), lariov::DatabaseRetrievalAlg::Reconfigure(), lariov::DatabaseRetrievalAlg::Tag(), lariov::DatabaseRetrievalAlg::UpdateFolder(), and lariov::DatabaseRetrievalAlg::URL().
|
private |
Definition at line 127 of file SIOVChannelStatusProvider.h.
Referenced by AddNoisyChannel(), GetChannelStatus(), Update(), and UpdateTimeStamp().