Ovis_Decoration_Info_Template_Scalar_Element_Add()

Abstract

Adds the scalar element to the Ovis template.

Syntax

Ovis_Decoration_Info_Template_Scalar_Element_Add (tmpl_ptr, element_name)
Argument Type Description
tmpl_ptr OvisT_Info_Template * Template
element_name const char * Element name

Return Type

OvisT_Compcode

OvisC_Compcode_Success if the scalar element could be added; OvisC_Compcode_Failure otherwise.

ovis_decoration.h

Details

This function adds the scalar element to the Ovis template.

Example

#define INCOMING_PACKET_FIELD								"Incoming"

OvisT_Info_Template					* template;
OvisT_Info_Group					* info;
OvisT_3D_Position					pos;

template = Ovis_Decoration_Info_Template_Create ("Packet count");
Ovis_Decoration_Info_Template_Scalar_Element_Add (template, INCOMING_PACKET_FIELD);
Ovis_Position_Geodetic_Set (&pos, 0, 0, 100);
info = Ovis_Decoration_Info_Group_Create (template, pos,
	prg_color_from_string ("blue"), OPC_NIL, OPC_NIL, OPC_NIL);
Ovis_Decoration_Info_Group_Scalar_Element_Value_Set (info, INCOMING_PACKET_FIELD,
	10);

Errors

  • Template is NIL.
  • No element name provided.
  • Element <name> is already part of the template.

Reference

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