[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RFD: new gnokii API for config handling

From: Pawel Kot
Subject: RFD: new gnokii API for config handling
Date: Sun, 17 Feb 2008 21:57:26 +0100


I have just committed to gnokii CVS first attempt to change gnokii API
for config structures handling. It will allow third party developers
not to use gnokiirc. This is as well approach to get rid of globals
from cfgreader.c. The changes are not complete yet, but please do take
a look at them and express your fillings on it.

We have four new API functions.

struct gn_cfg_header *gn_cfg_generic_create(model, connection, port)
This is to prepare generic (global) section based on these three variables.

struct gn_cfg_header *gn_cfg_bluetooth_create(model, btmac, rfcomm)
This is the same but prepares section for bluetooth connection. It
prepares global section as well.

struct gn_cfg_header *gn_cfg_section_create(section, model, connection, port)
This is a bit more generic than the above. You may give a section name.

struct gn_cfg_variable_set(gn_cfg_header, section, name, value, overwrite)
This one creates new variable in given section in given config
(gn_cfg_header). overwrite argument is to determine behaviour on what
to do if the key (name) already exists.

Please not that this is just a proposal and a subject to change.
Please let me know what are your needs and preferred API for gnokii
config; what functions you need for your applications.

take care,
Pawel Kot

reply via email to

[Prev in Thread] Current Thread [Next in Thread]