Classes Files

Wombat::MamaMsg

More…

#include <MamaMsg.h>

Public Functions

  Name
  ~MamaMsg()
  MamaMsg(void )
  MamaMsg(const MamaMsg & mm)
void create(void )
  MAMADeprecated(“createForPayload has been deprecated, use dynamic loading instead!” ) const
void createForPayloadBridge(mamaPayloadBridge payloadBridge)
void createFromBuffer(const void * buffer, size_t bufferLength)
void copy(const MamaMsg & rhs)
MamaMsg * getTempCopy()
void applyMsg(const MamaMsg & msg)
void clear(void )
size_t getNumFields(void ) const
size_t getByteSize(void ) const
bool getBoolean(const char * name, mama_fid_t fid) const
bool getBoolean(const MamaFieldDescriptor * fieldDesc) const
char getChar(const char * name, mama_fid_t fid) const
char getChar(const MamaFieldDescriptor * fieldDesc) const
mama_i8_t getI8(const char * name, mama_fid_t fid) const
mama_i8_t getI8(const MamaFieldDescriptor * fieldDesc) const
mama_u8_t getU8(const char * name, mama_fid_t fid) const
mama_u8_t getU8(const MamaFieldDescriptor * fieldDesc) const
mama_i16_t getI16(const char * name, mama_fid_t fid) const
mama_i16_t getI16(const MamaFieldDescriptor * fieldDesc) const
mama_u16_t getU16(const char * name, mama_fid_t fid) const
mama_u16_t getU16(const MamaFieldDescriptor * fieldDesc) const
mama_i32_t getI32(const char * name, mama_fid_t fid) const
mama_i32_t getI32(const MamaFieldDescriptor * fieldDesc) const
mama_u32_t getU32(const char * name, mama_fid_t fid) const
mama_u32_t getU32(const MamaFieldDescriptor * fieldDesc) const
mama_i64_t getI64(const char * name, mama_fid_t fid) const
mama_i64_t getI64(const MamaFieldDescriptor * fieldDesc) const
mama_u64_t getU64(const char * name, mama_fid_t fid) const
mama_u64_t getU64(const MamaFieldDescriptor * fieldDesc) const
mama_f32_t getF32(const char * name, mama_fid_t fid) const
mama_f32_t getF32(const MamaFieldDescriptor * fieldDesc) const
mama_f64_t getF64(const char * name, mama_fid_t fid) const
mama_f64_t getF64(const MamaFieldDescriptor * fieldDesc) const
const char * getString(const char * name, mama_fid_t fid) const
const char * getString(const MamaFieldDescriptor * fieldDesc) const
const void * getOpaque(const char * name, mama_fid_t fid, size_t & size) const
const void * getOpaque(const MamaFieldDescriptor * fieldDesc, size_t & size) const
void getDateTime(const char * name, mama_fid_t fid, MamaDateTime & result) const
void getDateTime(const MamaFieldDescriptor * fieldDesc, MamaDateTime & result) const
void getPrice(const char * name, mama_fid_t fid, MamaPrice & result) const
void getPrice(const MamaFieldDescriptor * fieldDesc, MamaPrice & result) const
const MamaMsg * getMsg(const char * name, mama_fid_t fid) const
const MamaMsg * getMsg(const MamaFieldDescriptor * fieldDesc) const
const char * getVectorChar(const char * name, mama_fid_t fid, size_t & resultLen) const
const char * getVectorChar(const MamaFieldDescriptor * fieldDesc, size_t & resultLen) const
const mama_i8_t * getVectorI8(const char * name, mama_fid_t fid, size_t & resultLen) const
const mama_i8_t * getVectorI8(const MamaFieldDescriptor * fieldDesc, size_t & resultLen) const
const mama_u8_t * getVectorU8(const char * name, mama_fid_t fid, size_t & resultLen) const
const mama_u8_t * getVectorU8(const MamaFieldDescriptor * fieldDesc, size_t & resultLen) const
const mama_i16_t * getVectorI16(const char * name, mama_fid_t fid, size_t & resultLen) const
const mama_i16_t * getVectorI16(const MamaFieldDescriptor * fieldDesc, size_t & resultLen) const
const mama_u16_t * getVectorU16(const char * name, mama_fid_t fid, size_t & resultLen) const
const mama_u16_t * getVectorU16(const MamaFieldDescriptor * fieldDesc, size_t & resultLen) const
const mama_i32_t * getVectorI32(const char * name, mama_fid_t fid, size_t & resultLen) const
const mama_i32_t * getVectorI32(const MamaFieldDescriptor * fieldDesc, size_t & resultLen) const
const mama_u32_t * getVectorU32(const char * name, mama_fid_t fid, size_t & resultLen) const
const mama_u32_t * getVectorU32(const MamaFieldDescriptor * fieldDesc, size_t & resultLen) const
const mama_i64_t * getVectorI64(const char * name, mama_fid_t fid, size_t & resultLen) const
const mama_i64_t * getVectorI64(const MamaFieldDescriptor * fieldDesc, size_t & resultLen) const
const mama_u64_t * getVectorU64(const char * name, mama_fid_t fid, size_t & resultLen) const
const mama_u64_t * getVectorU64(const MamaFieldDescriptor * fieldDesc, size_t & resultLen) const
const mama_f32_t * getVectorF32(const char * name, mama_fid_t fid, size_t & resultLen) const
const mama_f32_t * getVectorF32(const MamaFieldDescriptor * fieldDesc, size_t & resultLen) const
const mama_f64_t * getVectorF64(const char * name, mama_fid_t fid, size_t & resultLen) const
const mama_f64_t * getVectorF64(const MamaFieldDescriptor * fieldDesc, size_t & resultLen) const
const MamaMsg ** getVectorMsg(const char * name, mama_fid_t fid, size_t & resultLen) const
const MamaMsg ** getVectorMsg(const MamaFieldDescriptor * fieldDesc, size_t & resultLen) const
const char ** getVectorString(const char * name, mama_fid_t fid, size_t & resultLen) const
const char ** getVectorString(const MamaFieldDescriptor * fieldDesc, size_t & resultLen) const
bool tryBoolean(const char * name, mama_fid_t fid, bool & result) const
bool tryBoolean(const MamaFieldDescriptor * field, bool & result) const
bool tryChar(const char * name, mama_fid_t fid, char & result) const
bool tryChar(const MamaFieldDescriptor * field, char & result) const
bool tryI8(const char * name, mama_fid_t fid, mama_i8_t & result) const
bool tryI8(const MamaFieldDescriptor * field, mama_i8_t & result) const
bool tryU8(const char * name, mama_fid_t fid, mama_u8_t & result) const
bool tryU8(const MamaFieldDescriptor * field, mama_u8_t & result) const
bool tryI16(const char * name, mama_fid_t fid, mama_i16_t & result) const
bool tryI16(const MamaFieldDescriptor * field, mama_i16_t & result) const
bool tryU16(const char * name, mama_fid_t fid, mama_u16_t & result) const
bool tryU16(const MamaFieldDescriptor * field, mama_u16_t & result) const
bool tryI32(const char * name, mama_fid_t fid, mama_i32_t & result) const
bool tryI32(const MamaFieldDescriptor * field, mama_i32_t & result) const
bool tryU32(const char * name, mama_fid_t fid, mama_u32_t & result) const
bool tryU32(const MamaFieldDescriptor * field, mama_u32_t & result) const
bool tryI64(const char * name, mama_fid_t fid, mama_i64_t & result) const
bool tryI64(const MamaFieldDescriptor * field, mama_i64_t & result) const
bool tryU64(const char * name, mama_fid_t fid, mama_u64_t & result) const
bool tryU64(const MamaFieldDescriptor * field, mama_u64_t & result) const
bool tryF32(const char * name, mama_fid_t fid, mama_f32_t & result) const
bool tryF32(const MamaFieldDescriptor * field, mama_f32_t & result) const
bool tryF64(const char * name, mama_fid_t fid, mama_f64_t & result) const
bool tryF64(const MamaFieldDescriptor * field, mama_f64_t & result) const
bool tryString(const char * name, mama_fid_t fid, const char *& result) const
bool tryString(const MamaFieldDescriptor * field, const char *& result) const
bool tryDateTime(const char * name, mama_fid_t fid, MamaDateTime & result) const
bool tryDateTime(const MamaFieldDescriptor * field, MamaDateTime & result) const
bool tryPrice(const char * name, mama_fid_t fid, MamaPrice & result) const
bool tryPrice(const MamaFieldDescriptor * field, MamaPrice & result) const
bool tryMsg(const char * name, mama_fid_t fid, const MamaMsg *& result) const
bool tryMsg(const MamaFieldDescriptor * field, const MamaMsg *& result) const
bool tryOpaque(const char * name, mama_fid_t fid, const void *& result, size_t & size) const
bool tryOpaque(const MamaFieldDescriptor * field, const void *& result, size_t & size) const
bool tryVectorChar(const char * name, mama_fid_t fid, const char *& result, size_t & resultLen) const
bool tryVectorChar(const MamaFieldDescriptor * fieldDesc, const char *& result, size_t & resultLen) const
bool tryVectorI8(const char * name, mama_fid_t fid, const mama_i8_t *& result, size_t & resultLen) const
bool tryVectorI8(const MamaFieldDescriptor * fieldDesc, const mama_i8_t *& result, size_t & resultLen) const
bool tryVectorU8(const char * name, mama_fid_t fid, const mama_u8_t *& result, size_t & resultLen) const
bool tryVectorU8(const MamaFieldDescriptor * fieldDesc, const mama_u8_t *& result, size_t & resultLen) const
bool tryVectorI16(const char * name, mama_fid_t fid, const mama_i16_t *& result, size_t & resultLen) const
bool tryVectorI16(const MamaFieldDescriptor * fieldDesc, const mama_i16_t *& result, size_t & resultLen) const
bool tryVectorU16(const char * name, mama_fid_t fid, const mama_u16_t *& result, size_t & resultLen) const
bool tryVectorU16(const MamaFieldDescriptor * fieldDesc, const mama_u16_t *& result, size_t & resultLen) const
bool tryVectorI32(const char * name, mama_fid_t fid, const mama_i32_t *& result, size_t & resultLen) const
bool tryVectorI32(const MamaFieldDescriptor * fieldDesc, const mama_i32_t *& result, size_t & resultLen) const
bool tryVectorU32(const char * name, mama_fid_t fid, const mama_u32_t *& result, size_t & resultLen) const
bool tryVectorU32(const MamaFieldDescriptor * fieldDesc, const mama_u32_t *& result, size_t & resultLen) const
bool tryVectorI64(const char * name, mama_fid_t fid, const mama_i64_t *& result, size_t & resultLen) const
bool tryVectorI64(const MamaFieldDescriptor * fieldDesc, const mama_i64_t *& result, size_t & resultLen) const
bool tryVectorU64(const char * name, mama_fid_t fid, const mama_u64_t *& result, size_t & resultLen) const
bool tryVectorU64(const MamaFieldDescriptor * fieldDesc, const mama_u64_t *& result, size_t & resultLen) const
bool tryVectorF32(const char * name, mama_fid_t fid, const mama_f32_t *& result, size_t & resultLen) const
bool tryVectorF32(const MamaFieldDescriptor * fieldDesc, const mama_f32_t *& result, size_t & resultLen) const
bool tryVectorF64(const char * name, mama_fid_t fid, const mama_f64_t *& result, size_t & resultLen) const
bool tryVectorF64(const MamaFieldDescriptor * fieldDesc, const mama_f64_t *& result, size_t & resultLen) const
bool tryVectorString(const char * name, mama_fid_t fid, const char **& result, size_t & resultLen) const
bool tryVectorString(const MamaFieldDescriptor * fieldDesc, const char **& result, size_t & resultLen) const
bool tryVectorMsg(const char * name, mama_fid_t fid, const MamaMsg **& result, size_t & resultLen) const
bool tryVectorMsg(const MamaFieldDescriptor * fieldDesc, const MamaMsg **& result, size_t & resultLen) const
void addBoolean(const char * name, mama_fid_t fid, bool value)
void addBoolean(const MamaFieldDescriptor * fieldDesc, bool value)
void addChar(const char * name, mama_fid_t fid, char value)
void addChar(const MamaFieldDescriptor * fieldDesc, char value)
void addI8(const char * name, mama_fid_t fid, mama_i8_t value)
void addI8(const MamaFieldDescriptor * fieldDesc, mama_i8_t value)
void addI16(const char * name, mama_fid_t fid, mama_i16_t value)
void addI16(const MamaFieldDescriptor * fieldDesc, mama_i16_t value)
void addI32(const char * name, mama_fid_t fid, mama_i32_t value)
void addI32(const MamaFieldDescriptor * fieldDesc, mama_i32_t value)
void addI64(const char * name, mama_fid_t fid, mama_i64_t value)
void addI64(const MamaFieldDescriptor * fieldDesc, mama_i64_t value)
void addU8(const char * name, mama_fid_t fid, mama_u8_t value)
void addU8(const MamaFieldDescriptor * fieldDesc, mama_u8_t value)
void addU16(const char * name, mama_fid_t fid, mama_u16_t value)
void addU16(const MamaFieldDescriptor * fieldDesc, mama_u16_t value)
void addU32(const char * name, mama_fid_t fid, mama_u32_t value)
void addU32(const MamaFieldDescriptor * fieldDesc, mama_u32_t value)
void addU64(const char * name, mama_fid_t fid, mama_u64_t value)
void addU64(const MamaFieldDescriptor * fieldDesc, mama_u64_t value)
void addF32(const char * name, mama_fid_t fid, mama_f32_t value)
void addF32(const MamaFieldDescriptor * fieldDesc, mama_f32_t value)
void addF64(const char * name, mama_fid_t fid, mama_f64_t value)
void addF64(const MamaFieldDescriptor * fieldDesc, mama_f64_t value)
void addString(const char * name, mama_fid_t fid, const char * value)
void addString(const MamaFieldDescriptor * fieldDesc, const char * value)
void addDateTime(const char * name, mama_fid_t fid, const MamaDateTime & value)
void addDateTime(const MamaFieldDescriptor * fieldDesc, const MamaDateTime & value)
void addPrice(const char * name, mama_fid_t fid, const MamaPrice & value)
void addPrice(const MamaFieldDescriptor * fieldDesc, const MamaPrice & value)
void addOpaque(const char * name, mama_fid_t fid, const void * value, size_t size)
void addOpaque(const MamaFieldDescriptor * fieldDesc, const void * value, size_t size)
void addMsg(const char * name, mama_fid_t fid, MamaMsg * value)
void addMsg(const MamaFieldDescriptor * fieldDesc, MamaMsg * value)
void addVectorChar(const char * name, mama_fid_t fid, const char vectorValues[], size_t vectorLen)
void addVectorChar(const MamaFieldDescriptor * fieldDesc, const char vectorValues[], size_t vectorLen)
void addVectorI8(const char * name, mama_fid_t fid, const mama_i8_t vectorValues[], size_t vectorLen)
void addVectorI8(const MamaFieldDescriptor * fieldDesc, const mama_i8_t vectorValues[], size_t vectorLen)
void addVectorU8(const char * name, mama_fid_t fid, const mama_u8_t vectorValues[], size_t vectorLen)
void addVectorU8(const MamaFieldDescriptor * fieldDesc, const mama_u8_t vectorValues[], size_t vectorLen)
void addVectorI16(const char * name, mama_fid_t fid, const mama_i16_t vectorValues[], size_t vectorLen)
void addVectorI16(const MamaFieldDescriptor * fieldDesc, const mama_i16_t vectorValues[], size_t vectorLen)
void addVectorU16(const char * name, mama_fid_t fid, const mama_u16_t vectorValues[], size_t vectorLen)
void addVectorU16(const MamaFieldDescriptor * fieldDesc, const mama_u16_t vectorValues[], size_t vectorLen)
void addVectorI32(const char * name, mama_fid_t fid, const mama_i32_t vectorValues[], size_t vectorLen)
void addVectorI32(const MamaFieldDescriptor * fieldDesc, const mama_i32_t vectorValues[], size_t vectorLen)
void addVectorU32(const char * name, mama_fid_t fid, const mama_u32_t vectorValues[], size_t vectorLen)
void addVectorU32(const MamaFieldDescriptor * fieldDesc, const mama_u32_t vectorValues[], size_t vectorLen)
void addVectorI64(const char * name, mama_fid_t fid, const mama_i64_t vectorValues[], size_t vectorLen)
void addVectorI64(const MamaFieldDescriptor * fieldDesc, const mama_i64_t vectorValues[], size_t vectorLen)
void addVectorU64(const char * name, mama_fid_t fid, const mama_u64_t vectorValues[], size_t vectorLen)
void addVectorU64(const MamaFieldDescriptor * fieldDesc, const mama_u64_t vectorValues[], size_t vectorLen)
void addVectorF32(const char * name, mama_fid_t fid, const mama_f32_t vectorValues[], size_t vectorLen)
void addVectorF32(const MamaFieldDescriptor * fieldDesc, const mama_f32_t vectorValues[], size_t vectorLen)
void addVectorF64(const char * name, mama_fid_t fid, const mama_f64_t vectorValues[], size_t vectorLen)
void addVectorF64(const MamaFieldDescriptor * fieldDesc, const mama_f64_t vectorValues[], size_t vectorLen)
void addVectorString(const char * name, mama_fid_t fid, const char * vectorValues[], size_t vectorLen)
void addVectorString(const MamaFieldDescriptor * fieldDesc, const char * vectorValues[], size_t vectorLen)
void addVectorMsg(const char * name, mama_fid_t fid, MamaMsg * vectorValues[], size_t vectorLen)
void addVectorMsg(const MamaFieldDescriptor * fieldDesc, MamaMsg * vectorValues[], size_t vectorLen)
void updateBoolean(const char * name, mama_fid_t fid, bool value)
void updateBoolean(const MamaFieldDescriptor * fieldDesc, bool value)
void updateChar(const char * name, mama_fid_t fid, const char value)
void updateChar(const MamaFieldDescriptor * fieldDesc, const char value)
void updateI8(const char * name, mama_fid_t fid, const mama_i8_t value)
void updateI8(const MamaFieldDescriptor * fieldDesc, const mama_i8_t value)
void updateU8(const char * name, mama_fid_t fid, const mama_u8_t value)
void updateU8(const MamaFieldDescriptor * fieldDesc, const mama_u8_t value)
void updateI16(const char * name, mama_fid_t fid, const mama_i16_t value)
void updateI16(const MamaFieldDescriptor * fieldDesc, const mama_i16_t value)
void updateU16(const char * name, mama_fid_t fid, const mama_u16_t value)
void updateU16(const MamaFieldDescriptor * fieldDesc, const mama_u16_t value)
void updateI32(const char * name, mama_fid_t fid, const mama_i32_t value)
void updateI32(const MamaFieldDescriptor * fieldDesc, const mama_i32_t value)
void updateU32(const char * name, mama_fid_t fid, const mama_u32_t value)
void updateU32(const MamaFieldDescriptor * fieldDesc, const mama_u32_t value)
void updateI64(const char * name, mama_fid_t fid, const mama_i64_t value)
void updateI64(const MamaFieldDescriptor * fieldDesc, const mama_i64_t value)
void updateU64(const char * name, mama_fid_t fid, const mama_u64_t value)
void updateU64(const MamaFieldDescriptor * fieldDesc, const mama_u64_t value)
void updateF32(const char * name, mama_fid_t fid, const mama_f32_t value)
void updateF32(const MamaFieldDescriptor * fieldDesc, const mama_f32_t value)
void updateF64(const char * name, mama_fid_t fid, const mama_f64_t value)
void updateF64(const MamaFieldDescriptor * fieldDesc, const mama_f64_t value)
void updateString(const char * name, mama_fid_t fid, const char * value)
void updateString(const MamaFieldDescriptor * fieldDesc, const char * value)
void updateOpaque(const char * name, mama_fid_t fid, const void * value, size_t size)
void updateOpaque(const MamaFieldDescriptor * fieldDesc, const void * value, size_t size)
void updateDateTime(const char * name, mama_fid_t fid, const MamaDateTime & value)
void updateDateTime(const MamaFieldDescriptor * fieldDesc, const MamaDateTime & value)
void updatePrice(const char * name, mama_fid_t fid, const MamaPrice & value)
void updatePrice(const MamaFieldDescriptor * fieldDesc, const MamaPrice & value)
mamaMsgType getType(void ) const
const char * getMsgTypeName(void ) const
mamaMsgStatus getStatus(void ) const
const char * getMsgStatusString(void ) const
void iterateFields(MamaMsgFieldIterator & iterator, const MamaDictionary * dictionary, void * closure) const
const char * toString() const
const char * toJsonString() const
const char * toJsonString(const MamaDictionary * dictionary) const
const char * toNormalizedString() const
void getFieldAsString(const char * name, mama_fid_t fid, char * result, size_t maxResultLen) const
void getFieldAsString(const MamaFieldDescriptor * fieldDesc, char * result, size_t maxResultLen) const
MamaMsgField * getField(const char * name, mama_fid_t fid) const
MamaMsgField * getField(const MamaFieldDescriptor * fieldDesc) const
bool tryField(const char * name, mama_fid_t fid) const
bool tryField(const MamaFieldDescriptor * fieldDesc) const
bool tryField(const char * name, mama_fid_t fid, MamaMsgField * result) const
bool tryField(const MamaFieldDescriptor * fieldDesc, MamaMsgField * result) const
bool tryFieldAsString(const char * name, mama_fid_t fid, char * result, size_t maxResultLen) const
bool tryFieldAsString(const MamaFieldDescriptor * fieldDesc, char * result, size_t maxResultLen) const
void getByteBuffer(const void *& buffer, size_t & bufferLength) const
MamaMsg * detach(void )
bool isFromInbox(void ) const
mama_seqnum_t getSeqNum(void ) const
bool getIsDefinitelyDuplicate(void ) const
bool getIsPossiblyDuplicate(void ) const
bool getIsPossiblyDelayed(void ) const
bool getIsDefinitelyDelayed(void ) const
bool getIsOutOfSequence(void ) const
bool setNewBuffer(void * buffer, mama_size_t size)
void * getNativeHandle(void ) const
void createFromMsg(mamaMsg msg, bool destroyMsg =false) const
void setMsg(mamaMsg msg)
const mamaMsg & getUnderlyingMsg(void ) const
mamaMsg getUnderlyingMsg(void )
MAMAIgnoreDeprecatedOpen mamaPayloadType getPayloadType(void ) const
MAMAIgnoreDeprecatedClose void * getNativeMsg(void )
MamaMsgField & begin(MamaMsgIterator & theIterator) const
mamaMsgReply getReplyHandle(void ) const
void destroyReplyHandle(mamaMsgReply replyHandle)

