3 //**************************************************************************
4 //* This file is property of and copyright by the ALICE HLT Project *
5 //* ALICE Experiment at CERN, All rights reserved. *
8 //* for The ALICE HLT Project. *
10 //* Permission to use, copy, modify and distribute this software and its *
11 //* documentation strictly for non-commercial purposes is hereby granted *
12 //* without fee, provided that the above copyright notice appears in all *
13 //* copies and that both the copyright notice and this permission notice *
14 //* appear in the supporting documentation. The authors make no claims *
15 //* about the suitability of this software for any purpose. It is *
16 //* provided "as is" without express or implied warranty. *
17 //**************************************************************************
19 /** @file AliHLTTRDOfflineTrackerV1Component.cxx
22 @brief A TRDClusterizer processing component for the HLT.
25 #include "AliHLTTRDOfflineTrackerV1Component.h"
26 #include "AliCDBManager.h"
27 #include "AliTRDrecoParam.h"
28 #include "AliHLTTRDDefinitions.h"
30 ClassImp(AliHLTTRDOfflineTrackerV1Component)
32 AliHLTTRDOfflineTrackerV1Component::AliHLTTRDOfflineTrackerV1Component()
33 :AliHLTTRDTrackerV1Component()
35 // Default constructor
39 AliHLTTRDOfflineTrackerV1Component::~AliHLTTRDOfflineTrackerV1Component()
42 // Work is Done in DoDeInit()
45 int AliHLTTRDOfflineTrackerV1Component::GetOutputDataTypes(AliHLTComponentDataTypeList& tgtList)
47 // Get the output data types
49 tgtList.push_back(AliHLTTRDDefinitions::fgkHiLvlTracksDataType);
50 return tgtList.size();
53 void AliHLTTRDOfflineTrackerV1Component::GetOutputDataSize( unsigned long& constBase, double& inputMultiplier )
55 // Get the output data size
57 inputMultiplier = 4*((double)fOutputPercentage);
60 AliHLTComponent* AliHLTTRDOfflineTrackerV1Component::Spawn()
62 // Spawn function, return new instance of this class
63 return new AliHLTTRDOfflineTrackerV1Component;
66 int AliHLTTRDOfflineTrackerV1Component::DoInit( int argc, const char** argv )
70 iResult=AliHLTTRDTrackerV1Component::DoInit(argc, argv);
71 fRecoParam->SetStreamLevel(AliTRDrecoParam::kTracker, 1); //in order to have the friends written
75 const char* AliHLTTRDOfflineTrackerV1Component::GetComponentID()
77 // Return the component ID const char *
78 return "TRDOfflineTrackerV1"; // The ID of this component
81 void AliHLTTRDOfflineTrackerV1Component::SetOfflineParams(){
82 if(!AliCDBManager::Instance()->IsDefaultStorageSet()){
83 HLTFatal("You are resetting the Default Storage of the CDBManager!");
84 HLTFatal("Let's hope that this program is NOT running on the HLT cluster!");
85 AliCDBManager::Instance()->SetDefaultStorage("local://$ALICE_ROOT/OCDB");
87 if(AliCDBManager::Instance()->GetRun()<0){
88 HLTFatal("You are resetting the CDB run number to 0!");
89 HLTFatal("Let's hope that this program is NOT running on the HLT cluster!");
90 AliCDBManager::Instance()->SetRun(0);
94 int AliHLTTRDOfflineTrackerV1Component::DoDeinit()
96 return AliHLTTRDTrackerV1Component::DoDeinit();
99 int AliHLTTRDOfflineTrackerV1Component::DoEvent(const AliHLTComponent_EventData& evtData, const AliHLTComponent_BlockData* blocks,
100 AliHLTComponent_TriggerData& trigData, AliHLTUInt8_t* outputPtr,
101 AliHLTUInt32_t& size, vector<AliHLTComponent_BlockData>& outputBlocks )
103 if ( GetFirstInputBlock( kAliHLTDataTypeSOR ) || GetFirstInputBlock( kAliHLTDataTypeEOR ) )
105 return AliHLTTRDTrackerV1Component::DoEvent(evtData, blocks, trigData, outputPtr, size, outputBlocks );