LArSoft
v09_90_00
Liquid Argon Software toolkit - https://larsoft.org/
|
Detects the presence of a new event, data product or wire plane. More...
#include "ChangeTrackers.h"
Classes | |
struct | LocalState_t |
Public Member Functions | |
PlaneDataChangeTracker_t ()=default | |
Default constructor: no current plane data. More... | |
PlaneDataChangeTracker_t (art::Event const &evt, art::InputTag const &label, geo::PlaneID const &pid) | |
Constructor: specifies current data product and TPC plane. More... | |
PlaneDataChangeTracker_t (art::EventID const &evt_id, art::InputTag const &label, geo::PlaneID const &pid) | |
Constructor: specifies current data product and TPC plane. More... | |
operator std::string () const | |
Returns a string representation of event and data product label. More... | |
State query | |
Returns the current input label | |
geo::PlaneID const & | planeID () const |
Returns the current plane ID. More... | |
bool | sameProduct (PlaneDataChangeTracker_t const &as) const |
Returns whether we are in the same event (the rest could differ) More... | |
bool | sameTPC (PlaneDataChangeTracker_t const &as) const |
Returns whether we have the same data product and TPC as "as". More... | |
bool | same (PlaneDataChangeTracker_t const &as) const |
Returns whether we have the same plane data as "as". More... | |
bool | isValid () const |
Returns whether there is a data product and plane. More... | |
bool | operator== (PlaneDataChangeTracker_t const &as) const |
Returns whether data product and TPC plane are the same as in "as". More... | |
bool | operator!= (PlaneDataChangeTracker_t const &than) const |
Returns whether data product or TPC plane are different than in "than". More... | |
State change | |
Forget the current data product | |
void | clear () |
Set a new event and data product label as current. More... | |
void | set (art::Event const &evt, art::InputTag const &label, geo::PlaneID const &pid) |
Set a new event and data product label as current. More... | |
bool | update (PlaneDataChangeTracker_t const &new_prod) |
Update to a new data product, return true if it has changed. More... | |
Private Member Functions | |
void | SetPlaneID (geo::PlaneID const &pid) |
State query | |
Returns the current input label | |
art::InputTag const & | inputLabel () const |
Returns whether we are in the same event (the rest could differ) More... | |
bool | sameEvent (DataProductChangeTracker_t const &as) const |
Returns whether we are in the same event (the rest could differ) More... | |
bool | same (DataProductChangeTracker_t const &as) const |
Returns whether we have same data product as in "as". More... | |
bool | operator== (DataProductChangeTracker_t const &as) const |
Returns whether the event and input label are the same as in "as". More... | |
bool | operator!= (DataProductChangeTracker_t const &than) const |
Returns whether the event or input label are different than in "than". More... | |
State query | |
Returns whether this tracker is in the same state as another | |
bool | same (EventChangeTracker_t const &as) const |
Returns whether this tracker is in the same state as another. More... | |
bool | operator== (EventChangeTracker_t const &as) const |
Returns whether this tracker is in the same state as another. More... | |
bool | operator!= (EventChangeTracker_t const &than) const |
Returns whether this tracker is in a different state than another. More... | |
State change | |
Forget the current data product | |
void | set (art::Event const &evt, art::InputTag const &label) |
Set a new event and data product label as current. More... | |
bool | update (DataProductChangeTracker_t const &new_prod) |
Update to a new data product, return true if it has changed. More... | |
State change | |
Forgets the current event | |
void | set (art::EventID const &evt_id) |
Sets the current event ID. More... | |
void | set (art::Event const &evt) |
Sets the current event ID from the given event. More... | |
bool | update (EventChangeTracker_t const &trk) |
Sets the current event, and returns true if it is changed. More... | |
Private Attributes | |
LocalState_t | state |
Detects the presence of a new event, data product or wire plane.
The state of this class describes the current data product input as the event it belongs to (by its ID) and the input tag, and the current wire plane in the TPC.
Definition at line 210 of file ChangeTrackers.h.
|
default |
Default constructor: no current plane data.
|
inline |
Constructor: specifies current data product and TPC plane.
Definition at line 216 of file ChangeTrackers.h.
|
inline |
Constructor: specifies current data product and TPC plane.
Definition at line 223 of file ChangeTrackers.h.
References util::DataProductChangeTracker_t::inputLabel().
|
inline |
Set a new event and data product label as current.
Definition at line 268 of file ChangeTrackers.h.
References util::DataProductChangeTracker_t::clear().
|
inlineinherited |
Returns whether we are in the same event (the rest could differ)
Definition at line 127 of file ChangeTrackers.h.
References util::EventChangeTracker_t::state.
Referenced by evd::details::RawDigitCacheDataClass::CheckUpToDate(), PlaneDataChangeTracker_t(), util::DataProductChangeTracker_t::same(), and evd::details::RawDigitCacheDataClass::Update().
|
inline |
Returns whether there is a data product and plane.
Definition at line 256 of file ChangeTrackers.h.
References util::DataProductChangeTracker_t::isValid().
|
inline |
Returns a string representation of event and data product label.
Definition at line 292 of file ChangeTrackers.h.
|
inlineinherited |
Returns whether this tracker is in a different state than another.
Definition at line 54 of file ChangeTrackers.h.
References util::EventChangeTracker_t::same().
|
inlineinherited |
Returns whether the event or input label are different than in "than".
Definition at line 151 of file ChangeTrackers.h.
References util::EventChangeTracker_t::same().
|
inline |
Returns whether data product or TPC plane are different than in "than".
Definition at line 262 of file ChangeTrackers.h.
References util::EventChangeTracker_t::same().
|
inlineinherited |
Returns whether this tracker is in the same state as another.
Definition at line 51 of file ChangeTrackers.h.
References util::EventChangeTracker_t::same().
|
inlineinherited |
Returns whether the event and input label are the same as in "as".
Definition at line 148 of file ChangeTrackers.h.
References util::EventChangeTracker_t::same().
|
inline |
Returns whether data product and TPC plane are the same as in "as".
Definition at line 259 of file ChangeTrackers.h.
References util::EventChangeTracker_t::same().
|
inline |
Returns the current plane ID.
Definition at line 235 of file ChangeTrackers.h.
References util::EventChangeTracker_t::state.
Referenced by same(), and sameTPC().
|
inlineinherited |
Returns whether this tracker is in the same state as another.
Definition at line 45 of file ChangeTrackers.h.
References util::EventChangeTracker_t::eventID().
Referenced by util::EventChangeTracker_t::operator!=(), util::DataProductChangeTracker_t::operator!=(), operator!=(), util::EventChangeTracker_t::operator==(), util::DataProductChangeTracker_t::operator==(), operator==(), util::DataProductChangeTracker_t::sameEvent(), util::EventChangeTracker_t::update(), util::DataProductChangeTracker_t::update(), and update().
|
inlineinherited |
Returns whether we have same data product as in "as".
Definition at line 136 of file ChangeTrackers.h.
References util::DataProductChangeTracker_t::inputLabel().
Referenced by sameProduct().
|
inline |
Returns whether we have the same plane data as "as".
Definition at line 250 of file ChangeTrackers.h.
References planeID().
|
inlineinherited |
Returns whether we are in the same event (the rest could differ)
Definition at line 130 of file ChangeTrackers.h.
References util::EventChangeTracker_t::same().
|
inline |
Returns whether we are in the same event (the rest could differ)
Definition at line 238 of file ChangeTrackers.h.
References util::DataProductChangeTracker_t::same().
Referenced by evd::details::RawDigitCacheDataClass::CheckUpToDate().
|
inline |
Returns whether we have the same data product and TPC as "as".
Definition at line 244 of file ChangeTrackers.h.
References planeID().
|
inlineinherited |
Sets the current event ID.
Definition at line 63 of file ChangeTrackers.h.
References util::EventChangeTracker_t::LocalState_t::event_id, and util::EventChangeTracker_t::state.
Referenced by util::DataProductChangeTracker_t::set().
|
inlineinherited |
Sets the current event ID from the given event.
Definition at line 66 of file ChangeTrackers.h.
References tca::evt.
|
inlineinherited |
Set a new event and data product label as current.
Definition at line 164 of file ChangeTrackers.h.
References util::EventChangeTracker_t::set().
Referenced by set().
|
inline |
Set a new event and data product label as current.
Definition at line 275 of file ChangeTrackers.h.
References util::DataProductChangeTracker_t::set().
|
inlineprivate |
Definition at line 304 of file ChangeTrackers.h.
References util::PlaneDataChangeTracker_t::LocalState_t::plane_id.
|
inlineinherited |
Sets the current event, and returns true if it is changed.
Definition at line 69 of file ChangeTrackers.h.
References util::EventChangeTracker_t::same().
|
inlineinherited |
Update to a new data product, return true if it has changed.
Definition at line 171 of file ChangeTrackers.h.
References util::EventChangeTracker_t::same().
Referenced by evd::TWQProjectionView::OnNewEvent().
|
inline |
Update to a new data product, return true if it has changed.
Definition at line 282 of file ChangeTrackers.h.
References util::EventChangeTracker_t::same().
|
private |
Definition at line 302 of file ChangeTrackers.h.