Logo ROOT   6.14/05
Reference Guide
Macros | Typedefs
TTableSorter.cxx File Reference
#include <stdlib.h>
#include "TTableSorter.h"
#include "TTable.h"
#include "TClass.h"
#include "TDataMember.h"
#include "TDataType.h"
#include "TMemberInspector.h"
Include dependency graph for TTableSorter.cxx:

Macros

#define BINARYSEARCH(valuetype)
 
#define COMPAREFLOATVALUES(valuetype)
 
#define COMPAREORDER(valuetype)   Compare##valuetype
 
#define COMPAREVALUES(valuetype)
 
#define SEARCHORDER(valuetype)   Search##valuetype
 

Typedefs

typedef Int_t(* CALLQSORT) (const void *, const void *)
 

Macro Definition Documentation

◆ BINARYSEARCH

#define BINARYSEARCH (   valuetype)

Definition at line 471 of file TTableSorter.cxx.

◆ COMPAREFLOATVALUES

#define COMPAREFLOATVALUES (   valuetype)
Value:
int TTableSorter::Search##valuetype (const void *elem1, const void **elem2) { \
valuetype *value1 = (valuetype *)(elem1); \
valuetype *value2 = (valuetype *)(*elem2); \
valuetype diff = *value1-*value2; \
Int_t res = 0; \
if (diff > 0) res = 1; \
else if (diff < 0) res = -1; \
return res; \
} \
int TTableSorter::Compare##valuetype (const void **elem1, const void **elem2) {\
valuetype *value1 = (valuetype *)(*elem1); \
valuetype *value2 = (valuetype *)(*elem2); \
valuetype diff = *value1-*value2; \
Int_t res = 0; \
if (diff > 0 ) res = 1; \
else if (diff < 0) res = -1; \
if (res) return res; \
return int(value1-value2); \
} \
BINARYSEARCH(valuetype)
Int_t Compare(const void *item1, const void *item2)

Definition at line 560 of file TTableSorter.cxx.

◆ COMPAREORDER

#define COMPAREORDER (   valuetype)    Compare##valuetype

Definition at line 611 of file TTableSorter.cxx.

◆ COMPAREVALUES

#define COMPAREVALUES (   valuetype)
Value:
int TTableSorter::Search##valuetype (const void *elem1, const void **elem2) { \
valuetype *value1 = (valuetype *)(elem1); \
valuetype *value2 = (valuetype *)(*elem2); \
return int(*value1-*value2); \
} \
int TTableSorter::Compare##valuetype (const void **elem1, const void **elem2) { \
valuetype *value1 = (valuetype *)(*elem1); \
valuetype *value2 = (valuetype *)(*elem2); \
valuetype diff = *value1-*value2; \
if (diff ) return diff; \
return int(value1-value2); \
} \
BINARYSEARCH(valuetype)
virtual Int_t Compare(const TObject *obj) const
Compare two TNamed objects.
Definition: TNamed.cxx:85

Definition at line 584 of file TTableSorter.cxx.

◆ SEARCHORDER

#define SEARCHORDER (   valuetype)    Search##valuetype

Definition at line 612 of file TTableSorter.cxx.

Typedef Documentation

◆ CALLQSORT

typedef Int_t(* CALLQSORT) (const void *, const void *)

Definition at line 21 of file TTableSorter.cxx.