8 #ifndef __KVNUMBERLIST_H
9 #define __KVNUMBERLIST_H
18 typedef std::vector<Int_t> IntArray;
19 typedef std::vector<Int_t>::iterator IntArrayIter;
20 typedef std::vector<Int_t>::const_iterator IntArrayCIter;
94 mutable Int_t fNValues;
98 mutable IntArrayIter fIterIndex;
99 mutable IntArrayIter fEndList;
100 mutable IntArray fValues;
104 mutable IntArray fRandomFastArray;
106 void init_numberlist();
110 void AddLimits(
TString&
string);
111 void ParseAndFindLimits(
const TString&
string,
const Char_t delim);
127 virtual void SetName(
const char* name);
152 void Add(
const IntArray&);
177 if (!fIsParsed)
const_cast<KVNumberList*
>(
this)->ParseList();
178 return (fNValues == 0);
198 void Begin(
void)
const;
201 return (fIterIndex == fEndList);
203 IntArrayIter
begin()
const;
204 IntArrayIter
end()
const;
217 operator const char* ()
const
#define ClassDefOverride(name, id)
Strings used to represent a set of ranges of values.
void Set(Int_t min, Int_t max, Int_t pas=1)
TList * CutInSubList(Int_t number)
Int_t GetRandomFast() const
bool operator!=(const KVNumberList &) const
Inequality test for number lists.
void Inter(const KVNumberList &list)
virtual void SetName(const char *name)
const Char_t * AsQuotedString() const
void Copy(TObject &) const override
Copy content of this number list into 'o'.
const Char_t * GetList() const
Bool_t Contains(Int_t val) const
returns kTRUE if the value 'val' is contained in the ranges defined by the number list
KVNumberList()
Default constructor.
Int_t First() const
Returns smallest number included in list.
void SetMinMax(Int_t min, Int_t max, Int_t pas=1)
Set list with all values from 'min' to 'max'.
KVNumberList GetListDividedBy(Int_t) const
KVNumberList operator+(const KVNumberList &) const
Return sum of this list and the other one.
void Clear(Option_t *="") override
Empty number list, reset it to initial state.
const Char_t * AsString(Int_t maxchars=0) const
void Remove(Int_t)
Remove value 'n' from the list.
const char * GetName() const override
IntArrayIter begin() const
const Char_t * AsHumanReadableString() const
const Char_t * GetExpandedList() const
KVNumberList operator-(const KVNumberList &) const
Bool_t IsFull(Int_t vinf=-1, Int_t vsup=-1) const
void SetList(const TString &)
void Add(Int_t)
Add value 'n' to the list.
bool operator==(const KVNumberList &) const
Equality test for number lists.
void Set(const TString &l)
void Print(Option_t *="") const override
IntArray GetArray() const
TString GetSQL(const Char_t *column) const
Int_t At(Int_t index) const
Bool_t PrepareRandomFast() const
KVNumberList GetSubList(Int_t vinf, Int_t vsup) const
Int_t operator[](Int_t index) const
KVNumberList GetComplementaryList() const
Int_t Last() const
Returns largest number included in list.
TString GetLogical(const Char_t *observable) const
const char * Data() const
RooArgList L(Args_t &&... args)
double min(double x, double y)
double max(double x, double y)