fNspecie(0),
fSspecie(0),
fNhighPt(0),
- fShighPt(0)
+ fShighPt(0),
+ fUpgradeModule("")
{
// create reconstruction object with default parameters
gGeoManager = NULL;
for (Int_t iDet = 0; iDet < kNDetectors; iDet++) {
fReconstructor[iDet] = NULL;
+ fUpgradeMask[iDet]=kFALSE;
fLoader[iDet] = NULL;
fTracker[iDet] = NULL;
}
fNspecie(0),
fSspecie(0),
fNhighPt(0),
- fShighPt(0)
+ fShighPt(0),
+ fUpgradeModule("")
{
// copy constructor
}
for (Int_t iDet = 0; iDet < kNDetectors; iDet++) {
fReconstructor[iDet] = NULL;
+ fUpgradeMask[iDet] = kFALSE;
fLoader[iDet] = NULL;
fTracker[iDet] = NULL;
}
fRecoParam = rec.fRecoParam;
for (Int_t iDet = 0; iDet < kNDetectors; iDet++) {
+ fUpgradeMask[iDet] = kFALSE;
delete fReconstructor[iDet]; fReconstructor[iDet] = NULL;
delete fLoader[iDet]; fLoader[iDet] = NULL;
delete fTracker[iDet]; fTracker[iDet] = NULL;
fSspecie = 0;
fNhighPt = 0;
fShighPt = 0;
+ fUpgradeModule="";
return *this;
}
AliCDBManager::Instance()->SetLock(1);
}
+//_____________________________________________________________________________
+void AliReconstruction::MatchUpgradeDetector() {
+ // Translates detector name in a boolean.
+ // The boolean is used in GetReconstructor to load the
+ // upgrade reconstructor instead of the standard one.
+ for(Int_t iDet = 0; iDet < kNDetectors; iDet++) {
+ if(fUpgradeModule.Contains(fgkDetectorName[iDet])) fUpgradeMask[iDet]=kTRUE;
+ }
+}
//_____________________________________________________________________________
Bool_t AliReconstruction::MisalignGeometry(const TString& detectors)
{
if (pluginHandler && (pluginHandler->LoadPlugin() == 0)) {
reconstructor = (AliReconstructor*) pluginHandler->ExecPlugin(0);
}
+
+ // check if the upgrade reconstructor should be used instead of the standard one
+ if(fUpgradeMask[iDet]) {
+ if(reconstructor) delete reconstructor;
+ TClass *cl = new TClass(Form("Ali%sUpgradeReconstructor",fgkDetectorName[iDet]));
+ reconstructor = (AliReconstructor*)(cl->New());
+ }
+
if (reconstructor) {
TObject* obj = fOptions.FindObject(detName.Data());
if (obj) reconstructor->SetOption(obj->GetTitle());
};
static Int_t GetDetIndex(const char * detector);
+ // Upgrade
+ void SetUpgradeModule(const char* detectors) {fUpgradeModule = detectors; MatchUpgradeDetector() ; }
+ void MatchUpgradeDetector();
+
protected:
virtual Bool_t ProcessEvent(void* event);
void InitRun(const char* input);
Int_t fSspecie; //! Number of events, sampled from fNspecie
Int_t fNhighPt; //! Number of events, selected by IsHighPt
Int_t fShighPt; //! Number of events, sampled from fNhighPt
+
+ // Upgrade detector reconstruction
+ TString fUpgradeModule;
+ Bool_t fUpgradeMask[kNDetectors];
ClassDef(AliReconstruction, 39) // class for running the reconstruction
};