AlcapDAQ
1
|
#include <TOnlineFrame.h>
Public Member Functions | |
TOnlineFrame (const TGWindow *p, std::string module_file_name) | |
~TOnlineFrame () | |
void | CloseWindow () |
Bool_t | ProcessMessage (Long_t msg, Long_t param1, Long_t param2) |
void | ConsiderCycling () |
void | ConsiderAutoupdate (const Bool_t force=kFALSE) |
void | runMacro (const char *macro) |
void | print_msg (const char *msg, const Int_t partidx=0) |
const char * | getServerName () const |
void | setServerName (const char *name) |
const unsigned int | getServerPort () const |
void | setServerPort (const unsigned int port_nr) |
const unsigned int | getAutoUpdateTime () const |
TSocket * | ConnectToServer () |
TFile * | OpenRootFile (const char *filename, const Bool_t update_filename=kTRUE) |
TSocket * | GetSocketHandle () |
TH1 * | GetHist (const char *histname) |
std::vector< TString > | GetHistTitles () |
void | UpdateDisplay () |
Data Fields | |
std::set< std::string > | fLoadedMacros |
std::map< std::string, TGTextButton * > | fButtons |
Private Attributes | |
TGHorizontalFrame * | fTopFrame |
TGButton * | fUpdateButton |
TGButton * | fPrintButton |
TGButton * | fConnectButton |
TGButton * | fFileOpenButton |
TRootEmbeddedCanvas * | fEmbeddedCanvas |
TGCheckButton * | fCycleDisplays |
TGCheckButton * | fAutoUpdate |
TGTextEntry * | fAutoUpdateTime |
TGTextEntry * | fFileName |
int | fCurrentDisplay |
TGStatusBar * | fStatusBar |
TGTextEntry * | fServerName |
TGTextEntry * | fServerPort |
ULong_t | run_nr |
TSocket * | fpSock |
Definition at line 22 of file TOnlineFrame.h.
TOnlineFrame::TOnlineFrame | ( | const TGWindow * | p, |
std::string | module_file_name | ||
) |
Definition at line 34 of file TOnlineFrame.cpp.
References B_AUTOUPDATE, B_CONNECT, B_CYCLE, B_FILE_OPEN, B_PRINT, B_UPDATE, buf, fAutoUpdate, fAutoUpdateTime, fButtons, fConnectButton, fCurrentDisplay, fCycleDisplays, fEmbeddedCanvas, fFileName, fFileOpenButton, fPrintButton, fServerName, fServerPort, fStatusBar, fTopFrame, fUpdateButton, gROOT, screen_info::hasArgs, height, i, screen_info::macroArgs, screen_info::macroName, run_nr, screens, SCREENS_BASE, screen_info::visibleName, and width.
TOnlineFrame::~TOnlineFrame | ( | ) |
Definition at line 226 of file TOnlineFrame.cpp.
void TOnlineFrame::CloseWindow | ( | ) |
Definition at line 337 of file TOnlineFrame.cpp.
TSocket * TOnlineFrame::ConnectToServer | ( | ) |
Definition at line 398 of file TOnlineFrame.cpp.
References fEmbeddedCanvas, fFileName, fpSock, fServerName, getServerName(), getServerPort(), gROOT, msg, openSocket(), print_msg(), s, and sprintf().
Referenced by main(), and ProcessMessage().
void TOnlineFrame::ConsiderAutoupdate | ( | const Bool_t | force = kFALSE ) |
force | Force update if true |
Definition at line 360 of file TOnlineFrame.cpp.
References fAutoUpdate, fCurrentDisplay, fCycleDisplays, runMacro(), and screens.
Referenced by main(), and ProcessMessage().
void TOnlineFrame::ConsiderCycling | ( | ) |
Definition at line 344 of file TOnlineFrame.cpp.
References fCurrentDisplay, fCycleDisplays, runMacro(), and screens.
Referenced by main().
const unsigned int TOnlineFrame::getAutoUpdateTime | ( | ) | const |
TH1 * TOnlineFrame::GetHist | ( | const char * | histname) |
std::vector< TString > TOnlineFrame::GetHistTitles | ( | ) |
const char * TOnlineFrame::getServerName | ( | ) | const |
Definition at line 369 of file TOnlineFrame.cpp.
References fServerName.
Referenced by ConnectToServer().
const unsigned int TOnlineFrame::getServerPort | ( | ) | const |
Definition at line 379 of file TOnlineFrame.cpp.
References fServerPort.
Referenced by ConnectToServer().
|
inline |
TFile * TOnlineFrame::OpenRootFile | ( | const char * | filename, |
const Bool_t | update_filename = kTRUE |
||
) |
Definition at line 438 of file TOnlineFrame.cpp.
References basename, fEmbeddedCanvas, fFileName, fServerName, gROOT, msg, openRootFile(), print_msg(), and sprintf().
Referenced by main(), and ProcessMessage().
void TOnlineFrame::print_msg | ( | const char * | msg, |
const Int_t | partidx = 0 |
||
) |
Definition at line 536 of file TOnlineFrame.cpp.
References fStatusBar, and printf().
Referenced by ConnectToServer(), OpenRootFile(), ProcessMessage(), and runMacro().
Bool_t TOnlineFrame::ProcessMessage | ( | Long_t | msg, |
Long_t | param1, | ||
Long_t | param2 | ||
) |
Definition at line 230 of file TOnlineFrame.cpp.
References B_CONNECT, B_FILE_OPEN, B_PRINT, B_UPDATE, ConnectToServer(), ConsiderAutoupdate(), fButtons, fCurrentDisplay, fEmbeddedCanvas, fFileName, OpenRootFile(), print_msg(), printf(), run_nr, screens, SCREENS_BASE, sprintf(), time, and UpdateDisplay().
void TOnlineFrame::runMacro | ( | const char * | macro) |
Definition at line 483 of file TOnlineFrame.cpp.
References clear_recv_buffer(), fEmbeddedCanvas, get_run_number(), get_status_code(), gROOT, msg, print_msg(), RDISP_ERR_BAD_RESPONSE, RDISP_ERR_BROKEN_PIPE, RDISP_ERR_NO_CON, RDISP_ERR_NO_FILE, RDISP_ERR_NO_FOLDER, RDISP_ERR_NO_RESPONSE, RDISP_ERR_NO_SOURCE, run_nr, sprintf(), and status.
Referenced by ConsiderAutoupdate(), and ConsiderCycling().
void TOnlineFrame::setServerName | ( | const char * | name) |
void TOnlineFrame::setServerPort | ( | const unsigned int | port_nr) |
Definition at line 384 of file TOnlineFrame.cpp.
References fServerPort, and sprintf().
Referenced by main().
void TOnlineFrame::UpdateDisplay | ( | ) |
Definition at line 313 of file TOnlineFrame.cpp.
References fButtons, fCurrentDisplay, fLoadedMacros, gROOT, screen_info::hasArgs, screen_info::macroArgs, screen_info::macroName, and screens.
Referenced by main(), and ProcessMessage().
|
private |
Definition at line 33 of file TOnlineFrame.h.
Referenced by ConsiderAutoupdate(), and TOnlineFrame().
|
private |
Definition at line 34 of file TOnlineFrame.h.
Referenced by getAutoUpdateTime(), and TOnlineFrame().
std::map<std::string, TGTextButton*> TOnlineFrame::fButtons |
Definition at line 67 of file TOnlineFrame.h.
Referenced by ProcessMessage(), TOnlineFrame(), and UpdateDisplay().
|
private |
Definition at line 29 of file TOnlineFrame.h.
Referenced by TOnlineFrame().
|
private |
Definition at line 36 of file TOnlineFrame.h.
Referenced by ConsiderAutoupdate(), ConsiderCycling(), ProcessMessage(), TOnlineFrame(), and UpdateDisplay().
|
private |
Definition at line 32 of file TOnlineFrame.h.
Referenced by ConsiderAutoupdate(), ConsiderCycling(), and TOnlineFrame().
|
private |
Definition at line 31 of file TOnlineFrame.h.
Referenced by ConnectToServer(), OpenRootFile(), ProcessMessage(), runMacro(), and TOnlineFrame().
|
private |
Definition at line 35 of file TOnlineFrame.h.
Referenced by ConnectToServer(), OpenRootFile(), ProcessMessage(), and TOnlineFrame().
|
private |
Definition at line 30 of file TOnlineFrame.h.
Referenced by TOnlineFrame().
std::set<std::string> TOnlineFrame::fLoadedMacros |
Definition at line 66 of file TOnlineFrame.h.
Referenced by UpdateDisplay().
|
private |
Definition at line 28 of file TOnlineFrame.h.
Referenced by TOnlineFrame().
|
private |
Definition at line 41 of file TOnlineFrame.h.
Referenced by ConnectToServer(), GetHist(), GetHistTitles(), and GetSocketHandle().
|
private |
Definition at line 38 of file TOnlineFrame.h.
Referenced by ConnectToServer(), getServerName(), OpenRootFile(), setServerName(), and TOnlineFrame().
|
private |
Definition at line 39 of file TOnlineFrame.h.
Referenced by getServerPort(), setServerPort(), and TOnlineFrame().
|
private |
Definition at line 37 of file TOnlineFrame.h.
Referenced by print_msg(), and TOnlineFrame().
|
private |
Definition at line 25 of file TOnlineFrame.h.
Referenced by TOnlineFrame().
|
private |
Definition at line 27 of file TOnlineFrame.h.
Referenced by TOnlineFrame().
|
private |
Definition at line 40 of file TOnlineFrame.h.
Referenced by ProcessMessage(), runMacro(), and TOnlineFrame().