Belle II Software  release-05-01-25
BasicAxialSegmentPairVarSet.h
1 /**************************************************************************
2  * BASF2 (Belle Analysis Framework 2) *
3  * Copyright(C) 2016 - 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 CDCAxialSegmentPair;
22 
24  constexpr
25  static char const* const basicAxialSegmentPairVarNames[] = {
26  "stereo_kind",
27  "from_size",
28  "to_size",
29  "from_n_layers",
30  "to_n_layers",
31  "sl_id",
32  };
33 
35  struct BasicAxialSegmentPairVarNames : public VarNames<CDCAxialSegmentPair > {
36 
38  static const size_t nVars = size(basicAxialSegmentPairVarNames);
39 
41  static constexpr char const* getName(int iName)
42  {
43  return basicAxialSegmentPairVarNames[iName];
44  }
45  };
46 
51  class BasicAxialSegmentPairVarSet : public VarSet<BasicAxialSegmentPairVarNames> {
52 
53  public:
55  bool extract(const CDCAxialSegmentPair* ptrAxialSegmentPair) override;
56  };
57  }
59 }
Belle2::TrackFindingCDC::BasicAxialSegmentPairVarSet::extract
bool extract(const CDCAxialSegmentPair *ptrAxialSegmentPair) override
Generate and assign the contained variables.
Definition: BasicAxialSegmentPairVarSet.cc:33
Belle2::TrackFindingCDC::BasicAxialSegmentPairVarNames::getName
static constexpr char const * getName(int iName)
Getter for the name at the given index.
Definition: BasicAxialSegmentPairVarSet.h:49
Belle2::TrackFindingCDC::CDCAxialSegmentPair
Class representing a pair of reconstructed axial segements in adjacent superlayer.
Definition: CDCAxialSegmentPair.h:41
Belle2
Abstract base class for different kinds of events.
Definition: MillepedeAlgorithm.h:19
Belle2::TrackFindingCDC::BasicAxialSegmentPairVarNames::nVars
static const size_t nVars
Number of variables to be generated.
Definition: BasicAxialSegmentPairVarSet.h:46
Belle2::TrackFindingCDC::BasicAxialSegmentPairVarSet
Class to compute floating point variables from a segment relation which can be recorded as a flat TNt...
Definition: BasicAxialSegmentPairVarSet.h:59
Belle2::TrackFindingCDC::VarSet
Generic class that generates some named float values from a given object.
Definition: VarSet.h:46