Kaa client C SDK
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
Functions
ext_configuration_persistence.h File Reference

External interface for storing/loading the configuration data used by Kaa Configuration subsystem. More...

Go to the source code of this file.

Functions

void ext_configuration_read (char **buffer, size_t *buffer_size, bool *needs_deallocation)
 Called on Kaa startup to restore the persisted configuration data (if present). More...
 
void ext_configuration_store (const char *buffer, size_t buffer_size)
 Called when Kaa is ready to persist configuration data. More...
 
void ext_configuration_delete (void)
 Called when Kaa need to remove configuration data. More...
 

Detailed Description

External interface for storing/loading the configuration data used by Kaa Configuration subsystem.

Function Documentation

void ext_configuration_delete ( void  )

Called when Kaa need to remove configuration data.

void ext_configuration_read ( char **  buffer,
size_t *  buffer_size,
bool *  needs_deallocation 
)

Called on Kaa startup to restore the persisted configuration data (if present).

Fetch configuration data to buffer and provide a valid size of it in buffer_size. If *buffer == NULL or *buffer_size == 0 then there is no persisted configuration yet. Set *needs_deallocation = true if buffer should be deallocated by Kaa, false otherwise.

Parameters
[out]bufferPointer to buffer which should be filled with Kaa configuration data.
[out]buffer_sizePointer to buffer's size.
[out]needs_deallocationIndicates if the Kaa library should deallocate buffer by itself.
void ext_configuration_store ( const char *  buffer,
size_t  buffer_size 
)

Called when Kaa is ready to persist configuration data.

Parameters
[in]bufferValid pointer to buffer which contains the current Kaa configuration data.
[in]buffer_sizeThe buffer's size.