CMS 3D CMS Logo

List of all members | Public Member Functions | Private Attributes
VirtualKinematicParticleFactory Class Reference

#include <VirtualKinematicParticleFactory.h>

Public Member Functions

RefCountedKinematicParticle particle (const KinematicState &kineState, float &chiSquared, float &degreesOfFr, ReferenceCountingPointer< KinematicParticle > previousParticle, KinematicConstraint *lastConstraint=0) const
 
 VirtualKinematicParticleFactory ()
 
 VirtualKinematicParticleFactory (KinematicStatePropagator *pr)
 
 ~VirtualKinematicParticleFactory ()
 

Private Attributes

const TransientTrackKinematicStateBuilder builder
 
KinematicStatePropagatorpropagator
 

Detailed Description

Definition at line 9 of file VirtualKinematicParticleFactory.h.

Constructor & Destructor Documentation

VirtualKinematicParticleFactory::VirtualKinematicParticleFactory ( )
VirtualKinematicParticleFactory::VirtualKinematicParticleFactory ( KinematicStatePropagator pr)

Factory constructor taking a KinematicStatePropagator

Definition at line 7 of file VirtualKinematicParticleFactory.cc.

References KinematicStatePropagator::clone(), and propagator.

8 {
9  if(pr!=nullptr)
10  {
11  propagator = pr->clone();
12  }else{
14  }
15 }
virtual KinematicStatePropagator * clone() const =0
VirtualKinematicParticleFactory::~VirtualKinematicParticleFactory ( )
inline

Default destructor

Definition at line 26 of file VirtualKinematicParticleFactory.h.

References particle(), and propagator.

27  {delete propagator;}

Member Function Documentation

RefCountedKinematicParticle VirtualKinematicParticleFactory::particle ( const KinematicState kineState,
float &  chiSquared,
float &  degreesOfFr,
ReferenceCountingPointer< KinematicParticle previousParticle,
KinematicConstraint lastConstraint = 0 
) const

Method building a particle out of new created kinematic state, chi2, number of degrees of freedom and history information

Definition at line 17 of file VirtualKinematicParticleFactory.cc.

References propagator.

Referenced by FinalTreeBuilder::buildTree(), ConstrainedTreeBuilder::buildTree(), ConstrainedTreeBuilderT::buildTree(), and ~VirtualKinematicParticleFactory().

20 {
21  if(previousParticle.get() != nullptr)
22  {
23  KinematicParticle * prp = &(*previousParticle);
24  VirtualKinematicParticle * pr = dynamic_cast<VirtualKinematicParticle * >(prp);
25  if(pr == nullptr){ throw VertexException("KinematicParticleFactoryFromTransientTrack::Previous particle passed is not TransientTrack based!");}
26  }
27  return ReferenceCountingPointer<KinematicParticle>(new VirtualKinematicParticle(kineState, chiSquared, degreesOfFr,
28  lastConstraint, previousParticle, propagator));
29 }
Common base class.

Member Data Documentation

const TransientTrackKinematicStateBuilder VirtualKinematicParticleFactory::builder
private

Definition at line 39 of file VirtualKinematicParticleFactory.h.

KinematicStatePropagator* VirtualKinematicParticleFactory::propagator
private