Add Scalar
Convenience Methods
Declaration
TibrvStatusadd
type
(
const char* fieldName,
tibrv_type
value,
tibrv_u16 fieldId=0);
Purpose
Add a field containing a scalar value.
Method Name |
Field Value Type |
Type Description |
|
|
boolean |
|
|
32-bit floating point |
|
|
64-bit floating point |
|
|
8-bit integer |
|
|
16-bit integer |
|
|
32-bit integer |
|
|
64-bit integer |
|
|
8-bit unsigned integer |
|
|
16-bit unsigned integer |
|
|
32-bit unsigned integer |
|
|
64-bit unsigned integer |
|
|
4-byte IP address |
|
|
2-byte IP port |
Parameter |
Description |
|
Create the field with this name.
|
|
Add a new field with this value (which may be a literal or stored in a variable). The convenience method must correspond to the datatype of this value. We recommend casting the data to match the convenience method. The method copies the value into the new message field. |
|
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 |