Detailed Description

class Wombat::MamaMsg;

Author: Michael Schonberg

MAMA message representation.

Field identifiers must be greater than 0. A field identifier of 0 indicates that there is no unique FID and multiple fields with the same name may have FID == 0.

Field lookup proceeds in the following manner similar to TIBRV.

  • If the fid supplied is non-zero, search for a field with the specified fid and return the field if it exists (the name is not validated). Otherwise throw a STATUS_NOT_FOUND exception.
  • If the fid supplied is 0, return the first field encountered with the supplied name or throw a STATUS_NOT_FOUND exception if no such field exists. Get methods for numeric values may result in loss of information through either rounding or truncation when a larger data type is accessed as a smaller one. The result may be the same as the result of casting the larger value to the smaller. For example calling getShort for an integer field with a value greater than Short.MAX_VALUE might return Short.MIN_VALUE. It is also valid to throw a ClassCastException or other appropriate RuntimeException.

Since some message implementations may not natively support all data types, the behaviour may vary substantially. In creating and accessing messages the API’s assume that the underlying values are stored in the smallest possible fields, and accesses them accordingly. For this reason the minimal requirement is that the methods for accessing and creating fields support the full range of values appropriate for their type. How they deal with larger values should be irrelevant.

Public Functions Documentation

function ~MamaMsg

