Logo ROOT  
Reference Guide
 
Loading...
Searching...
No Matches
TProofProgressLog.cxx
Go to the documentation of this file.
1// @(#)root/sessionviewer:$Id$
2// Author: G Ganis, Jul 2005
3
4/*************************************************************************
5 * Copyright (C) 1995-2005, 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#include "TError.h"
13#include "TPRegexp.h"
14#include "TGFrame.h"
15#include "TGTextView.h"
16#include "TGLabel.h"
17#include "TProof.h"
19#include "TProofProgressLog.h"
20#include "TProofLog.h"
21#include "TGNumberEntry.h"
22#include "TGListBox.h"
23#include "TGButton.h"
24
25const UInt_t kLogElemFilled = BIT(17); // If the log element has been retrieved at least once
26const UInt_t kDefaultActive = BIT(18); // If the log element is active by default
27
28
29/** \class TProofProgressLog
30 \ingroup sessionviewer
31
32Dialog used to display Proof session logs from the Proof progress
33dialog.
34It uses TProofMgr::GetSessionLogs() mechanism internally
35
36*/
37
38
40
41////////////////////////////////////////////////////////////////////////////////
42/// Create a window frame for log messages.
43
45 TGTransientFrame(gClient->GetRoot(), gClient->GetRoot(), w, h)
46{
47 fDialog = d;
49 fSessionIdx = 0;
50
51 Init(w, h);
52}
53
54////////////////////////////////////////////////////////////////////////////////
55/// Create a window frame for log messages.
56
58 TGTransientFrame(gClient->GetRoot(), gClient->GetRoot(), w, h)
59{
60 fDialog = 0;
61 fSessionUrl = url;
62 fSessionIdx = (idx > 0) ? -idx : idx;
63
64 Init(w, h);
65}
66
67////////////////////////////////////////////////////////////////////////////////
68/// Init window frame for log messages.
69
71{
72 fProofLog = 0;
75 // use hierarchical cleaning
77
78 //The text window
79 TGHorizontalFrame *htotal = new TGHorizontalFrame(this, w, h);
80 TGVerticalFrame *vtextbox = new TGVerticalFrame(htotal, w, h);
81 //fText = new TGTextView(this, w, h);
82 fText = new TGTextView(vtextbox, w, h);
83 vtextbox->AddFrame(fText, new TGLayoutHints(kLHintsTop | kLHintsExpandX | kLHintsExpandY, 3, 3, 3, 3));
84
85 //The frame for choosing workers
86 fVworkers = new TGVerticalFrame(htotal);
87 // URL choice
88 TGLabel *laburl = new TGLabel(fVworkers, "Enter cluster URL:");
89 fVworkers->AddFrame(laburl, new TGLayoutHints(kLHintsTop | kLHintsLeft, 5, 2, 2, 2));
93 //The lower row of number entries and buttons
94 TGHorizontalFrame *hfurlbox = new TGHorizontalFrame(fVworkers, 20, 20);
95 TGLabel *labsess = new TGLabel(hfurlbox, "Enter session:");
96 hfurlbox->AddFrame(labsess, new TGLayoutHints(kLHintsCenterY | kLHintsLeft, 5, 2, 2, 2));
97 fSessNum = new TGNumberEntry(hfurlbox, 0, 5, -1, TGNumberFormat::kNESInteger);
100 fSessNum->GetNumberEntry()->SetToolTipText("Use 0 for the last known one,"
101 " negative numbers for the previous ones, e.g. -1 for the last-but-one");
102 hfurlbox->AddFrame(fSessNum, new TGLayoutHints(kLHintsCenterY | kLHintsLeft, 2, 0, 0, 0));
103 fUrlButton = new TGTextButton(hfurlbox, "Get logs info");
104 fUrlButton->Connect("Clicked()", "TProofProgressLog", this, "Rebuild()");
105 hfurlbox->AddFrame(fUrlButton, new TGLayoutHints(kLHintsCenterY | kLHintsRight, 4, 0, 0, 0));
106 fVworkers->AddFrame(hfurlbox, new TGLayoutHints(kLHintsTop | kLHintsLeft | kLHintsExpandX, 2, 2, 2, 2));
107
108 TGNumberEntry *nent = new TGNumberEntry(hfurlbox);
109 fVworkers->AddFrame(nent, new TGLayoutHints(kLHintsTop | kLHintsLeft, 4, 0, 0, 0));
110
111 //The list of workers
112 fLogList = 0;
114 fLogList->Resize(102,52);
116
117 //The SelectAll/ClearAll buttons
118 TGHorizontalFrame *hfselbox = new TGHorizontalFrame(fVworkers, 20, 20);
119 TGLabel *label1 = new TGLabel(hfselbox,"Choose workers:");
120 hfselbox->AddFrame(label1, new TGLayoutHints(kLHintsCenterY | kLHintsLeft, 0, 0, 0, 0));
121 TGTextButton *selall = new TGTextButton(hfselbox, " &All ");
122 selall->Connect("Clicked()", "TProofProgressLog", this, "Select(=0)");
123 hfselbox->AddFrame(selall, new TGLayoutHints(kLHintsCenterY | kLHintsRight, 10, 0, 0, 0));
124 TGTextButton *clearall = new TGTextButton(hfselbox, " &Clear ");
125 clearall->Connect("Clicked()", "TProofProgressLog", this, "Select(=1)");
126 hfselbox->AddFrame(clearall, new TGLayoutHints(kLHintsCenterY | kLHintsRight, 10, 0, 0, 0));
127
128 //select the default actives to start with
129 Select(0, kFALSE);
130
131 //Display button
132 fLogNew = new TGTextButton(fVworkers, "&Display");
133 fLogNew->Connect("Clicked()", "TProofProgressLog", this, "DoLog(=kFALSE)");
134 //fLogNew->Resize(102, 20);
135 // fLogNew->SetMargins(1, 1, 0, 1);
136 fLogNew->SetTextColor(0xffffff, kFALSE);
137 fLogNew->SetBackgroundColor(0x000044);
138 fVworkers->AddFrame(hfselbox, new TGLayoutHints(kLHintsExpandX | kLHintsTop, 5, 2, 2, 2));
141
143
144 //The lower row of number entries and buttons
145 TGHorizontalFrame *hflogbox = new TGHorizontalFrame(vtextbox, 550, 20);
146 fClose = new TGTextButton(hflogbox, " &Close ");
147 fClose->Connect("Clicked()", "TProofProgressLog", this, "CloseWindow()");
149 kLHintsRight, 10, 2, 2, 2));
150
151 //Saving to a file controls
152 fSave = new TGTextButton(hflogbox, "&Save");
153 fSave->Connect("Clicked()", "TProofProgressLog", this, "SaveToFile()");
154 hflogbox->AddFrame(fSave, new TGLayoutHints(kLHintsCenterY | kLHintsRight, 4, 0, 0, 0));
155 fFileName = new TGTextEntry(hflogbox);
156 fFileName->SetText("<session-tag>.log");
158 TGLabel *label10 = new TGLabel(hflogbox, "Save to a file:");
159 hflogbox->AddFrame(label10, new TGLayoutHints(kLHintsCenterY | kLHintsRight, 50, 2, 2, 2));
160
161 //Choose the number of lines to display
162 TGVerticalFrame *vlines = new TGVerticalFrame(hflogbox);
163 TGHorizontalFrame *vlines_buttons = new TGHorizontalFrame(vlines);
164 TGLabel *label2 = new TGLabel(vlines_buttons, "Lines:");
165 vlines_buttons->AddFrame(label2, new TGLayoutHints(kLHintsCenterY | kLHintsLeft, 2, 2, 2, 2));
166
167 fAllLines = new TGCheckButton(vlines_buttons, "all");
168 fAllLines->SetToolTipText("Retrieve all lines (service messages excluded)");
170 fAllLines->Connect("Clicked()", "TProofProgressLog", this, "NoLineEntry()");
171 vlines_buttons->AddFrame(fAllLines, new TGLayoutHints(kLHintsCenterY | kLHintsLeft, 2, 2, 2, 2));
172
173 fRawLines = new TGCheckButton(vlines_buttons, "svcmsg");
174 fRawLines->SetToolTipText("Retrieve all type of lines, service messages included");
176 vlines_buttons->AddFrame(fRawLines, new TGLayoutHints(kLHintsCenterY | kLHintsLeft, 2, 2, 2, 2));
177
178 TGLabel *label11 = new TGLabel(vlines_buttons, "From");
179 vlines_buttons->AddFrame(label11, new TGLayoutHints(kLHintsCenterY | kLHintsLeft, 2, 2, 2, 2));
180
181 fLinesFrom = new TGNumberEntry(vlines_buttons, 0, 5, -1, TGNumberFormat::kNESInteger);
182 // coverity[negative_returns]: no problem with -100, the format is kNESInteger
184 fLinesFrom->GetNumberEntry()->SetToolTipText("Negative values indicate \"tail\" action");
185
186
187 vlines_buttons->AddFrame(fLinesFrom, new TGLayoutHints(kLHintsCenterY | kLHintsLeft, 2, 2, 2, 2));
188
189 TGLabel *label3 = new TGLabel(vlines_buttons, "to");
190 vlines_buttons->AddFrame(label3, new TGLayoutHints(kLHintsCenterY | kLHintsLeft, 2, 2, 2, 2));
191 fLinesTo = new TGNumberEntry(vlines_buttons, 0, 5, -1, TGNumberFormat::kNESInteger);
192 vlines_buttons->AddFrame(fLinesTo, new TGLayoutHints(kLHintsCenterY | kLHintsLeft, 2, 2, 2, 2));
193 vlines->AddFrame(vlines_buttons, new TGLayoutHints(kLHintsCenterY));
194 hflogbox->AddFrame(vlines, new TGLayoutHints(kLHintsCenterY | kLHintsLeft, 2, 2, 2, 2));
195
196 //
197 // Lowest line, with filter (grep or cmd pipe) controls
198 //
199
200 TGHorizontalFrame *hfgrepbox = new TGHorizontalFrame(vtextbox, 550, 20);
201
202 // Grep/pipe label, textbox and button
203 fGrepLabel = new TGLabel(hfgrepbox, "");
204 hfgrepbox->AddFrame(fGrepLabel, new TGLayoutHints(kLHintsCenterY | kLHintsLeft, 2, 2, 2, 2));
205 fGrepText = new TGTextEntry(hfgrepbox);
206 {
209 }
211 fGrepButton = new TGTextButton(hfgrepbox, "Filter");
212 fGrepButton->Connect("Clicked()", "TProofProgressLog", this, "DoLog(=kTRUE)");
213 hfgrepbox->AddFrame(fGrepButton, new TGLayoutHints(kLHintsCenterY | kLHintsLeft, 4, 10, 0, 0)); // l r t b
214
215 // Checkbox for inverting selection or giving a pipe command
216 fGrepCheckInv = new TGCheckButton(hfgrepbox, "invert match");
217 fGrepCheckInv->Connect("Clicked()", "TProofProgressLog", this, "SetGrepView()");
218 hfgrepbox->AddFrame(fGrepCheckInv, new TGLayoutHints(kLHintsCenterY | kLHintsLeft, 2, 2, 2, 2));
219
220 fGrepCheckCmd = new TGCheckButton(hfgrepbox, "is a pipe command");
221 fGrepCheckCmd->Connect("Clicked()", "TProofProgressLog", this, "SetGrepView()");
222 hfgrepbox->AddFrame(fGrepCheckCmd, new TGLayoutHints(kLHintsCenterY | kLHintsLeft, 2, 2, 2, 2));
223
224 // fRawLines->SetToolTipText("Retrieve all type of lines, service messages included");
225 // fRawLines->SetState(kButtonUp);
226 // vlines_buttons->AddFrame(fRawLines, new TGLayoutHints(kLHintsCenterY | kLHintsLeft, 2, 2, 2, 2));
227
228 //
229 // Add frames to the global picture
230 //
231
232 vtextbox->AddFrame(hflogbox, new TGLayoutHints(kLHintsTop | kLHintsLeft | kLHintsExpandX, 2, 2, 2, 2));
233 vtextbox->AddFrame(hfgrepbox, new TGLayoutHints(kLHintsBottom | kLHintsLeft | kLHintsExpandX, 2, 2, 2, 2));
234 htotal->AddFrame(vtextbox, new TGLayoutHints(kLHintsExpandX | kLHintsExpandY | kLHintsRight, 3, 3, 3, 3));
236 kLHintsExpandY, 3, 3, 3, 3));
237 SetGrepView();
239 Resize();
241 Popup();
242}
243
244////////////////////////////////////////////////////////////////////////////////
245/// Destructor
246
248{
249 // Cleanup the log object
251
252 // Detach from owner dialog
253 if (fDialog) {
254 fDialog->fLogWindow = 0;
255 fDialog->fProof->Disconnect("LogMessage(const char*,Bool_t)", this,
256 "LogMessage(const char*,Bool_t)");
257 }
258}
259
260////////////////////////////////////////////////////////////////////////////////
261/// Show log window.
262
264{
265 MapWindow();
266}
267
268////////////////////////////////////////////////////////////////////////////////
269/// Clear log window.
270
272{
273 if (fText)
274 fText->Clear();
275}
276
277////////////////////////////////////////////////////////////////////////////////
278/// Load a text buffer in the window.
279
280void TProofProgressLog::LoadBuffer(const char *buffer)
281{
282 if (fText)
283 fText->LoadBuffer(buffer);
284}
285
286////////////////////////////////////////////////////////////////////////////////
287/// Load a file in the window.
288
290{
291 if (fText)
293}
294
295////////////////////////////////////////////////////////////////////////////////
296/// Add text to the window.
297
298void TProofProgressLog::AddBuffer(const char *buffer)
299{
300 if (fText) {
301 TGText txt;
302 txt.LoadBuffer(buffer);
303 fText->AddText(&txt);
304 }
305}
306
307////////////////////////////////////////////////////////////////////////////////
308/// Handle close button or when closed via window manager action.
309
311{
312 DeleteWindow();
313}
314
315////////////////////////////////////////////////////////////////////////////////
316/// Build the list of workers. For this, extract the logs and take the names
317/// of TProofLogElements
318
320{
321 // Set title
322 TString title;
323 title.Form("PROOF - Processing logs for session 'undefined'");
324 SetWindowName(title.Data());
325 SetIconName(title.Data());
326
327 // Create the list-box now
328 if (create) {
329 if (fLogList) delete fLogList;
331 } else {
332 // Reset
334 fLogList->RemoveEntries(0,nent);
335 fLogList->Layout();
336 }
337
338 if (fSessionUrl.IsNull()) {
339 if (gDebug > 0)
340 Info("BuildLogList", "session URL undefined - do nothing");
341 return;
342 }
344 if (!mgr || !mgr->IsValid()) {
345 Warning("BuildLogList", "unable open a manager connection to %s",
346 fSessionUrl.Data());
347 return;
348 }
349 if (!(fProofLog = mgr->GetSessionLogs(fSessionIdx,"NR"))) {
350 Warning("BuildLogList", "unable to get logs from %s",
351 fSessionUrl.Data());
352 return;
353 }
354 // Set title
355 title.Form("PROOF - Processing logs for session '%s', started on %s at %s",
358 SetWindowName(title.Data());
359 SetIconName(title.Data());
360
361 TList *elem = fProofLog->GetListOfLogs();
362 TIter next(elem);
363 TProofLogElem *pe = 0;
364
365 Int_t is = 0;
366 TGLBEntry *ent = 0;
367 TString buf;
368 while ((pe=(TProofLogElem*)next())){
369 TUrl url(pe->GetTitle());
370 buf.Form("%s %s", pe->GetName(), url.GetHost());
371 fLogList->AddEntry(buf.Data(), is);
372 if ((ent = fLogList->FindEntry(buf.Data()))) {
375 if (!(pe->IsWorker())) ent->SetBit(kDefaultActive);
376 }
377 is++;
378 }
379
380 // Done
381 return;
382}
383
384////////////////////////////////////////////////////////////////////////////////
385/// Display logs. 'grep' is set to kTRUE if it is invoked by pressing the
386/// 'Filter' button.
387
389{
390 Clear();
391
392 if (!fGrepText) {
393 Warning("DoLog", "no text: do nothing!");
394 return;
395 }
396
397 TString greptext = fGrepText->GetText();
398 greptext.Remove(TString::kBoth, ' ');
399 if (greptext.IsNull()) {
400 grep = kFALSE;
401 }
402 else if (!fGrepCheckCmd->IsOn()) {
403 // Not a command: sanitize string
404 TPMERegexp san("(^|[^\\\\])([^a-zA-Z0-9_=\\\\/.-])");
405 while ( san.Substitute(greptext, "$1\\$2") > 0 );
406 }
407
408 Int_t from, to;
409 if (fAllLines->IsOn()){
410 from = 0;
411 to = -1;
412 } else {
413 from = fLinesFrom->GetIntNumber();
414 to = fLinesTo->GetIntNumber();
415 }
416
417 // Create the TProofLog instance
418 if (!fProofLog) {
419 TProofMgr *mgr = 0;
420 if ((mgr = TProof::Mgr(fSessionUrl.Data()))) {
421 if (!(fProofLog = mgr->GetSessionLogs(fSessionIdx, "NR"))) {
422 Warning("DoLog", "unable to instantiate TProofLog for %s",
423 fSessionUrl.Data());
424 }
425 } else {
426 Warning("DoLog", "unable to instantiate a TProofMgr for %s",
427 fSessionUrl.Data());
428 }
429 }
430
431 // Pipe command for filtering
432 TString pipeCommand;
433
434 // Filter out SvcMsg
435 if (!fRawLines->IsOn()) {
436 pipeCommand = "grep -v \"| SvcMsg\"";
437 }
438
439 // Default is not retrieving
441 if (!grep) {
442 // Not invoked via 'Filter' button
443 if (!fFullText ||
444 ((fTextType != kRaw && fRawLines->IsOn()) ||
445 (fTextType != kStd && !fRawLines->IsOn())) ||
447 retrieve = kTRUE;
448 if (fRawLines->IsOn()) {
449 fTextType = kRaw;
450 } else {
451 fTextType = kStd;
452 }
455 }
456 } else {
457 retrieve = kTRUE;
459
460 if (!pipeCommand.IsNull())
461 pipeCommand.Append('|');
462
463 if (fGrepCheckCmd->IsOn()) {
464 pipeCommand.Append(greptext);
465 }
466 else {
467 pipeCommand.Append("grep ");
468 if (fGrepCheckInv->IsOn())
469 pipeCommand.Append("-v ");
470 pipeCommand.Append("-- ");
471 pipeCommand.Append(greptext); // sanitized
472 }
473
476 }
477
478 // Display now
479 if (fProofLog) {
480 TList *selected = new TList;
481 fLogList->GetSelectedEntries(selected);
482 TIter next(selected);
483 TGTextLBEntry *selentry;
484 Bool_t logonly = fProofLog->LogToBox();
486
487 fProofLog->Connect("Prt(const char*)", "TProofProgressLog",
488 this, "LogMessage(const char*, Bool_t)");
489 while ((selentry=(TGTextLBEntry*)next())){
490 TString ord = selentry->GetText()->GetString();
491 Int_t is = ord.Index(" ");
492 if (is != kNPOS) ord.Remove(is);
493 if (retrieve || !selentry->TestBit(kLogElemFilled)) {
494 pipeCommand.Prepend('|');
495 if (fTextType == kRaw) {
496 if (gDebug >= 2)
497 Info("DoLog", "Retrieving unfiltered log for %s", ord.Data());
499 }
500 else {
501 if (gDebug >= 2)
502 Info("DoLog", "Retrieving log for %s filtered with %s",
503 ord.Data(), pipeCommand.Data());
504 fProofLog->Retrieve(ord.Data(), TProofLog::kGrep, 0, pipeCommand.Data());
505 }
506 selentry->SetBit(kLogElemFilled);
507 }
508 fProofLog->Display(ord.Data(), from, to);
509 }
510 fProofLog->SetLogToBox(logonly);
511 fProofLog->Disconnect("Prt(const char*)", this, "LogMessage(const char*, Bool_t)");
512 delete selected;
513 }
514}
515
516////////////////////////////////////////////////////////////////////////////////
517/// Load/append a log msg in the log frame, if open
518
519void TProofProgressLog::LogMessage(const char *msg, Bool_t all)
520{
521 if (all) {
522 // load buffer
523 LoadBuffer(msg);
524 } else {
525 // append
526 AddBuffer(msg);
527 }
528}
529
530////////////////////////////////////////////////////////////////////////////////
531///Save the logs to a file
532///Only the name of the file is taken, no expansion
533
535{
536 if (!fProofLog) DoLog();
537
538 // File name: the default is <session-tag>.log
539 TString filename = fFileName->GetText();
540 if (filename.IsNull() || filename == "<session-tag>.log") {
541 filename = (fDialog && fDialog->fProof) ?
542 TString::Format("%s.log", fDialog->fProof->GetName()) :
543 TString("proof.log");
544 }
545
546 TList *selected = new TList;
547 fLogList->GetSelectedEntries(selected);
548 TIter next(selected);
549 TGTextLBEntry *selentry;
550 Bool_t writemode=kTRUE;
551 const char *option;
552 TString ord;
553 while ((selentry=(TGTextLBEntry*)next())){
554 ord = selentry->GetText()->GetString();
555 Int_t isp = ord.Index(' ');
556 if (isp != kNPOS) ord.Remove(isp);
557 //open the file in "w" mode for the first time
558 option = writemode ? "w" : "a";
559 fProofLog->Save(ord.Data(), filename.Data(), option);
560 writemode=kFALSE;
561 }
562 delete selected;
563
564 Info("SaveToFile", "logs saved to file %s", filename.Data());
565}
566
567////////////////////////////////////////////////////////////////////////////////
568/// Sets the view of grep filters according to the value of checkboxes
569
571{
572 if (fGrepCheckCmd->IsOn()) {
573 fGrepLabel->SetText("Pipe log through command:");
575 }
576 else {
577 fGrepLabel->SetText("Grep:");
580 if (u) {
581 fGrepLabel->SetText("Show lines not matching:");
583 }
584 else {
585 fGrepLabel->SetText("Show lines matching:");
587 }
588 }
589
590 // Ugly but necessary const_cast
591 TGFrame *frame = dynamic_cast<TGFrame *>( const_cast<TGWindow *>(fGrepLabel->GetParent()) );
592 if (frame) frame->Layout();
593
594}
595
596////////////////////////////////////////////////////////////////////////////////
597///Enable/disable the line number entry
598
600{
601 if (fAllLines->IsOn()){
602 //disable the line number entry
605 } else {
608 }
609}
610
611////////////////////////////////////////////////////////////////////////////////
612///actions of select all/clear all button
613
615{
617 Bool_t sel = id ? 0 : 1;
618
619 TGLBEntry *ent = 0;
620 for (Int_t ie=0; ie<nen; ie++) {
621 if (all) {
622 fLogList->Select(ie, sel);
623 } else {
624 if ((ent = fLogList->GetEntry(ie))) {
625 if (ent->TestBit(kDefaultActive)) fLogList->Select(ie, sel);
626 }
627 }
628 }
629}
630
631
632////////////////////////////////////////////////////////////////////////////////
633/// Rebuild the log info for a new entered session
634
636{
637 // Check if we need to remake the TProofLog object
638 Bool_t sameurl = kFALSE;
639 TUrl url(fUrlText->GetText());
640 TUrl urlref(fSessionUrl.Data());
641 if (!strcmp(url.GetHostFQDN(), urlref.GetHostFQDN())) {
642 if (url.GetPort() == urlref.GetPort()) {
643 if (!strcmp(url.GetUser(), urlref.GetUser())) {
644 sameurl = kTRUE;
645 }
646 }
647 }
648 Int_t idx = 0;
649 if (sameurl) {
650 idx = fSessNum->GetIntNumber();
651 if (idx == fSessionIdx) {
652 Info("Rebuild", "same parameters {%s, %s}, {%d, %d}: no need to rebuild TProofLog",
653 url.GetUrl(), urlref.GetUrl(), idx, fSessionIdx);
654 return;
655 }
656 }
657 // Cleanup current TProofLog
658 if (fProofLog) {
659 delete fProofLog;
660 fProofLog = nullptr;
661 }
662
663 // Set new parameters
665 fSessionIdx = idx;
666
667 // Rebuild the list now
669
670 // Select the default actives to start with
671 Select(0, kFALSE);
672 // Redraw
673 fLogList->Layout();
674
675 // Done
676 return;
677}
#define SafeDelete(p)
Definition RConfig.hxx:537
#define d(i)
Definition RSha256.hxx:102
#define h(i)
Definition RSha256.hxx:106
static void retrieve(const gsl_integration_workspace *workspace, double *a, double *b, double *r, double *e)
const Ssiz_t kNPOS
Definition RtypesCore.h:124
unsigned int UInt_t
Definition RtypesCore.h:46
const Bool_t kFALSE
Definition RtypesCore.h:101
const Bool_t kTRUE
Definition RtypesCore.h:100
const char Option_t
Definition RtypesCore.h:66
#define BIT(n)
Definition Rtypes.h:85
#define ClassImp(name)
Definition Rtypes.h:364
void Info(const char *location, const char *msgfmt,...)
Use this function for informational messages.
Definition TError.cxx:220
void Warning(const char *location, const char *msgfmt,...)
Use this function in warning situations.
Definition TError.cxx:231
@ kButtonDown
Definition TGButton.h:54
@ kButtonUp
Definition TGButton.h:53
#define gClient
Definition TGClient.h:157
@ kDeepCleanup
Definition TGFrame.h:42
@ kLHintsRight
Definition TGLayout.h:26
@ kLHintsExpandY
Definition TGLayout.h:31
@ kLHintsLeft
Definition TGLayout.h:24
@ kLHintsCenterY
Definition TGLayout.h:28
@ kLHintsBottom
Definition TGLayout.h:29
@ kLHintsTop
Definition TGLayout.h:27
@ kLHintsExpandX
Definition TGLayout.h:30
const UInt_t kDefaultActive
const UInt_t kLogElemFilled
Int_t gDebug
Definition TROOT.cxx:592
const char * AsString() const
Return the date & time as a string (ctime() format).
Definition TDatime.cxx:102
virtual void SetToolTipText(const char *text, Long_t delayms=400)
Set tool tip text associated with this button.
Definition TGButton.cxx:445
virtual void SetEnabled(Bool_t e=kTRUE)
Set enabled or disabled state of button.
Definition TGButton.cxx:459
Selects different options.
Definition TGButton.h:264
virtual Bool_t IsOn() const
Definition TGButton.h:311
virtual void SetDisabledAndSelected(Bool_t)
Set the state of a check button to disabled and either on or off.
virtual void SetState(EButtonState state, Bool_t emit=kFALSE)
Set check button state.
virtual void AddFrame(TGFrame *f, TGLayoutHints *l=0)
Add frame to the composite frame using the specified layout hints.
Definition TGFrame.cxx:1117
virtual void SetCleanup(Int_t mode=kLocalCleanup)
Turn on automatic cleanup of child frames in dtor.
Definition TGFrame.cxx:1072
virtual void MapSubwindows()
Map all sub windows that are part of the composite frame.
Definition TGFrame.cxx:1164
UInt_t fHeight
Definition TGDimension.h:21
A subclasses of TGWindow, and is used as base class for some simple widgets (buttons,...
Definition TGFrame.h:80
virtual void SetBackgroundColor(Pixel_t back)
Set background color (override from TGWindow base class).
Definition TGFrame.cxx:312
virtual void DeleteWindow()
Delete window.
Definition TGFrame.cxx:276
virtual void Resize(UInt_t w=0, UInt_t h=0)
Resize the frame.
Definition TGFrame.cxx:605
virtual void Layout()
Definition TGFrame.h:199
virtual void MapWindow()
map window
Definition TGFrame.h:204
A composite frame that layout their children in horizontal way.
Definition TGFrame.h:386
Basic listbox entries.
Definition TGListBox.h:24
This class handles GUI labels.
Definition TGLabel.h:24
virtual void SetText(TGString *newText)
Set new text in label.
Definition TGLabel.cxx:180
This class describes layout hints used by the layout classes.
Definition TGLayout.h:50
A listbox is a box, possibly with scrollbar, containing entries.
Definition TGListBox.h:221
virtual void Resize(UInt_t w, UInt_t h)
Resize the listbox widget.
virtual TGLBEntry * Select(Int_t id, Bool_t sel=kTRUE)
Definition TGListBox.h:284
virtual Int_t GetNumberOfEntries() const
Definition TGListBox.h:263
virtual void AddEntry(TGString *s, Int_t id)
Add entry with specified string and id to listbox.
virtual TGLBEntry * GetEntry(Int_t id) const
Returns list box entry with specified id.
virtual void SetMultipleSelections(Bool_t multi=kTRUE)
Definition TGListBox.h:259
virtual void Layout()
Layout the listbox components.
virtual void GetSelectedEntries(TList *selected)
Adds all selected entries (TGLBEntry) of the list box into the list selected.
virtual void RemoveEntries(Int_t from_ID, Int_t to_ID)
Remove a range of entries defined by from_ID and to_ID.
virtual TGLBEntry * FindEntry(const char *s) const
Find entry by name.
void SetIconName(const char *name)
Set window icon name. This is typically done via the window manager.
Definition TGFrame.cxx:1801
void SetWindowName(const char *name=0)
Set window name. This is typically done via the window manager.
Definition TGFrame.cxx:1788
TGNumberEntry is a number entry input widget with up/down buttons.
TGNumberEntryField * GetNumberEntry() const
virtual void SetLimits(ELimit limits=TGNumberFormat::kNELNoLimits, Double_t min=0, Double_t max=1)
virtual void SetState(Bool_t enable=kTRUE)
Set the active state.
virtual void SetIntNumber(Long_t val, Bool_t emit=kTRUE)
virtual Long_t GetIntNumber() const
@ kNESInteger
Style of number entry field.
@ kNELLimitMax
Upper limit only.
const char * GetString() const
Definition TGString.h:30
Yield an action as soon as it is clicked.
Definition TGButton.h:142
virtual void SetTextColor(Pixel_t color, Bool_t global=kFALSE)
Changes text color.
Definition TGButton.cxx:918
A TGTextEntry is a one line text input widget.
Definition TGTextEntry.h:24
virtual void SetDefaultSize(UInt_t w, UInt_t h)
Set the default / minimal size of the widget.
const char * GetText() const
virtual void SetToolTipText(const char *text, Long_t delayms=500)
Set tool tip text associated with this text entry.
virtual void SetText(const char *text, Bool_t emit=kTRUE)
Sets text entry to text, clears the selection and moves the cursor to the end of the line.
virtual TGDimension GetDefaultSize() const
Return the default / minimal size of the widget.
Text string listbox entries.
Definition TGListBox.h:48
const TGString * GetText() const
Definition TGListBox.h:79
A TGTextView is a text viewer widget.
Definition TGTextView.h:22
virtual Bool_t LoadFile(const char *fname, long startpos=0, long length=-1)
Load a file in the text view widget.
virtual Bool_t LoadBuffer(const char *txtbuf)
Load text from a text buffer. Return false in case of failure.
virtual void Clear(Option_t *="")
Clear text view widget.
virtual void AddText(TGText *text)
Add text to the view widget.
A TGText is a multi line text buffer.
Definition TGText.h:57
Bool_t LoadBuffer(const char *txtbuf)
Load a 0 terminated buffer. Lines will be split at ' '.
Definition TGText.cxx:513
Defines transient windows that typically are used for dialogs windows.
Definition TGFrame.h:499
virtual void CenterOnParent(Bool_t croot=kTRUE, EPlacement pos=kCenter)
Position transient frame centered relative to the parent frame.
Definition TGFrame.cxx:1955
A composite frame that layout their children in vertical way.
Definition TGFrame.h:375
ROOT GUI Window base class.
Definition TGWindow.h:23
const TGWindow * GetParent() const
Definition TGWindow.h:76
A doubly linked list.
Definition TList.h:38
virtual const char * GetTitle() const
Returns title of object.
Definition TNamed.h:48
virtual const char * GetName() const
Returns name of object.
Definition TNamed.h:47
R__ALWAYS_INLINE Bool_t TestBit(UInt_t f) const
Definition TObject.h:201
void SetBit(UInt_t f, Bool_t set)
Set or unset the user status bits as specified in f.
Definition TObject.cxx:766
void ResetBit(UInt_t f)
Definition TObject.h:200
Wrapper for PCRE library (Perl Compatible Regular Expressions).
Definition TPRegexp.h:97
Int_t Substitute(TString &s, const TString &r, Bool_t doDollarSubst=kTRUE)
Substitute matching part of s with r, dollar back-ref substitution is performed if doDollarSubst is t...
Definition TPRegexp.cxx:872
Bool_t IsWorker() const
Definition TProofLog.h:105
void Display(const char *ord="*", Int_t from=-10, Int_t to=-1)
Display the content associated with worker 'ord' from line 'from' to line 'to' inclusive.
TDatime StartTime()
Definition TProofLog.h:67
Int_t Save(const char *ord="*", const char *fname=0, Option_t *opt="w")
Save the content associated with worker 'ord' to finel 'fname'.
Int_t Retrieve(const char *ord="*", TProofLog::ERetrieveOpt opt=TProofLog::kTrailing, const char *fname=0, const char *pattern=0)
Retrieve the content of the log file associated with worker 'ord'.
Definition TProofLog.cxx:87
Bool_t LogToBox()
Definition TProofLog.h:71
TList * GetListOfLogs() const
Definition TProofLog.h:58
void SetLogToBox(Bool_t lgbox=kFALSE)
Definition TProofLog.h:70
The PROOF manager interacts with the PROOF server coordinator to create or destroy a PROOF session,...
Definition TProofMgr.h:43
virtual TProofLog * GetSessionLogs(Int_t=0, const char *=0, const char *="-v \"| SvcMsg\"", Bool_t=kFALSE)
Definition TProofMgr.h:91
virtual Bool_t IsValid() const
Definition TProofMgr.h:77
This class provides a query progress bar.
TProofProgressLog * fLogWindow
Dialog used to display Proof session logs from the Proof progress dialog.
virtual ~TProofProgressLog()
Destructor.
TGTextButton * fClose
void Select(Int_t id, Bool_t all=kTRUE)
actions of select all/clear all button
void Init(Int_t w=700, Int_t h=600)
Init window frame for log messages.
void Rebuild()
Rebuild the log info for a new entered session.
void DoLog(Bool_t grep=kFALSE)
Display logs.
TGCheckButton * fGrepCheckInv
TGTextEntry * fUrlText
TGTextButton * fGrepButton
TGVerticalFrame * fVworkers
TGCheckButton * fAllLines
void LogMessage(const char *msg, Bool_t all)
Load/append a log msg in the log frame, if open.
void SetGrepView()
Sets the view of grep filters according to the value of checkboxes.
TGNumberEntry * fSessNum
TGTextButton * fLogNew
void LoadBuffer(const char *buffer)
Load a text buffer in the window.
void AddBuffer(const char *buffer)
Add text to the window.
void BuildLogList(Bool_t create=kFALSE)
Build the list of workers.
TGTextButton * fUrlButton
TGCheckButton * fGrepCheckCmd
void Clear(Option_t *=0)
Clear log window.
TProofProgressDialog * fDialog
TProofProgressLog(TProofProgressDialog *d, Int_t w=700, Int_t h=600)
Create a window frame for log messages.
void LoadFile(const char *file)
Load a file in the window.
TGTextEntry * fGrepText
TGNumberEntry * fLinesTo
TGCheckButton * fRawLines
TGTextEntry * fFileName
TGTextButton * fSave
TGNumberEntry * fLinesFrom
void NoLineEntry()
Enable/disable the line number entry.
void CloseWindow()
Handle close button or when closed via window manager action.
void SaveToFile()
Save the logs to a file Only the name of the file is taken, no expansion.
void Popup()
Show log window.
static TProofMgr * Mgr(const char *url)
Get instance of the effective manager for 'url' Return 0 on failure.
Definition TProof.cxx:11724
Bool_t Connect(const char *signal, const char *receiver_class, void *receiver, const char *slot)
Non-static method is used to connect from the signal of this object to the receiver slot.
Definition TQObject.cxx:869
Bool_t Disconnect(const char *signal=0, void *receiver=0, const char *slot=0)
Disconnects signal of this object from slot of receiver.
Basic string class.
Definition TString.h:136
const char * Data() const
Definition TString.h:369
@ kBoth
Definition TString.h:267
TString & Prepend(const char *cs)
Definition TString.h:661
Bool_t IsNull() const
Definition TString.h:407
TString & Remove(Ssiz_t pos)
Definition TString.h:673
TString & Append(const char *cs)
Definition TString.h:564
static TString Format(const char *fmt,...)
Static method which formats a string using a printf style format descriptor and return a TString.
Definition TString.cxx:2336
void Form(const char *fmt,...)
Formats a string using a printf style format descriptor.
Definition TString.cxx:2314
Ssiz_t Index(const char *pat, Ssiz_t i=0, ECaseCompare cmp=kExact) const
Definition TString.h:639
This class represents a WWW compatible URL.
Definition TUrl.h:33
const char * GetUrl(Bool_t withDeflt=kFALSE) const
Return full URL.
Definition TUrl.cxx:389
const char * GetUser() const
Definition TUrl.h:65
const char * GetHost() const
Definition TUrl.h:67
const char * GetHostFQDN() const
Return fully qualified domain name of url host.
Definition TUrl.cxx:471
Int_t GetPort() const
Definition TUrl.h:78
Definition file.py:1