HannaPlusPlusClientComm

Aus HERMESwiki
Version vom 12. Dezember 2008, 20:47 Uhr von Hyonsuk (Diskussion _ Beiträge)
(Unterschied) ← Nächstältere Version _ Aktuelle Version (Unterschied) _ Nächstjüngere Version → (Unterschied)
Zur Navigation springen Zur Suche springen

Page maintainer: Andreas

Checked.png This page is considered done. It been reviewed by Hyon-Suk. There may be missing elements, but they are all flagged and the text has no errors.

Hanna++ Client Communication

The class THClient is used to communicate with a remote analysis. To open a connection one has to get a list of remote analyses from the daemon (hppdaemon) via a call to

root[0] THClient::GetAnalysisList("host.desy.de", port);

If the host name is omitted, the client will try to get the list of remote analyses from the host and port specified in the environment variables HPPDAEMON and HPPDAEMONPORT.

Once the list of remote analyses is available the actual THClient object is created by a call to

root[1] THClient * client = THClient::Connect(Int_t id, const char * password)

where id is the id of the remote analysis in the list and password is a plain text password used for authentication.

On creation, the client will log into the remote analysis and get a list of histograms on the remote analysis. In addition, all histograms managed by the remote THistoManager are added to a folder structure that is browseable with the ROOT browser.

In addition one can also send commands to the remote analysis. Here is a list of implemented calls:

  • Pause the remote Analysis:
THClient::Pause(const char * password);
  • Resume the remote Analysis:
THClient::Resume(const char * password);
  • Reset all histos on remote Analysis:
THClient::Reset(const char * password);
  • Abort the remote Analysis:
THClient::Abort(const char * password);
  • Save all histos and cuts to files on the remote host:
THClient::Save();
  • Save all histos to a file on the remote host:
THClient::SaveHistos();
  • Save all cuts to a file on the remote host:
THClient::SaveCuts();
  • Upload a new set of cuts to the remote analysis (filename is the name of the file on the local host):
THClient::LoadCuts(const char * filename, const char * password);
  • Download the current set of cuts from the remote analysis (filename is the name of the file on the local host):
THClient::GetCuts(const char * filename, const char * password);

Hanna++ Graphical Client

Hanna++ also provides a GUI for the client communication. To start the GUI do the following from within an interactive ROOT session:

root [0] .x HClientGui.C

The screenshot below shows the GUI together with a browser

Hanna++ graphical client

Further Reading

Hanna++ Class Documentation