op_ima_sim_attr_get_int32()

摘要

获取 integer 类型仿真属性的值。

语法

op_ima_sim_attr_get_int32 (attr_name, value_ptr)
参数 类型 说明
attr_name const char * 目标属性的名称
[该值必须指定仿真环境中已定义的属性,否则会弹出针对该属性值的输入提示。]
value_ptr int * 指向某个变量的指针,该变量将被填入指定属性的值

返回类型

Compcode

若成功获取属性值,返回 OPC_COMPCODE_SUCCESS;否则返回 OPC_COMPCODE_FAILURE。

示例

/* If specified, obtain the values set for the maximum  */
/* number of log entries on a per "category" basis. */
if (op_ima_sim_attr_exists (ATMC_CONF_LOG_LIMIT))
	op_ima_sim_attr_get_int32 (ATMC_CONF_LOG_LIMIT, &atm_conf_log_limit);

详情

无。

用途

提供一种机制,用于获取在仿真运行时已被赋值的仿真属性。该内核过程与 op_ima_sim_attr_get() 的工作方式完全相同,但仅适用于数据类型为 integer 的仿真属性。完整用途与详情参见 op_ima_sim_attr_get()。

错误

参考

本站文档由 北京智网畅联科技有限公司 整理、翻译并提供 · Documentation compiled and provided by Beijing ZNetLink Technology Co., Ltd.

交流群 · QQ Group:OPNET/智网妙算网络仿真交流群(群号 486383494)

原文档 © 2017 Riverbed Technology · 本站为公益翻译,由 AI 辅助完成,请仔细甄别

Original documentation © 2017 Riverbed Technology. Community translation, AI-assisted. Contact: jiazequn@znetlink.com