Go to the documentation of this file.
22 #ifndef MamaDictionaryH__
23 #define MamaDictionaryH__
26 #if defined (__cplusplus)
122 const char** result);
134 const char** result);
165 unsigned short index);
326 const char* fileName);
342 const char* fileName);
344 #if defined (__cplusplus)
MAMAExpDLL mama_status mamaDictionary_getFeedHost(mamaDictionary dictionary, const char **result)
Return the dictionary source feed host.
MAMAExpDLL mama_status mamaDictionary_setMaxFid(mamaDictionary dictionary, mama_size_t maxFid)
Tell the dictionary what the probable maximum fid in the data dictionary may be.
enum mamaFieldType_ mamaFieldType
The mamaFieldDescriptor class represents a field in a mamaMsg.
MAMAExpDLL mama_status mamaDictionary_getFieldDescriptorByNameAll(mamaDictionary dictionary, const char *fname, mamaFieldDescriptor *descList, size_t *size)
Return an array of mamaFieldDescriptor which includes every field in the dictionary with the specifie...
MAMAExpDLL mama_status mamaDictionary_getFeedName(mamaDictionary dictionary, const char **result)
Return the dictionary source feed name.
mama_status
Definition: status.h:37
MAMAExpDLL mama_status mamaDictionary_getFieldDescriptorByFid(mamaDictionary dictionary, mamaFieldDescriptor *result, mama_fid_t fid)
Return the mamaFieldDescriptor with the specified field FID.
struct mamaFieldDescriptorImpl_ * mamaFieldDescriptor
Definition: types.h:110
MAMAExpDLL mama_status mama_createDictionary(mamaDictionary *dictionary, mamaQueue queue, mamaDictionaryCallbackSet dictionaryCallbacks, mamaSource source, double timeout, int retries, void *closure)
Create a data dictionary from a subscription.
MAMAExpDLL mama_status mamaDictionary_hasDuplicates(mamaDictionary dictionary, int *value)
Return true if there are multiple fields with the same name.
MAMAExpDLL mama_status mamaDictionary_create(mamaDictionary *dictionary)
Create an empty mamaDictionary so that can be populated at a later stage via a call to buildDictionar...
void(MAMACALLTYPE * mamaDictionary_errorCallback)(mamaDictionary, const char *, void *)
Definition: dictionary.h:52
struct mamaDictionaryImpl_ * mamaDictionary
Definition: types.h:102
struct mamaSourceImpl_ * mamaSource
Definition: types.h:116
void(MAMACALLTYPE * mamaDictionary_completeCallback)(mamaDictionary, void *)
The mamaDictionary class maps field identifiers (FIDs) to human readable strings.
Definition: dictionary.h:48
uint16_t mama_fid_t
Definition: types.h:46
MAMAExpDLL mama_status mamaDictionary_getMaxFid(mamaDictionary dictionary, mama_fid_t *value)
Return the highest field identifier.
MAMAExpDLL mama_status mamaDictionary_populateFromFile(mamaDictionary dictionary, const char *fileName)
Populate a dictionary from the contents of a file.
MAMAExpDLL mama_status mamaDictionary_getDictionaryMessage(mamaDictionary dictionary, mamaMsg *msg)
Get the underlying message for the data dictionary.
MAMAExpDLL mama_status mamaDictionary_destroy(mamaDictionary dictionary)
Destroy this mamaDictionary object and free all its resources.
MAMAExpDLL mama_status mamaDictionary_getFieldDescriptorByName(mamaDictionary dictionary, mamaFieldDescriptor *result, const char *fname)
Return the descriptor of the field with the specified name.
void(MAMACALLTYPE * mamaDictionary_timeoutCallback)(mamaDictionary, void *)
Definition: dictionary.h:50
struct mamaDictionaryCallbackSet mamaDictionaryCallbackSet
A structure containing the callbacks for dictionary creation.
size_t mama_size_t
Definition: types.h:47
mamaDictionary_completeCallback onComplete
Definition: dictionary.h:60
struct mamaMsgImpl_ * mamaMsg
Opaque definitions for all major MAMA data types.
Definition: types.h:95
MAMAExpDLL mama_status mamaDictionary_buildDictionaryFromMessage(mamaDictionary dictionary, const mamaMsg msg)
Build a data dictionary from the specified message.
A structure containing the callbacks for dictionary creation.
Definition: dictionary.h:58
MAMAExpDLL mama_status mamaDictionary_getSize(mamaDictionary dictionary, size_t *value)
Return the number of fields in the dictionary.
MAMAExpDLL mama_status mamaDictionary_writeToFile(mamaDictionary dictionary, const char *fileName)
Write the data dictionary to a file.
MAMAExpDLL mama_status mamaDictionary_createFieldDescriptor(mamaDictionary dictionary, mama_fid_t fid, const char *name, mamaFieldType type, mamaFieldDescriptor *descriptor)
Create a new field descriptor and add it to the dictionary.
mamaDictionary_errorCallback onError
Definition: dictionary.h:62
MAMAExpDLL mama_status mamaDictionary_getFieldDescriptorByIndex(mamaDictionary dictionary, mamaFieldDescriptor *result, unsigned short index)
Return the field with the corresponding zero based index.
struct mamaQueueImpl_ * mamaQueue
Definition: types.h:107
mamaDictionary_timeoutCallback onTimeout
Definition: dictionary.h:61