"AliRawDataErrorLogs"};
//______________________________________________________________________________
AliESDEvent::AliESDEvent():
+ AliVEvent(),
fESDObjects(new TList()),
fESDRun(0),
fHeader(0),
}
//______________________________________________________________________________
AliESDEvent::AliESDEvent(const AliESDEvent& esd):
- TObject(esd),
+ AliVEvent(esd),
fESDObjects(new TList()),
fESDRun(new AliESDRun(*esd.fESDRun)),
fHeader(new AliESDHeader(*esd.fHeader)),
// Assignment operator
if(&source == this) return *this;
- TObject::operator=(source);
+ AliVEvent::operator=(source);
fESDRun = new AliESDRun(*source.fESDRun);
fHeader = new AliESDHeader(*source.fHeader);
if(fESDTZERO) fESDTZERO->Reset();
// CKB no clear/reset implemented
if(fSPDVertex){
+ fSPDVertex->~AliESDVertex();
new (fSPDVertex) AliESDVertex();
fSPDVertex->SetName(fESDListName[kSPDVertex]);
}
if(fPrimaryVertex){
+ fPrimaryVertex->~AliESDVertex();
new (fPrimaryVertex) AliESDVertex();
fPrimaryVertex->SetName(fESDListName[kPrimaryVertex]);
}
- if(fSPDMult)new (fSPDMult) AliMultiplicity();
+ if(fSPDMult){
+ fSPDMult->~AliMultiplicity();
+ new (fSPDMult) AliMultiplicity();
+ }
if(fPHOSTrigger)fPHOSTrigger->Reset();
if(fEMCALTrigger)fEMCALTrigger->Reset();
- if(fTracks)fTracks->Clear();
+ if(fTracks)fTracks->Delete();
if(fMuonTracks)fMuonTracks->Clear();
if(fPmdTracks)fPmdTracks->Clear();
if(fTrdTracks)fTrdTracks->Clear();
if(fV0s)fV0s->Clear();
if(fCascades)fCascades->Clear();
if(fKinks)fKinks->Clear();
- if(fCaloClusters)fCaloClusters->Clear();
+ if(fCaloClusters)fCaloClusters->Delete();
if(fErrorLogs) fErrorLogs->Clear();
// don't reset fconnected fConnected ;
printf(" emcal %d\n", GetNumberOfEMCALClusters());
printf(" FMD %s\n", (fESDFMD ? "yes" : "no"));
printf(" VZERO %s\n", (fESDVZERO ? "yes" : "no"));
+
+ return;
}
void AliESDEvent::SetESDfriend(const AliESDfriend *ev) {
}
}
+Bool_t AliESDEvent::RemoveTrack(Int_t /*i*/) {
+ // ---------------------------------------------------------
+ // Remove track
+ // ---------------------------------------------------------
+
+ // Check if this track comes from a reconstructed decay
+ // if (yes) return kFALSE
+
+ // Remap the indices of the daughters of recosntructed decays
+
+ // Remove the track
+ // delete fTracks->RemoveAt(i);
+
+ // Compress the array with tracks
+ // fTracks->Compress();
+
+ return kTRUE;
+}
+
+
Int_t AliESDEvent::AddTrack(const AliESDtrack *t) {
// Add track
TClonesArray &ftr = *fTracks;
void AliESDEvent::SetVertex(const AliESDVertex *vertex) {
// use already allocated space
if(fSPDVertex){
- new(fSPDVertex) AliESDVertex(*vertex);
+ *fSPDVertex = *vertex;
fSPDVertex->SetName(fESDListName[kSPDVertex]);
}
}
void AliESDEvent::SetPrimaryVertex(const AliESDVertex *vertex) {
- // use already allocated space
if(fPrimaryVertex){
- new(fPrimaryVertex) AliESDVertex(*vertex);
+ *fPrimaryVertex = *vertex;
fPrimaryVertex->SetName(fESDListName[kPrimaryVertex]);
}
}
void AliESDEvent::SetMultiplicity(const AliMultiplicity *mul) {
if(fSPDMult){
- new (&fSPDMult) AliMultiplicity(*mul);
+ *fSPDMult = *mul;
}
}
void AliESDEvent::SetFMDData(AliESDFMD * obj) {
// use already allocated space
if(fESDFMD){
- new(fESDFMD) AliESDFMD(*obj);
+ *fESDFMD = *obj;
}
}
SetStdNames();
// read back pointers
GetStdContent();
-
-
-
}
TObject* AliESDEvent::FindListObject(const char *name){
}
void AliESDEvent::ReadFromTree(TTree *tree){
-
-
+
+ // load the TTree
+ tree->LoadTree(0);
+
// if we find the "ESD" branch on the tree we do have the old structure
if(tree->GetBranch("ESD")){
char ** address = (char **)(tree->GetBranch("ESD")->GetAddress());
// leave amps out
// VZERO
- SetVZEROData(fESDOld->GetVZEROData());
+ if (fESDOld->GetVZEROData()) SetVZEROData(fESDOld->GetVZEROData());
SetVertex(fESDOld->GetVertex());