UM C API  6.17.2
Add a field to a message

Functions

LBMSDMExpDLL int lbmsdm_msg_add_boolean (lbmsdm_msg_t *Message, const char *Name, uint8_t Value)
 Add a field to a message. More...
 
LBMSDMExpDLL int lbmsdm_msg_add_int8 (lbmsdm_msg_t *Message, const char *Name, int8_t Value)
 
LBMSDMExpDLL int lbmsdm_msg_add_uint8 (lbmsdm_msg_t *Message, const char *Name, uint8_t Value)
 
LBMSDMExpDLL int lbmsdm_msg_add_int16 (lbmsdm_msg_t *Message, const char *Name, int16_t Value)
 
LBMSDMExpDLL int lbmsdm_msg_add_uint16 (lbmsdm_msg_t *Message, const char *Name, uint16_t Value)
 
LBMSDMExpDLL int lbmsdm_msg_add_int32 (lbmsdm_msg_t *Message, const char *Name, int32_t Value)
 
LBMSDMExpDLL int lbmsdm_msg_add_uint32 (lbmsdm_msg_t *Message, const char *Name, uint32_t Value)
 
LBMSDMExpDLL int lbmsdm_msg_add_int64 (lbmsdm_msg_t *Message, const char *Name, int64_t Value)
 
LBMSDMExpDLL int lbmsdm_msg_add_uint64 (lbmsdm_msg_t *Message, const char *Name, uint64_t Value)
 
LBMSDMExpDLL int lbmsdm_msg_add_float (lbmsdm_msg_t *Message, const char *Name, float Value)
 
LBMSDMExpDLL int lbmsdm_msg_add_double (lbmsdm_msg_t *Message, const char *Name, double Value)
 
LBMSDMExpDLL int lbmsdm_msg_add_decimal (lbmsdm_msg_t *Message, const char *Name, const lbmsdm_decimal_t *Value)
 
LBMSDMExpDLL int lbmsdm_msg_add_timestamp (lbmsdm_msg_t *Message, const char *Name, const struct timeval *Value)
 
LBMSDMExpDLL int lbmsdm_msg_add_message (lbmsdm_msg_t *Message, const char *Name, const lbmsdm_msg_t *Value)
 
LBMSDMExpDLL int lbmsdm_msg_add_string (lbmsdm_msg_t *Message, const char *Name, const char *Value)
 
LBMSDMExpDLL int lbmsdm_msg_add_unicode (lbmsdm_msg_t *Message, const char *Name, const wchar_t *Value, size_t Length)
 Add a unicode field to a message. More...
 
LBMSDMExpDLL int lbmsdm_msg_add_blob (lbmsdm_msg_t *Message, const char *Name, const void *Value, size_t Length)
 Add a BLOB field to a message. More...
 

Detailed Description

The functions in this group allow scalar (non-array) fields to be added to a message. The field value is also specified.

Function Documentation

LBMSDMExpDLL int lbmsdm_msg_add_blob ( lbmsdm_msg_t *  Message,
const char *  Name,
const void *  Value,
size_t  Length 
)

Add a BLOB field to a message.

Parameters
MessageThe SDM message to which the field is to be added.
NameName of the field to be added.
ValueValue of the field to be added.
LengthLength of the data, in bytes.
Returns
LBMSDM_SUCCESS if successful, LBMSDM_FAILURE otherwise.
LBMSDMExpDLL int lbmsdm_msg_add_boolean ( lbmsdm_msg_t *  Message,
const char *  Name,
uint8_t  Value 
)

Add a field to a message.

Parameters
MessageThe SDM message to which the field is to be added.
NameName of the field to be added.
ValueValue of the field to be added.
Returns
LBMSDM_SUCCESS if successful, LBMSDM_FAILURE otherwise.
LBMSDMExpDLL int lbmsdm_msg_add_decimal ( lbmsdm_msg_t *  Message,
const char *  Name,
const lbmsdm_decimal_t *  Value 
)

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

LBMSDMExpDLL int lbmsdm_msg_add_double ( lbmsdm_msg_t *  Message,
const char *  Name,
double  Value 
)

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

LBMSDMExpDLL int lbmsdm_msg_add_float ( lbmsdm_msg_t *  Message,
const char *  Name,
float  Value 
)

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

LBMSDMExpDLL int lbmsdm_msg_add_int16 ( lbmsdm_msg_t *  Message,
const char *  Name,
int16_t  Value 
)

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

LBMSDMExpDLL int lbmsdm_msg_add_int32 ( lbmsdm_msg_t *  Message,
const char *  Name,
int32_t  Value 
)

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

LBMSDMExpDLL int lbmsdm_msg_add_int64 ( lbmsdm_msg_t *  Message,
const char *  Name,
int64_t  Value 
)

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

LBMSDMExpDLL int lbmsdm_msg_add_int8 ( lbmsdm_msg_t *  Message,
const char *  Name,
int8_t  Value 
)

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

LBMSDMExpDLL int lbmsdm_msg_add_message ( lbmsdm_msg_t *  Message,
const char *  Name,
const lbmsdm_msg_t *  Value 
)

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

LBMSDMExpDLL int lbmsdm_msg_add_string ( lbmsdm_msg_t *  Message,
const char *  Name,
const char *  Value 
)

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

LBMSDMExpDLL int lbmsdm_msg_add_timestamp ( lbmsdm_msg_t *  Message,
const char *  Name,
const struct timeval *  Value 
)

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

LBMSDMExpDLL int lbmsdm_msg_add_uint16 ( lbmsdm_msg_t *  Message,
const char *  Name,
uint16_t  Value 
)

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

LBMSDMExpDLL int lbmsdm_msg_add_uint32 ( lbmsdm_msg_t *  Message,
const char *  Name,
uint32_t  Value 
)

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

LBMSDMExpDLL int lbmsdm_msg_add_uint64 ( lbmsdm_msg_t *  Message,
const char *  Name,
uint64_t  Value 
)

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

LBMSDMExpDLL int lbmsdm_msg_add_uint8 ( lbmsdm_msg_t *  Message,
const char *  Name,
uint8_t  Value 
)

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

LBMSDMExpDLL int lbmsdm_msg_add_unicode ( lbmsdm_msg_t *  Message,
const char *  Name,
const wchar_t *  Value,
size_t  Length 
)

Add a unicode field to a message.

Parameters
MessageThe SDM message to which the field is to be added.
NameName of the field to be added.
ValueValue of the field to be added.
LengthLength of the unicode string, in wchar_ts.
Returns
LBMSDM_SUCCESS if successful, LBMSDM_FAILURE otherwise.