~MamaMsg()

function MamaMsg

MamaMsg(
    void 
)

function MamaMsg

MamaMsg(
    const MamaMsg & mm
)

function create

void create(
    void 
)

Create the actual underlying wire format message. This method will create a an underlying message native to the middleware being used. Tibrv: RV message LBM: Wombat Message TCP: Wombat Message

function MAMADeprecated

MAMADeprecated(
    "createForPayload has been deprecated,
    use dynamic loading instead!" 
) const

Parameters:

  • id The identifier of the payload to be used.

Deprecated:

This has been deprecated in favor of dynamic loading.

Create a mamaMsg.

function createForPayloadBridge

void createForPayloadBridge(
    mamaPayloadBridge payloadBridge
)

Parameters:

  • id The payload bridge to be used.

Create a mamaMsg.

function createFromBuffer

void createFromBuffer(
    const void * buffer,
    size_t bufferLength
)

Parameters:

  • buffer The byte array containing the wire format of the message
  • bufferLength The length, in bytes, of the supplied buffer

Return: mama_status The outcome of the operation

Create a MamaMsg from the provided byte buffer. The application is responsible for destroying the message. In all cases the buffer is copied as the message is constructed.

Any transport differences are detailed below.

rv: The bufferLength parameter is not required.

Note: wombatmsg format is not currently supported on tibrv transports. At the moment a buffer containing the wire format for each of these transports is expected to be passed to the function.

function copy

void copy(
    const MamaMsg & rhs
)

Copy the message from another, severing all links to the original message

function getTempCopy

MamaMsg * getTempCopy()

Return: The message copy.

Get a temporary copy of the mamaMsg so to be able to modify the content. If the message can be modified directly, the message itself is returned. If the message cannot be modified then only one copy is performed the first time this method is called and then the same copy is returned when this method is called again. The copy has the same life time of the original message.

function applyMsg

void applyMsg(
    const MamaMsg & msg
)

function clear

void clear(
    void 
)

Clear the message. All fields are removed.

function getNumFields

size_t getNumFields(
    void 
) const

Return: The number of fields in the message.

Returns the total number of fields in the message. Sub-messages count as a single field.

function getByteSize

size_t getByteSize(
    void 
) const

Return: The number of bytes in the message

Get the message size in bytes. Supported with the following transports: tibrv LBT

function getBoolean

bool getBoolean(
    const char * name,
    mama_fid_t fid
) const

Parameters:

  • name The name
  • fid The field identifier

Return: The integer value.

Get a boolean field.

function getBoolean

bool getBoolean(
    const MamaFieldDescriptor * fieldDesc
) const

Parameters:

  • fieldDesc The field descriptor

Return: The integer value.

Get a boolean field.

function getChar

char getChar(
    const char * name,
    mama_fid_t fid
) const

Parameters:

  • name The name
  • fid The field identifier

Return: The integer value.

Get a char field.

function getChar

char getChar(
    const MamaFieldDescriptor * fieldDesc
) const

Parameters:

  • fieldDesc The field descriptor

Return: The integer value.

Get a char field.

function getI8

mama_i8_t getI8(
    const char * name,
    mama_fid_t fid
) const

Parameters:

  • name The name
  • fid The field identifier

Return: The integer value.

Get an I8 field.

function getI8

mama_i8_t getI8(
    const MamaFieldDescriptor * fieldDesc
) const

Parameters:

  • fieldDesc The field descriptor

Return: The integer value.

Get a I8 field.

function getU8

mama_u8_t getU8(
    const char * name,
    mama_fid_t fid
) const

Parameters:

  • name The name
  • fid The field identifier

Return: The integer value.

Get a U8 field.

function getU8

mama_u8_t getU8(
    const MamaFieldDescriptor * fieldDesc
) const

Parameters:

  • fieldDesc The field descriptor

Return: The integer value.

Get a U8 field.

function getI16

mama_i16_t getI16(
    const char * name,
    mama_fid_t fid
) const

Parameters:

  • name The name
  • fid The field identifier

Return: The integer value.

Get an I16 field.

function getI16

mama_i16_t getI16(
    const MamaFieldDescriptor * fieldDesc
) const

Parameters:

  • fieldDesc The field descriptor

Return: The integer value.

Get an I16 field.

function getU16

mama_u16_t getU16(
    const char * name,
    mama_fid_t fid
) const

Parameters:

  • name The name
  • fid The field identifier

Return: The integer value.

Get a U16 field.

function getU16

mama_u16_t getU16(
    const MamaFieldDescriptor * fieldDesc
) const

Parameters:

  • fieldDesc The field descriptor

Return: The integer value.

Get an U16 field.

function getI32

mama_i32_t getI32(
    const char * name,
    mama_fid_t fid
) const

Parameters:

  • name The name
  • fid The field identifier

Return: The integer value.

Get an I32 field.

function getI32

mama_i32_t getI32(
    const MamaFieldDescriptor * fieldDesc
) const

Parameters:

  • fieldDesc The field descriptor

Return: The integer value.

Get a I32 field.

function getU32

mama_u32_t getU32(
    const char * name,
    mama_fid_t fid
) const

Parameters:

  • name The name
  • fid The field identifier

Return: The integer value.

Get a U32 field.

function getU32

mama_u32_t getU32(
    const MamaFieldDescriptor * fieldDesc
) const

Parameters:

  • fieldDesc The field descriptor

Return: The integer value.

Get a U32 field.

function getI64

mama_i64_t getI64(
    const char * name,
    mama_fid_t fid
) const

Parameters:

  • name The name
  • fid The field identifier.

Return: The field value as a long.

Get a I64 field.

function getI64

mama_i64_t getI64(
    const MamaFieldDescriptor * fieldDesc
) const

Parameters:

  • fieldDesc The field descriptor

Return: The integer value.

Get a I64 field.

function getU64

mama_u64_t getU64(
    const char * name,
    mama_fid_t fid
) const

Parameters:

  • name The name
  • fid The field identifier

Return: The integer value.

Get a U64 field.

function getU64

mama_u64_t getU64(
    const MamaFieldDescriptor * fieldDesc
) const

Parameters:

  • fieldDesc The field descriptor

Return: The integer value.

Get a U64 field.

function getF32

mama_f32_t getF32(
    const char * name,
    mama_fid_t fid
) const

Parameters:

  • name The name.
  • fid The field identifier.

Return: The double value.

Get a f32 field.

function getF32

mama_f32_t getF32(
    const MamaFieldDescriptor * fieldDesc
) const

Parameters:

  • fieldDesc The field descriptor

Return: The double value.

Get a f32 field.

function getF64

mama_f64_t getF64(
    const char * name,
    mama_fid_t fid
) const

Parameters:

  • name The name.
  • fid The field identifier.

Return: The double value.

Get a f64 field.

function getF64

mama_f64_t getF64(
    const MamaFieldDescriptor * fieldDesc
) const

Parameters:

  • fieldDesc The field descriptor

Return: The double value.

Get a f64 field.

function getString

const char * getString(
    const char * name,
    mama_fid_t fid
) const

Parameters:

  • name The field name.
  • fid The field identifier.

Return: The string value. The return value points to the string inside the mamaMsg object. This piece of memory is owned by the object and does not need to be explicitly freed.

Get a const char* field

function getString

const char * getString(
    const MamaFieldDescriptor * fieldDesc
) const

Parameters:

  • fieldDesc Pointer to the field descriptor

Return: The string value. The return value points to the string inside the mamaMsg object. This piece of memory is owned by the object and does not need to be explicitly freed.

Get a const char* field

function getOpaque

const void * getOpaque(
    const char * name,
    mama_fid_t fid,
    size_t & size
) const

Parameters:

  • name The field name.
  • fid The field identifier.
  • size The opaque size in bytes.

Return: the string value.

Get an opaque field.

function getOpaque

const void * getOpaque(
    const MamaFieldDescriptor * fieldDesc,
    size_t & size
) const

Parameters:

  • fieldDesc The field descriptor
  • size The opaque size in bytes.

Return: The double value.

Get a const char* field.

function getDateTime

void getDateTime(
    const char * name,
    mama_fid_t fid,
    MamaDateTime & result
) const

Parameters:

  • name The field name.
  • fid The field identifier.
  • result (out) the date/time.

Get a MamaDateTime field.

function getDateTime

void getDateTime(
    const MamaFieldDescriptor * fieldDesc,
    MamaDateTime & result
) const

Parameters:

  • fieldDesc The field descriptor
  • result (out) the date/time.

Get a MamaDateTime field.

function getPrice

void getPrice(
    const char * name,
    mama_fid_t fid,
    MamaPrice & result
) const

Parameters:

  • name The field name.
  • fid The field identifier.
  • result (out) the date/time.

Get a MamaPrice field.

function getPrice

void getPrice(
    const MamaFieldDescriptor * fieldDesc,
    MamaPrice & result
) const

Parameters:

  • fieldDesc The field descriptor
  • result (out) the date/time.

Get a MamaPrice field.

function getMsg

const MamaMsg * getMsg(
    const char * name,
    mama_fid_t fid
) const

Parameters:

  • name The field name.
  • fid The field identifier.

Return: The submessage.

Get a submessage field.

function getMsg

const MamaMsg * getMsg(
    const MamaFieldDescriptor * fieldDesc
) const

Parameters:

  • fieldDesc The field descriptor

Return: The vector.

Get a submessage field.

function getVectorChar

const char * getVectorChar(
    const char * name,
    mama_fid_t fid,
    size_t & resultLen
) const

Parameters:

  • name The field name.
  • fid The field identifier.
  • resultLen (out) the size of the vector.

Return: The vector.

Get a vector of characters. (Note: prefer using string fields or opaque fields over a vector of characters.)

function getVectorChar

const char * getVectorChar(
    const MamaFieldDescriptor * fieldDesc,
    size_t & resultLen
) const

Parameters:

  • fieldDesc The field descriptor
  • resultLen (out) the size of the vector.

Return: The vector.

Get a vector of characters. (Note: prefer using string fields or opaque fields over a vector of characters.)

function getVectorI8

const mama_i8_t * getVectorI8(
    const char * name,
    mama_fid_t fid,
    size_t & resultLen
) const

Parameters:

  • name The field name.
  • fid The field identifier.
  • resultLen (out) the size of the vector.

Return: The vector.

Get a vector of signed 8-bit integers.

function getVectorI8

const mama_i8_t * getVectorI8(
    const MamaFieldDescriptor * fieldDesc,
    size_t & resultLen
) const

