Elektra  0.9.7
Typedefs
kdbnotificationinternal.h File Reference

Elektra-Notification structures and declarations for developing notification and transport plugins. More...

#include "kdb.h"
#include "kdbnotification.h"
#include "kdbplugin.h"
Include dependency graph for kdbnotificationinternal.h:
This graph shows which files directly or indirectly include this file:

Typedefs

typedef int(* ElektraNotificationPluginRegisterCallback) (Plugin *handle, Key *key, ElektraNotificationChangeCallback callback, void *context)
 Subscribe for updates via callback when a given key value is changed. More...
 
typedef int(* ElektraNotificationPluginRegisterCallbackSameOrBelow) (Plugin *handle, Key *key, ElektraNotificationChangeCallback callback, void *context)
 Subscribe for updates via callback when a given key or a key below is changed. More...
 
typedef void(* ElektraNotificationSetConversionErrorCallback) (Plugin *handle, ElektraNotificationConversionErrorCallback callback, void *context)
 Allow setting a callback that is called when a value conversion failed. More...
 
typedef struct _ElektraNotificationCallbackContext ElektraNotificationCallbackContext
 Context for notification callbacks.
 
typedef void(* ElektraNotificationCallback) (Key *key, ElektraNotificationCallbackContext *context)
 Notify notification library of changes to a key. More...
 
typedef void(* ElektraNotificationKdbUpdate) (KDB *kdb, Key *changedKey)
 Used by notification plugins to get values from the key database. More...
 

Detailed Description

Elektra-Notification structures and declarations for developing notification and transport plugins.

Only available in Elektra's source.

Only used by elektra-notification library, notification plugins (e.g. internalnotification) and transport plugins.

Typedef Documentation

◆ ElektraNotificationCallback

typedef void(* ElektraNotificationCallback) (Key *key, ElektraNotificationCallbackContext *context)

Notify notification library of changes to a key.

This callback is provided by the internalnotification plugin and for use by notification transport plugins.

Parameters
keychanged key
contextadditional data

◆ ElektraNotificationKdbUpdate

typedef void(* ElektraNotificationKdbUpdate) (KDB *kdb, Key *changedKey)

Used by notification plugins to get values from the key database.

Parameters
kdbkdb handle
changedKeywhich key was updated

◆ ElektraNotificationPluginRegisterCallback

typedef int(* ElektraNotificationPluginRegisterCallback) (Plugin *handle, Key *key, ElektraNotificationChangeCallback callback, void *context)

Subscribe for updates via callback when a given key value is changed.

Exported as "registerCallback" by notification plugins.

Parameters
handleplugin handle
keykey to watch for changes
callbackcallback function
contextuser supplied context passed to callback function
Return values
1on success
0on failure

◆ ElektraNotificationPluginRegisterCallbackSameOrBelow

typedef int(* ElektraNotificationPluginRegisterCallbackSameOrBelow) (Plugin *handle, Key *key, ElektraNotificationChangeCallback callback, void *context)

Subscribe for updates via callback when a given key or a key below is changed.

Exported as "registerCallbackSameOrBelow" by notification plugins.

Parameters
handleplugin handle
keykey to watch for changes
callbackcallback function
contextuser supplied context passed to callback function
Return values
1on success
0on failure

◆ ElektraNotificationSetConversionErrorCallback

typedef void(* ElektraNotificationSetConversionErrorCallback) (Plugin *handle, ElektraNotificationConversionErrorCallback callback, void *context)

Allow setting a callback that is called when a value conversion failed.

Exported as "setConversionErrorCallback" notification plugins.

Parameters
kdbkdb handle
callbackcallback
contextcontext