8#ifndef __KVNUMBERLIST_H
9#define __KVNUMBERLIST_H
18typedef std::vector<Int_t> IntArray;
19typedef std::vector<Int_t>::iterator IntArrayIter;
20typedef std::vector<Int_t>::const_iterator IntArrayCIter;
127 virtual void SetName(
const char* name);
152 void Add(
const IntArray&);
198 void Begin(
void)
const;
203 IntArrayIter
begin()
const;
204 IntArrayIter
end()
const;
217 operator const char* ()
const
#define ClassDef(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)
void Copy(TObject &) const
Copy content of this number list into 'o'.
virtual void SetName(const char *name)
Int_t fNLimits
number of limits in arrays
const Char_t * AsQuotedString() const
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.
virtual const char * GetName() const
void SetMinMax(Int_t min, Int_t max, Int_t pas=1)
Set list with all values from 'min' to 'max'.
void Print(Option_t *="") const
KVNumberList operator+(const KVNumberList &) const
Return sum of this list and the other one.
const Char_t * AsString(Int_t maxchars=0) const
void Remove(Int_t)
Remove value 'n' from the list.
IntArrayIter begin() const
IntArray fRandomFastArray
used by GetRandomFast()
const Char_t * AsHumanReadableString() const
Int_t fFirstValue
smallest value included in list
const Char_t * GetExpandedList() const
KVNumberList operator-(const KVNumberList &) const
TString fTMPSTR
dummy string to compute AsString (non static)
Bool_t IsFull(Int_t vinf=-1, Int_t vsup=-1) const
TString fName
name of the list
Int_t fMaxNLimits
size of arrays
void SetList(const TString &)
IntArrayIter fEndList
used by Next() & End() to iterate over list
void AddLimits(Int_t min, Int_t max)
IntArrayIter fIterIndex
used by Next() to iterate over list
IntArray fValues
used by Next() to iterate over list
void Clear(Option_t *="")
Empty number list, reset it to initial state.
bool operator==(const KVNumberList &) const
Equality test for number lists.
void Set(const TString &l)
void ParseAndFindLimits(const TString &string, const Char_t delim)
Int_t fLastValue
largest value included in list
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.
void clear()
private method called by ParseList()
TString GetLogical(const Char_t *observable) const
Int_t fNValues
total number of values included in ranges
void init_numberlist()
Default initialisation used by ctors.
const char * Data() const
Column in an SQLite database.
double min(double x, double y)
double max(double x, double y)