Belle II Software  release-05-02-19
Filter.icc.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/filters/base/Filter.dcl.h>
13 
14 #include <tracking/trackFindingCDC/numerics/Weight.h>
15 
16 #include <string>
17 #include <cmath>
18 
19 namespace Belle2 {
24  class ModuleParamList;
26 }
27 
28 namespace Belle2 {
33  namespace TrackFindingCDC {
34 
35  template<class AObject>
36  Filter<AObject>::Filter() = default;
37 
38  template<class AObject>
39  Filter<AObject>::~Filter() = default;
40 
41  template <class AObject>
42  void Filter<AObject>::exposeParameters(ModuleParamList* moduleParamListw __attribute__((unused)),
43  const std::string& prefix __attribute__((unused)))
44  {
45  }
46 
47  template <class AObject>
49  {
50  return false;
51  }
52 
53  template <class AObject>
54  Weight Filter<AObject>::operator()(const Object& obj __attribute__((unused)))
55  {
56  return 1;
57  }
58 
59  template <class AObject>
61  {
62  return obj ? operator()(*obj) : NAN;
63  }
64  }
66 }
Belle2::TrackFindingCDC::Relation
Type for two related objects.
Definition: CDCSegment2D.h:37
Belle2::TrackFindingCDC::Filter::Filter
Filter()
Default constructor.
Belle2::TrackFindingCDC::Filter::~Filter
virtual ~Filter()
Make destructor of interface class virtual.
Belle2::TrackFindingCDC::Filter::operator()
virtual Weight operator()(const Object &obj)
Function to evaluate the object.
Belle2
Abstract base class for different kinds of events.
Definition: MillepedeAlgorithm.h:19
Belle2::TrackFindingCDC::Filter::needsTruthInformation
virtual bool needsTruthInformation()
Indicates if the filter requires Monte Carlo information.
Definition: Filter.icc.h:48
Belle2::TrackFindingCDC::Filter::exposeParameters
virtual void exposeParameters(ModuleParamList *moduleParamList, const std::string &prefix)
Expose the set of parameters of the filter to the module parameter list.
Definition: Filter.icc.h:42
Belle2::ModuleParamList
The Module parameter list class.
Definition: ModuleParamList.h:46