Parameters:

  • fieldDesc The field descriptor
  • resultLen (out) the size of the vector.

Return: The vector.

Get a vector of signed 8-bit integers. or opaque fields over a vector of characters.)

function getVectorU8

const mama_u8_t * getVectorU8(
    const char * name,
    mama_fid_t fid,
    size_t & resultLen
) const

Parameters:

  • name The field name.
  • fid The field identifier.
  • resultLen (out) the size of the vector.

Return: The vector.

Get a vector of unsigned 8-bit integers.

function getVectorU8

const mama_u8_t * getVectorU8(
    const MamaFieldDescriptor * fieldDesc,
    size_t & resultLen
) const

Parameters:

  • fieldDesc The field descriptor
  • resultLen (out) the size of the vector.

Return: The vector.

Get a vector of unsigned 8-bit integers. or opaque fields over a vector of characters.)

function getVectorI16

const mama_i16_t * getVectorI16(
    const char * name,
    mama_fid_t fid,
    size_t & resultLen
) const

Parameters:

  • name The field name.
  • fid The field identifier.
  • resultLen (out) the size of the vector.

Return: The vector.

Get a vector of signed 16-bit integers.

function getVectorI16

const mama_i16_t * getVectorI16(
    const MamaFieldDescriptor * fieldDesc,
    size_t & resultLen
) const

Parameters:

  • fieldDesc The field descriptor
  • resultLen (out) the size of the vector.

Return: The vector.

Get a vector of signed 16-bit integers. or opaque fields over a vector of characters.)

function getVectorU16

const mama_u16_t * getVectorU16(
    const char * name,
    mama_fid_t fid,
    size_t & resultLen
) const

Parameters:

  • name The field name.
  • fid The field identifier.
  • resultLen (out) the size of the vector.

Return: The vector.

Get a vector of unsigned 16-bit integers.

function getVectorU16

const mama_u16_t * getVectorU16(
    const MamaFieldDescriptor * fieldDesc,
    size_t & resultLen
) const

Parameters:

  • fieldDesc The field descriptor
  • resultLen (out) the size of the vector.

Return: The vector.

Get a vector of unsigned 16-bit integers. or opaque fields over a vector of characters.)

function getVectorI32

const mama_i32_t * getVectorI32(
    const char * name,
    mama_fid_t fid,
    size_t & resultLen
) const

Parameters:

  • name The field name.
  • fid The field identifier.
  • resultLen (out) the size of the vector.

Return: The vector.

Get a vector of signed 32-bit integers.

function getVectorI32

const mama_i32_t * getVectorI32(
    const MamaFieldDescriptor * fieldDesc,
    size_t & resultLen
) const

Parameters:

  • fieldDesc The field descriptor
  • resultLen (out) the size of the vector.

Return: The vector.

Get a vector of signed 32-bit integers. or opaque fields over a vector of characters.)

function getVectorU32

const mama_u32_t * getVectorU32(
    const char * name,
    mama_fid_t fid,
    size_t & resultLen
) const

Parameters:

  • name The field name.
  • fid The field identifier.
  • resultLen (out) the size of the vector.

Return: The vector.

Get a vector of unsigned 32-bit integers.

function getVectorU32

const mama_u32_t * getVectorU32(
    const MamaFieldDescriptor * fieldDesc,
    size_t & resultLen
) const

Parameters:

  • fieldDesc The field descriptor
  • resultLen (out) the size of the vector.

Return: The vector.

Get a vector of unsigned 32-bit integers. or opaque fields over a vector of characters.)

function getVectorI64

const mama_i64_t * getVectorI64(
    const char * name,
    mama_fid_t fid,
    size_t & resultLen
) const

Parameters:

  • name The field name.
  • fid The field identifier.
  • resultLen (out) the size of the vector.

Return: The vector.

Get a vector of signed 64-bit integers.

function getVectorI64

const mama_i64_t * getVectorI64(
    const MamaFieldDescriptor * fieldDesc,
    size_t & resultLen
) const

Parameters:

  • fieldDesc The field descriptor
  • resultLen (out) the size of the vector.

Return: The vector.

Get a vector of signed 64-bit integers. or opaque fields over a vector of characters.)

function getVectorU64

const mama_u64_t * getVectorU64(
    const char * name,
    mama_fid_t fid,
    size_t & resultLen
) const

Parameters:

  • name The field name.
  • fid The field identifier.
  • resultLen (out) the size of the vector.

Return: The vector.

Get a vector of unsigned 64-bit integers.

function getVectorU64

const mama_u64_t * getVectorU64(
    const MamaFieldDescriptor * fieldDesc,
    size_t & resultLen
) const

Parameters:

  • fieldDesc The field descriptor
  • resultLen (out) the size of the vector.

Return: The vector.

Get a vector of unsigned 64-bit integers. or opaque fields over a vector of characters.)

function getVectorF32

const mama_f32_t * getVectorF32(
    const char * name,
    mama_fid_t fid,
    size_t & resultLen
) const

Parameters:

  • name The field name.
  • fid The field identifier.
  • resultLen (out) the size of the vector.

Return: The vector.

Get a vector of 32-bit floating point numbers.

function getVectorF32

const mama_f32_t * getVectorF32(
    const MamaFieldDescriptor * fieldDesc,
    size_t & resultLen
) const

Parameters:

  • fieldDesc The field descriptor
  • resultLen (out) the size of the vector.

Return: The vector.

Get a vector of 32-bit floating point numbers. or opaque fields over a vector of characters.)

function getVectorF64

const mama_f64_t * getVectorF64(
    const char * name,
    mama_fid_t fid,
    size_t & resultLen
) const

Parameters:

  • name The field name.
  • fid The field identifier.
  • resultLen (out) the size of the vector.

Return: The vector.

Get a vector of 64-bit floating point numbers.

function getVectorF64

const mama_f64_t * getVectorF64(
    const MamaFieldDescriptor * fieldDesc,
    size_t & resultLen
) const

Parameters:

  • fieldDesc The field descriptor
  • resultLen (out) the size of the vector.

Return: The vector.

Get a vector of 64-bit floating point numbers. or opaque fields over a vector of characters.)

function getVectorMsg

const MamaMsg ** getVectorMsg(
    const char * name,
    mama_fid_t fid,
    size_t & resultLen
) const

Parameters:

  • name The field name.
  • fid The field identifier.
  • resultLen (out) the size of the vector.

Return: The vector.

Get a vector of submessages field.

function getVectorMsg

const MamaMsg ** getVectorMsg(
    const MamaFieldDescriptor * fieldDesc,
    size_t & resultLen
) const

Parameters:

  • fieldDesc The field descriptor
  • resultLen (out) the size of the vector.

Return: The vector.

Get a vector of submessages.

function getVectorString

const char ** getVectorString(
    const char * name,
    mama_fid_t fid,
    size_t & resultLen
) const

Parameters:

  • name The field name.
  • fid The field identifier.
  • resultLen (out) the size of the vector.

Return: The vector.

Get a vector of strings field. The vector is deleted with the message and overwritten by subsequent calls to getVectorString.

function getVectorString

const char ** getVectorString(
    const MamaFieldDescriptor * fieldDesc,
    size_t & resultLen
) const

Parameters:

  • fieldDesc The field descriptor
  • resultLen (out) the size of the vector.

Return: The vector.

Get a vector of submessages. The vector is deleted with the message and overwritten by subsequent calls to getVectorString.

function tryBoolean

bool tryBoolean(
    const char * name,
    mama_fid_t fid,
    bool & result
) const

Parameters:

  • result The result (not modified if field not present) const
  • name The field name
  • fid The field identifier

Return: Whether the field was present.

Try to get a boolean field.

function tryBoolean

bool tryBoolean(
    const MamaFieldDescriptor * field,
    bool & result
) const

Parameters:

  • result The result (not modified if field not present) const
  • field The field to try

Return: Whether the field was present.

Try to get a boolean field.

function tryChar

bool tryChar(
    const char * name,
    mama_fid_t fid,
    char & result
) const

Parameters:

  • result The result (not modified if field not present) const
  • name The field name
  • fid The field identifier

Return: Whether the field was present.

Try to get a char field.

function tryChar

bool tryChar(
    const MamaFieldDescriptor * field,
    char & result
) const

Parameters:

  • result The result (not modified if field not present) const
  • field The field to try

Return: Whether the field was present.

Try to get a char field.

function tryI8

bool tryI8(
    const char * name,
    mama_fid_t fid,
    mama_i8_t & result
) const

Parameters:

  • result The result (not modified if field not present) const
  • name The field name
  • fid The field identifier

Return: Whether the field was present.

Try to get an unsigned 8 bit integer field.

function tryI8

bool tryI8(
    const MamaFieldDescriptor * field,
    mama_i8_t & result
) const

Parameters:

  • result The result (not modified if field not present) const
  • field The field to try

Return: Whether the field was present.

Try to get an unsigned 8 bit field.

function tryU8

bool tryU8(
    const char * name,
    mama_fid_t fid,
    mama_u8_t & result
) const

Parameters:

  • result The result (not modified if field not present) const
  • name The field name
  • fid The field identifier

Return: Whether the field was present.

Try to get an unsigned 8 bit integer field.

function tryU8

bool tryU8(
    const MamaFieldDescriptor * field,
    mama_u8_t & result
) const

Parameters:

  • result The result (not modified if field not present) const
  • field The field to try

Return: Whether the field was present.

Try to get an unsigned 8 bit field.

function tryI16

bool tryI16(
    const char * name,
    mama_fid_t fid,
    mama_i16_t & result
) const

Parameters:

  • result The result (not modified if field not present) const
  • name The field name
  • fid The field identifier

Return: Whether the field was present.

Try to get a signed 16 bit integer field.

function tryI16

bool tryI16(
    const MamaFieldDescriptor * field,
    mama_i16_t & result
) const

Parameters:

  • result The result (not modified if field not present) const
  • field The field to try

Return: Whether the field was present.

Try to get a signed 16 bit field.

function tryU16

bool tryU16(
    const char * name,
    mama_fid_t fid,
    mama_u16_t & result
) const

Parameters:

  • result The result (not modified if field not present) const
  • name The field name
  • fid The field identifier

Return: Whether the field was present.

Try to get an unsigned 16 bit integer field.

function tryU16

bool tryU16(
    const MamaFieldDescriptor * field,
    mama_u16_t & result
) const

Parameters:

  • result The result (not modified if field not present) const
  • field The field to try

Return: Whether the field was present.

Try to get an unsigned 16 bit field.

function tryI32

bool tryI32(
    const char * name,
    mama_fid_t fid,
    mama_i32_t & result
) const

Parameters:

  • result The result (not modified if field not present) const
  • name The field name
  • fid The field identifier

Return: Whether the field was present.

Try to get a signed 32 bit integer field.

function tryI32

bool tryI32(
    const MamaFieldDescriptor * field,
    mama_i32_t & result
) const

Parameters:

  • result The result (not modified if field not present) const
  • field The field to try

Return: Whether the field was present.

Try to get a signed 32 bit integer field.

function tryU32

bool tryU32(
    const char * name,
    mama_fid_t fid,
    mama_u32_t & result
) const

Parameters:

  • result The result (not modified if field not present) const
  • name The field name
  • fid The field identifier

Return: Whether the field was present.

Try to get an unsigned 32 bit integer field.

function tryU32

bool tryU32(
    const MamaFieldDescriptor * field,
    mama_u32_t & result
) const

Parameters:

  • result The result (not modified if field not present) const
  • field The field to try

Return: Whether the field was present.

Try to get an unsigned 32 bit integer field.

