2 // Class AliRsnCutManager
4 // The cut manager: contains a complete set of cut definitions
5 // to be applied to all possible targets (one for each target),
6 // in order to ease the set-up procedure of cuts and allow to
7 // pass them at once to each object which must use them
9 // author: Martin Vala (martin.vala@cern.ch)
14 #include "AliRsnCutManager.h"
16 ClassImp(AliRsnCutManager)
18 //_____________________________________________________________________________
19 AliRsnCutManager::AliRsnCutManager() :
20 TNamed("defaultName", "defaultTitle"),
24 // Constructor without arguments.
28 for (i = 0; i < 3; i++) fDaughterCuts[i] = 0x0;
31 //_____________________________________________________________________________
32 AliRsnCutManager::AliRsnCutManager(const char *name, const char *title) :
37 // Constructor with name and title.
41 for (i = 0; i < 3; i++) fDaughterCuts[i] = 0x0;
44 //_____________________________________________________________________________
45 AliRsnCutManager::AliRsnCutManager(const AliRsnCutManager &cut) :
47 fMotherCuts(cut.fMotherCuts)
50 // Constructor with name and title.
54 for (i = 0; i < 3; i++) fDaughterCuts[i] = cut.fDaughterCuts[i];
57 AliRsnCutManager& AliRsnCutManager::operator=(const AliRsnCutManager &cut)
63 SetName(cut.GetName());
64 SetTitle(cut.GetTitle());
67 for (i = 0; i < 3; i++) fDaughterCuts[i] = cut.fDaughterCuts[i];
69 fMotherCuts = cut.fMotherCuts;
74 //_____________________________________________________________________________
75 AliRsnCutManager::~AliRsnCutManager()
79 // Deletes all cut definitions.
83 for (i = 0; i < 3; i++) delete fDaughterCuts[i];
88 //_____________________________________________________________________________
89 void AliRsnCutManager::SetEvent(AliRsnEvent *event)
92 // Sets reference event in all cut sets
96 for (i = 0; i < 3; i++) if (fDaughterCuts[i]) fDaughterCuts[i]->SetEvent(event);
98 if (fMotherCuts) fMotherCuts->SetEvent(event);