Add Array

Convenience Methods

Declaration

TibrvStatus addelement_typeArray(
    const char*           fieldName,
    const element_type*    value,
    tibrv_u32             numElements,
    tibrv_u16             fieldId=0);

Purpose

Add a field containing an array value.

Method Name

Element Type

Type Description

addF32Array

tibrv_f32

32-bit floating point array

addF64Array

tibrv_f64

64-bit floating point array

addI8Array

tibrv_i8

8-bit integer array

addI16Array

tibrv_i16

16-bit integer array

addI32Array

tibrv_i32

32-bit integer array

addI64Array

tibrv_i64

64-bit integer array

addU8Array

tibrv_u8

8-bit unsigned integer array

addU16Array

tibrv_u16

16-bit unsigned integer array

addU32Array

tibrv_u32

32-bit unsigned integer array

addU64Array

tibrv_u64

64-bit unsigned integer array

Parameter

Description

fieldName

Create the new field with this name.

NULL is a legal name. However, if fieldId is non-zero, then fieldName must be non-NULL.

value

Add a new field that contains this array.

The method signature must correspond to the datatype of this value.

The method copies the array into the new message field.

numElements

When adding an array type, the program supplies the count of array elements in this parameter.

fieldId

Create the new field with this identifier. Zero is a special value that signifies no field identifier. All non-zero field identifiers must be unique within each message.

It is illegal to add a field that has both a NULL field name, and a non-zero field identifier.