Ets_Odb_Run_Command()

摘要

执行一条 ODB 命令,并以列表形式返回其输出。

语法

Ets_Odb_Run_Command (state_ptr, command)
参数 类型 说明
state_ptr void * 仿真状态
command const char * 要执行的 ODB 命令

返回类型

PrgT_List *

命令输出的字符串列表。

头文件

ets_api_odb.h

示例

int dest_ip_objid;
char tmp [VOSC_STR_LEN];
sprintf (tmp, "proldiag %d ip_interfaces", dest_ip_objid);
// first check if the sim hasn't initialized.
PrgT_List *ip_addrs_output = Ets_Odb_Run_Command (sim_state_ptr, tmp);
char *line = (char *)prg_list_access (ip_addrs_output, 0);

详情

此函数不会打断仿真流程。命令及其响应不会出现在控制台中。

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