function tryI64

bool tryI64(
    const char * name,
    mama_fid_t fid,
    mama_i64_t & result
) const

Parameters:

  • result The result (not modified if field not present) const
  • name The field name
  • fid The field identifier

Return: Whether the field was present.

Try to get a signed 64 bit field.

function tryI64

bool tryI64(
    const MamaFieldDescriptor * field,
    mama_i64_t & result
) const

Parameters:

  • result The result (not modified if field not present) const
  • field The field to try

Return: Whether the field was present.

Try to get a signed 64 bit field.

function tryU64

bool tryU64(
    const char * name,
    mama_fid_t fid,
    mama_u64_t & result
) const

Parameters:

  • result The result (not modified if field not present) const
  • name The field name
  • fid The field identifier

Return: Whether the field was present.

Try to get an unsigned 64 bit field.

function tryU64

bool tryU64(
    const MamaFieldDescriptor * field,
    mama_u64_t & result
) const

Parameters:

  • result The result (not modified if field not present) const
  • field The field to try

Return: Whether the field was present.

Try to get an unsigned 64 bit field.

function tryF32

bool tryF32(
    const char * name,
    mama_fid_t fid,
    mama_f32_t & result
) const

Parameters:

  • result The result (not modified if field not present) const
  • name The field name
  • fid The field identifier

Return: Whether the field was present.

Try to get a f32 field.

function tryF32

bool tryF32(
    const MamaFieldDescriptor * field,
    mama_f32_t & result
) const

Parameters:

  • result The result (not modified if field not present) const
  • field The field to try

Return: Whether the field was present.

Try to get a f32 field.

function tryF64

bool tryF64(
    const char * name,
    mama_fid_t fid,
    mama_f64_t & result
) const

Parameters:

  • result The result (not modified if field not present) const
  • name The field name
  • fid The field identifier

Return: Whether the field was present.

Try to get a f64 field.

function tryF64

bool tryF64(
    const MamaFieldDescriptor * field,
    mama_f64_t & result
) const

Parameters:

  • result The result (not modified if field not present) const
  • field The field to try

Return: Whether the field was present.

Try to get a f64 field.

function tryString

bool tryString(
    const char * name,
    mama_fid_t fid,
    const char *& result
) const

Parameters:

  • result The result (not modified if field not present) const
  • name The field name
  • fid The field identifier

Return: Whether the field was present.

Try to get a string field.

function tryString

bool tryString(
    const MamaFieldDescriptor * field,
    const char *& result
) const

Parameters:

  • result The result (not modified if field not present) const
  • field The field to try

Return: Whether the field was present.

Try to get a string field.

function tryDateTime

bool tryDateTime(
    const char * name,
    mama_fid_t fid,
    MamaDateTime & result
) const

Parameters:

  • name The field name
  • fid The field identifier
  • result The result (not modified if field not present) const

Return: Whether the field was present.

Try to get a date/time field.

function tryDateTime

bool tryDateTime(
    const MamaFieldDescriptor * field,
    MamaDateTime & result
) const

Parameters:

  • field The field to try
  • result The result (not modified if field not present) const

Return: Whether the field was present.

Try to get a date/time field.

function tryPrice

bool tryPrice(
    const char * name,
    mama_fid_t fid,
    MamaPrice & result
) const

Parameters:

  • name The field name
  • fid The field identifier
  • result The result (not modified if field not present) const

Return: Whether the field was present.

Try to get a price field.

function tryPrice

bool tryPrice(
    const MamaFieldDescriptor * field,
    MamaPrice & result
) const

Parameters:

  • field The field to try
  • result The result (not modified if field not present) const

Return: Whether the field was present.

Try to get a price field.

function tryMsg

bool tryMsg(
    const char * name,
    mama_fid_t fid,
    const MamaMsg *& result
) const

Parameters:

  • name The field name
  • fid The field identifier
  • result The result

Return: Whether the field was present.

Try to get a submessage field.

function tryMsg

bool tryMsg(
    const MamaFieldDescriptor * field,
    const MamaMsg *& result
) const

Parameters:

  • field The field to try
  • result The result

Return: Whether the field was present.

Try to get a submessage field.

function tryOpaque

bool tryOpaque(
    const char * name,
    mama_fid_t fid,
    const void *& result,
    size_t & size
) const

Parameters:

  • result The result (not modified if field not present) const
  • name The field name
  • fid The field identifier
  • size (out) The size of the opaque in bytes.

Return: Whether the field was present.

Try to get a string field.

function tryOpaque

bool tryOpaque(
    const MamaFieldDescriptor * field,
    const void *& result,
    size_t & size
) const

Parameters:

  • result The result (not modified if field not present) const
  • field The field to try
  • size (out) The size of the opaque in bytes.

Return: Whether the field was present.

Try to get a string field.

function tryVectorChar

bool tryVectorChar(
    const char * name,
    mama_fid_t fid,
    const char *& result,
    size_t & resultLen
) const

Parameters:

  • name The field name.
  • fid The field identifier.
  • result (out) The vector.
  • resultLen (out) The size of the vector.

Return: Whether the field was present.

Try to get a vector of characters. (Note: prefer using string fields or opaque fields over a vector of characters.)

function tryVectorChar

bool tryVectorChar(
    const MamaFieldDescriptor * fieldDesc,
    const char *& result,
    size_t & resultLen
) const

Parameters:

  • fieldDesc The field descriptor
  • result (out) The vector.
  • resultLen (out) The size of the vector.

Return: Whether the field was present.

Try to get a vector of characters. (Note: prefer using string fields or opaque fields over a vector of characters.)

function tryVectorI8

bool tryVectorI8(
    const char * name,
    mama_fid_t fid,
    const mama_i8_t *& result,
    size_t & resultLen
) const

Parameters:

  • name The field name.
  • fid The field identifier.
  • result (out) The vector.
  • resultLen (out) The size of the vector.

Return: Whether the field was present.

Try to get a vector of signed 8-bit integers.

function tryVectorI8

bool tryVectorI8(
    const MamaFieldDescriptor * fieldDesc,
    const mama_i8_t *& result,
    size_t & resultLen
) const

Parameters:

  • fieldDesc The field descriptor
  • result (out) The vector.
  • resultLen (out) The size of the vector.

Return: Whether the field was present.

Try to get a vector of signed 8-bit integers. or opaque fields over a vector of characters.)

function tryVectorU8

bool tryVectorU8(
    const char * name,
    mama_fid_t fid,
    const mama_u8_t *& result,
    size_t & resultLen
) const

Parameters:

  • name The field name.
  • fid The field identifier.
  • result (out) The vector.
  • resultLen (out) The size of the vector.

Return: Whether the field was present.

Try to get a vector of unsigned 8-bit integers.

function tryVectorU8

bool tryVectorU8(
    const MamaFieldDescriptor * fieldDesc,
    const mama_u8_t *& result,
    size_t & resultLen
) const

Parameters:

  • fieldDesc The field descriptor
  • result (out) The vector.
  • resultLen (out) The size of the vector.

Return: Whether the field was present.

Try to get a vector of unsigned 8-bit integers. or opaque fields over a vector of characters.)

function tryVectorI16

bool tryVectorI16(
    const char * name,
    mama_fid_t fid,
    const mama_i16_t *& result,
    size_t & resultLen
) const

Parameters:

  • name The field name.
  • fid The field identifier.
  • result (out) The vector.
  • resultLen (out) The size of the vector.

Return: Whether the field was present.

Try to get a vector of signed 16-bit integers.

function tryVectorI16

bool tryVectorI16(
    const MamaFieldDescriptor * fieldDesc,
    const mama_i16_t *& result,
    size_t & resultLen
) const

Parameters:

  • fieldDesc The field descriptor
  • result (out) The vector.
  • resultLen (out) The size of the vector.

Return: Whether the field was present.

Try to get a vector of signed 16-bit integers. or opaque fields over a vector of characters.)

function tryVectorU16

bool tryVectorU16(
    const char * name,
    mama_fid_t fid,
    const mama_u16_t *& result,
    size_t & resultLen
) const

Parameters:

  • name The field name.
  • fid The field identifier.
  • result (out) The vector.
  • resultLen (out) The size of the vector.

Return: Whether the field was present.

Try to get a vector of unsigned 16-bit integers.

function tryVectorU16

bool tryVectorU16(
    const MamaFieldDescriptor * fieldDesc,
    const mama_u16_t *& result,
    size_t & resultLen
) const

Parameters:

  • fieldDesc The field descriptor
  • result (out) The vector.
  • resultLen (out) The size of the vector.

Return: Whether the field was present.

Try to get a vector of unsigned 16-bit integers. or opaque fields over a vector of characters.)

function tryVectorI32

bool tryVectorI32(
    const char * name,
    mama_fid_t fid,
    const mama_i32_t *& result,
    size_t & resultLen
) const

Parameters:

  • name The field name.
  • fid The field identifier.
  • result (out) The vector.
  • resultLen (out) The size of the vector.

Return: Whether the field was present.

Try to get a vector of signed 32-bit integers.

function tryVectorI32

bool tryVectorI32(
    const MamaFieldDescriptor * fieldDesc,
    const mama_i32_t *& result,
    size_t & resultLen
) const

Parameters:

  • fieldDesc The field descriptor
  • result (out) The vector.
  • resultLen (out) The size of the vector.

Return: Whether the field was present.

Try to get a vector of signed 32-bit integers. or opaque fields over a vector of characters.)

function tryVectorU32

bool tryVectorU32(
    const char * name,
    mama_fid_t fid,
    const mama_u32_t *& result,
    size_t & resultLen
) const

Parameters:

  • name The field name.
  • fid The field identifier.
  • result (out) The vector.
  • resultLen (out) The size of the vector.

Return: Whether the field was present.

Try to get a vector of unsigned 32-bit integers.

function tryVectorU32

bool tryVectorU32(
    const MamaFieldDescriptor * fieldDesc,
    const mama_u32_t *& result,
    size_t & resultLen
) const

Parameters:

  • fieldDesc The field descriptor
  • result (out) The vector.
  • resultLen (out) The size of the vector.

Return: Whether the field was present.

Try to get a vector of unsigned 32-bit integers. or opaque fields over a vector of characters.)

function tryVectorI64

bool tryVectorI64(
    const char * name,
    mama_fid_t fid,
    const mama_i64_t *& result,
    size_t & resultLen
) const

Parameters:

  • name The field name.
  • fid The field identifier.
  • result (out) The vector.
  • resultLen (out) The size of the vector.

Return: Whether the field was present.

Try to get a vector of signed 64-bit integers.

function tryVectorI64

bool tryVectorI64(
    const MamaFieldDescriptor * fieldDesc,
    const mama_i64_t *& result,
    size_t & resultLen
) const

Parameters:

  • fieldDesc The field descriptor
  • result (out) The vector.
  • resultLen (out) The size of the vector.

Return: Whether the field was present.

Try to get a vector of signed 64-bit integers. or opaque fields over a vector of characters.)

function tryVectorU64

bool tryVectorU64(
    const char * name,
    mama_fid_t fid,
    const mama_u64_t *& result,
    size_t & resultLen
) const

Parameters:

  • name The field name.
  • fid The field identifier.
  • result (out) The vector.
  • resultLen (out) The size of the vector.

Return: Whether the field was present.

Try to get a vector of unsigned 64-bit integers.

function tryVectorU64

bool tryVectorU64(
    const MamaFieldDescriptor * fieldDesc,
    const mama_u64_t *& result,
    size_t & resultLen
) const

