Device
Classes
A device
class is a group of related physical devices or device drivers through
which applications send and receive the information or data that makes up a
call. Every device class has a device class name that uniquely
identifies the class, and provides information about the programming interface
and commands that can be used to open and communicate with the devices in the
class.
The Telephony
application programming interface (TAPI) associates devices from one or more
device classes to each line or phone device. You access one of these devices by
retrieving the device identifier for the device using the lineGetID
Note The device
identifier definitions apply to 16-bit and 32-bit TAPI. In some cases, the data
type of a media handle in the device identifier definition may be different
from that specified by the Microsoft Windows operating system version 3.x or Microsoft Win32 application
programming interface. For example, Windows version 3.x and Win32 define
wave device identifiers with the UINT type, but TAPI defines this device
identifier with the DWORD type. In such cases, you should cast the media
handle to the appropriate data type when using it with the Windows version 3.x
or Win32 API.
You also use
device class names with the lineConfigDialog71035C and phoneConfigDialog functions to enable the
user to set configuration options for the given device, with the lineGetIcon and phoneGetIcon functions to retrieve an
icon to represent the given device, and with the lineGetDevConfig and lineSetDevConfig functions to directly
retrieve and set configuration options for the given device.
By default,
there are the following device class names.
Device
Class Name |
Description |
comm |
Communications
port. |
comm/datamodem
|
Modem
through a communications port. |
comm/datamodem/portname
|
Name of the
device to which a modem is connected. |
wave/in |
Wave audio
device (input only). |
wave/out |
Wave audio
device (output only). |
midi/in |
Midi
sequencer (input only). |
midi/out |
Midi
sequencer (output only). |
tapi/line |
Line
device. |
tapi/phone |
Phone
device. |
ndis |
Network
device. |
tapi/terminal
|
Terminal
device. |
Note These names
are not case sensitive; you can use any combination of uppercase and lowercase
letters.
Additional
device classes and device class names may be available on a given system. In
general, if a device does not belong to one of the default device classes, the
manufacturer typically defines a new device class and assigns a unique device
class name. Check the documentation for the device to determine what additional
device classes are available for it. Note, however, that although the device
class and media mode are related, they are not the same. A media mode describes
a format of information on a call, and a device class defines the programming
interface used to manage that information. So, even if a manufacturer defines a
new media mode, it is not necessarily true that the manufacturer also needs to
define a new device class to support the mode.
The format of
the configuration data used with the lineSetDevConfig