Belle II Software  release-05-01-25
RecoParticle.cc
1 /**************************************************************************
2  * BASF2 (Belle Analysis Framework 2) *
3  * Copyright(C) 2018 - Belle II Collaboration *
4  * *
5  * Author: The Belle II Collaboration *
6  * Contributor: Wouter Hulsbergen, Francesco Tenchini, Jo-Frederik Krohn *
7  * *
8  * This software is provided "as is" without any warranty. *
9  **************************************************************************/
10 
11 #include <analysis/VertexFitting/TreeFitter/RecoParticle.h>
12 #include <analysis/VertexFitting/TreeFitter/FitParams.h>
13 
14 namespace TreeFitter {
15 
16  RecoParticle::RecoParticle(Belle2::Particle* particle, const ParticleBase* mother)
17  : ParticleBase(particle, mother) {}
18 
19  ErrCode RecoParticle::initMotherlessParticle([[gnu::unused]] FitParams& fitparams)
20  {
21  return ErrCode(ErrCode::Status::success);
22  }
23 
24  std::string RecoParticle::parname(int index) const
25  {
26  return ParticleBase::parname(index + 4);
27  }
28 
30  {
31  ErrCode status ;
32  switch (type) {
33  case Constraint::track :
34  case Constraint::photon :
35  case Constraint::klong :
36  status |= projectRecoConstraint(fitparams, p);
37  break ;
38  default:
39  status |= ParticleBase::projectConstraint(type, fitparams, p);
40  }
41  return status;
42  }
43 
44 }
TreeFitter::ParticleBase::projectConstraint
virtual ErrCode projectConstraint(Constraint::Type, const FitParams &, Projection &) const
project constraint.
Definition: ParticleBase.cc:537
TreeFitter::RecoParticle::RecoParticle
RecoParticle(Belle2::Particle *bc, const ParticleBase *mother)
hier koennte ihre werbung stehen
Definition: RecoParticle.cc:24
TreeFitter::ErrCode
abstract errorocode be aware that the default is succes
Definition: ErrCode.h:23
TreeFitter::ParticleBase::type
virtual int type() const =0
get particle type
TreeFitter::FitParams
Class to store and manage fitparams (statevector)
Definition: FitParams.h:29
TreeFitter::RecoParticle::parname
virtual std::string parname(int index) const override
name
Definition: RecoParticle.cc:32
TreeFitter::RecoParticle::initMotherlessParticle
virtual ErrCode initMotherlessParticle(FitParams &fitparams) override
init particle without mother
Definition: RecoParticle.cc:27
TreeFitter::Constraint::Type
Type
type of constraints the order of these constraints is important: it is the order in which they are ap...
Definition: Constraint.h:36
TreeFitter::ParticleBase::index
int index() const
get index
Definition: ParticleBase.h:112
TreeFitter::RecoParticle::projectRecoConstraint
virtual ErrCode projectRecoConstraint(const FitParams &fitparams, Projection &p) const =0
abstract projection
TreeFitter::ParticleBase::parname
virtual std::string parname(int index) const
get name of parameter i
Definition: ParticleBase.cc:304
Belle2::Particle
Class to store reconstructed particles.
Definition: Particle.h:77
TreeFitter::RecoParticle::projectConstraint
virtual ErrCode projectConstraint(Constraint::Type, const FitParams &, Projection &) const override
abstract abstract projection
Definition: RecoParticle.cc:37
TreeFitter::Projection
class to store the projected residuals and the corresponding jacobian as well as the covariance matri...
Definition: Projection.h:27