]> git.uio.no Git - u/mrichter/AliRoot.git/blame - STEER/AliSimulation.h
Modified plots and made jet finder use SDigits
[u/mrichter/AliRoot.git] / STEER / AliSimulation.h
CommitLineData
85a5290f 1#ifndef ALISIMULATION_H
2#define ALISIMULATION_H
3/* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4 * See cxx source for full Copyright notice */
5
6/* $Id$ */
7
af7ba10c 8//
9// class for running generation, simulation and digitization
10// Hits, sdigits and digits are created for all detectors by typing:
af7ba10c 11// AliSimulation sim;
12// sim.Run();
13//
14
85a5290f 15#include <TNamed.h>
16#include <TString.h>
17
18class AliRunLoader;
19
20
21class AliSimulation: public TNamed {
22public:
95601147 23 AliSimulation(const char* configFileName = "Config.C",
24 const char* name = "AliSimulation",
85a5290f 25 const char* title = "generation, simulation and digitization");
26 AliSimulation(const AliSimulation& sim);
27 AliSimulation& operator = (const AliSimulation& sim);
28 virtual ~AliSimulation();
29
30 void SetNumberOfEvents(Int_t nEvents);
31 void SetConfigFile(const char* fileName);
0421c3d1 32 void SetGAliceFile(const char* fileName);
85a5290f 33
34 void SetRunGeneration(Bool_t run) {fRunGeneration = run;};
35 void SetRunSimulation(Bool_t run) {fRunSimulation = run;};
36 void SetMakeSDigits(const char* detectors)
37 {fMakeSDigits = detectors;};
05526d44 38 void MergeWith(const char* fileName, Int_t nSignalPerBkgrd = 0);
04bae0a0 39 void SetUseBkgrdVertex(Bool_t useBkgrdVertex)
40 {fUseBkgrdVertex = useBkgrdVertex;};
4df28b43 41 void SetRegionOfInterest(Bool_t flag) {fRegionOfInterest = flag;};
85a5290f 42 void SetMakeDigits(const char* detectors)
43 {fMakeDigits = detectors;};
44 void SetMakeDigitsFromHits(const char* detectors)
45 {fMakeDigitsFromHits = detectors;};
0421c3d1 46 void SetWriteRawData(const char* detectors)
47 {fWriteRawData = detectors;};
85a5290f 48
49 virtual Bool_t Run(Int_t nEvents = 0);
50
95601147 51 virtual Bool_t RunSimulation(Int_t nEvents = 0);
52 virtual Bool_t RunSDigitization(const char* detectors = "ALL");
53 virtual Bool_t RunDigitization(const char* detectors = "ALL",
54 const char* excludeDetectors = "");
55 virtual Bool_t RunHitsDigitization(const char* detectors = "ALL");
0421c3d1 56 virtual Bool_t WriteRawData(const char* detectors = "ALL");
8e4a4643 57
95601147 58private:
59 AliRunLoader* LoadRun() const;
05526d44 60 Int_t GetNSignalPerBkgrd(Int_t nEvents = 0) const;
85a5290f 61 Bool_t IsSelected(TString detName, TString& detectors) const;
62
85a5290f 63 Bool_t fRunGeneration; // generate prim. particles or not
64 Bool_t fRunSimulation; // simulate detectors (hits) or not
65 TString fMakeSDigits; // create sdigits for these detectors
66 TString fMakeDigits; // create digits for these detectors
67 TString fMakeDigitsFromHits; // create digits from hits for these detectors
0421c3d1 68 TString fWriteRawData; // write raw data for these detectors
85a5290f 69 Bool_t fStopOnError; // stop or continue on errors
70
71 Int_t fNEvents; // number of events
72 TString fConfigFileName; // name of the config file
73 TString fGAliceFileName; // name of the galice file
74 TObjArray* fBkgrdFileNames; // names of background files for merging
04bae0a0 75 Bool_t fUseBkgrdVertex; // use vertex from background in case of merging
4df28b43 76 Bool_t fRegionOfInterest; // digitization in region of interest
85a5290f 77
85a5290f 78 ClassDef(AliSimulation, 1) // class for running generation, simulation and digitization
79};
80
81#endif