/home/bes3soft/bes3soft/Boss/7.0.2/dist/7.0.2/Event/BesDChain/BesDChain-00-00-14/src/CDLambda.cxx

Go to the documentation of this file.
00001 // -*- C++ -*-
00002 //
00003 // Package:     <CleoDChain>
00004 // Module:      CDLambda
00005 // 
00006 // Description: <one line class summary>
00007 //
00008 // Implementation:
00009 //     <Notes on implementation>
00010 //
00011 // Author:      David Urner
00012 // Created:     Thu Mar 22 16:23:36 EST 2001
00013 // $Id: CDLambda.cxx,v 1.2 2009/07/15 10:56:41 zoujh Exp $
00014 //
00015 // Revision history
00016 //
00017 // $Log: CDLambda.cxx,v $
00018 // Revision 1.2  2009/07/15 10:56:41  zoujh
00019 // *** empty log message ***
00020 //
00021 // Revision 1.1  2009/06/22 14:55:48  zoujh
00022 // See ChangeLog
00023 //
00024 // Revision 1.1.1.1  2009/03/03 06:05:56  maqm
00025 // first import of BesDChain
00026 //
00027 // Revision 1.4  2006/01/11 20:37:25  cdj
00028 // work with renaming done in DChain package
00029 //
00030 // Revision 1.3  2003/05/15 19:58:09  cdj
00031 // revamped memory handling so always use a ReferenceHolder to deal with the reference counting
00032 //
00033 // Revision 1.2  2001/11/06 15:20:46  ajm36
00034 // override defaultKinematicData for pi0, eta, ks, lambda
00035 //
00036 // Revision 1.1  2001/09/11 15:08:27  ajm36
00037 // add files for lambdas
00038 //
00039 // Revision 1.2  2001/04/25 12:52:12  ajm36
00040 // plugged memory leak in ctor for pi0's, k shorts, etas
00041 //
00042 // Revision 1.1  2001/04/11 13:19:02  urner
00043 // transition to files with CD prefix. Addition of new files
00044 //
00045 // Revision 1.2  2001/03/24 03:07:56  cdj
00046 // fixed CDPi0 CDLambda and CDEta classes so could properly assess info from CDCandidate class
00047 //
00048 // Revision 1.1  2001/03/23 23:05:28  urner
00049 // added pi0 eta and CDLambda decay lists
00050 //
00051 
00052 
00053 // user include files
00054 #include "EvtRecEvent/EvtRecVeeVertex.h"
00055 #include "BesDChain/util/KinematicData.h"
00056 #include "BesDChain/CDChargedPion.h"
00057 #include "BesDChain/CDProton.h"
00058 #include "BesDChain/CDLambda.h"
00059 
00060 
00061 //
00062 // constants, enums and typedefs
00063 //
00064 using namespace dchain;
00065 
00066 //
00067 // static data member definitions
00068 //
00069 
00070 //
00071 // constructors and destructor
00072 //
00073 CDLambda::CDLambda(const EvtRecVeeVertex* aVisible):
00074 //  CDDecay(*(new CDChargedPion(aVisible.piPlus()))),
00075   m_lambda(aVisible)
00076 {
00077    EvtRecVeeVertex* lambda = const_cast<EvtRecVeeVertex*>(aVisible);
00078 
00079    int index[2]  = {0, 1};
00080    if (aVisible->vertexId() < 0) {
00081       index[0] = 1;
00082       index[1] = 0;
00083    }
00084 
00085    ReferenceHolder<CDProton> tmp = new CDProton(lambda->daughter(index[0]));
00086    addChild(*tmp);
00087    ReferenceHolder<CDChargedPion> tmp2 = new CDChargedPion(lambda->daughter(index[1]));
00088    addChild(*tmp2);
00089 }
00090 
00091 
00092 // CDLambda::CDLambda( const CDLambda& rhs )
00093 // {
00094 //    // do actual copying here; if you implemented
00095 //    // operator= correctly, you may be able to use just say      
00096 //    *this = rhs;
00097 // }
00098 
00099 CDLambda::~CDLambda()
00100 {
00101 }
00102 
00103 
00104 //------ buildFromCDLambda -----
00105 // return `true' as CDLambda is made up from VisibleEvidence
00106 //
00107 bool CDLambda::builtFromCDLambda() const
00108 {
00109    return true;
00110 }
00111 
00112 
00113 //------ CDLambda -----
00114 // return NavLambda for this CDLambda
00115 //
00116 const EvtRecVeeVertex* CDLambda::navLambda() const
00117 {
00118    return m_lambda ;
00119 }
00120 
00121 KinematicData* CDLambda::defaultKinematicData() const
00122 {
00123    KinematicData* data = new KinematicData();
00124 
00125    const HepVector& w_lambda = m_lambda->w();
00126 
00127    data->setP4( HepLorentzVector(w_lambda[0], w_lambda[1], w_lambda[2], w_lambda[3]) );
00128 
00129    return data;
00130 }

Generated on Tue Nov 29 22:58:19 2016 for BOSS_7.0.2 by  doxygen 1.4.7