#include "AliMUONVClusterFinder.h"
#include "AliMUONVClusterServer.h"
#include "AliMUONVTrackStore.h"
+#include "AliMUONTriggerElectronics.h"
#include "AliMpArea.h"
#include "AliMpCDB.h"
fClusterServer(0x0),
fTriggerStore(0x0),
fTrackStore(0x0),
-fClusterStore(0x0)
+fClusterStore(0x0),
+fTriggerProcessor(0x0)
{
/// normal ctor
AliDebug(1,"");
+
+ // Unload mapping objects
+ // if they have been loaded from the obsolete OCDB mapping objects
+
+ if ( AliMpDDLStore::Instance(false) ) {
+ AliCDBManager::Instance()->UnloadFromCache("MUON/Calib/DDLStore");
+ delete AliMpDDLStore::Instance();
+ }
- // Unload and delete old mapping
- AliCDBManager::Instance()->UnloadFromCache("MUON/Calib/Mapping");
- AliCDBManager::Instance()->UnloadFromCache("MUON/Calib/DDLStore");
- delete AliMpDDLStore::Instance();
- delete AliMpSegmentation::Instance();
+ if ( AliMpSegmentation::Instance(false) ) {
+ AliCDBManager::Instance()->UnloadFromCache("MUON/Calib/Mapping");
+ delete AliMpSegmentation::Instance();
+ }
// Load mapping
if ( ! AliMpCDB::LoadDDLStore() ) {
delete fTriggerStore;
delete fTrackStore;
delete fClusterStore;
+ delete fTriggerProcessor;
delete AliMpSegmentation::Instance(false);
delete AliMpDDLStore::Instance(false);
//_____________________________________________________________________________
void
-AliMUONReconstructor::CreateCalibrator() const
+AliMUONReconstructor::CreateCalibrationData() const
{
/// Create the calibrator
- AliCodeTimerAuto("",0)
+ AliCodeTimerAuto("",0);
Int_t runNumber = AliCDBManager::Instance()->GetRun();
- AliInfo("Calibration will occur.");
-
fCalibrationData = new AliMUONCalibrationData(runNumber);
if ( !fCalibrationData->IsValid() )
{
}
}
}
-
+}
+
+//_____________________________________________________________________________
+void
+AliMUONReconstructor::CreateCalibrator() const
+{
+ /// Create the calibrator
+
+ AliCodeTimerAuto("",0);
+
+ if ( ! fCalibrationData )
+ CreateCalibrationData();
+
+ AliInfo("Calibration will occur.");
+
TString opt(GetOption());
opt.ToUpper();
fDigitCalibrator = new AliMUONDigitCalibrator(*fCalibrationData,GetRecoParam(),calibMode.Data());
}
+//_____________________________________________________________________________
+void
+AliMUONReconstructor::ResponseRemovingChambers(AliMUONVTriggerStore* triggerStore) const
+{
+ /// Update trigger information with informatins obtained after
+ /// re-calculation of trigger response
+ AliCodeTimerAuto("",0);
+
+ if ( ! fCalibrationData )
+ CreateCalibrationData();
+
+ if ( ! fTriggerProcessor )
+ fTriggerProcessor = new AliMUONTriggerElectronics(fCalibrationData);
+
+ fTriggerProcessor->ResponseRemovingChambers(*triggerStore);
+}
+
//_____________________________________________________________________________
AliMUONVDigitStore*
AliMUONReconstructor::DigitStore() const
if ( triggerStore )
{
+ ResponseRemovingChambers(triggerStore);
ok = triggerStore->Connect(clustersTree,alone);
if (!ok)
{