Belle II Software  release-05-01-25
HitGapSegmentPairVarSet.h
1 /**************************************************************************
2  * BASF2 (Belle Analysis Framework 2) *
3  * Copyright(C) 2015 - Belle II Collaboration *
4  * *
5  * Author: The Belle II Collaboration *
6  * Contributors: Oliver Frost *
7  * *
8  * This software is provided "as is" without any warranty. *
9  **************************************************************************/
10 #pragma once
11 
12 #include <tracking/trackFindingCDC/varsets/VarSet.h>
13 #include <tracking/trackFindingCDC/varsets/VarNames.h>
14 
15 namespace Belle2 {
20  namespace TrackFindingCDC {
21  class CDCSegmentPair;
22 
24  constexpr
25  static char const* const hitGapSegmentPairVarNames[] = {
26  "delta_hit_pos_phi",
27  "delta_hit_mom_phi",
28  "delta_hit_alpha",
29 
30  "hit_distance",
31  "hit_long_distance",
32  "delta_hit_distance",
33 
34  "from_hit_forward",
35  "to_hit_forward",
36  "hit_forward",
37 
38  "hit_reco_z",
39  "hit_z_bound_factor",
40  "hit_arclength_gap",
41  };
42 
44  struct HitGapSegmentPairVarNames : public VarNames<CDCSegmentPair> {
45 
47  static const size_t nVars = size(hitGapSegmentPairVarNames);
48 
50  static constexpr char const* getName(int iName)
51  {
52  return hitGapSegmentPairVarNames[iName];
53  }
54  };
55 
60  class HitGapSegmentPairVarSet : public VarSet<HitGapSegmentPairVarNames> {
61 
62  public:
64  bool extract(const CDCSegmentPair* ptrSegmentPair) override;
65  };
66  }
68 }
Belle2::TrackFindingCDC::CDCSegmentPair
Class representing a pair of one reconstructed axial segement and one stereo segment in adjacent supe...
Definition: CDCSegmentPair.h:44
Belle2::TrackFindingCDC::HitGapSegmentPairVarSet::extract
bool extract(const CDCSegmentPair *ptrSegmentPair) override
Generate and assign the contained variables.
Definition: HitGapSegmentPairVarSet.cc:22
Belle2::TrackFindingCDC::HitGapSegmentPairVarNames::getName
static constexpr char const * getName(int iName)
Getter for the name at the given index.
Definition: HitGapSegmentPairVarSet.h:58
Belle2::TrackFindingCDC::HitGapSegmentPairVarSet
Class to compute floating point variables from an axial stereo segment pair which can be recorded as ...
Definition: HitGapSegmentPairVarSet.h:68
Belle2
Abstract base class for different kinds of events.
Definition: MillepedeAlgorithm.h:19
Belle2::TrackFindingCDC::VarSet
Generic class that generates some named float values from a given object.
Definition: VarSet.h:46
Belle2::TrackFindingCDC::HitGapSegmentPairVarNames::nVars
static const size_t nVars
Number of variables to be generated.
Definition: HitGapSegmentPairVarSet.h:55