Partager via


TSPI_lineGetDevCaps

This function queries a specified line device to determine its telephony capabilities. The returned information is valid for all addresses on the line device.

LONG TSPIAPI TSPI_lineGetDevCaps(
  DWORD dwDeviceID, 
  DWORD dwTSPIVersion, 
  DWORD dwExtVersion, 
  LPLINEDEVCAPS lpLineDevCaps 
);

Parameters

  • dwDeviceID
    Line device to be queried.
  • dwTSPIVersion
    Negotiated TSPI version number. This value has already been negotiated for this device through the TSPI_lineNegotiateTSPIVersion function.
  • dwExtVersion
    Negotiated extension version number. This value has already been negotiated for this device through the TSPI_lineNegotiateExtVersion function. This parameter is not validated by TAPI when this function is called.
  • lpLineDevCaps
    Pointer to a variably sized structure of type LINEDEVCAPS. Upon successful completion of the request, this structure is filled with line device capabilities information.

Return Values

Returns zero if the function succeeds, or an error number if an error occurs. The following table shows the return values for this function.

Value Description
LINEERR_INCOMPATIBLEAPIVERSION The API version is incompatible.
LINEERR_OPERATIONUNAVAIL The operation is unavailable.
LINEERR_INCOMPATIBLEEXTVERSION The extension version is incompatible.
LINEERR_OPERATIONFAILED The operation failed.
LINEERR_NODRIVER The driver cannot be found.
LINEERR_RESOURCEUNAVAIL The resource is unavailable.
LINEERR_NOMEM Not enough memory is available.

Remarks

Line device identifier numbering for a service provider is sequential from the value set by the dwLineDeviceIDBase parameter that is passed to the TSPI_providerInit function.

The dwExtVersion formal parameter indicates the version number of the requested extension information. If it is zero, no extension information is requested. If it is nonzero, it holds a value that was negotiated for this device with the TSPI_lineNegotiateExtVersion function. The service provider fills in device- and vendor-specific extended information according to the extension version specified.

The service provider fills in all the members of the LINEDEVCAPS data structure, except for dwTotalSize, which is filled in by TAPI. The service provider must not overwrite the dwTotalSize member.

The service provider must fill in all members of the LINETERMCAPS data structure or structures embedded in the varying part of the LINEDEVCAPS data structure.

After the service provider returns from the TSPI_lineGetDevCaps function, TAPI sets the **dwLinesStates****member of the LINEDEVCAPS structure as follows.

LINEDEVCAPS.dwLineStates |=
    LINEDEVSTATE_OPEN |
    LINEDEVSTATE_CLOSE |
    LINEDEVSTATE_REINIT |
    LINEDEVSTATE_TRANSLATECHANGE;

Requirements

OS Versions: Windows CE 3.0 and later.
Header: Tapicomn.h.
Link Library: Coredll.lib.

See Also

TSPI_lineNegotiateExtVersion | TSPI_lineNegotiateTSPIVersion | TSPI_providerInit

 Last updated on Saturday, April 10, 2004

© 1992-2003 Microsoft Corporation. All rights reserved.