Main Page | Class Hierarchy | Class List | File List | Class Members

Comms Class Reference

#include <comms.h>

Inheritance diagram for Comms:

Inheritance graph
[legend]
Collaboration diagram for Comms:

Collaboration graph
[legend]
List of all members.

Public Member Functions

 Comms (LaunchNewId &lid, Manager &manager)
 ~Comms ()
virtual void StopAllCommunications ()
void AdviseCallCreation (const PString &remoteCont)
virtual void SilentlyEndAll ()

Protected Member Functions

virtual void ProcessTransferUdp (PStringArray &cmds, PString &sender)
virtual void ProcessHangup (PStringArray &cmds, PString &sender)
virtual void ProcessCallNode (PStringArray &cmds, PString &sender)
virtual void ProcessStatusQuery (PStringArray &cmds, PString &sender)
PString GetDurationInfo ()
virtual void ProcessDuration (PStringArray &cmds, PString &sender)
virtual void ProcessIdentify (PStringArray &cmds, PString &sender)
virtual void ProcessDebug (PStringArray &cmds, PString &sender)
virtual void ProcessAnswer (PStringArray &cmds, PString &sender)
virtual BOOL SendDtmf (const PString &dtmfVals)
virtual BOOL OkToHangup ()

Protected Attributes

Managermanager
PString remoteController
Audio read write thread handles, socket,
AudioReadaudioReadThread
AudioWriteaudioWriteThread

Detailed Description

A class that handles all the messaging with the remote controller. Thus, incoming messages, when executed by this class, exert control over the program, and reference to the manager class.


Constructor & Destructor Documentation

Comms::Comms LaunchNewId lid,
Manager manager
 

Constructor, with a reference to the manager and the unique ID generator

Comms::~Comms  ) 
 

Close down the handling of incoming message,


Member Function Documentation

void Comms::AdviseCallCreation const PString &  remoteCont  ) 
 

Send a message to the remote controller saying that we are created. The id of this node is appended to the message.

PString Comms::GetDurationInfo  )  [protected]
 

Get information (in a textual form) of how long this call has been up

virtual BOOL Comms::OkToHangup  )  [inline, protected, virtual]
 

Some MessageFrame instances do not obey the hangup command. This virtual method says we can hangup, cause we are one channel of a conference call. This instance of the comms should close on receiving a hangup

Reimplemented from MessageFrame.

void Comms::ProcessAnswer PStringArray &  cmds,
PString &  sender
[protected, virtual]
 

we have received a command advising us how to answer to the incoming call, so we act as required and reply accordingly

Reimplemented from MessageFrame.

void Comms::ProcessCallNode PStringArray &  cmds,
PString &  sender
[protected, virtual]
 

we have received a Call other Node command, so do it and reply accordingly

Reimplemented from MessageFrame.

void Comms::ProcessDebug PStringArray &  cmds,
PString &  sender
[protected, virtual]
 

we have received a command which enables/disables debug information so install as required and reply accordingly

Reimplemented from MessageFrame.

void Comms::ProcessDuration PStringArray &  cmds,
PString &  sender
[protected, virtual]
 

we have received a command queryig the current call duration , so extract information & answer

Reimplemented from MessageFrame.

void Comms::ProcessHangup PStringArray &  cmds,
PString &  sender
[protected, virtual]
 

we have received a hangup message, so end the call

Reimplemented from MessageFrame.

void Comms::ProcessIdentify PStringArray &  cmds,
PString &  sender
[protected, virtual]
 

we have received a command requesting that we identify ourselves so do it and reply accordingly

Reimplemented from MessageFrame.

void Comms::ProcessStatusQuery PStringArray &  cmds,
PString &  sender
[protected, virtual]
 

we have received a query status command, so do it and reply accordingly

Reimplemented from MessageFrame.

void Comms::ProcessTransferUdp PStringArray &  cmds,
PString &  sender
[protected, virtual]
 

we have received a command advising us that we are to install udp comms with a particular remote node id. We override this method so we know when are being transferred. On being transferred, we move ourselves out of the Manager's list of pending calls. Then we call the ancestor method to actually do the work of transferring the udp

Reimplemented from MessageFrame.

BOOL Comms::SendDtmf const PString &  dtmfVals  )  [protected, virtual]
 

Send this dtmf string to the remote node. Returns TRUE on success, FALSE on failure.

Reimplemented from MessageFrame.

void Comms::SilentlyEndAll  )  [virtual]
 

We have a comms error, so just close everything right now (or alternatively, it is the end of this program).

Send no message to the remote node - just end end end.

Reimplemented from MessageFrame.

void Comms::StopAllCommunications  )  [virtual]
 

Send a message to the remote controller that we are closing down now


Member Data Documentation

AudioRead* Comms::audioReadThread [protected]
 

Pointer to the thead instance that reads from PSafePtr<Member>, and sends this back through the socket

AudioWrite* Comms::audioWriteThread [protected]
 

Pointer to the thead instance that reads from a socket, and writes the audio to the PSafePtr<Member>

Manager& Comms::manager [protected]
 

Reference back to the most important class of all

PString Comms::remoteController [protected]
 

The id of the controller who has created this call


The documentation for this class was generated from the following files:
Generated on Sun Jan 29 19:49:28 2006 for Sofa Switch Multipoint Conf. Utility by  doxygen 1.4.4