oms_data_def_entry_access()
摘要
从属性数据库中获取数据。
语法
oms_data_def_entry_access (category_name, entry_name)
| 参数 | 类型 | 说明 |
|---|---|---|
category_name |
char * |
所要查询的类别名。 |
entry_name |
char * |
所要查询的条目名。 |
返回类型
void *
在指定类别名与条目名下所存储的指针。
如果该类别不存在,或者该类别下的该条目不存在,函数返回 OPC_NIL。
详细说明
每个类别名在全网范围的数据库内唯一,每个条目名在其所属类别内唯一。这种两级分类方式简化了分类,并缩短了存储与检索时间。
在许多情况下,category_name 的值是高层属性名(例如 IP Compression Info),而 entry_name 的值是赋予某个取值组合的 Name 的值。
示例
摘自 ip_rte_v4 进程模型中 wait 状态的 exit execs。
/* Retrieve the information about the compression scheme*/
/* used for this interface from the network-wide attribute*/
/* database. Use the comp_info_str (name) as the reference.*/
iface_info_ptr->comp_info = oms_data_def_entry_access ("IP Compression Information", comp_info_str);