Logo ROOT   6.08/07
Reference Guide
TTable.h
Go to the documentation of this file.
1 // @(#)root/table:$Id$
2 // Author: Valery Fine(fine@mail.cern.ch) 03/07/98
3 
4 /*************************************************************************
5  * Copyright (C) 1995-2000, Rene Brun and Fons Rademakers. *
6  * All rights reserved. *
7  * *
8  * For the licensing terms see $ROOTSYS/LICENSE. *
9  * For the list of contributors see $ROOTSYS/README/CREDITS. *
10  *************************************************************************/
11 
12 #ifndef ROOT_TTable
13 #define ROOT_TTable
14 
15 //////////////////////////////////////////////////////////////////////////
16 // //
17 // TTable //
18 // //
19 // It is a base class to create a "wrapper" class //
20 // holding the plain C-structure array //
21 // (1 element of the structure per element) //
22 // //
23 //////////////////////////////////////////////////////////////////////////
24 
25 #ifdef __CINT__
26 #pragma Ccomment on
27 #endif
28 
29 #include "Ttypes.h"
30 #include "TDataSet.h"
31 #include "tableDescriptor.h"
32 #ifndef ROOT_TCut
33 # include "TCut.h"
34 #endif
35 
36 # ifndef ROOT_Riosfwd
37 # include "Riosfwd.h"
38 # endif
39 
40 #ifndef __CINT__
41 # include <string.h>
42 # include <assert.h>
43 #endif
44 
45 #include <vector>
46 
47 class TTableDescriptor;
48 class TH1;
49 class TTableMap;
50 typedef TTableMap* Ptr_t;
51 
52 class TTable : public TDataSet {
53  friend class TDataSet;
54  friend class St_XDFFile;
55 protected:
56  Long_t fSize; // Size of the one element (row) of the table
57 
58 protected:
59 
60  Int_t fN; //Number of array elements
61  Char_t *fTable; // Array of (fN*fSize) longs
62  Long_t fMaxIndex; // The used capacity of this array
63 
64  Bool_t BoundsOk(const char *where, Int_t at) const;
65  Bool_t OutOfBoundsError(const char *where, Int_t i) const;
66 
67  void CopyStruct(Char_t *dest, const Char_t *src);
68  Char_t *Create();
69  virtual void Clear(Option_t *opt="");
70  virtual void Delete(Option_t *opt="");
71  virtual Bool_t EntryLoop(const Char_t *exprFileName,Int_t &action, TObject *obj, Int_t nentries=1000000000, Int_t firstentry=0, Option_t *option="");
72  Int_t SetfN(Long_t len);
73  void SetTablePointer(void *table);
74  void SetUsedRows(Int_t n);
75  virtual void SetType(const char *const type);
76  void StreamerHeader(TBuffer &b,Version_t version=3);
77  void StreamerTable(TBuffer &b,Version_t version=3);
78  virtual TTableDescriptor *GetDescriptorPointer() const;
79  virtual void SetDescriptorPointer(TTableDescriptor *list);
80 
81  void ReAlloc(Int_t newsize);
82  static const char *TableDictionary(const char *className,const char *structName,TTableDescriptor *&ColDescriptors);
83 
84 public:
85 
89  enum ETableBits {
90  kIsNotOwn = BIT(23) // if the TTable wrapper doesn't own the STAF table
91  // As result of the Update() method for example
92  };
93  static const char *fgTypeName[kEndColumnType];
94  TTable(const char *name=0, Int_t size=0);
95  TTable(const char *name, Int_t n,Int_t size);
96  TTable(const char *name, Int_t n, Char_t *array,Int_t size);
97  TTable(const char *name, const char *type, Int_t n, Char_t *array, Int_t size);
98  TTable(const TTable &table);
99  TTable &operator=(const TTable &rhs);
100  virtual ~TTable();
101 
102  virtual void Adopt(Int_t n, void *array);
103  virtual Int_t AddAt(const void *c);
104  virtual void AddAt(const void *c, Int_t i);
105  virtual void AddAt(TDataSet *dataset,Int_t idx=0);
106  virtual Long_t AppendRows(const void *row, UInt_t nRows);
107  virtual void AsString(void *buf, EColumnType type, Int_t width, std::ostream &out) const;
108  const void *At(Int_t i) const;
109  virtual void Browse(TBrowser *b);
110  virtual void CopySet(TTable &array);
111  Int_t CopyRows(const TTable *srcTable,Long_t srcRow=0, Long_t dstRow=0, Long_t nRows=0, Bool_t expand=kFALSE);
112  virtual void DeleteRows(Long_t indx,UInt_t nRows=1);
113  virtual void Draw(Option_t *opt);
114  virtual TH1 *Draw(TCut varexp, TCut selection, Option_t *option=""
115  ,Int_t nentries=1000000000, Int_t firstentry=0);
116  virtual TH1 *Draw(const char *varexp, const char *selection, Option_t *option=""
117  ,Int_t nentries=1000000000, Int_t firstentry=0); // *MENU*
118  void *GetArray() const ;
119  virtual TClass *GetRowClass() const ;
120  Int_t GetSize() const { return fN; }
121  virtual Long_t GetNRows() const;
122  virtual Long_t GetRowSize() const;
123  virtual Long_t GetTableSize() const;
124  virtual TTableDescriptor *GetTableDescriptors() const;
125  virtual TTableDescriptor *GetRowDescriptors() const;
126  virtual const Char_t *GetType() const;
127  virtual void Fit(const char *formula ,const char *varexp, const char *selection="",Option_t *option="" ,Option_t *goption=""
128  ,Int_t nentries=1000000000, Int_t firstentry=0); // *MENU*
129 
130  virtual Long_t HasData() const { return 1; }
131  virtual Long_t InsertRows(const void *rows, Long_t indx, UInt_t nRows=1);
132  virtual Bool_t IsFolder() const;
133  Int_t NaN();
134  static TTable *New(const Char_t *name, const Char_t *type, void *array, UInt_t size);
135  virtual Char_t *MakeExpression(const Char_t *expressions[],Int_t nExpressions);
136  virtual Char_t *Print(Char_t *buf,Int_t n) const ;
137  virtual void Print(Option_t *opt="") const;
138  virtual const Char_t *Print(Int_t row, Int_t rownumber=10,
139  const Char_t *colfirst="", const Char_t *collast="") const; // *MENU*
140  virtual void PrintContents(Option_t *opt="") const;
141  virtual const Char_t *PrintHeader() const; // *MENU*
142  virtual void Project(const char *hname, const char *varexp, const char *selection="", Option_t *option=""
143  ,Int_t nentries=1000000000, Int_t firstentry=0);
144 
145  virtual Int_t Purge(Option_t *opt="");
146 
147  void *ReAllocate(Int_t newsize);
148  void *ReAllocate();
149  virtual void SavePrimitive(std::ostream &out, Option_t *option = "");
150  virtual void Set(Int_t n);
151  virtual void Set(Int_t n, Char_t *array);
152  virtual void SetNRows(Int_t n);
153  virtual void Reset(Int_t c=0);
154  virtual void ResetMap(Bool_t wipe=kTRUE);
155  virtual void Update();
156  virtual void Update(TDataSet *set,UInt_t opt=0);
157  void *operator[](Int_t i);
158  const void *operator[](Int_t i) const;
159 
160 
161  // ---- Table descriptor service ------
162 
163  virtual Int_t GetColumnIndex(const Char_t *columnName) const;
164  virtual const Char_t *GetColumnName(Int_t columnIndex) const;
165  virtual const UInt_t *GetIndexArray(Int_t columnIndex) const;
166  virtual UInt_t GetNumberOfColumns() const;
167  virtual UInt_t GetOffset(Int_t columnIndex) const;
168  virtual Int_t GetOffset(const Char_t *columnName=0) const;
169  virtual UInt_t GetColumnSize(Int_t columnIndex) const;
170  virtual Int_t GetColumnSize(const Char_t *columnName=0) const;
171  virtual UInt_t GetTypeSize(Int_t columnIndex) const;
172  virtual Int_t GetTypeSize(const Char_t *columnName=0) const ;
173  virtual UInt_t GetDimensions(Int_t columnIndex) const;
174  virtual Int_t GetDimensions(const Char_t *columnName=0) const ;
175  virtual EColumnType GetColumnType(Int_t columnIndex) const;
176  virtual EColumnType GetColumnType(const Char_t *columnName=0) const;
177  virtual const Char_t *GetColumnComment(Int_t columnIndex) const;
178 
179  static const char *GetTypeName(EColumnType type);
180  static EColumnType GetTypeId(const char *typeName);
181 
182  // Table index iterator:
183  class iterator {
184  public:
185  typedef std::vector<Long_t>::iterator vec_iterator;
186  typedef std::vector<Long_t>::const_iterator vec_const_iterator;
187  private:
190  vec_iterator fCurrentRow;
191  public:
192  iterator(): fRowSize(0), fThisTable(0) {;}
193  iterator(const TTable &table, vec_iterator &arowPtr) :
194  fRowSize(table.GetRowSize()), fThisTable(&table), fCurrentRow(arowPtr) {;}
195  iterator(const TTable &table, vec_const_iterator &arowPtr) :
196  fRowSize(table.GetRowSize()), fThisTable(&table),
197  fCurrentRow(*(std::vector<Long_t>::iterator *)(void *)&arowPtr) {;}
198  //fCurrentRow(* const_cast<std::vector<Long_t>::iterator *>(&arowPtr) ) {;}
199  iterator(const iterator& iter) : fRowSize (iter.fRowSize), fThisTable(iter.fThisTable),fCurrentRow(iter.fCurrentRow){}
200  iterator &operator=(const iterator& iter) { fRowSize = iter.fRowSize; fThisTable = iter.fThisTable; fCurrentRow=iter.fCurrentRow; return *this; }
201  void operator++() { ++fCurrentRow; }
202  void operator++(int) { fCurrentRow++; }
203  void operator--() { --fCurrentRow; }
204  void operator--(int) { fCurrentRow--; }
205  iterator operator+(Int_t idx) { std::vector<Long_t>::iterator addition = fCurrentRow+idx; return iterator(*fThisTable,addition); }
206  iterator operator-(Int_t idx) { std::vector<Long_t>::iterator subtraction = fCurrentRow-idx; return iterator(*fThisTable,subtraction); }
207  void operator+=(Int_t idx) { fCurrentRow+=idx; }
208  void operator-=(Int_t idx) { fCurrentRow-=idx; }
209  void *rowPtr() const { return (void *)(((const char *)fThisTable->GetArray()) + (*fCurrentRow)*fRowSize ); }
210  operator void *() const { return rowPtr(); }
211  Int_t operator-(const iterator &it) const { return (*fCurrentRow)-(*(it.fCurrentRow)); }
212  Long_t operator *() const { return *fCurrentRow; }
213  Bool_t operator==(const iterator &t) const { return ( (fCurrentRow == t.fCurrentRow) && (fThisTable == t.fThisTable) ); }
214  Bool_t operator!=(const iterator &t) const { return !operator==(t); }
215 
216  const TTable &Table() const { return *fThisTable;}
217  const Long_t &RowSize() const { return fRowSize;}
218 #ifndef __CINT__
219  const std::vector<Long_t>::iterator &Row() const { return fCurrentRow;}
220 #endif
221  };
222 
223 #ifndef __CINT__
224  // pointer iterator
225  // This create an iterator to iterate over all table column of the
226  // type provided.
227  // For example" piterator(table,kPtr) is to iterate over
228  // all cells of (TTableMap *) type
229 
230  class piterator {
231  private:
232  std::vector<ULong_t> fPtrs;
238 
239  protected:
240  void **column() {return fCurrentColPtr = (void **)(fCurrentRowPtr + fPtrs[fCurrentColIndex]);}
241 
242  public:
243  piterator(const TTable *t=0,EColumnType type=kPtr);
244  piterator(const piterator& iter);
245  void operator=(const piterator& iter);
246 
247  void operator++();
248  void operator++(int);
249  void operator--();
250  void operator--(int);
251 
252 // operator const char *() const;
253  void **operator *();
254 
255  Bool_t operator==(const piterator &t) const;
256  Bool_t operator!=(const piterator &t) const;
257 
258  UInt_t Row() const;
259  UInt_t Column() const;
260 
261  void MakeEnd(UInt_t lastRowIndex);
262  }; // class iterator over pointers
263 
264  piterator pbegin(){ return piterator(this); }
265  piterator pend(){ piterator pLast(this); pLast.MakeEnd(GetNRows()); return pLast; }
266 #endif
267  static const char *TableDictionary() { return 0; };
268  ClassDef(TTable,4) // vector of the C structures
269 };
270 
271 //________________________________________________________________________
272 inline void TTable::AddAt(TDataSet *dataset,Int_t idx)
273 { TDataSet::AddAt(dataset,idx); }
274 
275 //________________________________________________________________________
276 inline Bool_t TTable::BoundsOk(const char *where, Int_t at) const
277 {
278  return (at < 0 || at >= fN)
279  ? OutOfBoundsError(where, at)
280  : kTRUE;
281 }
282 
283 //________________________________________________________________________
284 inline void *TTable::GetArray() const { return (void *)fTable;}
285 
286 //________________________________________________________________________
287 inline void TTable::Print(Option_t *) const { Print((Char_t *)0,Int_t(0)); }
288 
289 //________________________________________________________________________
291 //________________________________________________________________________
293 // ULong_t &operator(){ return GetTable();}
294 
295 //________________________________________________________________________
296 inline void *TTable::operator[](Int_t i)
297 {
298  if (!BoundsOk("TTable::operator[]", i))
299  i = 0;
300  return (void *)(fTable+i*fSize);
301 }
302 
303 //________________________________________________________________________
304 inline const void *TTable::operator[](Int_t i) const
305 {
306  if (!BoundsOk("TTable::operator[]", i))
307  i = 0;
308  return (const void *)(fTable+i*fSize);
309 }
310 
311 //________________________________________________________________________
312 inline void TTable::Draw(Option_t *opt)
313 { Draw(opt, "", "", 1000000000, 0); }
314 
315 #ifndef __CINT__
316  //________________________________________________________________________________________________________________
318  fPtrs (iter.fPtrs),
319  fCurrentRowIndex(iter.fCurrentRowIndex),
320  fCurrentColIndex(iter.fCurrentColIndex),
321  fRowSize(iter.fRowSize),
322  fCurrentRowPtr(iter.fCurrentRowPtr),
323  fCurrentColPtr(iter.fCurrentColPtr)
324  {}
325  //________________________________________________________________________________________________________________
326  inline void TTable::piterator::operator=(const piterator& iter){
327  fPtrs = iter.fPtrs;
330  fRowSize = iter.fRowSize;
333  }
334  //________________________________________________________________________________________________________________
336  {
338  if (fCurrentColIndex >= fPtrs.size()) {
339  fCurrentColIndex = 0;
342  }
343  column();
344  }
345  //________________________________________________________________________________________________________________
347  //________________________________________________________________________________________________________________
349  {
350  if (fCurrentColIndex > 0) {
352  fCurrentColIndex = fPtrs.size()-1;
355  } else {
357  }
358  column();
359  }
360  //________________________________________________________________________________________________________________
362  //________________________________________________________________________________________________________________
363  // inline TTable::piterator::operator const char *() const { return fCurrentColPtr; }
364  //________________________________________________________________________________________________________________
365  inline void **TTable::piterator::operator *() { return fCurrentColPtr; }
366  //________________________________________________________________________________________________________________
368  return (
371 // && (fCurrentRowPtr == t.fCurrentRowPtr )
372 // && (fCurrentColPtr == t.fCurrentColPtr )
373  );
374  }
375  //________________________________________________________________________________________________________________
376  inline Bool_t TTable::piterator::operator!=(const piterator &t) const { return !operator==(t); }
377  //________________________________________________________________________________________________________________
378  inline void TTable::piterator::MakeEnd(UInt_t lastRowIndex){fCurrentColIndex = 0; fCurrentRowIndex = lastRowIndex;}
379  //________________________________________________________________________________________________________________
381  //________________________________________________________________________________________________________________
383 #endif
384 
385 #endif
TTableMap * Ptr_t
Definition: TTable.h:49
virtual void AsString(void *buf, EColumnType type, Int_t width, std::ostream &out) const
AsString represents the value provided via "void *b" with type defined by "name". ...
Definition: TTable.cxx:229
virtual Long_t InsertRows(const void *rows, Long_t indx, UInt_t nRows=1)
void InsertRows(cons void *row, Long_t indx, UInt_t nRows)
Definition: TTable.cxx:1207
ETableBits
Definition: TTable.h:89
UInt_t Row() const
Definition: TTable.h:380
Int_t SetfN(Long_t len)
to be documented
Definition: TTable.cxx:2184
Long_t fSize
Definition: TTable.h:56
void * ReAllocate()
Reallocate this table leaving only (used rows)+1 allocated GetTableSize() = GetNRows() + 1 returns a ...
Definition: TTable.cxx:1226
short Version_t
Definition: RtypesCore.h:61
piterator pbegin()
Definition: TTable.h:264
void SetUsedRows(Int_t n)
Definition: TTable.h:290
virtual Long_t HasData() const
Definition: TTable.h:130
iterator operator-(Int_t idx)
Definition: TTable.h:206
return c
const char Option_t
Definition: RtypesCore.h:62
#define BIT(n)
Definition: Rtypes.h:120
UInt_t fRowSize
Definition: TTable.h:235
iterator(const TTable &table, vec_iterator &arowPtr)
Definition: TTable.h:193
virtual Bool_t IsFolder() const
return Folder flag to be used by TBrowse object The table is a folder if
Definition: TTable.cxx:1461
virtual TClass * GetRowClass() const
to be documented
Definition: TTable.cxx:1379
Int_t GetSize() const
Definition: TTable.h:120
Buffer base class used for serializing objects.
Definition: TBuffer.h:42
virtual const Char_t * PrintHeader() const
Print general table inforamtion.
Definition: TTable.cxx:1625
void StreamerHeader(TBuffer &b, Version_t version=3)
Read "table parameters first".
Definition: TTable.cxx:2145
static const char * TableDictionary()
Definition: TTable.h:267
int Int_t
Definition: RtypesCore.h:41
bool Bool_t
Definition: RtypesCore.h:59
const Bool_t kFALSE
Definition: Rtypes.h:92
STL namespace.
TTable & operator=(const TTable &rhs)
TTable assignment operator.
Definition: TTable.cxx:1087
virtual const Char_t * GetType() const
Returns the type of the wrapped C-structure kept as the TNamed title.
Definition: TTable.cxx:1449
void operator++()
Definition: TTable.h:201
virtual void Browse(TBrowser *b)
Wrap each table coulumn with TColumnView object to browse.
Definition: TTable.cxx:1298
void ** fCurrentColPtr
Definition: TTable.h:237
virtual TTableDescriptor * GetDescriptorPointer() const
to be documented
Definition: TTable.cxx:2246
virtual Char_t * Print(Char_t *buf, Int_t n) const
Create IDL table defintion (to be used for XDF I/O)
Definition: TTable.cxx:1553
virtual void SavePrimitive(std::ostream &out, Option_t *option="")
Save a primitive as a C++ statement(s) on output stream "out".
Definition: TTable.cxx:1820
void ** operator*()
Definition: TTable.h:365
void operator-=(Int_t idx)
Definition: TTable.h:208
TTable(const char *name=0, Int_t size=0)
Default TTable ctor.
Definition: TTable.cxx:1035
#define ClassDef(name, id)
Definition: Rtypes.h:254
Bool_t operator!=(const piterator &t) const
Definition: TTable.h:376
virtual const UInt_t * GetIndexArray(Int_t columnIndex) const
Definition: TTable.cxx:2432
void operator--()
Definition: TTable.h:203
virtual void SetNRows(Int_t n)
Definition: TTable.h:292
const std::vector< Long_t >::iterator & Row() const
Definition: TTable.h:219
EColumnType
Definition: TTable.h:86
const Long_t & RowSize() const
Definition: TTable.h:217
virtual void Draw(Option_t *opt)
Default Draw method for all objects.
Definition: TTable.h:312
virtual void Set(Int_t n)
Set array size of TTable object to n longs. If n<0 leave array unchanged.
Definition: TTable.cxx:1962
Bool_t OutOfBoundsError(const char *where, Int_t i) const
Generate an out-of-bounds error. Always returns false.
Definition: TTable.cxx:1545
Int_t CopyRows(const TTable *srcTable, Long_t srcRow=0, Long_t dstRow=0, Long_t nRows=0, Bool_t expand=kFALSE)
CopyRows copies nRows from starting from the srcRow of srcTable to the dstRow in this table upto nRow...
Definition: TTable.cxx:332
const TTable * fThisTable
Definition: TTable.h:189
A specialized string object used for TTree selections.
Definition: TCut.h:27
const void * At(Int_t i) const
Returns a pointer to the i-th row of the table.
Definition: TTable.cxx:303
Bool_t operator==(const iterator &t) const
Definition: TTable.h:213
virtual Bool_t EntryLoop(const Char_t *exprFileName, Int_t &action, TObject *obj, Int_t nentries=1000000000, Int_t firstentry=0, Option_t *option="")
EntryLoop creates a CINT bytecode to evaluate the given expressions for all table rows in loop and fi...
Definition: TTable.cxx:789
void * operator[](Int_t i)
Definition: TTable.h:296
void operator+=(Int_t idx)
Definition: TTable.h:207
Using a TBrowser one can browse all ROOT objects.
Definition: TBrowser.h:41
virtual TTableDescriptor * GetRowDescriptors() const
to be documented
Definition: TTable.cxx:2232
friend class St_XDFFile
Definition: TTable.h:54
virtual void SetType(const char *const type)
to be documented
Definition: TTable.cxx:1983
piterator pend()
Definition: TTable.h:265
virtual const Char_t * GetColumnComment(Int_t columnIndex) const
Get a comment from the table descriptor.
Definition: TTable.cxx:1170
virtual Int_t AddAt(const void *c)
Add the "row" at the GetNRows() position, and reallocate the table if neccesary, and return the row i...
Definition: TTable.cxx:1126
virtual Long_t AppendRows(const void *row, UInt_t nRows)
Append nRows row of the array "row" to the table return.
Definition: TTable.cxx:1182
virtual UInt_t GetDimensions(Int_t columnIndex) const
Definition: TTable.cxx:2444
virtual void Fit(const char *formula, const char *varexp, const char *selection="", Option_t *option="", Option_t *goption="", Int_t nentries=1000000000, Int_t firstentry=0)
-*-*-*-*-*-*-*-*Fit a projected item(s) from a TTable-*-*-*-*-*-*-*-*-* *-* =========================...
Definition: TTable.cxx:1427
unsigned int UInt_t
Definition: RtypesCore.h:42
Char_t * fTable
Definition: TTable.h:61
void ** column()
Definition: TTable.h:240
virtual const Char_t * GetColumnName(Int_t columnIndex) const
Definition: TTable.cxx:2431
virtual void Update()
to be documented
Definition: TTable.cxx:2387
Int_t NaN()
return the total number of the NaN for float/double cells of this table Thanks Victor Perevoztchikov ...
Definition: TTable.cxx:1479
virtual void ResetMap(Bool_t wipe=kTRUE)
Clean all filled columns with the pointers to TTableMap if any wipe = kTRUE - delete all object the M...
Definition: TTable.cxx:2097
virtual void DeleteRows(Long_t indx, UInt_t nRows=1)
Delete one or several rows from the table.
Definition: TTable.cxx:364
std::vector< ULong_t > fPtrs
Definition: TTable.h:232
Long_t operator*() const
Definition: TTable.h:212
void operator=(const piterator &iter)
Definition: TTable.h:326
The ROOT global object gROOT contains a list of all defined classes.
Definition: TClass.h:81
void * GetArray() const
Definition: TTable.h:284
iterator(const iterator &iter)
Definition: TTable.h:199
Int_t operator-(const iterator &it) const
Definition: TTable.h:211
virtual ~TTable()
Delete TTable object.
Definition: TTable.cxx:1102
std::vector< Long_t >::iterator vec_iterator
Definition: TTable.h:185
long Long_t
Definition: RtypesCore.h:50
iterator(const TTable &table, vec_const_iterator &arowPtr)
Definition: TTable.h:195
virtual UInt_t GetColumnSize(Int_t columnIndex) const
Definition: TTable.cxx:2438
void StreamerTable(TBuffer &b, Version_t version=3)
Stream an object of class TTable.
Definition: TTable.cxx:2127
iterator & operator=(const iterator &iter)
Definition: TTable.h:200
virtual TTableDescriptor * GetTableDescriptors() const
protected: create a new TTableDescriptor descriptor for this table
Definition: TTable.cxx:214
Bool_t BoundsOk(const char *where, Int_t at) const
Definition: TTable.h:276
vec_iterator fCurrentRow
Definition: TTable.h:190
virtual void AddAt(TDataSet *dataset, Int_t idx=0)
Add TDataSet object at the "idx" position in ds or at the end of the dataset The final result is defi...
Definition: TDataSet.cxx:235
int type
Definition: TGX11.cxx:120
int nentries
Definition: THbookFile.cxx:89
void SetTablePointer(void *table)
to be documented
Definition: TTable.cxx:1974
void CopyStruct(Char_t *dest, const Char_t *src)
Copy the C-structure src into the new location the length of the strucutre is defined by this class d...
Definition: TTable.cxx:1155
The TH1 histogram class.
Definition: TH1.h:80
static EColumnType GetTypeId(const char *typeName)
return the Id of the C basic type by given name return kNAN if the name provided fits no knwn basic n...
Definition: TTable.cxx:292
static TTable * New(const Char_t *name, const Char_t *type, void *array, UInt_t size)
This static method creates a new TTable object if provided.
Definition: TTable.cxx:1520
virtual Int_t GetColumnIndex(const Char_t *columnName) const
Definition: TTable.cxx:2430
UInt_t Column() const
Definition: TTable.h:382
Definition: TTable.h:52
virtual Long_t GetTableSize() const
Returns the number of the allocated rows.
Definition: TTable.cxx:1406
const Char_t * fCurrentRowPtr
Definition: TTable.h:236
Mother of all ROOT objects.
Definition: TObject.h:37
char Char_t
Definition: RtypesCore.h:29
iterator operator+(Int_t idx)
Definition: TTable.h:205
virtual Char_t * MakeExpression(const Char_t *expressions[], Int_t nExpressions)
Create CINT macro to evaluate the user-provided expresssion Expression may contains: ...
Definition: TTable.cxx:2013
typedef void((*Func_t)())
void operator++()
Definition: TTable.h:335
virtual void PrintContents(Option_t *opt="") const
to be documented
Definition: TTable.cxx:1779
static const char * GetTypeName(EColumnType type)
return table type name
Definition: TTable.cxx:282
virtual void Project(const char *hname, const char *varexp, const char *selection="", Option_t *option="", Int_t nentries=1000000000, Int_t firstentry=0)
-*-*-*-*-*-*-*-*Make a projection of a TTable using selections-*-*-*-*-*-* *-* ======================...
Definition: TTable.cxx:1797
Bool_t operator==(const piterator &t) const
Definition: TTable.h:367
#define dest(otri, vertexptr)
Definition: triangle.c:1040
virtual Long_t GetNRows() const
Returns the number of the used rows for the wrapped table.
Definition: TTable.cxx:1392
Char_t * Create()
Allocate a space for the new table, if any Sleep for a while if space is not available and try again...
Definition: TTable.cxx:1272
void MakeEnd(UInt_t lastRowIndex)
Definition: TTable.h:378
you should not use this method at all Int_t Int_t Double_t Double_t Double_t Int_t Double_t Double_t Double_t Double_t b
Definition: TRolke.cxx:630
void operator++(int)
Definition: TTable.h:202
virtual UInt_t GetTypeSize(Int_t columnIndex) const
Definition: TTable.cxx:2441
Bool_t operator!=(const iterator &t) const
Definition: TTable.h:214
virtual Long_t GetRowSize() const
Returns the size (in bytes) of one table row.
Definition: TTable.cxx:1399
Int_t fN
Definition: TTable.h:60
Long_t fRowSize
Definition: TTable.h:188
virtual void SetDescriptorPointer(TTableDescriptor *list)
to be documented
Definition: TTable.cxx:2255
piterator(const TTable *t=0, EColumnType type=kPtr)
to be documented
Definition: TTable.cxx:2454
virtual void Delete(Option_t *opt="")
Delete the internal array and free the memory it occupied if this object did own this array...
Definition: TTable.cxx:1370
virtual EColumnType GetColumnType(Int_t columnIndex) const
Definition: TTable.cxx:2447
void operator--(int)
Definition: TTable.h:204
void operator--()
Definition: TTable.h:348
virtual void Clear(Option_t *opt="")
Deletes the internal array of this class if this object does own its internal table.
Definition: TTable.cxx:1346
static const char * fgTypeName[kEndColumnType]
Definition: TTable.h:93
const Bool_t kTRUE
Definition: Rtypes.h:91
UInt_t fCurrentRowIndex
Definition: TTable.h:233
const TTable & Table() const
Definition: TTable.h:216
virtual void Adopt(Int_t n, void *array)
Adopt array arr into TTable, i.e.
Definition: TTable.cxx:1111
const Int_t n
Definition: legend1.C:16
virtual UInt_t GetNumberOfColumns() const
Definition: TTable.cxx:2433
Long_t fMaxIndex
Definition: TTable.h:62
virtual void CopySet(TTable &array)
to be documented
Definition: TTable.cxx:1162
char name[80]
Definition: TGX11.cxx:109
void * rowPtr() const
Definition: TTable.h:209
virtual UInt_t GetOffset(Int_t columnIndex) const
Definition: TTable.cxx:2435
void ReAlloc(Int_t newsize)
The table is reallocated if it is an owner of the internal array.
Definition: TTable.cxx:1247
std::vector< Long_t >::const_iterator vec_const_iterator
Definition: TTable.h:186
virtual void Reset(Int_t c=0)
Fill the entire table with byte "c" ; / c=0 "be default".
Definition: TTable.cxx:2082
virtual Int_t Purge(Option_t *opt="")
Shrink the table to free the unused but still allocated rows.
Definition: TTable.cxx:1811
UInt_t fCurrentColIndex
Definition: TTable.h:234