Jpp 21.0.1
the software that should make you happy
Loading...
Searching...
No Matches
has_history Struct Reference

Auxiliary class to test whether given track has specified history. More...

#include <reconstruction.hh>

Public Member Functions

 has_history (const int type, const rec_stages_range range)
 Constructor.
 
bool operator() (const Trk &track) const
 

Public Attributes

const int type
 reconstruction type
 
const rec_stages_range range
 range of application types
 

Detailed Description

Auxiliary class to test whether given track has specified history.


The history of a track consists of a reconstruction type and a range of application types.

Definition at line 130 of file tools/reconstruction.hh.

Constructor & Destructor Documentation

◆ has_history()

has_history::has_history ( const int type,
const rec_stages_range range )
inline

Constructor.

Parameters
typereconstruction type
rangerange of application types

Definition at line 137 of file tools/reconstruction.hh.

137 :
138 type (type),
139 range(range)
140 {}
const int type
reconstruction type
const rec_stages_range range
range of application types

Member Function Documentation

◆ operator()()

bool has_history::operator() ( const Trk & track) const
inline
Parameters
tracktrack
Returns
true if given track has specified history; else false

Definition at line 146 of file tools/reconstruction.hh.

147 {
148 if (track.rec_type == type)
149 return std::find_if(track.rec_stages.begin(), track.rec_stages.end(), range) != track.rec_stages.end();
150 else
151 return false;
152 }
std::vector< int > rec_stages
list of identifiers of successful fitting stages resulting in this track
Definition Trk.hh:26
int rec_type
identifier of the fitting algorithm/chain/strategy, see km3net-dataformat/definitions/reconstruction....
Definition Trk.hh:25

Member Data Documentation

◆ type

const int has_history::type

reconstruction type

Definition at line 154 of file tools/reconstruction.hh.

◆ range

const rec_stages_range has_history::range

range of application types

Definition at line 155 of file tools/reconstruction.hh.


The documentation for this struct was generated from the following file: