Belle II Software development
|
a container for counting accepted and rejected stuff, just delivers some interfaces to make the code more readable More...
Classes | |
struct | AcceptRejectPair |
simple struct for counting accepted and rejected cases. More... | |
Public Types | |
typedef std::vector< int > | Particles |
a vector containing IDs | |
typedef std::pair< bool, Particles > | Key |
key for the internal container of this map | |
Public Member Functions | |
CountContainer () | |
constructor. | |
void | clear () |
clear container | |
unsigned int | size () |
size of container | |
bool | IncreaseCounter (Key &aKey, bool accepted) |
accepts a key (first parameter) and if given key was accepted by the filter (second parameter) | |
AcceptRejectPair | ReturnResult (const Key &givenKey) |
for given key, the function returns the result found. | |
AcceptRejectPair | ReturnResult (const Particles &givenKey) |
for given key, the function returns the result found. | |
void | PrintResults (const string &identifier="unknown") |
for easy printing of results collected so far | |
Static Public Member Functions | |
template<class ContainerType > | |
static void | uniqueIdentifier (ContainerType &particles) |
cleans a container of double entries | |
static std::string | key2str (const Key &aKey) |
small helper for easily printing vectors | |
static std::string | key2str (const Key *aKey) |
small helper for easily printing vectors | |
template<class Type > | |
static std::string | vec2str (const vector< Type > &vec) |
small helper for easily printing vectors | |
Protected Attributes | |
std::map< Key, AcceptRejectPair > | m_container |
collects the data | |
a container for counting accepted and rejected stuff, just delivers some interfaces to make the code more readable
Definition at line 204 of file observers.cc.
key for the internal container of this map
.first is a bool which is true, if combination was from the same particle which was primary .second vector of IDs (e.g. PDG or mcParticleIDs)
Definition at line 217 of file observers.cc.
typedef std::vector<int> Particles |
a vector containing IDs
Definition at line 209 of file observers.cc.
|
inline |
constructor.
Definition at line 206 of file observers.cc.
|
inline |
clear container
Definition at line 242 of file observers.cc.
|
inline |
accepts a key (first parameter) and if given key was accepted by the filter (second parameter)
Definition at line 259 of file observers.cc.
|
inlinestatic |
small helper for easily printing vectors
Definition at line 321 of file observers.cc.
|
inlinestatic |
small helper for easily printing vectors
Definition at line 328 of file observers.cc.
|
inline |
for easy printing of results collected so far
Definition at line 306 of file observers.cc.
|
inline |
for given key, the function returns the result found.
If key was not found in container, a AcceptRejectPair with 0, 0 is returned
Definition at line 277 of file observers.cc.
|
inline |
for given key, the function returns the result found.
If key was not found in container, a AcceptRejectPair with 0, 0 is returned
Definition at line 292 of file observers.cc.
|
inline |
|
inlinestatic |
cleans a container of double entries
Definition at line 250 of file observers.cc.
|
inlinestatic |
small helper for easily printing vectors
Definition at line 342 of file observers.cc.
|
protected |
collects the data
Definition at line 353 of file observers.cc.