Ets_Obj_Attr_Set()

摘要

设置指定 ETS 对象某个属性的值。

语法

Ets_Obj_Attr_Set (obj_hndl, attr_name, val_ptr)
参数 类型 说明
obj_hndl_ptr EtsT_Obj_Handle 目标对象的句柄。
attr_name char * 目标属性的名称。
val_ptr void * 要设置到目标属性上的新值。

返回类型

EtsT_Compcode

若属性存在且有效则返回 EtsC_Compcode_Success,否则返回 EtsC_Compcode_Failure。

头文件

ets_api_obj.h

详情

该函数的用途是设置对象某个特定属性的值字段。该对象不必已安装(installed)在模型中。你可能需要先设置模型层的属性。对于未安装的对象,不能修改以下属性:orbit、trajectory。

该函数只能设置下列类型的属性。调用方必须知道属性的类型(不确定时可使用 Ets_Obj_Attr_Desc_Type_Get())。

要设置的属性类型… val_ptr 必须是…
int int
double double
string char *
text list PrgT_List
compound attr obj EtsT_Obj_Handle
toggle int
typed file char *
profile PrgT_Profile_Spec

本站文档由 北京智网畅联科技有限公司 整理、翻译并提供 · 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