📄 cm.h
字号:
* purpose: Converts a PVT subtree of AliasAddress type into an Alias
* input : hVal - The PVT handle
* nodeId - PVT subtree of AliasAddress type we want to convert
* output : alias - Alias struct converted. The application is responsible
* to supply the string field inside the cmAlias struct
* with enough allocated size.
* return : Non-negative value on success
* Negative value on failure
************************************************************************/
RVAPI int RVCALLCONV cmVt2Alias(
IN HPVT hVal,
OUT cmAlias* alias,
IN int nodeId);
RVAPI int RVCALLCONV cmGetProperty(
IN HPROTOCOL hsProtocol);
RVAPI HAPP RVCALLCONV cmGetAHandle(
IN HPROTOCOL hsProtocol);
RVAPI
int RVCALLCONV cmCallStatusEnquiry(
IN HCALL hsCall,
RvUint8 * display);
/*
cmGetH225RemoteVersion
return H225 version number of remote side via OUT parameter
version.
version is user allocated string*/
RVAPI
int RVCALLCONV cmGetH225RemoteVersion(IN HCALL hsCall,OUT char * version);
/*
cmCallUserInformationCreate
create root of information message .Build all must parameters.
Add display and nonstandard parameter if they are and return root id to user to
do changes if it need
*/
RVAPI
int RVCALLCONV cmCallUserInformationCreate(IN HCALL hsCall,char* InputDigit,cmNonStandardParam* param);
/*
cmCallUserInformationSend
send user information message
*/
RVAPI
int RVCALLCONV cmCallUserInformationSend(IN HCALL hsCall, IN int nodeId);
/*
cmCallUserInformationGet
Get rootId of the user information message and retrieve display and nonStandard parameter
Root Id of incoming user information message is passed to callback function of cmEvCallUserInfoT type
if it is set by user.
*/
RVAPI
int RVCALLCONV cmCallUserInformationGet(IN HAPP hApp,IN int nodeId,
OUT char *display,IN int displaySize,
OUT cmNonStandardParam* param);
/************************************************************************
* cmCallSendCallProceeding
* purpose: Sends Q.931 CALL PROCEEDING message
* input : hsCall - Stack handle for the call
* output : none
* return : Non-negative value on success
* Negative value on failure
************************************************************************/
RVAPI
int RVCALLCONV cmCallSendCallProceeding(IN HCALL hsCall);
/* delete pvt of connect,setup,alerting and callProceeding from call property to reduce memory
can be run only in connected state.All information from this messages will be lost after runing
this function.*/
RVAPI
int RVCALLCONV cmFreeProperty(IN HCALL hsCall);
RVAPI
int RVCALLCONV cmCallOverlapSending(IN HCALL hsCall,char * address);
RVAPI
HPROTCONN RVCALLCONV cmGetTpktChanHandle(
IN HCALL hsCall,
IN cmTpktChanHandleType tpktChanHandleType);
RVAPI
HPROTCONN RVCALLCONV cmGetUdpChanHandle(IN HCALL hsCall,cmUdpChanHandleType udpChanHandleType);
RVAPI
int RVCALLCONV cmSetUdpChanApplHandle(IN HPROTCONN hCon,HAPPCONN hAppConn);
RVAPI
int RVCALLCONV cmSetTpktChanApplHandle(
IN HPROTCONN hConn,
IN HAPPCONN hAppConn);
RVAPI
int RVCALLCONV cmGetUdpChanApplHandle(IN HPROTCONN hCon,HAPPCONN * hAppConn);
RVAPI
int RVCALLCONV cmGetTpktChanApplHandle(
IN HPROTCONN hConn,
OUT HAPPCONN* hAppConn);
RVAPI
int RVCALLCONV cmCallIncompleteAddress(IN HCALL hsCall);
RVAPI
int RVCALLCONV cmCallAddressComplete(IN HCALL hsCall);
RVAPI
int RVCALLCONV cmCallOverlapSendingExt(IN HCALL hsCall,char * address,RvBool sendingComplete);
/************************************************************************
* cmSendRAI
* purpose: Sends a RAI message to the gatekeeper.
* It is only applicable when the RAS.manualRAS key is not
* defined in the configuration (automatic RAS mode).
* It reads registration information from RAS.registrationInfo
* configuration key.
* input : hApp - Application's handle of the stack
* almoustOutOfResources - Indicates that it is or is not almost
* out of resources
* output : none
* return : If an error occurs, the function returns a negative value.
* If no error occurs, the function returns a non-negative value.
************************************************************************/
RVAPI int RVCALLCONV
cmSendRAI(
IN HAPP hApp,
IN RvBool almostOutOfResources);
#define cmCallSetHandle cmSetCallHandle
RVAPI
int RVCALLCONV cmSetCallHandle(IN HCALL hsCall, IN HAPPCALL haCall);
/************************************************************************
* cmCallGetHandle
* purpose: Returns the application handle for a call from the call handle.
* input : hsCall - Stack handle for the call
* output : haCall - Application handle for the call
* return : Non-negative value on success
* Negative value on failure
************************************************************************/
RVAPI
int RVCALLCONV cmCallGetHandle(IN HCALL hsCall, OUT HAPPCALL* haCall);
/************************************************************************
* cmGetConfiguration
* purpose: Gives access to the session's configuration context.
* The returned HCFG should be considered read-only, and should
* never be destroyed.
* input : hApp - Stack instance handle
* output : none
* return : HCFG handle of the configuration on success
* NULL on failure
************************************************************************/
RVAPI
HCFG RVCALLCONV cmGetConfiguration(IN HAPP hApp);
/************************************************************************
* cmGetDelimiter
* purpose: Returns the character used as a delimiter between fields,
* such as in the destAddress and srcAddress fields in the
* cmCallMake function.
* input : hApp - Stack instance handle
* output : none
* return : Delimiter character used
************************************************************************/
RVAPI char RVCALLCONV
cmGetDelimiter(HAPP hApp);
RVAPI int RVCALLCONV
cmSetPartnerHandle(HAPP hApp, HAPPPARTNER hAppPartner);
RVAPI int RVCALLCONV
cmGetPartnerHandle(HAPP hApp, HAPPPARTNER* hAppPartner);
/************************************************************************************
*
* cmCallMultiplex
*
* Purpose: To specify call's Q.931 multiplex behavior.
* This function call marks the call as supporting the Q.931 multiplexing
*
* Input: hsCall - The stack handle to the call
* hsSameConnectionCall - The stack handle to the call which Q.931
* connection is the prefered connection for the hsCall
* If this parameter is not NULL and hsSameConnectionCall
* has Q.931 connection, which remote address equal to the
* hsCall's desireable Q.931 connection remote address then
* the same Q.931 connection will be used for both calls.
*
* Output: None.
*
* Returned value: A nonnegative value on success
*
**************************************************************************************/
RVAPI
int RVCALLCONV cmCallMultiplex(
IN HCALL hsCall,
IN HCALL hsSameConnectionCall);
/************************************************************************************
* progressInd_IE enum
* Progress indication information element inside Q931.
* The PROGRESS element can use tag value 30 or 31. When creating a progress record,
* the application can specify which of the tags to use.
* use30asPI_IE - Uses tag value 30 for the ProgressIndication
* use31asPI_IE - Uses tag value 31 for the ProgressIndication
* use30_31asPI_IE - Use both tags. ie - create them both
************************************************************************************/
typedef enum
{
use30asPI_IE=1,
use31asPI_IE=2,
use30_31asPI_IE=3
} progressInd_IE;
/************************************************************************************
*
* cmCallProgressCreate
*
* Purpose: To create PROGRESS message and fill it with the specified parameters
*
* Input: hsCall - The stack handle to the call
* display - The display field
* cause - The causeValue (-1 if not used)
* pi_IE - Indicator whether IE to use for progressIndicator IE
* 30 , 31 or both
* progressDescription - The value of the progressIndicator's progressDescription (-1 if not used)
* notificationDescription - The value of the notifyIndicator's notifyDescription (-1 if not used)
* param - The nonStandardParam to be put into the message (NULL if not used)
*
* Output: None.
*
* Returned value: The root node ID of the created progress message on success
* This root value should be passed to cmCallProgress() function.
* Negative value on failure
*
**************************************************************************************/
RVAPI
int RVCALLCONV cmCallProgressCreate(
IN HCALL hsCall,
IN char* display,
IN int cause,
IN progressInd_IE pi_IE,
IN int progressDescription,
IN int notificationDescription,
IN cmNonStandardParam* param);
/************************************************************************************
*
* cmCallProgressGet
*
* Purpose: To decode PROGRESS message
*
* Input: hApp - The stack instance handle
* message - Progress message to decode
* displaySize - The display field size in bytes.
*
* Output: display - The display field (user allocated memory)
* cause - The causeValue (-1 if absent)
* pi_IE - Indicator whether IE to use for progressIndicator IE
* 30 , 31 or both
* progressDescription - The value of the progressIndicator's progressDescription (-1 if absent)
* notificationDescription - The value of the notifyIndicator's notifyDescription (-1 if absent)
* param - The nonStandardParam from the message
* (param->length==RV_ERROR_UNKNOWN if it wasn't there)
* ** Any of the output fields can be passed as NULL if the
* application doesn't care about their values
*
* Returned value: A nonnegative value on success
*
**************************************************************************************/
RVAPI
int RVCALLCONV cmCallProgressGet(
IN HAPP hApp,
IN int message,
OUT char* display,
IN int displaySize,
OUT int* cause,
OUT progressInd_IE* pi_IE,
OUT int* progressDescription,
OUT int* notificationDescription,
OUT cmNonStandardParam* param);
/************************************************************************************
*
* cmCallNotifyCreate
*
* Purpose: To create NOTIFY message and fill it with the specified parameters
*
* Input: hsCall - The stack handle to the call
* display - The display field
* notificationDescription - The value of the notifyIndicator's notifyDescription (-1 if not used)
* param - The nonStandardParam to be put into the message
*
* Output: None.
*
* Returned value: The root node ID of the created notify message on success
* This root value should be passed to cmCallNotify() function.
* Negative value on failure
*
**************************************************************************************/
RVAPI
int RVCALLCONV cmCallNotifyCreate(
IN HCALL hsCall,
IN char* display,
IN int notificationDescription,
IN cmNonStandardParam* param);
/************************************************************************************
*
* cmCallNotifyGet
*
* Purpose: To decode NOTIFY message
*
* Input: hApp - The stack instance handle
* message - Progress message to decode
* displaySize - The display field size in bytes.
*
* Output: display - The display field (user allocated memory)
* notificationDescription - The value of the notifyIndicator's notifyDescription (-1 if absent)
* param
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -