Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   File Members  

TGo4ObjClient Class Reference

Client for the go4 object server delivering root objects. More...

#include <TGo4ObjClient.h>

List of all members.

Public Methods

 TGo4ObjClient (const Text_t *clientname, const Text_t *base=0, const Text_t *passwd=0, const Text_t *host=0, Int_t port=0)
 TGo4ObjClient ()
virtual ~TGo4ObjClient ()
TGo4AnalysisObjectNamesRequestNamesList (const Text_t *base=0, const Text_t *passwd=0, const Text_t *host=0, Int_t port=0)
 Get nameslist object from client. More...

TObject * RequestObject (const Text_t *objectname, const Text_t *base=0, const Text_t *passwd=0, const Text_t *host=0, Int_t port=0)
 Get object by name from client. More...

void SetBase (const char *serverbase)
void SetPasswd (const char *serverpasswd)
void SetHost (const char *serverhost)
void SetPort (Int_t port)
const char * GetBase () const
const char * GetPasswd () const
const char * GetHost () const
Int_t GetPort () const

Protected Methods

void SendCommand (const Text_t *com)
 Send (command) string to server. More...

TObject * ReceiveObject ()
 Receive root object streamed from server. More...


Private Methods

void SetParms (const Text_t *base, const Text_t *passwd, const Text_t *host, Int_t port)
 Set server parameters if necessary. More...

Int_t ConnectServer ()
Int_t DisconnectServer ()
TBuffer * ReceiveBuffer ()
 Receive root buffer containing requested object. More...


Private Attributes

TString fxServerName
 contains api basename. More...

TString fxServerPass
 contains api password. More...

TString fxHostname
 hostname of the server to connect to. More...

Int_t fiPort
 serversocket port number. More...

TGo4SocketfxTransport
 transport socket for connection to server. More...


Detailed Description

Client for the go4 object server delivering root objects.

Author:
J. Adamczewski
Since:
17-Jan-2003

Definition at line 32 of file TGo4ObjClient.h.


Constructor & Destructor Documentation

TGo4ObjClient::TGo4ObjClient const Text_t *    clientname,
const Text_t *    base = 0,
const Text_t *    passwd = 0,
const Text_t *    host = 0,
Int_t    port = 0
 

Definition at line 34 of file TGo4ObjClient.cxx.

References fxTransport, and SetParms().

TGo4ObjClient::TGo4ObjClient   [inline]
 

Definition at line 41 of file TGo4ObjClient.h.

TGo4ObjClient::~TGo4ObjClient   [virtual]
 

Definition at line 45 of file TGo4ObjClient.cxx.

References fxTransport.


Member Function Documentation

TGo4AnalysisObjectNames * TGo4ObjClient::RequestNamesList const Text_t *    base = 0,
const Text_t *    passwd = 0,
const Text_t *    host = 0,
Int_t    port = 0
 

Get nameslist object from client.

basename, password,host and portnumber may be specified at any time new if left out (default), the previously stored values are used

Definition at line 64 of file TGo4ObjClient.cxx.

References ConnectServer(), DisconnectServer(), TGo4HistogramServer::fgcCOMGETLIST, ReceiveObject(), SendCommand(), and SetParms().

Referenced by main().

TObject * TGo4ObjClient::RequestObject const Text_t *    objectname,
const Text_t *    base = 0,
const Text_t *    passwd = 0,
const Text_t *    host = 0,
Int_t    port = 0
 

Get object by name from client.

basename, password, host and portnumber may be specified at any time new if left out (default), the previously stored values are used

Definition at line 96 of file TGo4ObjClient.cxx.

References ConnectServer(), DisconnectServer(), ReceiveObject(), SendCommand(), and SetParms().

Referenced by main().

void TGo4ObjClient::SetBase const char *    serverbase [inline]
 

Definition at line 62 of file TGo4ObjClient.h.

References fxServerName.

Referenced by SetParms().

void TGo4ObjClient::SetPasswd const char *    serverpasswd [inline]
 

Definition at line 63 of file TGo4ObjClient.h.

References fxServerPass.

Referenced by SetParms().

void TGo4ObjClient::SetHost const char *    serverhost [inline]
 

Definition at line 64 of file TGo4ObjClient.h.

References fxHostname.

Referenced by SetParms().

