Browse
 
Tools
Rss Categories

LVGrammar_GetMetaDataValue

Reference Number: AA-00841 Views: 6478 0 Rating/ Voters

Return the value of the meta data indicated by the index.

Function

  • int LVGrammar_GetMetaDataValue(HGRAMMAR Grammar, int index)

Parameters

Grammar

A handle to the grammar.

index

Index of the meta data. It should be in the range [ 0, (LVGrammar_GetNumberOfMetaData() -1) ].

Return Values

NULL

The index is not valid.

Non-NULL

A pointer to the value string.

Example

If the grammar has following lines:

meta 'description' is 'example grammar';

meta 'date' is '05/12/2005';


You can access meta data as follows:

int count = LVGrammar_GetNumberOfMetaData(grammar); // Returns 2

const char* key = LVGrammar_GetMetaDataKey(grammar, 0); // Returns "description"

const char* value = LVGrammar_GetMetaDataValue(grammar, 1); // Returns "05/12/2005"

See Also