Parameters:

  • fieldDesc The field descriptor
  • result (out) The vector.
  • resultLen (out) The size of the vector.

Return: Whether the field was present.

Try to get a vector of unsigned 64-bit integers. or opaque fields over a vector of characters.)

function tryVectorF32

bool tryVectorF32(
    const char * name,
    mama_fid_t fid,
    const mama_f32_t *& result,
    size_t & resultLen
) const

Parameters:

  • name The field name.
  • fid The field identifier.
  • result (out) The vector.
  • resultLen (out) The size of the vector.

Return: Whether the field was present.

Try to get a vector of 32-bit floating point numbers.

function tryVectorF32

bool tryVectorF32(
    const MamaFieldDescriptor * fieldDesc,
    const mama_f32_t *& result,
    size_t & resultLen
) const

Parameters:

  • fieldDesc The field descriptor
  • result (out) The vector.
  • resultLen (out) The size of the vector.

Return: Whether the field was present.

Try to get a vector of 32-bit floating point numbers. or opaque fields over a vector of characters.)

function tryVectorF64

bool tryVectorF64(
    const char * name,
    mama_fid_t fid,
    const mama_f64_t *& result,
    size_t & resultLen
) const

Parameters:

  • name The field name.
  • fid The field identifier.
  • result (out) The vector.
  • resultLen (out) The size of the vector.

Return: Whether the field was present.

Try to get a vector of 64-bit floating point numbers.

function tryVectorF64

bool tryVectorF64(
    const MamaFieldDescriptor * fieldDesc,
    const mama_f64_t *& result,
    size_t & resultLen
) const

Parameters:

  • fieldDesc The field descriptor
  • result (out) The vector.
  • resultLen (out) The size of the vector.

Return: Whether the field was present.

Try to get a vector of 64-bit floating point numbers. or opaque fields over a vector of characters.)

function tryVectorString

bool tryVectorString(
    const char * name,
    mama_fid_t fid,
    const char **& result,
    size_t & resultLen
) const

Parameters:

  • name The field name.
  • fid The field identifier.
  • result (out) The vector.
  • resultLen (out) The size of the vector.

Return: Whether the field was present.

Try to get a vector of strings.

function tryVectorString

bool tryVectorString(
    const MamaFieldDescriptor * fieldDesc,
    const char **& result,
    size_t & resultLen
) const

Parameters:

  • fieldDesc The field descriptor
  • result (out) The vector.
  • resultLen (out) The size of the vector.

Return: Whether the field was present.

Try to get a vector of strings

function tryVectorMsg

bool tryVectorMsg(
    const char * name,
    mama_fid_t fid,
    const MamaMsg **& result,
    size_t & resultLen
) const

Parameters:

  • name The field name.
  • fid The field identifier.
  • result (out) The vector.
  • resultLen (out) The size of the vector.

Return: Whether the field was present.

Try to get a vector of submessages field.

function tryVectorMsg

bool tryVectorMsg(
    const MamaFieldDescriptor * fieldDesc,
    const MamaMsg **& result,
    size_t & resultLen
) const

Parameters:

  • fieldDesc The field descriptor
  • result (out) The vector.
  • resultLen (out) The size of the vector.

Return: Whether the field was present.

Try to get a vector of submessages.

function addBoolean

void addBoolean(
    const char * name,
    mama_fid_t fid,
    bool value
)

Parameters:

  • name The name.
  • value The value.
  • fid The field identifier.

Add a new boolean field.

function addBoolean

void addBoolean(
    const MamaFieldDescriptor * fieldDesc,
    bool value
)

Parameters:

  • fieldDesc The field descriptor
  • value The value.

Add a new boolean field.

function addChar

void addChar(
    const char * name,
    mama_fid_t fid,
    char value
)

Parameters:

  • name The name.
  • value The value.
  • fid The field identifier.

Add a new char field.

function addChar

void addChar(
    const MamaFieldDescriptor * fieldDesc,
    char value
)

Parameters:

  • fieldDesc The field descriptor
  • value The value.

Add a new char field.

function addI8

void addI8(
    const char * name,
    mama_fid_t fid,
    mama_i8_t value
)

Parameters:

  • name The name.
  • value The value.
  • fid The field identifier.

Add a new I8 field.

function addI8

void addI8(
    const MamaFieldDescriptor * fieldDesc,
    mama_i8_t value
)

Parameters:

  • fieldDesc The field descriptor
  • value The value.

Add a new I8 field.

function addI16

void addI16(
    const char * name,
    mama_fid_t fid,
    mama_i16_t value
)

Parameters:

  • name The name.
  • value The value.
  • fid The field identifier.

Add a new I16 field.

function addI16

void addI16(
    const MamaFieldDescriptor * fieldDesc,
    mama_i16_t value
)

Parameters:

  • fieldDesc The field descriptor
  • value The value.

Add a new I16 field.

function addI32

void addI32(
    const char * name,
    mama_fid_t fid,
    mama_i32_t value
)

Parameters:

  • name The name.
  • value The value.
  • fid The field identifier.

Add a new I32 field.

function addI32

void addI32(
    const MamaFieldDescriptor * fieldDesc,
    mama_i32_t value
)

Parameters:

  • fieldDesc The field descriptor
  • value The value.

Add a new I32 field.

function addI64

void addI64(
    const char * name,
    mama_fid_t fid,
    mama_i64_t value
)

Parameters:

  • name The name.
  • value The value.
  • fid The field identifier.

Add a new I64 field.

function addI64

void addI64(
    const MamaFieldDescriptor * fieldDesc,
    mama_i64_t value
)

Parameters:

  • fieldDesc The field descriptor
  • value The value.

Add a new I64 field.

function addU8

void addU8(
    const char * name,
    mama_fid_t fid,
    mama_u8_t value
)

Parameters:

  • name The name.
  • value The value.
  • fid The field identifier.

Add a new byte (U8) const field.

function addU8

void addU8(
    const MamaFieldDescriptor * fieldDesc,
    mama_u8_t value
)

Parameters:

  • fieldDesc The field descriptor
  • value The value.

Add a new U8 field.

function addU16

void addU16(
    const char * name,
    mama_fid_t fid,
    mama_u16_t value
)

Parameters:

  • name The name.
  • value The value.
  • fid The field identifier.

Add a new short (U16) const field.

function addU16

void addU16(
    const MamaFieldDescriptor * fieldDesc,
    mama_u16_t value
)

Parameters:

  • fieldDesc The field descriptor
  • value The value.

Add a new U16 field.

function addU32

void addU32(
    const char * name,
    mama_fid_t fid,
    mama_u32_t value
)

Parameters:

  • name The name.
  • value The value.
  • fid The field identifier.

Add a new int (U32) const field.

function addU32

void addU32(
    const MamaFieldDescriptor * fieldDesc,
    mama_u32_t value
)

Parameters:

  • fieldDesc The field descriptor
  • value The value.

Add a new U32 field.

function addU64

void addU64(
    const char * name,
    mama_fid_t fid,
    mama_u64_t value
)

Parameters:

  • name The name.
  • value The value.
  • fid The field identifier.

Add a new int (U64) const field.

function addU64

void addU64(
    const MamaFieldDescriptor * fieldDesc,
    mama_u64_t value
)

Parameters:

  • fieldDesc The field descriptor
  • value The value.

Add a new U64 field.

function addF32

void addF32(
    const char * name,
    mama_fid_t fid,
    mama_f32_t value
)

Parameters:

  • name The name.
  • value The value.
  • fid The field identifier.

Add a new F32 field.

function addF32

void addF32(
    const MamaFieldDescriptor * fieldDesc,
    mama_f32_t value
)

Parameters:

  • fieldDesc The field descriptor
  • value The value.

Add a new F32 field.

function addF64

void addF64(
    const char * name,
    mama_fid_t fid,
    mama_f64_t value
)

Parameters:

  • name The name.
  • value The value.
  • fid The field identifier.

Add a new F64 field.

function addF64

void addF64(
    const MamaFieldDescriptor * fieldDesc,
    mama_f64_t value
)

Parameters:

  • fieldDesc The field descriptor
  • value The value.

Add a new F64 field.

function addString

void addString(
    const char * name,
    mama_fid_t fid,
    const char * value
)

Parameters:

  • name The name.
  • value The value.
  • fid The field identifier.

Add a const char* field.

function addString

void addString(
    const MamaFieldDescriptor * fieldDesc,
    const char * value
)

Parameters:

  • fieldDesc The field descriptor
  • value The value.

Add a new const char* field.

function addDateTime

void addDateTime(
    const char * name,
    mama_fid_t fid,
    const MamaDateTime & value
)

Parameters:

  • name The field name.
  • fid The field identifier.
  • value The value.

Add a date/time field.

function addDateTime

void addDateTime(
    const MamaFieldDescriptor * fieldDesc,
    const MamaDateTime & value
)

Parameters:

  • fieldDesc The field descriptor
  • value The value.

Add a new date/time field.

function addPrice

void addPrice(
    const char * name,
    mama_fid_t fid,
    const MamaPrice & value
)

Parameters:

  • name The field name.
  • fid The field identifier.
  • value The value.

Add a price field.

function addPrice

void addPrice(
    const MamaFieldDescriptor * fieldDesc,
    const MamaPrice & value
)

Parameters:

  • fieldDesc The field descriptor
  • value The value.

Add a new price field.

function addOpaque

void addOpaque(
    const char * name,
    mama_fid_t fid,
    const void * value,
    size_t size
)

Parameters:

  • name The name.
  • value The value.
  • fid The field identifier.
  • size the size of the opaque field, in bytes

Add an opaque field

function addOpaque

void addOpaque(
    const MamaFieldDescriptor * fieldDesc,
    const void * value,
    size_t size
)

Parameters:

  • fieldDesc The field descriptor
  • value The value.
  • size the size of the opaque field, in bytes

Add an opaque field

function addMsg

void addMsg(
    const char * name,
    mama_fid_t fid,
    MamaMsg * value
)

Parameters:

  • name The field name.
  • fid The field identifier.
  • value the value to add

Add a MamaMsg object

function addMsg

void addMsg(
    const MamaFieldDescriptor * fieldDesc,
    MamaMsg * value
)

Parameters:

  • fieldDesc The field descriptor
  • value the value to add

Add a MamaMsg object

function addVectorChar

void addVectorChar(
    const char * name,
    mama_fid_t fid,
    const char vectorValues[],
    size_t vectorLen
)

Parameters:

  • name The field name.
  • fid The field identifier.
  • vectorValues The vector values.
  • vectorLen The size of the vector.

Add a vector of characters. (Note: prefer using string fields or opaque fields over a vector of characters.)

function addVectorChar

void addVectorChar(
    const MamaFieldDescriptor * fieldDesc,
    const char vectorValues[],
    size_t vectorLen
)

Parameters:

  • fieldDesc The field descriptor
  • vectorValues The vector values.
  • vectorLen The size of the vector.

Add a vector of characters. (Note: prefer using string fields or opaque fields over a vector of characters.)

function addVectorI8

void addVectorI8(
    const char * name,
    mama_fid_t fid,
    const mama_i8_t vectorValues[],
    size_t vectorLen
)

Parameters:

  • name The field name.
  • fid The field identifier.
  • vectorValues The vector values.
  • vectorLen The size of the vector.

Add a vector of signed 8-bit integers.

function addVectorI8

void addVectorI8(
    const MamaFieldDescriptor * fieldDesc,
    const mama_i8_t vectorValues[],
    size_t vectorLen
)

Parameters:

  • fieldDesc The field descriptor
  • vectorValues The vector values.
  • vectorLen The size of the vector.

Add a vector of signed 8-bit integers.

