| Elektra 0.11.0

Functions
elektra.h File Reference

Elektra High Level API. More...

`#include <elektra/error.h>`
`#include <elektra/types.h>`
`#include <kdb.h>`
`#include <kdbmacros.h>`
`#include <kdbtypes.h>`

## Functions
Elektra * | elektraOpen (const char *application, KeySet *defaults, KeySet *contract, ElektraError **error)
| Initializes a new Elektra instance.
void | elektraClose (Elektra *elektra)
| Releases all resources used by the given elektra instance.
void | elektraFatalErrorHandler (Elektra *elektra, ElektraErrorHandler fatalErrorHandler)
| Sets the fatal error handler that will be called, whenever a fatal error occurs.
Key * | elektraFindKey (Elektra *elektra, const char *name, KDBType type)
| Helper function for code generation.
Key * | elektraFindArrayElementKey (Elektra *elektra, const char *name, kdb_long_long_t index, KDBType type)
| Helper function for code generation.
void | elektraFatalError (Elektra *elektra, ElektraError *fatalError)
| Promote an ElektraError to fatal and call the fatal error handler.
const char * | elektraFindReference (Elektra *elektra, const char *name)
| Resolves the reference stored in a key.
const char * | elektraFindReferenceArrayElement (Elektra *elektra, const char *name, kdb_long_long_t index)
| Resolves the reference stored in a key.
Key * | elektraHelpKey (Elektra *elektra)
| This function is only intended for use with code-generation.
const char * | elektraGetRawString (Elektra *elektra, const char *name)
| Get the raw string value of a key.
const char * | elektraGetString (Elektra *elektra, const char *keyname)
| Gets a string value.
kdb_boolean_t | elektraGetBoolean (Elektra *elektra, const char *keyname)
| Gets a boolean value.
kdb_char_t | elektraGetChar (Elektra *elektra, const char *keyname)
| Gets a char value.
kdb_octet_t | elektraGetOctet (Elektra *elektra, const char *keyname)
| Gets an octet value.
kdb_short_t | elektraGetShort (Elektra *elektra, const char *keyname)
| Gets a short value.
kdb_unsigned_short_t | elektraGetUnsignedShort (Elektra *elektra, const char *keyname)
| Gets a unsigned short value.
kdb_long_t | elektraGetLong (Elektra *elektra, const char *keyname)
| Gets a long value.
kdb_unsigned_long_t | elektraGetUnsignedLong (Elektra *elektra, const char *keyname)
| Gets a unsigned long value.
kdb_long_long_t | elektraGetLongLong (Elektra *elektra, const char *keyname)
| Gets a long long value.
kdb_unsigned_long_long_t | elektraGetUnsignedLongLong (Elektra *elektra, const char *keyname)
| Gets a long long value.
kdb_float_t | elektraGetFloat (Elektra *elektra, const char *keyname)
| Gets a float value.
kdb_double_t | elektraGetDouble (Elektra *elektra, const char *keyname)
| Gets a double value.
void | elektraSetRawString (Elektra *elektra, const char *name, const char *value, KDBType type, ElektraError **error)
| Set the raw string value of a key.
void | elektraSetString (Elektra *elektra, const char *keyname, const char *value, ElektraError **error)
| Sets a string value.
void | elektraSetBoolean (Elektra *elektra, const char *keyname, kdb_boolean_t value, ElektraError **error)
| Sets a boolean value.
void | elektraSetChar (Elektra *elektra, const char *keyname, kdb_char_t value, ElektraError **error)
| Sets a char value.
void | elektraSetOctet (Elektra *elektra, const char *keyname, kdb_octet_t value, ElektraError **error)
| Sets an octet value.
void | elektraSetShort (Elektra *elektra, const char *keyname, kdb_short_t value, ElektraError **error)
| Sets a short value.
void | elektraSetUnsignedShort (Elektra *elektra, const char *keyname, kdb_unsigned_short_t value, ElektraError **error)
| Sets a unsigned short value.
void | elektraSetLong (Elektra *elektra, const char *keyname, kdb_long_t value, ElektraError **error)
| Sets a long value.
void | elektraSetUnsignedLong (Elektra *elektra, const char *keyname, kdb_unsigned_long_t value, ElektraError **error)
| Sets a unsigned long value.
void | elektraSetLongLong (Elektra *elektra, const char *keyname, kdb_long_long_t value, ElektraError **error)
| Sets a long long value.
void | elektraSetUnsignedLongLong (Elektra *elektra, const char *keyname, kdb_unsigned_long_long_t value, ElektraError **error)
| Sets a unsigned long long value.
void | elektraSetFloat (Elektra *elektra, const char *keyname, kdb_float_t value, ElektraError **error)
| Sets a float value.
void | elektraSetDouble (Elektra *elektra, const char *keyname, kdb_double_t value, ElektraError **error)
| Sets a double value.
kdb_long_long_t | elektraArraySize (Elektra *elektra, const char *name)
| Gets the size of an array.
const char * | elektraGetRawStringArrayElement (Elektra *elektra, const char *name, kdb_long_long_t index)
| Get the raw string value of an array element key.
const char * | elektraGetStringArrayElement (Elektra *elektra, const char *keyname, kdb_long_long_t index)
| Gets a string value array element.
kdb_boolean_t | elektraGetBooleanArrayElement (Elektra *elektra, const char *keyname, kdb_long_long_t index)
| Gets a boolean value array element.
kdb_char_t | elektraGetCharArrayElement (Elektra *elektra, const char *keyname, kdb_long_long_t index)
| Gets a char value array element.
kdb_octet_t | elektraGetOctetArrayElement (Elektra *elektra, const char *keyname, kdb_long_long_t index)
| Gets an octet value array element.
kdb_short_t | elektraGetShortArrayElement (Elektra *elektra, const char *keyname, kdb_long_long_t index)
| Gets a short value array element.
kdb_unsigned_short_t | elektraGetUnsignedShortArrayElement (Elektra *elektra, const char *keyname, kdb_long_long_t index)
| Gets a unsigned short value array element.
kdb_long_t | elektraGetLongArrayElement (Elektra *elektra, const char *keyname, kdb_long_long_t index)
| Gets a long value array element.
kdb_unsigned_long_t | elektraGetUnsignedLongArrayElement (Elektra *elektra, const char *keyname, kdb_long_long_t index)
| Gets a unsigned long value array element.
kdb_long_long_t | elektraGetLongLongArrayElement (Elektra *elektra, const char *keyname, kdb_long_long_t index)
| Gets a long long value array element.
kdb_unsigned_long_long_t | elektraGetUnsignedLongLongArrayElement (Elektra *elektra, const char *keyname, kdb_long_long_t index)
| Gets a unsigned long long value array element.
kdb_float_t | elektraGetFloatArrayElement (Elektra *elektra, const char *keyname, kdb_long_long_t index)
| Gets a float value array element.
kdb_double_t | elektraGetDoubleArrayElement (Elektra *elektra, const char *keyname, kdb_long_long_t index)
| Gets a double value array element.
void | elektraSetRawStringArrayElement (Elektra *elektra, const char *name, kdb_long_long_t index, const char *value, KDBType type, ElektraError **error)
| Set the raw string value of an array element key.
void | elektraSetStringArrayElement (Elektra *elektra, const char *keyname, kdb_long_long_t index, const char *value, ElektraError **error)
| Sets a string value array element.
void | elektraSetBooleanArrayElement (Elektra *elektra, const char *keyname, kdb_long_long_t index, kdb_boolean_t value, ElektraError **error)
| Sets a boolean value array element.
void | elektraSetCharArrayElement (Elektra *elektra, const char *keyname, kdb_long_long_t index, kdb_char_t value, ElektraError **error)
| Sets a char value array element.
void | elektraSetOctetArrayElement (Elektra *elektra, const char *keyname, kdb_long_long_t index, kdb_octet_t value, ElektraError **error)
| Sets an octet value array element.
void | elektraSetShortArrayElement (Elektra *elektra, const char *keyname, kdb_long_long_t index, kdb_short_t value, ElektraError **error)
| Sets a short value array element.
void | elektraSetUnsignedShortArrayElement (Elektra *elektra, const char *keyname, kdb_long_long_t index, kdb_unsigned_short_t value, ElektraError **error)
| Sets a unsigned short value array element.
void | elektraSetLongArrayElement (Elektra *elektra, const char *keyname, kdb_long_long_t index, kdb_long_t value, ElektraError **error)
| Sets a long value array element.
void | elektraSetUnsignedLongArrayElement (Elektra *elektra, const char *keyname, kdb_long_long_t index, kdb_unsigned_long_t value, ElektraError **error)
| Sets a unsigned long value array element.
void | elektraSetLongLongArrayElement (Elektra *elektra, const char *keyname, kdb_long_long_t index, kdb_long_long_t value, ElektraError **error)
| Sets a long long value array element.
void | elektraSetUnsignedLongLongArrayElement (Elektra *elektra, const char *keyname, kdb_long_long_t index, kdb_unsigned_long_long_t value, ElektraError **error)
| Sets a unsigned long long value array element.
void | elektraSetFloatArrayElement (Elektra *elektra, const char *keyname, kdb_long_long_t index, kdb_float_t value, ElektraError **error)
| Sets a float value array element.
void | elektraSetDoubleArrayElement (Elektra *elektra, const char *keyname, kdb_long_long_t index, kdb_double_t value, ElektraError **error)
| Sets a double value array element.
KDBType | elektraGetType (Elektra *elektra, const char *keyname)
| Reads the type metadata of a given key.
KDBType | elektraGetArrayElementType (Elektra *elektra, const char *keyname, kdb_long_long_t index)
| Reads the type metadata of a given array element.

## Detailed Description

Elektra High Level API.

Copyright
  BSD License (see doc/LICENSE.md or http://www.libelektra.org)