24 #include "WatcherClient.h"
40 TDirectory *Watcher_dir = gROOT, *Watcher_dir_tag = gROOT;
44 Watcher_dir_tag = file_tag;
48 TTask *Snooper =
new LoopOnTasks(Watcher_dir,Watcher_dir_tag);
65 WatcherClient *wEventPSA =
new WatcherClient(
"EB",
"Watchers to analyse data after the Event Builder",Watcher_dir,Watcher_dir_tag);
67 Snooper->Add ( wEventPSA );
74 WatcherClient *wMerger =
new WatcherClient(
"MERGER",
"Watchers to analyse data @ the MERGER level",Watcher_dir,Watcher_dir_tag);
76 Snooper->Add ( wMerger );
86 Snooper->Add ( wTrack );
95 Snooper->Add(TSCollector);
98 gROOT->GetListOfTasks()->Add(Snooper);
100 if ( !gROOT->IsBatch() ) {
101 TBrowser *
b = (TBrowser*)gROOT->GetListOfBrowsers()->Last();
103 TFolder *GwWatchersFolder = (TFolder*)gROOT->GetRootFolder()->FindObject(
"GwWatchers");
104 if(GwWatchersFolder) b->Add(GwWatchersFolder);
106 TFolder *RootFilesFolder = (TFolder*)gROOT->GetRootFolder()->FindObject(
"ROOT Files");
107 if(RootFilesFolder) b->Add(RootFilesFolder);
110 Snooper->ExecuteTask(
"l");
Bool_t SetupWatchers(const char *df_type, FrameDispatcher *fd, const char *ext="")
It shows how to set up the watchers for different kind of data flow.
void CloseOnlineWatchers()
void SetAutoTime(Int_t autotime=0)
change time to autosave
void DoTSRateCollector(TTask *top_task, TSRateCollector *collector)
browse all dispatchers to look for TSRate Watcher and add them to the rate collector ...
To get a buffer from an actor, trigg on a Frame and dispach the Frame to sub-watchers.
Bool_t SetConnection(const Char_t *machine="localhost", UInt_t port=9090)
change the place where are picked data
void OnlineWatchersGLP(TFile *file=0x0, TFile *file_tag=0x0, Bool_t start_loop=false)
This is the default configuration.
To start a loop on tasks.
virtual void SetDirectory(TDirectory *mother_dir_of_watcher, TDirectory *mother_dir_tag, Bool_t load_objects=true)
to change the directory in which watcher's objects are stored
compute histograms for several TSRate