]> git.uio.no Git - u/mrichter/AliRoot.git/blame - HLT/CALO/AliHLTCaloRecoParamHandler.cxx
ATO-17 Adding dummy function: AliTPCDigitizer::DigitizeWithTailAndCrossTalk
[u/mrichter/AliRoot.git] / HLT / CALO / AliHLTCaloRecoParamHandler.cxx
CommitLineData
09dce353 1/**************************************************************************
2 * Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
3 * *
4 * Authors: Oystein Djuvsland <oysteind@ift.uib.no> *
5 * *
6 * Permission to use, copy, modify and distribute this software and its *
7 * documentation strictly for non-commercial purposes is hereby granted *
8 * without fee, provided that the above copyright notice appears in all *
9 * copies and that both the copyright notice and this permission notice *
10 * appear in the supporting documentation. The authors make no claims *
11 * about the suitability of this software for any purpose. It is *
12 * provided "as is" without express or implied warranty. *
13 **************************************************************************/
14
15#include "AliHLTCaloRecoParamHandler.h"
f05c2d17 16#include "AliDetectorRecoParam.h"
17#include "AliCDBEntry.h"
18#include "AliCDBManager.h"
19#include "TObjArray.h"
09dce353 20
2618a358 21ClassImp(AliHLTCaloRecoParamHandler);
22
09dce353 23AliHLTCaloRecoParamHandler::AliHLTCaloRecoParamHandler ( TString det ) :
24AliHLTCaloConstantsHandler(det)
2618a358 25,AliHLTLogging()
09dce353 26,fLogWeight(4.5)
27,fRecPointMemberThreshold(0.01)
28,fRecPointThreshold(0.1)
f05c2d17 29,fRecoParamPtr(0)
30,fRecoParamPath(det, "Calib", "RecoParam")
09dce353 31{
32 // See header file for class documentation
f05c2d17 33
09dce353 34}
35
36
37AliHLTCaloRecoParamHandler::~AliHLTCaloRecoParamHandler()
38{
39 // See header file for class documentation
40
41}
42
f05c2d17 43
44
45Int_t AliHLTCaloRecoParamHandler::GetParametersFromCDB()
46{
47 // See header file for documentation
48
49 if(fRecoParamPath.GetPath())
50 {
51// HLTInfo("configure from entry %s", path.GetPath());
52 AliCDBEntry *pEntry = AliCDBManager::Instance()->Get(fRecoParamPath/*,GetRunNo()*/);
53 if (pEntry)
54 {
e4d93924 55
f05c2d17 56 TObjArray *paramArray = dynamic_cast<TObjArray*>(pEntry->GetObject());
e4d93924 57 if(paramArray)
58 {
59 fRecoParamPtr = dynamic_cast<AliDetectorRecoParam*>((paramArray)->At(0));
60 }
f05c2d17 61 if(!fRecoParamPtr)
e4d93924 62 {
63 HLTError("can not fetch object reconstruction parameters from \"%s\"", fRecoParamPath.GetPath().Data());
64 return -1;
65 }
f05c2d17 66 }
67 else
68 {
2618a358 69 HLTError("can not fetch object \"%s\" from OCDB", fRecoParamPath.GetPath().Data());
f05c2d17 70 return -1;
71 }
72 }
73 FillParameters();
74 return 0;
75}