function addVectorU8

void addVectorU8(
    const char * name,
    mama_fid_t fid,
    const mama_u8_t vectorValues[],
    size_t vectorLen
)

Parameters:

  • name The field name.
  • fid The field identifier.
  • vectorValues The vector values.
  • vectorLen The size of the vector.

Add a vector of unsigned 8-bit integers.

function addVectorU8

void addVectorU8(
    const MamaFieldDescriptor * fieldDesc,
    const mama_u8_t vectorValues[],
    size_t vectorLen
)

Parameters:

  • fieldDesc The field descriptor
  • vectorValues The vector values.
  • vectorLen The size of the vector.

Add a vector of unsigned 8-bit integers.

function addVectorI16

void addVectorI16(
    const char * name,
    mama_fid_t fid,
    const mama_i16_t vectorValues[],
    size_t vectorLen
)

Parameters:

  • name The field name.
  • fid The field identifier.
  • vectorValues The vector values.
  • vectorLen The size of the vector.

Add a vector of signed 16-bit integers.

function addVectorI16

void addVectorI16(
    const MamaFieldDescriptor * fieldDesc,
    const mama_i16_t vectorValues[],
    size_t vectorLen
)

Parameters:

  • fieldDesc The field descriptor
  • vectorValues The vector values.
  • vectorLen The size of the vector.

Add a vector of signed 16-bit integers.

function addVectorU16

void addVectorU16(
    const char * name,
    mama_fid_t fid,
    const mama_u16_t vectorValues[],
    size_t vectorLen
)

Parameters:

  • name The field name.
  • fid The field identifier.
  • vectorValues The vector values.
  • vectorLen The size of the vector.

Add a vector of unsigned 16-bit integers.

function addVectorU16

void addVectorU16(
    const MamaFieldDescriptor * fieldDesc,
    const mama_u16_t vectorValues[],
    size_t vectorLen
)

Parameters:

  • fieldDesc The field descriptor
  • vectorValues The vector values.
  • vectorLen The size of the vector.

Add a vector of unsigned 16-bit integers.

function addVectorI32

void addVectorI32(
    const char * name,
    mama_fid_t fid,
    const mama_i32_t vectorValues[],
    size_t vectorLen
)

Parameters:

  • name The field name.
  • fid The field identifier.
  • vectorValues The vector values.
  • vectorLen The size of the vector.

Add a vector of signed 32-bit integers.

function addVectorI32

void addVectorI32(
    const MamaFieldDescriptor * fieldDesc,
    const mama_i32_t vectorValues[],
    size_t vectorLen
)

Parameters:

  • fieldDesc The field descriptor
  • vectorValues The vector values.
  • vectorLen The size of the vector.

Add a vector of signed 32-bit integers.

function addVectorU32

void addVectorU32(
    const char * name,
    mama_fid_t fid,
    const mama_u32_t vectorValues[],
    size_t vectorLen
)

Parameters:

  • name The field name.
  • fid The field identifier.
  • vectorValues The vector values.
  • vectorLen The size of the vector.

Add a vector of unsigned 32-bit integers.

function addVectorU32

void addVectorU32(
    const MamaFieldDescriptor * fieldDesc,
    const mama_u32_t vectorValues[],
    size_t vectorLen
)

Parameters:

  • fieldDesc The field descriptor
  • vectorValues The vector values.
  • vectorLen The size of the vector.

Add a vector of unsigned 32-bit integers.

function addVectorI64

void addVectorI64(
    const char * name,
    mama_fid_t fid,
    const mama_i64_t vectorValues[],
    size_t vectorLen
)

Parameters:

  • name The field name.
  • fid The field identifier.
  • vectorValues The vector values.
  • vectorLen The size of the vector.

Add a vector of signed 64-bit integers.

function addVectorI64

void addVectorI64(
    const MamaFieldDescriptor * fieldDesc,
    const mama_i64_t vectorValues[],
    size_t vectorLen
)

Parameters:

  • fieldDesc The field descriptor
  • vectorValues The vector values.
  • vectorLen The size of the vector.

Add a vector of signed 64-bit integers.

function addVectorU64

void addVectorU64(
    const char * name,
    mama_fid_t fid,
    const mama_u64_t vectorValues[],
    size_t vectorLen
)

Parameters:

  • name The field name.
  • fid The field identifier.
  • vectorValues The vector values.
  • vectorLen The size of the vector.

Add a vector of unsigned 64-bit integers.

function addVectorU64

void addVectorU64(
    const MamaFieldDescriptor * fieldDesc,
    const mama_u64_t vectorValues[],
    size_t vectorLen
)

Parameters:

  • fieldDesc The field descriptor
  • vectorValues The vector values.
  • vectorLen The size of the vector.

Add a vector of unsigned 64-bit integers.

function addVectorF32

void addVectorF32(
    const char * name,
    mama_fid_t fid,
    const mama_f32_t vectorValues[],
    size_t vectorLen
)

Parameters:

  • name The field name.
  • fid The field identifier.
  • vectorValues The vector values.
  • vectorLen The size of the vector.

Add a vector of 32-bit floating point numbers.

function addVectorF32

void addVectorF32(
    const MamaFieldDescriptor * fieldDesc,
    const mama_f32_t vectorValues[],
    size_t vectorLen
)

Parameters:

  • fieldDesc The field descriptor
  • vectorValues The vector values.
  • vectorLen The size of the vector.

Add a vector of unsigned 32-bit integers.

function addVectorF64

void addVectorF64(
    const char * name,
    mama_fid_t fid,
    const mama_f64_t vectorValues[],
    size_t vectorLen
)

Parameters:

  • name The field name.
  • fid The field identifier.
  • vectorValues The vector values.
  • vectorLen The size of the vector.

Add a vector of 64-bit floating point numbers.

function addVectorF64

void addVectorF64(
    const MamaFieldDescriptor * fieldDesc,
    const mama_f64_t vectorValues[],
    size_t vectorLen
)

Parameters:

  • fieldDesc The field descriptor
  • vectorValues The vector values.
  • vectorLen The size of the vector.

Add a vector of unsigned 64-bit integers.

function addVectorString

void addVectorString(
    const char * name,
    mama_fid_t fid,
    const char * vectorValues[],
    size_t vectorLen
)

Parameters:

  • name The field name.
  • fid The field identifier.
  • vectorValues The vector values.
  • vectorLen The size of the vector.

Add a vector of strings.

function addVectorString

void addVectorString(
    const MamaFieldDescriptor * fieldDesc,
    const char * vectorValues[],
    size_t vectorLen
)

Parameters:

  • fieldDesc The field descriptor
  • vectorValues The vector values.
  • vectorLen The size of the vector.

Add a vector of strings.

function addVectorMsg

void addVectorMsg(
    const char * name,
    mama_fid_t fid,
    MamaMsg * vectorValues[],
    size_t vectorLen
)

Parameters:

  • name The field name.
  • fid The field identifier.
  • vectorValues The vector values.
  • vectorLen The size of the vector.

Add a vector of MamaMsg objects.

function addVectorMsg

void addVectorMsg(
    const MamaFieldDescriptor * fieldDesc,
    MamaMsg * vectorValues[],
    size_t vectorLen
)

Parameters:

  • fieldDesc The field descriptor
  • vectorValues The vector values.
  • vectorLen The size of the vector.

Add a vector of MamaMsg objects.

function updateBoolean

void updateBoolean(
    const char * name,
    mama_fid_t fid,
    bool value
)

Parameters:

  • name The name.
  • value The new value.
  • fid The field identifier.

Update the value of an existing boolean field. If the field does not exist it is added.

function updateBoolean

void updateBoolean(
    const MamaFieldDescriptor * fieldDesc,
    bool value
)

Parameters:

  • fieldDesc The field descriptor
  • value The new value.

Update the value of an existing boolean field. If the field does not exist it is added.

function updateChar

void updateChar(
    const char * name,
    mama_fid_t fid,
    const char value
)

Parameters:

  • name The name.
  • value The new value.
  • fid The field identifier.

Update the value of an existing char field. If the field does not exist it is added.

function updateChar

void updateChar(
    const MamaFieldDescriptor * fieldDesc,
    const char value
)

Parameters:

  • fieldDesc The field descriptor
  • value The new value.

Update the value of an existing char field. If the field does not exist it is added.

function updateI8

void updateI8(
    const char * name,
    mama_fid_t fid,
    const mama_i8_t value
)

Parameters:

  • name The name.
  • value The new value.
  • fid The field identifier.

Update the value of an existing byte field. If the field does not exist it is added.

function updateI8

void updateI8(
    const MamaFieldDescriptor * fieldDesc,
    const mama_i8_t value
)

Parameters:

  • fieldDesc The field descriptor
  • value The new value.

Update the value of an existing byte field. If the field does not exist it is added.

function updateU8

void updateU8(
    const char * name,
    mama_fid_t fid,
    const mama_u8_t value
)

Parameters:

  • name The name.
  • value The new value.
  • fid The field identifier.

Update the value of an existing U8 field. If the field does not exist it is added.

function updateU8

void updateU8(
    const MamaFieldDescriptor * fieldDesc,
    const mama_u8_t value
)

Parameters:

  • fieldDesc The field descriptor
  • value The new value.

Update the value of an existing U8 field. If the field does not exist it is added.

function updateI16

void updateI16(
    const char * name,
    mama_fid_t fid,
    const mama_i16_t value
)

Parameters:

  • name The name.
  • value The new value.
  • fid The field identifier.

Update the value of an existing short field. If the field does not exist it is added.

function updateI16

void updateI16(
    const MamaFieldDescriptor * fieldDesc,
    const mama_i16_t value
)

Parameters:

  • fieldDesc The field descriptor
  • value The new value.

Update the value of an existing short field. If the field does not exist it is added.

function updateU16

void updateU16(
    const char * name,
    mama_fid_t fid,
    const mama_u16_t value
)

Parameters:

  • name The name.
  • value The new value.
  • fid The field identifier.

Update the value of an existing U16 field. If the field does not exist it is added.

function updateU16

void updateU16(
    const MamaFieldDescriptor * fieldDesc,
    const mama_u16_t value
)

Parameters:

  • fieldDesc The field descriptor
  • value The new value.

Update the value of an existing U16 field. If the field does not exist it is added.

function updateI32

void updateI32(
    const char * name,
    mama_fid_t fid,
    const mama_i32_t value
)

Parameters:

  • name The name.
  • value The new value.
  • fid The field identifier.

Update the value of an existing integer field. If the field does not exist it is added.

function updateI32

void updateI32(
    const MamaFieldDescriptor * fieldDesc,
    const mama_i32_t value
)

Parameters:

  • fieldDesc The field descriptor
  • value The new value.

Update the value of an existing integer field. If the field does not exist it is added.

function updateU32

void updateU32(
    const char * name,
    mama_fid_t fid,
    const mama_u32_t value
)

Parameters:

  • name The name.
  • value The new value.
  • fid The field identifier.

Update the value of an existing U32 field. If the field does not exist it is added.

function updateU32

void updateU32(
    const MamaFieldDescriptor * fieldDesc,
    const mama_u32_t value
)

Parameters:

  • fieldDesc The field descriptor
  • value The new value.

Update the value of an existing U32 field. If the field does not exist it is added.

function updateI64

void updateI64(
    const char * name,
    mama_fid_t fid,
    const mama_i64_t value
)

Parameters:

  • name The name.
  • value The new value.
  • fid The field identifier.

Update the value of an existing long field. If the field does not exist it is added.

function updateI64

void updateI64(
    const MamaFieldDescriptor * fieldDesc,
    const mama_i64_t value
)

