libscipaper 1.0.x
sci-conf.h
Go to the documentation of this file.
1
18#ifndef _SPHONE_CONF_H_
19#define _SPHONE_CONF_H_
20
21#include <glib.h>
22#include <stdbool.h>
23
24#ifdef __cplusplus
25extern "C" {
26#endif
27
42bool sci_conf_get_bool(const gchar *group, const gchar *key,
43 const bool defaultval, gpointer keyfileptr);
44
54gint sci_conf_get_int(const gchar *group, const gchar *key,
55 const gint defaultval, gpointer keyfileptr);
56
66gint *sci_conf_get_int_list(const gchar *group, const gchar *key,
67 gsize *length, gpointer keyfileptr);
68
78gchar *sci_conf_get_string(const gchar *group, const gchar *key,
79 const gchar *defaultval, gpointer keyfileptr);
80
90gchar **sci_conf_get_string_list(const gchar *group, const gchar *key,
91 gsize *length, gpointer keyfileptr);
92
93
100gpointer sci_conf_read_conf_file(const gchar *const conffile);
101
109gpointer sci_conf_read_conf_bytes(const char* data, size_t length);
110
111void sci_conf_free_conf_file(gpointer keyfileptr);
112
115bool sci_conf_init(const char* fileName, const char* data, size_t length);
116void sci_conf_exit(void);
117
118#ifdef __cplusplus
119}
120#endif
121#endif /* _SPHONE_CONF_H_ */
bool sci_conf_get_bool(const gchar *group, const gchar *key, const bool defaultval, gpointer keyfileptr)
Get a boolean configuration value.
gint * sci_conf_get_int_list(const gchar *group, const gchar *key, gsize *length, gpointer keyfileptr)
Get an integer list configuration value.
gpointer sci_conf_read_conf_bytes(const char *data, size_t length)
Read configuration from raw memory.
gpointer sci_conf_read_conf_file(const gchar *const conffile)
Read configuration file.
gchar ** sci_conf_get_string_list(const gchar *group, const gchar *key, gsize *length, gpointer keyfileptr)
Get a string list configuration value.
gchar * sci_conf_get_string(const gchar *group, const gchar *key, const gchar *defaultval, gpointer keyfileptr)
Get a string configuration value.
gint sci_conf_get_int(const gchar *group, const gchar *key, const gint defaultval, gpointer keyfileptr)
Get an integer configuration value.