class description - source file - inheritance tree

class TMonitor : public TObject

TMonitor TMonitor() TMonitor TMonitor(TMonitor&) virtual void ~TMonitor() void Activate(TSocket* sock) void ActivateAll() void Add(TSocket* sock) TClass* Class() void DeActivate(TSocket* sock) void DeActivateAll() Int_t GetActive() const Int_t GetDeActive() const virtual TClass* IsA() const void Remove(TSocket* sock) TSocket* Select(Long_t timeout) TSocket* Select() void SetReady(TSocket* sock) virtual void ShowMembers(TMemberInspector& insp, char* parent) virtual void Streamer(TBuffer& b)

Data Members

TList* fActive list of sockets to monitor TList* fDeActive list of (temporary) disabled sockets TSocket* fReady socket which is ready to be read

Class Description

 This class monitors activity on a number of network sockets.         
 The actual monitoring is done by TSystem::DispatchOneEvent().        
 Typical usage: create a TMonitor object. Register a number of        
 TSocket objects and call TMonitor::Select(). Select() returns the    
 socket object which has data waiting. TSocket objects can be added,  
 removed, (temporary) enabled or disabled.                            

 Create a monitor object.

 Cleanup the monitor object. Does not delete socket being monitored.

void Add(TSocket *sock)
 Add socket to the monitor's active list.

void Remove(TSocket *sock)
 Remove a socket from the monitor.

void Activate(TSocket *sock)
 Activate a de-activated socket.

void ActivateAll()
 Activate all de-activated sockets.

void DeActivate(TSocket *sock)
 De-activate a socket.

void DeActivateAll()
 De-activate all activated sockets.

TSocket* Select()
 Return pointer to socket for which an event is waiting.

TSocket* Select(Long_t timeout)
 Return pointer to socket for which an event is waiting. Wait a maximum
 of timeout milliseconds. If return is due to timeout it returns
 (TSocket *)-1.

void SetReady(TSocket *sock)
 Called by TSocketHandler::Notify() to signal which socket is ready
 to be read. User should not call this routine. The ready socket will
 be returned via the Select() user function.

Int_t GetActive() const
 Return number of sockets in the active list.

Int_t GetDeActive() const
 Return number of sockets in the de-active list.

Inline Functions

            TClass* Class()
            TClass* IsA() const
               void ShowMembers(TMemberInspector& insp, char* parent)
               void Streamer(TBuffer& b)
           TMonitor TMonitor(TMonitor&)

Author: Fons Rademakers 09/01/97
Last update: 2.22/00 21/03/99 19.50.40 by Fons Rademakers
Copyright (c) 1995-1999, The ROOT System, All rights reserved. *

ROOT page - Class index - Top of the page

This page has been automatically generated. If you have any comments or suggestions about the page layout send a mail to ROOT support, or contact the developers with any questions or problems regarding ROOT.