// Empty ctor.
//
AliDebug(1,Form("this=%p Empty ctor",this));
+#ifdef WITH_ROOT
+ fPCBs.SetOwner(kTRUE);
+#endif
+ fManuMap.SetOwner(kFALSE);
}
//_____________________________________________________________________________
// Normal ctor
//
AliDebug(1,Form("this=%p id=%s",this,id));
+#ifdef WITH_ROOT
+ fPCBs.SetOwner(kTRUE);
+#endif
+ fManuMap.SetOwner(kFALSE);
}
//_____________________________________________________________________________
// Dtor.
//
AliDebug(1,Form("this=%p fId=%s",this,fId.Data()));
+#ifdef WITH_ROOT
+ fPCBs.Delete();
+#else
+ for ( size_t i = 0; i < fPCBs.size(); ++i )
+ {
+ delete fPCBs[i];
+ }
+#endif
}
//_____________________________________________________________________________
void
-AliMpSlat::Add(AliMpPCB* pcbType, const TArrayI& manuList)
+AliMpSlat::Add(const AliMpPCB& pcbType, const TArrayI& manuList)
{
//
// Adds a PCB to this slat. The manuList specifies the ids of the manu
}
else
{
- ixOffset = pcbType->Ixmin();
+ ixOffset = pcbType.Ixmin();
}
Double_t xOffset = DX()*2;
- AliMpPCB* pcb = pcbType->Clone(manuList,ixOffset,xOffset);
+ AliMpPCB* pcb = pcbType.Clone(manuList,ixOffset,xOffset);
#ifdef WITH_ROOT
fPCBs.AddLast(pcb);
#else
}
else
{
- AliError(Form("ManuID %d is duplicated for PCB %s",manuID,pcbType->GetID()));
+ AliError(Form("ManuID %d is duplicated for PCB %s",manuID,pcbType.GetID()));
}
//#else
// fManuMap[manuID] = mp;