PandaRoot
DecayTreeFitter::Constraint Class Reference

#include <Constraint.h>

Inheritance diagram for DecayTreeFitter::Constraint:
DecayTreeFitter::MergedConstraint

Public Types

enum  Type {
  unknown = 0, beamspot, lifetime, resonance,
  composite, track, photon, conversion,
  kinematic, massEnergy, geometric, mass,
  beamenergy, merged, ntypes
}
 

Public Member Functions

bool operator< (const Constraint &rhs) const
 
bool operator== (const Constraint &rhs) const
 
Type type () const
 
unsigned int dim () const
 
bool isLineair () const
 
unsigned int nIter () const
 
 Constraint ()
 
 Constraint (const ParticleBase *node, Type atype, int depth, unsigned int adim, int maxniter=1)
 
virtual ~Constraint ()
 
virtual ErrCode project (const FitParams *fitpar, Projection &p) const
 
virtual ErrCode filter (FitParams *fitpar) const
 
virtual ErrCode filter (FitParams *fitpar, const FitParams *reference) const
 
virtual void print (std::ostream &os=std::cout) const
 
std::string name () const
 
void setWeight (int w)
 

Protected Member Functions

 Constraint (Constraint::Type atype)
 
void setDim (unsigned int d)
 
void setNIter (unsigned int d)
 

Detailed Description

Definition at line 21 of file Constraint.h.

Member Enumeration Documentation

◆ Type

Constructor & Destructor Documentation

◆ Constraint() [1/3]

DecayTreeFitter::Constraint::Constraint ( )
inline

Definition at line 38 of file Constraint.h.

38 : m_node(nullptr), m_depth(0), m_type(unknown), m_dim(0) {}

◆ Constraint() [2/3]

DecayTreeFitter::Constraint::Constraint ( const ParticleBase node,
Type  atype,
int  depth,
unsigned int  adim,
int  maxniter = 1 
)
inline

Definition at line 40 of file Constraint.h.

41  : m_node(node), m_depth(depth), m_type(atype), m_dim(adim), m_weight(1), m_maxNIter(maxniter)
42  {
43  }

◆ ~Constraint()

virtual DecayTreeFitter::Constraint::~Constraint ( )
inlinevirtual

Definition at line 45 of file Constraint.h.

References filter(), name(), print(), and project().

45 {}

◆ Constraint() [3/3]

DecayTreeFitter::Constraint::Constraint ( Constraint::Type  atype)
inlineprotected

Definition at line 57 of file Constraint.h.

57 : m_node(nullptr), m_depth(0), m_type(atype), m_dim(0), m_weight(0), m_maxNIter(0) {}

Member Function Documentation

◆ dim()

unsigned int DecayTreeFitter::Constraint::dim ( ) const
inline

Definition at line 34 of file Constraint.h.

Referenced by DecayTreeFitter::MergedConstraint::push_back().

34 { return m_dim; }

◆ filter() [1/2]

virtual ErrCode DecayTreeFitter::Constraint::filter ( FitParams fitpar) const
virtual

Referenced by ~Constraint().

◆ filter() [2/2]

virtual ErrCode DecayTreeFitter::Constraint::filter ( FitParams fitpar,
const FitParams reference 
) const
virtual

◆ isLineair()

bool DecayTreeFitter::Constraint::isLineair ( ) const
inline

Definition at line 35 of file Constraint.h.

35 { return m_maxNIter <= 1; }

◆ name()

std::string DecayTreeFitter::Constraint::name ( ) const

Referenced by ~Constraint().

◆ nIter()

unsigned int DecayTreeFitter::Constraint::nIter ( ) const
inline

Definition at line 36 of file Constraint.h.

Referenced by DecayTreeFitter::MergedConstraint::push_back().

36 { return m_maxNIter; }

◆ operator<()

bool DecayTreeFitter::Constraint::operator< ( const Constraint rhs) const

◆ operator==()

bool DecayTreeFitter::Constraint::operator== ( const Constraint rhs) const
inline

Definition at line 30 of file Constraint.h.

30 { return m_type == rhs.m_type; }

◆ print()

virtual void DecayTreeFitter::Constraint::print ( std::ostream &  os = std::cout) const
virtual

Reimplemented in DecayTreeFitter::MergedConstraint.

Referenced by ~Constraint().

◆ project()

virtual ErrCode DecayTreeFitter::Constraint::project ( const FitParams fitpar,
Projection p 
) const
virtual

Reimplemented in DecayTreeFitter::MergedConstraint.

Referenced by ~Constraint().

◆ setDim()

void DecayTreeFitter::Constraint::setDim ( unsigned int  d)
inlineprotected

◆ setNIter()

void DecayTreeFitter::Constraint::setNIter ( unsigned int  d)
inlineprotected

Definition at line 59 of file Constraint.h.

Referenced by DecayTreeFitter::MergedConstraint::push_back().

59 { m_maxNIter = d; }

◆ setWeight()

void DecayTreeFitter::Constraint::setWeight ( int  w)
inline

Definition at line 54 of file Constraint.h.

54 { m_weight = w < 0 ? -1 : 1; }

◆ type()

Type DecayTreeFitter::Constraint::type ( ) const
inline

Definition at line 33 of file Constraint.h.

33 { return m_type; }

The documentation for this class was generated from the following file: