mco_metadict_size

Return the size of the meta-dictionary.

Prototype

    void mco_metadict_size(  /*IN*/ unsigned short n_entries,
                     /*OUT*/ unsigned int * size );

Arguments

n_entries
The number of registered databases (dictionaries).
size
The address of an integer variable to receive the size in bytes.

Description

The function returns the size of the meta-dictionary in bytes (including the header).

Return Codes

void
No value returned.

Example

    Application snippet:

    const char * dbname = "SimpleDb";
    int main(int argc, char* argv[])
    {
        unsigned int size;
        mco_metadict_header_t *header;

        mco_metadict_size(10, &size); /* figure out the buffer size to
                             register 10 database dictionaries */
        ...

        header = (mco_metadict_header_t *) malloc(size);
        mco_metadict_init(header, size); /* initialize the metadict */
        ...
    }

Files

Header file:
mcouda.h
Source file:
mcouda.c
Library:
libmcouda.a