The lineMakeCall function first attempts to obtain a call appearance on an address on the line, then waits for a dial tone, and finally dials the specified address. A call appearance is a connection to the switch over which a call can be made. Once the connection is established, the call appearance exists, even if no call is placed. After the call is established, the call appearance remains in existence until the call transitions to the idle state. If calls controlled by other applications exist on the line, these calls would normally have to be on hold, and would typically be forced to stay on hold until the application either drops its call or places it on hold. If dialing is successful, a handle to a call with owner privileges is returned to the application.
Before invoking lineMakeCall, an application can set up parameters for the call and store them in the LINECALLPARAMS data structure. A pointer to this structure is then used as a parameter of lineMakeCall. In the members of LINECALLPARAMS, the application can specify the quality of service requested from the network, as well as a variety of ISDN call setup parameters. If no LINECALLPARAMS structure is supplied to lineMakeCall, a default POTS voice-grade call is requested with a set of default values. However, it is a good idea to use LINECALLPARAMS so that monitoring applications can report this call information (such as the identification of the called party) accurately.
The call's origination address also appears in LINECALLPARAMS. Using this field, the application can specify the address on the line where it wants the call to originate. It can do so by specifying an address identifier, though in some configurations it is more practical to identify the originating address by its directory number.
Note Do not mix function calls of TAPI with the those of Assisted Telephony because it creates needless repetition and additional overhead.
Once dialing is complete and the call is being established, it passes through a number of different states. These states (the progress of the call) are provided to the application with LINE_CALLSTATE messages. This mechanism lets the application track whether the call is reaching the called party. It is important that every telephony application base its behavior on the information received in these messages, and not on any other assumptions about a call's state. An application must not assume that a requested state change has occurred until notification of that state change arrives. It can be helpful to display user-friendly interpretations of call states as indicators of a call's progress, especially for calls expected to pass through states slowly.
If special call setup parameters are to be taken into consideration, the application must supply them to lineMakeCall. Call setup parameters are required for actions such as the following: