StRoot  1
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
StHbtPicoEvent.cc
1 /***************************************************************************
2  *
3  * $Id: StHbtPicoEvent.cc,v 1.4 2000/07/16 21:38:23 laue Exp $
4  *
5  * Author: Mike Lisa, Ohio State, lisa@mps.ohio-state.edu
6  ***************************************************************************
7  *
8  * Description: part of STAR HBT Framework: StHbtMaker package
9  * PicoEvents are last-step ultra-compressed "events" just containing
10  * bare information about the particles of interest. They have already
11  * gone through Event and Track cuts, so only Pair cuts are left.
12  * PicoEvents are *internal* to the code, and are stored in the
13  * Event-mixing buffers.
14  *
15  *
16  ***************************************************************************
17  *
18  * $Log: StHbtPicoEvent.cc,v $
19  * Revision 1.4 2000/07/16 21:38:23 laue
20  * StHbtCoulomb.cxx StHbtSectoredAnalysis.cxx : updated for standalone version
21  * StHbtV0.cc StHbtV0.hh : some cast to prevent compiling warnings
22  * StHbtParticle.cc StHbtParticle.hh : pointers mTrack,mV0 initialized to 0
23  * StHbtIOBinary.cc : some printouts in #ifdef STHBTDEBUG
24  * StHbtEvent.cc : B-Field set to 0.25Tesla, we have to think about a better
25  * solution
26  *
27  * Revision 1.3 2000/06/01 20:40:13 laue
28  * StHbtIO.cc: updated for new V0s
29  * StHbtPicoEvent.cc: collections especially cleared
30  * franks1DHistoD.hh, include changed from <stdio> to <cstdio>
31  * franks1DHistoD.cc, cout statement deleted
32  *
33  * Revision 1.2 2000/03/17 17:23:05 laue
34  * Roberts new three particle correlations implemented.
35  *
36  * Revision 1.1.1.1 1999/06/29 16:02:57 lisa
37  * Installation of StHbtMaker
38  *
39  **************************************************************************/
40 
41 #include "StHbtMaker/Infrastructure/StHbtPicoEvent.hh"
42 
43 //________________
44 StHbtPicoEvent::StHbtPicoEvent(){
45  mFirstParticleCollection = new StHbtParticleCollection;
46  mSecondParticleCollection = new StHbtParticleCollection;
47  mThirdParticleCollection = new StHbtParticleCollection;
48 }
49 //_________________
50 StHbtPicoEvent::~StHbtPicoEvent(){
51  StHbtParticleIterator iter;
52 
53 
54  if (mFirstParticleCollection){
55  for (iter=mFirstParticleCollection->begin();iter!=mFirstParticleCollection->end();iter++){
56  delete *iter;
57  }
58  mFirstParticleCollection->clear();
59  delete mFirstParticleCollection;
60  mFirstParticleCollection = 0;
61  }
62 
63  if (mSecondParticleCollection){
64  for (iter=mSecondParticleCollection->begin();iter!=mSecondParticleCollection->end();iter++){
65  delete *iter;
66  }
67  mSecondParticleCollection->clear();
68  delete mSecondParticleCollection;
69  mSecondParticleCollection = 0;
70  }
71 
72  if (mThirdParticleCollection){
73  if (mThirdParticleCollection->size() != 0 ) {
74  for (iter=mThirdParticleCollection->begin();iter!=mThirdParticleCollection->end();iter++){
75  delete *iter;
76  }
77  }
78  mThirdParticleCollection->clear();
79  delete mThirdParticleCollection;
80  mThirdParticleCollection = 0;
81  }
82 }
83 //_________________