Parameters:

  • fieldDesc The field descriptor
  • value The new value.

Update the value of an existing long field. If the field does not exist it is added.

function updateU64

void updateU64(
    const char * name,
    mama_fid_t fid,
    const mama_u64_t value
)

Parameters:

  • name The name.
  • value The new value.
  • fid The field identifier.

Update the value of an existing U64 field. If the field does not exist it is added.

function updateU64

void updateU64(
    const MamaFieldDescriptor * fieldDesc,
    const mama_u64_t value
)

Parameters:

  • fieldDesc The field descriptor
  • value The new value.

Update the value of an existing U64 field. If the field does not exist it is added.

function updateF32

void updateF32(
    const char * name,
    mama_fid_t fid,
    const mama_f32_t value
)

Parameters:

  • name The name.
  • value The new value.
  • fid The field identifier.

Update the value of an existing F32 field. If the field does not exist it is added.

function updateF32

void updateF32(
    const MamaFieldDescriptor * fieldDesc,
    const mama_f32_t value
)

Parameters:

  • fieldDesc The field descriptor
  • value The new value.

Update the value of an existing F32 field. If the field does not exist it is added.

function updateF64

void updateF64(
    const char * name,
    mama_fid_t fid,
    const mama_f64_t value
)

Parameters:

  • name The name.
  • value The new value.
  • fid The field identifier.

Update the value of an existing F64 field. If the field does not exist it is added.

function updateF64

void updateF64(
    const MamaFieldDescriptor * fieldDesc,
    const mama_f64_t value
)

Parameters:

  • fieldDesc The field descriptor
  • value The new value.

Update the value of an existing F64 field. If the field does not exist it is added.

function updateString

void updateString(
    const char * name,
    mama_fid_t fid,
    const char * value
)

Parameters:

  • name The name.
  • value The new value.
  • fid The field identifier.

Update the value of an existing const char* field. If the field does not exist it is added.

function updateString

void updateString(
    const MamaFieldDescriptor * fieldDesc,
    const char * value
)

Parameters:

  • fieldDesc The field descriptor
  • value The new value.

Update the value of an existing string field. If the field does not exist it is added.

function updateOpaque

void updateOpaque(
    const char * name,
    mama_fid_t fid,
    const void * value,
    size_t size
)

Parameters:

  • name The name.
  • value The new value.
  • fid The field identifier.
  • size The size of the opaque in bytes

Update the value of an existing opaque field. If the field does not exist it is added.

function updateOpaque

void updateOpaque(
    const MamaFieldDescriptor * fieldDesc,
    const void * value,
    size_t size
)

Parameters:

  • fieldDesc The field descriptor
  • value The new value.
  • size The size of the opaque in bytes

Update the value of an existing opaque field. If the field does not exist it is added.

function updateDateTime

void updateDateTime(
    const char * name,
    mama_fid_t fid,
    const MamaDateTime & value
)

Parameters:

  • name The field name.
  • fid The field identifier.
  • value The value.

Update a date/time field. If the field does not exist it is added.

function updateDateTime

void updateDateTime(
    const MamaFieldDescriptor * fieldDesc,
    const MamaDateTime & value
)

Parameters:

  • fieldDesc The field descriptor
  • value The new value.

Update the value of an existing date/time field. If the field does not exist it is added.

function updatePrice

void updatePrice(
    const char * name,
    mama_fid_t fid,
    const MamaPrice & value
)

Parameters:

  • name The field name.
  • fid The field identifier.
  • value The value.

Update a price field. If the field does not exist it is added.

function updatePrice

void updatePrice(
    const MamaFieldDescriptor * fieldDesc,
    const MamaPrice & value
)

Parameters:

  • fieldDesc The field descriptor
  • value The new value.

Update the value of an existing price field. If the field does not exist it is added.

function getType

mamaMsgType getType(
    void 
) const

Get the message type.

function getMsgTypeName

const char * getMsgTypeName(
    void 
) const

Get a human readable type name.

function getStatus

mamaMsgStatus getStatus(
    void 
) const

Get the msg status.

function getMsgStatusString

const char * getMsgStatusString(
    void 
) const

Get human readable message status.

function iterateFields

void iterateFields(
    MamaMsgFieldIterator & iterator,
    const MamaDictionary * dictionary,
    void * closure
) const

Iterate over all the fields.

function toString

const char * toString() const

Return: A string representation of the message.

Return a const char * representation the message. The memory allocated by this method gets freed upon destroying the message or invoking toString() again.

function toJsonString

const char * toJsonString() const

Return: A string representation of the message.

Return a const char * json representation the message. The memory allocated by this method gets freed upon destroying the message or invoking toString() again.

function toJsonString

const char * toJsonString(
    const MamaDictionary * dictionary
) const

Return: A string representation of the message.

Return a const char * json representation the message. The memory allocated by this method gets freed upon destroying the message or invoking toString() again.

function toNormalizedString

const char * toNormalizedString() const

Return: A string representation of the message.

Return a const char * normalized representation the message. The memory allocated by this method gets freed upon destroying the message or invoking toString() again.

function getFieldAsString

void getFieldAsString(
    const char * name,
    mama_fid_t fid,
    char * result,
    size_t maxResultLen
) const

Parameters:

  • name The field name.
  • fid The field identifier.
  • result Buffer to put result.
  • maxResultLen Maximum size of buffer to put result.

Obtain a string representation the field with the given fid.

function getFieldAsString

void getFieldAsString(
    const MamaFieldDescriptor * fieldDesc,
    char * result,
    size_t maxResultLen
) const

Parameters:

  • fieldDesc The field descriptor
  • result Buffer to put result.
  • maxResultLen Maximum size of buffer to put result.

Obtain a string representation the field with the given fid.

function getField

MamaMsgField * getField(
    const char * name,
    mama_fid_t fid
) const

Parameters:

  • name The field name.
  • fid The field identifier.

Obtain a the mamaMsgField with the given fid.

function getField

MamaMsgField * getField(
    const MamaFieldDescriptor * fieldDesc
) const

Parameters:

  • fieldDesc The field descriptor

Obtain a the mamaMsgField with the given fid.

function tryField

bool tryField(
    const char * name,
    mama_fid_t fid
) const

Parameters:

  • name The field name.
  • fid The field identifier.

Test for the presence of the MamaMsgField with the given fid. This method does not return the field.

function tryField

bool tryField(
    const MamaFieldDescriptor * fieldDesc
) const

Parameters:

  • fieldDesc The field descriptor

Test for the presence of the MamaMsgField with the given field descriptor. This method does not return the field.

function tryField

bool tryField(
    const char * name,
    mama_fid_t fid,
    MamaMsgField * result
) const

Parameters:

  • name The field name.
  • fid The field identifier.
  • result The result (not modified if field not present)

Try to obtain the MamaMsgField with the given fid.

function tryField

bool tryField(
    const MamaFieldDescriptor * fieldDesc,
    MamaMsgField * result
) const

Parameters:

  • fieldDesc The field descriptor
  • result The result (not modified if field not present)

Try to obtain the MamaMsgField with the given field descriptor.

function tryFieldAsString

bool tryFieldAsString(
    const char * name,
    mama_fid_t fid,
    char * result,
    size_t maxResultLen
) const

Parameters:

  • name The field name.
  • fid The field identifier.
  • result Buffer to put result.
  • maxResultLen Maximum size of buffer to put result.

Return: Whether the field was present.

Try to obtain a string representation the field with the given fid.

function tryFieldAsString

bool tryFieldAsString(
    const MamaFieldDescriptor * fieldDesc,
    char * result,
    size_t maxResultLen
) const

Parameters:

  • fieldDesc The field descriptor
  • result Buffer to put result.
  • maxResultLen Maximum size of buffer to put result.

Return: Whether the field was present.

Try to obtain a string representation the field with the given fid.

function getByteBuffer

void getByteBuffer(
    const void *& buffer,
    size_t & bufferLength
) const

Parameters:

  • buffer The byte array containing the buffer
  • bufferLength The length, in bytes of the returned buffer

Get the underlying message as an array of bytes. The buffer still belongs to the underlying message so no attempt should be made to modify it.

function detach

MamaMsg * detach(
    void 
)

Normally the Mama API owns incoming mamaMsg objects and they go out of scope and are freed when the message callback returns. Calling this method from the message callback creates a new C++ wrapper for the underlying message and transfers responsibility for calling destroy() to the caller.

The caller must also delete the pointer returned by detach(). Note that calling “delete msg.detach()” invokes destroy() so calling destroy is not necessary if the application calls delete.

function isFromInbox

bool isFromInbox(
    void 
) const

Whether this message is the result of a request needing a response.

function getSeqNum

mama_seqnum_t getSeqNum(
    void 
) const

function getIsDefinitelyDuplicate

bool getIsDefinitelyDuplicate(
    void 
) const

Return true if this message is definitely a duplicate message. This condition will not occur with the current feed handlers.

function getIsPossiblyDuplicate

bool getIsPossiblyDuplicate(
    void 
) const

Return true if this message is possibly a duplicate message. This may occur in the event of a fault tolerant feed handler take over where the feed handler replays messages to prevent gaps.

function getIsPossiblyDelayed

bool getIsPossiblyDelayed(
    void 
) const

Return true if the message is possibly delayed. This condition may be true during a fault-tolerant takeover.

function getIsDefinitelyDelayed

bool getIsDefinitelyDelayed(
    void 
) const

Return true if the message is delayed. This condition may be true during a fault-tolerant takeover.

function getIsOutOfSequence

bool getIsOutOfSequence(
    void 
) const

Return true when the FH sends the message out of sequence.

function setNewBuffer

bool setNewBuffer(
    void * buffer,
    mama_size_t size
)

Parameters:

  • buffer the new byte buffer
  • size size of buffer

Return: status

Sets a new for an existing mamaMsg using the provided byte buffer. The application is responsible for destroying the message.

function getNativeHandle

void * getNativeHandle(
    void 
) const

Return the native middleware message handle. This is only intended for Wombat internal use.

function createFromMsg

void createFromMsg(
    mamaMsg msg,
    bool destroyMsg =false
) const

Create the message from an existing mamaMsg

function setMsg

void setMsg(
    mamaMsg msg
)

Set the message to a different underlying C message. Can be called multiple times on a single MamaMsg

function getUnderlyingMsg

const mamaMsg & getUnderlyingMsg(
    void 
) const

Return const reference to underlying mamaMsg

function getUnderlyingMsg

mamaMsg getUnderlyingMsg(
    void 
)

Return the underlying mamaMsg (non const)

function getPayloadType

MAMAIgnoreDeprecatedOpen mamaPayloadType getPayloadType(
    void 
) const

Return: payloadType The payload type.

Return the type of the payload message (wombat message or, if using a non-wombat message payload, RV or FAST message).

function getNativeMsg

MAMAIgnoreDeprecatedClose void * getNativeMsg(
    void 
)

Return: nativeMsg The resulting native handle.

Get the native message structure for the underlying message

function begin

MamaMsgField & begin(
    MamaMsgIterator & theIterator
) const

Parameters:

  • theiterator iterator to be used

Return: first MamaMsgField

Sets a iterator to be used with existing mamaMsg. The iterator is set to the first MamaMsgField of the mamaMsg

function getReplyHandle

mamaMsgReply getReplyHandle(
    void 
) const

Get a copy of the reply Handle

function destroyReplyHandle

static void destroyReplyHandle(
    mamaMsgReply replyHandle
)

Destroy a copied reply Handle


Updated on 2023-03-31 at 15:29:25 +0100