Configuration management plugin

Configuration management plugins provide a way to store an application configuration. Openpaperwork_core provides the plugin openpaperwork_core.config_file that stores the configuration in a configuration file (see Python’s configparser).

There could be other plugins providing identical API and interface that store the configuration in Windows registry or in an Android ContentProvider. However since they are not cross-platform, they would have to be distributed in separated packages.

Manages a configuration file using configparser.

class openpaperwork_core.config_file.ConfigBool(value=False)[source]
class openpaperwork_core.config_file.ConfigDate(value=datetime.datetime(1970, 1, 1, 0, 0))[source]
DATE_FORMAT = '%Y-%m-%d'
class openpaperwork_core.config_file.ConfigDict(value=None, elements={})[source]
SEPARATOR_ITEMS = ', '
SEPARATOR_KEYVALS = '='
class openpaperwork_core.config_file.ConfigList(value=None, elements=None)[source]
SEPARATOR = ', '
append(value)[source]
class openpaperwork_core.config_file.Plugin[source]
config_add_observer(section, callback)[source]
config_add_plugin(opt_name, module_name)[source]
config_del(section, key)[source]
config_get(section, key, default=None)[source]
config_list_active_plugins(opt_name)[source]
config_load(application_name)[source]
config_load_plugins(opt_name, default=[])[source]

Load and init the plugin list from the configuration.

config_put(section, key, value)[source]

Section must be a string. Key must be a string.

config_remove_observer(section, callback)[source]
config_remove_plugin(opt_name, module_name)[source]
config_reset_plugins(opt_name)[source]
config_save(application_name=None)[source]
get_interfaces()[source]
init(core)[source]