$darkmode
|
Elektra 0.11.0
|
Implementation of notification functions as defined in kdbnotification.h. More...
#include <kdbassert.h>#include <kdbease.h>#include <kdbhelper.h>#include <kdbinvoke.h>#include <kdbioprivate.h>#include <kdblogger.h>#include <kdbnotification.h>#include <kdbnotificationinternal.h>#include <kdbplugin.h>#include <kdbprivate.h>#include <stdio.h>
Functions | |
| int | elektraNotificationContract (KeySet *contract) |
| Creates a contract for use with kdbOpen() that sets up notifications. More... | |
| int | elektraNotificationRegisterCallback (KDB *kdb, Key *key, ElektraNotificationChangeCallback callback, void *context) |
| Subscribe for updates via callback when a given key value is changed. More... | |
| int | elektraNotificationRegisterCallbackSameOrBelow (KDB *kdb, Key *key, ElektraNotificationChangeCallback callback, void *context) |
| Subscribe for updates via callback when a given key or a key below changed. More... | |
Implementation of notification functions as defined in kdbnotification.h.
| int elektraNotificationContract | ( | KeySet * | contract | ) |
Creates a contract for use with kdbOpen() that sets up notifications.
When you call kdbOpen() with this contract, the internalnotification plugin will be mounted automatically. This allows you to call other elektraNotification* functions.
If you need to configure notification transport plugins, you should manually add the relevant keys to contract.
| contract | The keyset into which the contract is written. |
| -1 | if contract is NULL |
| 0 | on success |