op_pk_create_vvec()

Abstract

Creates a new value vector packet.

Syntax

op_pk_create_vvec ()
Argument Type Description
no arguments

Return Type

Packet*

Pointer to the new packet created by this KP.

Example

/* A value vector representing an entire packet has been */
/* completely received on an esys interface. */

/* Create a new empty value vector packet */
rcv_pkptr = op_pk_create_vvec ();

/* Set the value vector obtained from the esys interface into the packet */
op_pk_vvec_set (rcv_pkptr, rcv_vvec);

/* Transform, in place, the value vector form of the packet to */
/* the named field form of an "ethernet" packet. */
op_pk_convert_from_vvec (rcv_pkptr, "ethernet");

Details

The value vector packet created does not contain a value vector. After creating the value vector packet, the KP op_pk_vvec_set() can be used to place an existing value vector inside the packet. Also, the newly created packet’s bulk size is 0, although this can be modified by op_pk_bulk_size_set().

Purpose

Provides a mechanism to create empty value vector packets.

Errors

  • Program Abort: Allocation of memory failed.

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