beautypg.com

Initializing the library – Grass Valley K2 TX/MAM Database Protocol Manual v.2.2 User Manual

Page 6

background image

TX/MAM Database Protocol Manual - document version: 2.2

– Page 6

5.

Initializing the library

The following functions are used to configure the library.

5.1 Initializing the library to use a local playout database

Use this function to verify if the local playout database can be accessed.

int cob_init( char *channel_name );



Parameters

Name

Description

char *channel_name

Not used, can be used with "no_name".



Result
The result of the function is an integer that can have following values:

Value

Description

0

Success, the library can now be used to retrieve information from the local
Playout database.

-1

Failure, setting up a connection to the local playout database failed.



Example

if ( cob_init("no_name")==0 ){

/* continue with the rest of the applet */

} else {

/* not possible to connect to database, report error and stop...*/

return -1;

}