Wrongly deleted code is restored
[u/mrichter/AliRoot.git] / EVGEN / AliGenCocktail.h
CommitLineData
fe4da5cc 1#ifndef ALIGENCOCKTAIL_H
2#define ALIGENCOCKTAIL_H
3da30618 3/* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4 * See cxx source for full Copyright notice */
5
6/* $Id$ */
7
675e9664 8// Container class for AliGenerator through recursion.
9// (Container is itself an AliGenerator)
10// Author: andreas.morsch@cern.ch
11//
12
fe4da5cc 13#include "AliGenerator.h"
1ebe6dc8 14#include <TArrayF.h>
886b6f73 15
374924b5 16class AliGenCocktailEntry;
4f85aa78 17class AliGenCocktailEventHeader;
1ebe6dc8 18class TArrayF;
fe4da5cc 19
20
21class AliGenCocktail : public AliGenerator
22{
fe4da5cc 23 public:
24 AliGenCocktail();
374924b5 25
fe4da5cc 26 virtual ~AliGenCocktail();
27 virtual void Init();
09e2e187 28 virtual void FinishRun();
fe4da5cc 29 virtual void Generate();
c44d1c08 30 virtual void SetVertexSmear(VertexSmear_t smear);
1ebe6dc8 31 virtual void SetRandomise(Bool_t flag) {fRandom = flag;}
c89fc3f1 32 virtual void UsePerEventRates() {fUsePerEventRate = kTRUE;}
1ebe6dc8 33
fe4da5cc 34 //
35 // Add a new generator to the list
36 virtual void AddGenerator
a764b7de 37 (AliGenerator *Generator, const char* Name, Float_t RateExp );
fe4da5cc 38 virtual TList* Entries() {return fEntries;}
39 // Iterators
40 AliGenCocktailEntry* FirstGenerator();
41 AliGenCocktailEntry* NextGenerator();
374924b5 42 void FirstGeneratorPair(AliGenCocktailEntry*&e1, AliGenCocktailEntry*&e2);
43 void NextGeneratorPair (AliGenCocktailEntry*&e1, AliGenCocktailEntry*&e2);
4f85aa78 44 virtual void AddHeader(AliGenEventHeader* header);
45
374924b5 46 protected:
4f85aa78 47 Int_t fNGenerators; // Number of generators booked
48 Bool_t fRandom; // Flag to select random generator from list
c89fc3f1 49 Bool_t fUsePerEventRate; // Flag to generate the events according to the rate per event
4f85aa78 50 TArrayF fProb; // Probability of an event (if fRandom == kTRUE)
51 TList *fEntries; // List of Generators
52 TObjLink *flnk1; // ! Iterator for first generator
53 TObjLink *flnk2; // ! Iterator for second generator
54 AliGenCocktailEventHeader* fHeader; // !Header container
55
fe4da5cc 56//
0af12c00 57 private:
93a2041b 58 AliGenCocktail(const AliGenCocktail &cocktail);
59 AliGenCocktail & operator=(const AliGenCocktail & rhs);
60
374924b5 61 ClassDef(AliGenCocktail,1) // Particle cocktail generator a la SHAKER
fe4da5cc 62};
63
64#endif
65
66
67
68
69