summaryrefslogtreecommitdiff
path: root/engine/dconf-engine.h
blob: f766f0be6a8ddc0337c818542c750288c99d0b0b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
#ifndef _dconf_engine_h_
#define _dconf_engine_h_

#include <dconf-readtype.h>
#include <glib.h>

typedef struct _DConfEngine DConfEngine;
typedef struct _DConfEngineResetList DConfEngineResetList;

typedef struct
{
  gint         bus_type;
  const gchar *destination;
  const gchar *object_path;
  const gchar *interface;
  const gchar *method;
  GVariant    *body;
} DConfEngineMessage;



typedef GVariant *    (*DConfEngineServiceFunc)                         (DConfEngine             *engine,
                                                                         DConfEngineMessage      *message);

DConfEngine *           dconf_engine_new                                (const gchar             *context);
void                    dconf_engine_unref                              (DConfEngine             *engine);
DConfEngine *           dconf_engine_ref                                (DConfEngine             *engine);

GVariant *              dconf_engine_read                               (DConfEngine             *engine,
                                                                         const gchar             *key,
                                                                         DConfReadType            type);
gchar **                dconf_engine_list                               (DConfEngine             *engine,
                                                                         const gchar             *path,
                                                                         DConfEngineResetList    *resets);

void                    dconf_engine_get_service_info                   (DConfEngine             *engine,
                                                                         const gchar            **bus_type,
                                                                         const gchar            **destination,
                                                                         const gchar            **object_path);
gboolean                dconf_engine_is_writable                        (DConfEngine             *engine,
                                                                         DConfEngineMessage      *message,
                                                                         const gchar             *name);
gboolean                dconf_engine_write                              (DConfEngine             *engine,
                                                                         DConfEngineMessage      *message,
                                                                         const gchar             *key,
                                                                         GVariant                *value);
gboolean                dconf_engine_write_tree                         (DConfEngine             *engine,
                                                                         DConfEngineMessage      *message,
                                                                         GTree                   *tree);
void                    dconf_engine_watch                              (DConfEngine             *engine,
                                                                         DConfEngineMessage      *message,
                                                                         const gchar             *name);
void                    dconf_engine_unwatch                            (DConfEngine             *engine,
                                                                         DConfEngineMessage      *message,
                                                                         const gchar             *name);
void                    dconf_engine_decode_notify                      (DConfEngine             *engine,
                                                                         const gchar            **prefix,
                                                                         const gchar           ***keys,
                                                                         GVariant                *body);

void                    dconf_engine_reset_list_init                    (DConfEngineResetList    *resets,
                                                                         const gchar * const     *list);
void                    dconf_engine_reset_list_add                     (DConfEngineResetList    *resets,
                                                                         const gchar             *item);
void                    dconf_engine_reset_list_clear                   (DConfEngineResetList    *resets);

#endif /* _dconf_engine_h_ */