1 #ifndef ALICUTVALUERANGE_H
2 #define ALICUTVALUERANGE_H
3 /* Copyright(c) 1998-2014, ALICE Experiment at CERN, All rights reserved. *
4 * See cxx source for full Copyright notice */
6 // Author: Markus Fasel
10 namespace EMCalTriggerPtAnalysis{
13 class AliCutValueRange : public TObject {
16 AliCutValueRange(t min, t max);
17 AliCutValueRange(t limit, bool isUpper);
18 virtual ~AliCutValueRange() {}
20 void SetLimits(t min, t max){
23 fHasLimit[0] = fHasLimit[1] = true;
25 void UnsetLimits(){ fHasLimit[0] = fHasLimit[1] = false; }
26 void SetLimit(t value, bool isUpper){
27 int bin = isUpper ? 1 : 0;
29 fHasLimit[bin] = true;
31 void UnsetLimit(bool isUpper){
32 int bin = isUpper ? 1 : 0;
33 fHasLimit[bin] = false;
35 void Negate() { fNegate = true; }
36 void SetPositive() { fNegate = false; }
37 bool IsInRange(t value) const;
43 ClassDef(AliCutValueRange, 1); // Value range for cuts