Logo ROOT  
Reference Guide
 
Loading...
Searching...
No Matches
TEveTreeTools.h
Go to the documentation of this file.
1// @(#)root/eve:$Id$
2// Authors: Matevz Tadel & Alja Mrak-Tadel: 2006, 2007
3
4/*************************************************************************
5 * Copyright (C) 1995-2007, 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_TEveTreeTools
13#define ROOT_TEveTreeTools
14
15#include "TSelectorDraw.h"
16#include "TEventList.h"
17
18/******************************************************************************/
19// TEveSelectorToEventList
20/******************************************************************************/
21
23{
26
27protected:
30public:
31 TEveSelectorToEventList(TEventList* evl, const char* sel);
32
33 Int_t Version() const override { return 1; }
34 Bool_t Process(Long64_t entry) override;
35
36 ClassDefOverride(TEveSelectorToEventList, 2); // TSelector that stores entry numbers of matching TTree entries into an event-list.
37};
38
39/******************************************************************************/
40// TEvePointSelectorConsumer, TEvePointSelector
41/******************************************************************************/
42
44
46{
47public:
49
50protected:
51 ETreeVarType_e fSourceCS; // Coordinate-System of the source tree variables
52
53public:
56
57 virtual void InitFill(Int_t /*subIdNum*/) {}
58 virtual void TakeAction(TEvePointSelector*) = 0;
59
62
63 ClassDef(TEvePointSelectorConsumer, 1); // Virtual base for classes that can be filled from TTree data via the TEvePointSelector class.
64};
65
67{
70
71protected:
74
77
80
82
83public:
85 const char* vexp="", const char* sel="");
86 ~TEvePointSelector() override {}
87
88 virtual Long64_t Select(const char* selection=nullptr);
89 virtual Long64_t Select(TTree* t, const char* selection=nullptr);
90 void TakeAction() override;
91
92
93 TTree* GetTree() const { return fSelectTree; }
94 void SetTree(TTree* t) { fSelectTree = t; }
95
98
99 const char* GetVarexp() const { return fVarexp; }
100 void SetVarexp(const char* v) { fVarexp = v; }
101
102 const char* GetSelection() const { return fSelection; }
103 void SetSelection(const char* s) { fSelection = s; }
104
105 const char* GetSubIdExp() const { return fSubIdExp; }
106 void SetSubIdExp(const char* s) { fSubIdExp = s; }
107
108 Int_t GetSubIdNum() const { return fSubIdNum; }
109
110 ClassDefOverride(TEvePointSelector, 2); // TSelector for direct extraction of point-like data from a Tree.
111};
112
113#endif
#define c(i)
Definition RSha256.hxx:101
bool Bool_t
Definition RtypesCore.h:63
long long Long64_t
Definition RtypesCore.h:80
#define ClassDef(name, id)
Definition Rtypes.h:337
#define ClassDefOverride(name, id)
Definition Rtypes.h:341
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char Point_t Rectangle_t WindowAttributes_t Float_t Float_t Float_t Int_t Int_t UInt_t UInt_t Rectangle_t Int_t Int_t Window_t TString Int_t GCValues_t GetPrimarySelectionOwner GetDisplay GetScreen GetColormap GetNativeEvent const char const char dpyName wid window const char font_name cursor keysym reg const char only_if_exist regb h Point_t winding char text const char depth char const char Int_t count const char ColorStruct_t color const char Pixmap_t Pixmap_t PictureAttributes_t attr const char char ret_data h unsigned char height h Atom_t Int_t ULong_t ULong_t unsigned char prop_list Atom_t sel
TEvePointSelectorConsumer is a virtual base for classes that can be filled from TTree data via the TE...
void SetSourceCS(ETreeVarType_e cs)
virtual void TakeAction(TEvePointSelector *)=0
ETreeVarType_e GetSourceCS() const
TEvePointSelectorConsumer(ETreeVarType_e cs=kTVT_XYZ)
virtual void InitFill(Int_t)
TEvePointSelector is a sub-class of TSelectorDraw for direct extraction of point-like data from a Tre...
const char * GetSelection() const
TEvePointSelectorConsumer * GetConsumer() const
const char * GetVarexp() const
~TEvePointSelector() override
void SetSubIdExp(const char *s)
void TakeAction() override
Callback from tree-player after a chunk of data has been processed.
TTree * GetTree() const
virtual Long64_t Select(const char *selection=nullptr)
Process the tree, select points matching 'selection'.
void SetTree(TTree *t)
Int_t GetSubIdNum() const
TEvePointSelectorConsumer * fConsumer
const char * GetSubIdExp() const
void SetVarexp(const char *v)
TEvePointSelector(const TEvePointSelector &)=delete
void SetConsumer(TEvePointSelectorConsumer *c)
TEvePointSelector & operator=(const TEvePointSelector &)=delete
void SetSelection(const char *s)
TSelector that stores entry numbers of matching TTree entries into an event-list.
TEveSelectorToEventList & operator=(const TEveSelectorToEventList &)=delete
Bool_t Process(Long64_t entry) override
Process entry.
TEveSelectorToEventList(const TEveSelectorToEventList &)=delete
Int_t Version() const override
A TEventList object is a list of selected events (entries) in a TTree.
Definition TEventList.h:31
A doubly linked list.
Definition TList.h:38
A specialized TSelector for TTree::Draw.
Basic string class.
Definition TString.h:139
A TTree represents a columnar dataset.
Definition TTree.h:79