BOSS 8.0.0
BESIII Offline Software System
Loading...
Searching...
No Matches
Event/BesDChain/include/BesDChain/CDDecay.h
Go to the documentation of this file.
1#ifndef CLEODCHAIN_CDDECAY_H
2#define CLEODCHAIN_CDDECAY_H
3// -*- C++ -*-
4//
5// Package: CleoDChain
6// Module: CDDecay
7//
8// Description: CDDecay candidate built from other candidates
9//
10// Usage:
11// <usage>
12//
13// Author: Simon Patton
14// Created: Wed Sep 18 14:47:30 EDT 1996
15// $Id: CDDecay.h,v 1.2 2009/09/22 08:24:41 hujf Exp $
16//
17// Revision history
18//
19// $Log: CDDecay.h,v $
20// Revision 1.2 2009/09/22 08:24:41 hujf
21// see ChangeLog
22//
23// Revision 1.1.1.1 2009/03/03 06:05:56 maqm
24// first import of BesDChain
25//
26// Revision 1.8 2006/03/17 19:36:47 ponyisi
27// Fix mcParticle() to use gammaFSR when available while doing matching
28//
29// Revision 1.7 2006/01/11 20:37:28 cdj
30// work with renaming done in DChain package
31//
32// Revision 1.6 2004/10/19 13:39:38 cdj
33// removed unimplemented CDDecay::parent() method
34//
35// Revision 1.5 2004/06/02 23:24:55 ryd
36// Made constructor of CDDecay from CDCandidate explicit
37//
38// Revision 1.4 2004/03/05 22:01:49 chengp
39// implemented Monte Carlo matching
40//
41// Revision 1.3 2003/05/15 19:58:15 cdj
42// revamped memory handling so always use a ReferenceHolder to deal with the reference counting
43//
44// Revision 1.2 2002/04/09 20:54:19 lyon
45// Added CDDecay::setKinematicData
46//
47// Revision 1.1 2001/04/11 13:19:14 urner
48// transition to files with CD prefix. Addition of new files
49//
50// Revision 1.3 2001/04/04 15:16:50 cdj
51// added a protected default constructor (used for storage)
52//
53// Revision 1.2 2001/04/03 17:25:57 cdj
54// changed isCDDecay to builtFromCDDecay
55//
56// Revision 1.1.1.1 2000/12/18 22:17:26 cdj
57// imported CleoDChain
58//
59// Revision 1.11 1998/04/17 18:49:12 sjp
60// Modifed to use latest CLEO types
61//
62// Revision 1.10 1997/09/03 14:58:43 sjp
63// Use new report.h and KTKinematicData
64//
65// Revision 1.9 1997/08/29 17:01:19 sjp
66// Modified to handle new CDDecay Templated classes
67//
68// Revision 1.8 1997/08/26 04:02:08 sjp
69// Added typedef for CandidateClass
70//
71// Revision 1.7 1997/08/19 23:01:40 sjp
72// Restructured package to be independent of CleoDChain
73//
74// Revision 1.6 1997/08/19 20:41:37 sjp
75// Updated to use <package>/<file>.h include structure.
76// (Note: This version of the code has not been compiled)
77//
78// Revision 1.5 1997/01/31 20:10:20 sjp
79// Modified to use the new `bug' include files
80//
81// Revision 1.4 1997/01/21 20:30:25 sjp
82// Changed CPP flags and include because of library reorganization
83//
84// Revision 1.3 1997/01/19 20:32:06 sjp
85// Changed LargeCount to Count
86//
87// Revision 1.2 1996/12/20 20:59:50 sjp
88// Extended pathname for Includes.
89//
90// Revision 1.1 1996/11/04 17:01:57 sjp
91// New class for CDDecay CDCandidate
92//
93
94// system include files
95#include <stdint.h>
96#include <vector>
97
98// user include files
99#include "BesDChain/CDCandidate.h" // superclass
100#include "DecayChain/Element/DCChildren.h" // For enumerator
101#include "DecayChain/Element/ReferenceHolder.h"
102
103// forward declarations
104template <class Arg> class DCAnalysisFunction;
105
106namespace DecayChain {
107 class KinematicData;
108}
109
110class CDDecay : public CDCandidate {
111 // friend classses and functions
112
113public:
114 // constants, enums and typedefs
116
117 // Constructors and destructor
118 CDDecay( const CDDecay& aOtherCDDecay );
119 explicit CDDecay( const CDCandidate& aProduct );
120 CDDecay( const CDDecay& aProducts, const CDCandidate& aAdditionalProduct );
121 virtual ~CDDecay();
122
123 // member functions
124 void addChild( const CDCandidate& aAdditionalProduct );
125
126 // Replace the KinematicData for this decay. Useful for
127 // saving results of a fit.
128 void setKinematicData( const DecayChain::KinematicData& aKinematicData );
129
130 // const member functions
131 virtual bool builtFromCDDecay( void ) const;
132 virtual const CDDecay& decay( void ) const;
133 uint32_t numberChildren() const;
134 void iterateChildren( void ( *analyze )( const CDCandidate& ) ) const;
136 const CDCandidate& child( unsigned int aPosition ) const;
137 const std::vector<dchain::ReferenceHolder<CDCandidate>>& children() const;
138 // static member functions
139 // add for kinematic fit
140#ifdef EXTEND
141 double chisq() const { return m_kmfit_chisq; }
142 void chisq( double c ) { m_kmfit_chisq = c; }
143 double vchisq() const { return m_vxfit_chisq; }
144 void vchisq( double c ) { m_vxfit_chisq = c; }
145
146protected:
147 double m_kmfit_chisq;
148 double m_vxfit_chisq;
149#endif
150protected:
151 // Constructors and destructor
152 CDDecay(); // used for storage
153
154 // protected member functions
155 virtual DecayChain::KinematicData* defaultKinematicData() const;
156
157private:
158 // Constructors and destructor
159
160 // assignment operator(s)
161 const CDDecay& operator=( const CDDecay& aOtherCDDecay ); // stop default
162
163 // private member functions
164
165 // data members
166 std::vector<dchain::ReferenceHolder<CDCandidate>>& m_children;
167
168 // static data members
169};
170
171typedef const CDDecay& FixedCDDecay;
173
174// inline function definitions
175
176#endif /* CLEODCHAIN_CDDECAY_H */
CDCandidate(const CDCandidate &aOtherCDCandidate)
virtual DecayChain::KinematicData * defaultKinematicData() const
Definition CDDecay.cxx:244
virtual bool builtFromCDDecay(void) const
Definition CDDecay.cxx:202
void addChild(const CDCandidate &aAdditionalProduct)
Definition CDDecay.cxx:188
void setKinematicData(const DecayChain::KinematicData &aKinematicData)
Definition CDDecay.cxx:193
const CDCandidate & child(unsigned int aPosition) const
Definition CDDecay.cxx:231
uint32_t numberChildren() const
Definition CDDecay.cxx:209
void iterateChildren(void(*analyze)(const CDCandidate &)) const
Definition CDDecay.cxx:214
virtual ~CDDecay()
Definition CDDecay.cxx:161
virtual const CDDecay & decay(void) const
Definition CDDecay.cxx:204
CDDecay(const CDDecay &aOtherCDDecay)
Definition CDDecay.cxx:126
const std::vector< dchain::ReferenceHolder< CDCandidate > > & children() const
Definition CDDecay.cxx:240