PREV TOC HOME INDEX NEXT


gc_CCLibIDToName( )


Termination Events | Cautions | Errors | Example | See Also

Name: int gc_CCLibIDToName(cclibid, lib_name)
Inputs:

int cclibid

  • ID code of library
 

char **lib_name

  • pointer to address of library name
Returns:

0 if successful

<0 if failure

Includes:

gclib.h

gcerr.h

Category:

library information

Mode:

synchronous

Platform and Technology:

All

Description

The gc_CCLibIDToName( ) function converts call control library ID to name of the call control library. The library name associated with the cclibid library identification parameter is stored in a string designated by the lib_name parameter.

Parameter

Description

cclibid identification number of call control library. If a library name is not associated with this parameter, then the library name will be NULL.
lib_name points to the location where the name of the call control library associated with the cclibid parameter is stored. See gc_CCLibNameToID( ) for valid call control library names.

Termination Events

None

Cautions

Do not overwrite the *lib_name pointer as it points to private internal Global Call data space.

Errors

If this function returns <0 to indicate failure, use the gc_ErrorInfo( ) function to retrieve the reason for the error. See the "Error Handling" section in the Global Call API Programming Guide. All Global Call error codes are defined in the gcerr.h file. If the error returned is technology specific, see the technology-specific error header file(s) for the error definition (for example, ccerr.h or isdnerr.h file for the ISDN call control library).

Example

#include <stdio.h>
#include <srllib.h>
#include <gclib.h>
#include <gcerr.h> 
int cclibid_to_name(int cclibid, char **lib_name)
{
    GC_INFO        gc_error_info;    /* GlobalCall error information data */ 
    if (gc_CCLibIDToName(cclibid, lib_name) != GC_SUCCESS) {
        /* process error return as shown */
        gc_ErrorInfo( &gc_error_info );
        printf ("Error: gc_CCLibIDToName(), cclibid: 0x%lx, GC ErrorValue: 0x%hx - %s, CCLibID: %i - %s, CC ErrorValue: 0x%lx - %s\n",
               cclibid, gc_error_info.gcValue, gc_error_info.gcMsg, 
               gc_error_info.ccLibId, gc_error_info.ccLibName,
               gc_error_info.ccValue, gc_error_info.ccMsg);
        return (gc_error_info.gcValue);
    }
    return(0);
} 

See Also


PREV TOC HOME INDEX NEXT

Click here to contact Telecom Support Resources

Copyright 2003, Intel Corporation
All rights reserved
This page generated February, 2003