Name
CatsPhoneLine -- Telephone Line Interface.
Codes
CATS_PHONE_FAILURE |
CATS_PHONE_UNEXPECTED_HANG_UP_RECEIVED |
CATS_PHONE_DTMF |
CATS_PHONE_UNEXPECTED_INCOMING_CALL_RECEIVED |
CATS_PHONE_ANSWERED_CALL |
Class Methods
CatsPhoneLine
CatsPhoneLine_create
(void *source);
void *getSource
(CatsPhoneLine
this);
Interface Methods
int open
(CatsPhoneLine
line);
int poll
(CatsPhoneLine
line);
int getDTMF
(CatsPhoneLine
line);
int getPollMsec
(CatsPhoneLine
line);
int disconnect
(CatsPhoneLine
line);
int close
(CatsPhoneLine
line);
int isOpen
(CatsPhoneLine
line);
int isConnected
(CatsPhoneLine
line);
Description
The CatsPhoneLine interface
provides generic telephone line services in CATS. The
open method is intended to initialize
the telephony device implementing
CatsPhoneLine, returning
MDTM_TRUE if the operation is
successful and MDTM_FALSE if the
operation fails. The poll method polls
an open telephone device for line events, returning one of
the phone line codes described above.
getDTMF returns the value of key
presses of an open line, which correspond to touchtone codes
associated with the CatsPhoneEvent
class. disconnect forces the line to
hang up, close releases the telephony
device. isOpen and
isConnected provide the status of the
line.