15#include "EvtRecEvent/EvtRecTrack.h"
16#include "EvtRecEvent/EvtRecPi0.h"
17#include "EvtRecEvent/EvtRecEtaToGG.h"
18#include "EvtRecEvent/EvtRecVeeVertex.h"
19#include "DecayChain/Element/ReferenceHolder.h"
21#include "BesDChain/util/KinematicData.h"
22#include "BesDChain/CDCandidate.h"
23#include "BesDChain/CDDecay.h"
31 void CDCandidate::recover()
const {
kinematicData()->recover(); }
38 m_kinematicDataPtr(0),
39 m_footPrint( aOtherCDCandidate.footPrint() )
41 if ( 0 != aOtherCDCandidate.m_kinematicDataPtr ) {
51 m_kinematicDataPtr( 0 ) ,
52 m_footPrint( aCDFootPrint )
60 delete m_kinematicDataPtr ;
69 if ( 0 == aOtherCDCandidate.m_kinematicDataPtr ) {
70 delete m_kinematicDataPtr ;
71 m_kinematicDataPtr = 0 ;
76 m_footPrint = aOtherCDCandidate.
footPrint() ;
83 this->modifiableKinematicData()->
setUserTag( tag );
90 this->modifiableKinematicData()->
setP4( aMomentum ) ;
101 if ( 0 == m_kinematicDataPtr ) {
103 if ( 0 == m_kinematicDataPtr ) {
104 std::cerr <<
"No memory to allocate another kinematicData" << std::endl ;
109 (*(this->modifiableKinematicData())) = aKinematicData ;
119 m_footPrint = aCDFootPrint ;
127 if ( 0 == m_kinematicDataPtr ) {
129 if ( 0 == m_kinematicDataPtr ) {
130 std::cerr <<
"No memory to allocate another kinematicData" << std::endl ;
134 return m_kinematicDataPtr ;
189 return ( (*(
CDCandidate*)
this).modifiableKinematicData() );
206 final.first.push_back( cand.
track() );
211 final.second.push_back( cand.
photon() );
215 const vector< ReferenceHolder<CDCandidate> >& children =
decay.
children();
216 vector< ReferenceHolder<CDCandidate> >::const_iterator lastChild = children.end();
218 child != lastChild; ++child)
238 std::cerr <<
"No navtrack for this CDCandidate" << std::endl ;
258 std::cerr <<
"No NavShower for this CDCandidate" << std::endl ;
278 std::cerr <<
"No NavCDPi0 for this CDCandidate" << std::endl ;
298 std::cerr <<
"No NavCDEta for this CDCandidate" << std::endl ;
318 std::cerr <<
"No NavKs for this CDCandidate" << std::endl ;
338 std::cerr <<
"No NavLambda for this CDCandidate" << std::endl ;
358 std::cerr <<
"No CDDecay for this CDCandidate" << std::endl ;
377 return ( m_footPrint ) ;
const CDFootPrint & footPrint() const
void setKinematicData(const DecayChain::KinematicData &aKinematicData)
virtual bool builtFromCDPi0() const
virtual const DecayEvidence & decay() const
virtual bool builtFromCDEta() const
virtual const EvtRecTrack * photon() const
virtual DecayChain::KinematicData * defaultKinematicData() const =0
CDCandidate & setP4(const HepLorentzVector &aMomentum)
virtual bool builtFromCDLambda() const
virtual const EvtRecVeeVertex * navLambda() const
CDCandidate(const CDCandidate &aOtherCDCandidate)
virtual const EvtRecTrack * track() const
const Hep3Vector & momentum() const
const CDCandidate & operator=(const CDCandidate &aOtherCDCandidate)
virtual bool builtFromCDPhoton() const
virtual bool builtFromTrack() const
const HepLorentzVector & p4() const
virtual const EvtRecVeeVertex * navKshort() const
TracksAndShowers finalChildren() const
const DecayChain::KinematicData * kinematicData() const
virtual bool builtFromCDDecay() const
virtual bool builtFromCDKs() const
virtual const EvtRecPi0 * navPi0() const
void recurseNode(TracksAndShowers &final, const CDCandidate &cand) const
bool overlap(const CDCandidate &aOtherCDCandidate) const
virtual const EvtRecEtaToGG * navEta() const
std::pair< vector< const EvtRecTrack * >, vector< const EvtRecTrack * > > TracksAndShowers
void setCDFootPrint(const CDFootPrint &aCDFootPrint)
const std::vector< dchain::ReferenceHolder< CDCandidate > > & children() const
void setP4(const HepLorentzVector &aMomentum)
void setUserTag(const int tag)
const HepLorentzVector & p4() const