/[PAMELA software]/PamCut/Collections/BlindCutCollection/BlindCutCollection.h
ViewVC logotype

Contents of /PamCut/Collections/BlindCutCollection/BlindCutCollection.h

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.2 - (show annotations) (download)
Fri May 29 10:10:18 2009 UTC (15 years, 6 months ago) by pam-fi
Branch: MAIN
Changes since 1.1: +6 -4 lines
File MIME type: text/plain
Previous commit was outdated; fixed.

1 /*
2 * BlindCutCollection.h
3 *
4 * Created on: 10-mar-2009
5 * Author: Nicola Mori
6 */
7
8 /*! @file BlindCutCollection.h The BlindCutCollection class definition file */
9
10 #ifndef BLINDCUTCOLLECTION_H_
11 #define BLINDCUTCOLLECTION_H_
12
13 #include "../../PamCutBase/PamCutBase.h"
14
15 /*! @brief A cut collection which applies all the cuts.
16 *
17 * This cut collection will apply all the cuts it contains to the
18 * events, even if some of them are not satisfied.
19 */
20 class BlindCutCollection: public PamCutCollection {
21 public:
22 /*! @brief Constructor.
23 *
24 * @param collectionName The collection's name.
25 */
26 BlindCutCollection(const char *collectionName) :
27 PamCutCollection(collectionName) {
28 }
29
30 /*! @brief Destructor. */
31 ~BlindCutCollection() {
32 }
33
34 /*! @brief Checks all the cuts.
35 *
36 * This method checks all the cuts for the current event. It exits only after
37 * all the cuts have been evaluated. Note that it doesn't call OnGood() nor OnBad(), not
38 * even for the PamCut objects in the collection.
39 * @return the index of the first failed cut (range: [0, \#cuts-1], see AddCut()); \
40 * #CUTOK if the event satisfies all the cuts.
41 */
42 int Check(PamLevel2 *event);
43
44 /*! @brief Applies all the cuts to the current event.
45 *
46 * This routine works pretty much like the redefinition of Check(), calling ApplyCut() (instead of
47 * Check() )for each cut. However, if a cut fails, it does not stops but continues until all the
48 * cuts are evaluated. If all the cuts are successful, on exit it calls OnGood(); if a single cut
49 * failed, it calls OnBad(), passing the index of the first failed cut as selectionResult.
50 *
51 * @param event The event to analyze.
52 * @return same return values as Check().
53 */
54 int ApplyCut(PamLevel2 *event);
55 //void OnGood(PamLevel2 *event){cout << "BlindCutCollection::OnGood" << endl;}
56 //void OnBad(PamLevel2 *event, int selectionResult){cout << "BlndCutCollection::OnBad, SelectionResult=" << selectionResult << endl;}
57
58 };
59
60 #endif /* BLINDCUTCOLLECTION_H_ */

  ViewVC Help
Powered by ViewVC 1.1.23