Belle II Software
release-08-01-10
|
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 More... | |
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. More... | |
AcceptRejectPair | ReturnResult (const Particles &givenKey) |
for given key, the function returns the result found. More... | |
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.
|
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.