class Vocal::ResGwDevice

Abstract base class for all hardware.

Inheritance:


Public Methods

[more] ResGwDevice()
[more] ResGwDevice( const char* deviceName, Sptr < Fifo < Sptr < SipProxyEvent > > > inputQ, Sptr < Fifo < Sptr < SipProxyEvent > > > outputQ )
Creates a hardware object to control a single port gateway
[more]virtual ~ResGwDevice()
Destructor
[more]virtual void* hardwareMain( void* parms ) = 0
Starts the main processing loop of the hardware
[more]virtual int addToFdSet( fd_set* fd ) = 0
Add device's socket to the fd; returns 0 if successful, errorcode otherwise
[more]virtual int process( fd_set* fd ) = 0
Process all pending hardware events; returns 0 if successful, otherwise returns an errorcode.
[more]virtual int audioStart( const HardwareAudioRequest& request ) = 0
Start audio channel on device; returns 0 if successful, errorcode otherwise
[more]virtual int audioStop() = 0
Stops audio channel on device; returns 0 if successful, errorcode otherwise
[more]virtual int audioSuspend() = 0
suspend audio channel on device; returns 0 if successful, errorcode otherwise
[more]virtual int audioResume( const HardwareAudioRequest& request ) = 0
resume audio channel on device; returns 0 if successful, errorcode otherwise
[more]virtual void processRTP() = 0
[more]virtual void setCallId( const Sptr<SipCallId> newCallId )
[more]virtual Sptr<SipCallId> getCallId() const
[more]virtual void addCallWaitingId( const Sptr<SipCallId> newCallId )
[more]virtual Sptr<SipCallId> getCallWaitingId() const
[more]virtual void removeCallWaitingId( const SipCallId& newCallId )
[more]virtual Sptr<DigitCollector> getDigitCollector()
[more]virtual HardwareStatusType getHardwareStatus()
[more]virtual bool isMyHardware(const SipCallId& callid)
[more]virtual bool isOnCallWaiting(const SipCallId& callid)
[more]virtual int getRtpPort() = 0
[more]virtual void releaseRtpPort() = 0
[more]inline Sptr< Fifo < Sptr<SipProxyEvent> > > getQ()
access functions to private data
[more]inline int getFD()
returns the file descriptor for the device
[more]void setUseRsvp( bool flag )
RSVP stuff ported from Sessionhxx

Public Members

[more] Creates a hardware object to control a multi port gateway

Protected Fields

[more]bool useRsvp
RSVP stuff ported from Sessionhxx
[more]int myFD
file descriptor for hardware device
[more]Sptr< Fifo < Sptr< SipProxyEvent > > > myQ
input queue to allow the session to control hardware signals
[more]bool hookStateOffhook
true if last reported hook state was offhook
[more]Sptr<SipCallId> callId
Current call id
[more]Sptr<CallWaitingIdList> callWaitingIdList
Call Id on call waiting list
[more]int stdinFD
needed for proper terminal control
[more]EntryState myEntryState
this bool is set to true if the user is entering text
[more]Data myTextEntry
this Data contains a partial URL entered by a user if they have entered 'u'
[more]Sptr<DigitCollector> digitCollector

Protected Methods

[more]virtual void provideDtmf( DeviceSignalType signal ) = 0
[more]virtual void provideCallInfo( string CallerId, string CalleeId, string ForwardReason ) = 0
[more]int provideSignal( DeviceSignalType signal )
Trigger the device to send the specified signal; returns 0 if successful, errorcode otherwise
[more]void processSessionMsg( Sptr < SipProxyEvent > event )
Process a msg received from an session
[more]void reportEvent( Sptr < Fifo < Sptr< SipProxyEvent > > > outputQ, DeviceEventType eventType )
Report hardware event by adding it to specified queue


Documentation

Abstract base class for all hardware. Specifies the SIP gateway hardware API. Defines a basic level of service provided by all supported hardware interfaces.
o ResGwDevice()

o ResGwDevice( const char* deviceName, Sptr < Fifo < Sptr < SipProxyEvent > > > inputQ, Sptr < Fifo < Sptr < SipProxyEvent > > > outputQ )
Creates a hardware object to control a single port gateway

o Creates a hardware object to control a multi port gateway
Creates a hardware object to control a multi port gateway

ovirtual ~ResGwDevice()
Destructor

ovirtual void* hardwareMain( void* parms ) = 0
Starts the main processing loop of the hardware

ovirtual int addToFdSet( fd_set* fd ) = 0
Add device's socket to the fd; returns 0 if successful, errorcode otherwise

ovirtual int process( fd_set* fd ) = 0
Process all pending hardware events; returns 0 if successful, otherwise returns an errorcode.

ovirtual int audioStart( const HardwareAudioRequest& request ) = 0
Start audio channel on device; returns 0 if successful, errorcode otherwise

ovirtual int audioStop() = 0
Stops audio channel on device; returns 0 if successful, errorcode otherwise

ovirtual int audioSuspend() = 0
suspend audio channel on device; returns 0 if successful, errorcode otherwise

ovirtual int audioResume( const HardwareAudioRequest& request ) = 0
resume audio channel on device; returns 0 if successful, errorcode otherwise

ovirtual void processRTP() = 0

ovirtual void setCallId( const Sptr<SipCallId> newCallId )

ovirtual Sptr<SipCallId> getCallId() const

ovirtual void addCallWaitingId( const Sptr<SipCallId> newCallId )

ovirtual Sptr<SipCallId> getCallWaitingId() const

ovirtual void removeCallWaitingId( const SipCallId& newCallId )

ovirtual Sptr<DigitCollector> getDigitCollector()

ovirtual HardwareStatusType getHardwareStatus()

ovirtual bool isMyHardware(const SipCallId& callid)

ovirtual bool isOnCallWaiting(const SipCallId& callid)

ovirtual int getRtpPort() = 0

ovirtual void releaseRtpPort() = 0

oinline Sptr< Fifo < Sptr<SipProxyEvent> > > getQ()
access functions to private data

oinline int getFD()
returns the file descriptor for the device

ovoid setUseRsvp( bool flag )
RSVP stuff ported from Sessionhxx

obool useRsvp
RSVP stuff ported from Sessionhxx

ovirtual void provideDtmf( DeviceSignalType signal ) = 0

ovirtual void provideCallInfo( string CallerId, string CalleeId, string ForwardReason ) = 0

oint provideSignal( DeviceSignalType signal )
Trigger the device to send the specified signal; returns 0 if successful, errorcode otherwise

ovoid processSessionMsg( Sptr < SipProxyEvent > event )
Process a msg received from an session

ovoid reportEvent( Sptr < Fifo < Sptr< SipProxyEvent > > > outputQ, DeviceEventType eventType )
Report hardware event by adding it to specified queue

oint myFD
file descriptor for hardware device

oSptr< Fifo < Sptr< SipProxyEvent > > > myQ
input queue to allow the session to control hardware signals

obool hookStateOffhook
true if last reported hook state was offhook

oSptr<SipCallId> callId
Current call id

oSptr<CallWaitingIdList> callWaitingIdList
Call Id on call waiting list

oint stdinFD
needed for proper terminal control

oEntryState myEntryState
this bool is set to true if the user is entering text

oData myTextEntry
this Data contains a partial URL entered by a user if they have entered 'u'

oSptr<DigitCollector> digitCollector


Direct child classes:
VmcpDevice
SoundCardDevice
SimpleExtDevice
PhoneCardDevice
DupCardDevice

Alphabetic index HTML hierarchy of classes or Java