Avaya Logo

Previous Topic

Next Topic

Book Contents

Book Index

Call profile

The call profile is a set of data elements that provide a context that determines the behavior of some functions, internal system event processing, and application dispatching.

The call profile is divided into two groups:

Parameters

Parameters are used to affect the behavior of or set options on functions. Once parameters are set initially for some application, they need not be re-specified for a function each and every time it is used. Therefore, for many functions, parameters are used instead of function arguments.

There are two types of parameters, channel specific and global. Channel specific parameters must be set and queried for each individual channel. Global parameters are set system wide; they are also read only, and are not part of the call profile since they are not specific to a channel or a call.

Channel-specific parameters

Channel specific parameters are defined in IrPARAMETERS(4IRAPI). As shown in the following table, each parameter has several attributes. 

Parameter attribute name

Description

type

Indicates an integer or string type.

size

Indicates the size, in bytes, required to contain the parameter value. All integer type parameters occupy sizeof(int) bytes; string type parameters vary in size.

save-on-exec

Indicates the parameter value persists that are saved across a call to irExec(3IRAPI) or irSubProg(3IRAPI). These parameters provide a communication path from parent to child process and allow a child process to execute in a context similar to the parent's with respect to IRAPI functions.

read-only

Indicates whether the parameter can or cannot be changed by the application.

auto-init

Indicates whether IRAPI automatically initiates the parameter.

Parameter values may be retrieved via irGetParam(3IRAPI) and irGetParamStr(3IRAPI) for integer and string type parameters, respectively. Parameter values may be set via irSetParam(3IRAPI) and irSetParamStr(3IRAPI) for integer and string type parameters, respectively.

When a channel is released via irDeinit(3IRAPI) or irReturn(3IRAPI), most parameters are reset to their default values. The default values are listed in IrPARAMETERS(4IRAPI). The irInitParam(3IRAPI) and irInitAllParams(3IRAPI) functions are also provided to set a single or all channel parameters to its/their default values. Most default values are not affected by the application environment or system administration settings; however, some are. For instance, the default value for IRP_FLASH_DURATION is taken from the values specified by the switch integration settings. Furthermore, its value is meaningless for certain telephony types.

Since channels are released to AD through irDeinit(3IRAPI) and AD does not change the parameters' default settings, any channel irExec(3IRAPI)'d from AD on an IRE_NEWCALL event has its parameters set to their default values.

Note:
Getting and setting string type parameters should be done with caution. irGetParamStr(3IRAPI) copies exactly the number of bytes specified. It does not interpret NULL characters nor does it NULL terminate strings. Applications are required to NULL terminate strings if the parameters containing them are as large as the string. irSetParamStr(3IRAPI) also does not interpret NULL characters and always copies the full parameter size out of the program space. Therefore, source arguments to irSetParamStr should point to sufficiently large areas of memory. The non-interpretation of NULL characters allow string type parameters to be used for both character string and buffer data types.

The chantest.c application, available on the system in the file /vs/examples/IRAPI/chantest.c, shows getting and setting string-type parameters.

Global parameters

Global parameters are used to set system wide options that affect the behavior of some IRAPI functions. Global parameters are set or modified by manually editing the /vs/data/irAPI.rc file. Global parameters are read-only from IRAPI applications. The irGetGlobalParam(3IRAPI) and irGetGlobalParamStr(3IRAPI) functions provide access to global parameters for integer and string type parameters, respectively.

Information elements

Information elements, which are available over some network connections, describe incoming calls to the voice system. The following Information elements can be set by incoming calls:

Information elements can also be used by the voice system to describe outgoing calls to the network. The following Information elements can be set by an application to describe outbound calls:

The IRAPI interface to information elements is similar to the channel parameter interface, including integer and string types, and is supported through the following functions:

© 2006 Avaya Inc. All Rights Reserved.