void TGo4ObjClient::SetPort Int_t    port [inline]
 

Definition at line 65 of file TGo4ObjClient.h.

References fiPort.

Referenced by SetParms().

const char* TGo4ObjClient::GetBase   const [inline]
 

Definition at line 67 of file TGo4ObjClient.h.

References fxServerName.

Referenced by ConnectServer().

const char* TGo4ObjClient::GetPasswd   const [inline]
 

Definition at line 68 of file TGo4ObjClient.h.

References fxServerPass.

Referenced by ConnectServer().

const char* TGo4ObjClient::GetHost   const [inline]
 

Definition at line 69 of file TGo4ObjClient.h.

References fxHostname.

Referenced by ConnectServer().

Int_t TGo4ObjClient::GetPort   const [inline]
 

Definition at line 70 of file TGo4ObjClient.h.

References fiPort.

Referenced by ConnectServer().

void TGo4ObjClient::SendCommand const Text_t *    com [protected]
 

Send (command) string to server.

Command may be just name of requested object

Definition at line 157 of file TGo4ObjClient.cxx.

References fxTransport, and TGo4Socket::Send().

Referenced by RequestNamesList(), and RequestObject().

TObject * TGo4ObjClient::ReceiveObject   [protected]
 

Receive root object streamed from server.

Definition at line 120 of file TGo4ObjClient.cxx.

References TGo4TaskHandler::fgcOK, fxTransport, ReceiveBuffer(), TGo4Socket::RecvRaw(), and TGo4Socket::Send().

Referenced by RequestNamesList(), and RequestObject().

void TGo4ObjClient::SetParms const Text_t *    base,
const Text_t *    passwd,
const Text_t *    host,
Int_t    port
[private]
 

Set server parameters if necessary.

Definition at line 51 of file TGo4ObjClient.cxx.

References SetBase(), SetHost(), SetPasswd(), and SetPort().

Referenced by RequestNamesList(), RequestObject(), and TGo4ObjClient().

Int_t TGo4ObjClient::ConnectServer   [private]
 

Definition at line 163 of file TGo4ObjClient.cxx.

References TGo4Log::Debug(), TGo4TaskHandler::fgcOK, fxTransport, GetBase(), GetHost(), GetPasswd(), GetPort(), TGo4Socket::Open(), TGo4Socket::RecvRaw(), and TGo4Socket::Send().

Referenced by RequestNamesList(), and RequestObject().

Int_t TGo4ObjClient::DisconnectServer   [private]
 

Definition at line 190 of file TGo4ObjClient.cxx.

References TGo4Socket::Close(), and fxTransport.

Referenced by RequestNamesList(), and RequestObject().

TBuffer * TGo4ObjClient::ReceiveBuffer   [private]
 

Receive root buffer containing requested object.

Definition at line 196 of file TGo4ObjClient.cxx.

References TGo4Log::Debug(), TGo4SocketSignalHandler::fgiLastSignal, fxTransport, TGo4Socket::GetBuffer(), and TGo4Socket::ReceiveBuffer().

Referenced by ReceiveObject().


Member Data Documentation

TString TGo4ObjClient::fxServerName [private]
 

contains api basename.

Definition at line 83 of file TGo4ObjClient.h.

Referenced by GetBase(), and SetBase().

TString TGo4ObjClient::fxServerPass [private]
 

contains api password.

Definition at line 86 of file TGo4ObjClient.h.

Referenced by GetPasswd(), and SetPasswd().

TString TGo4ObjClient::fxHostname [private]
 

hostname of the server to connect to.

Definition at line 89 of file TGo4ObjClient.h.

Referenced by GetHost(), and SetHost().

Int_t TGo4ObjClient::fiPort [private]
 

serversocket port number.

Definition at line 92 of file TGo4ObjClient.h.

Referenced by GetPort(), and SetPort().

TGo4Socket* TGo4ObjClient::fxTransport [private]
 

transport socket for connection to server.

Definition at line 95 of file TGo4ObjClient.h.

Referenced by ConnectServer(), DisconnectServer(), ReceiveBuffer(), ReceiveObject(), SendCommand(), TGo4ObjClient(), and ~TGo4ObjClient().


The documentation for this class was generated from the following files:
Generated on Tue Nov 8 10:56:48 2005 for Go4-v2.10-5 by doxygen1.2.15