Click here to view and discuss this page in DocCommentXchange. In the future, you will be sent there automatically.

SQL Anywhere 11.0.1 (中文) » MobiLink - 服务器启动的同步 » 用于 Palm 设备的 MobiLink 监听器 C API

 

PalmLsnCheckConfigDB 方法

报告监听器配置数据库中的错误。

语法
palm_lsn_ret PalmLsnCheckConfigDB(
 Char const *  cfg,
 UInt16 * const rec
)
参数
  • cfg   包含配置数据库名称的字符数组。要获得配置数据库名称,请使用 PalmLsnGetConfigFileName 方法。请参见PalmLsnGetConfigFileName 方法

  • rec   标识配置数据库中有问题或格式有误的记录的索引的输出参数。

返回值

palm_lsn_ret 枚举中列出的返回代码之一。请参见palm_lsn_ret 枚举

注释

可以使用此方法检测打开配置数据库或读取其记录时发生的错误。

另请参见
示例

以下示例使用 PalmLsnCheckConfigDB 检测配置数据库中有问题的或残缺的记录:

Err     ret;
UInt16  badRec;
Char    configDb[dmDBNameLength];

// Get configuration database name
PalmLsnGetConfigFileName(configDb);

// check for errors in the configuration database
ret = PalmLsnCheckConfigDB(configDb, &badRec);
if (ret!=errNone) {
    // handle error
}