14 #define CN_BOOL 0x000001
15 #define CN_INT 0x000002
19 #define CN_STR 0x000008
20 #define CN_RO 0x000010
21 #define CN_RW 0x000020
23 #define NODECB(w, x, y) rz_config_set_cb(cfg, w, x, y)
24 #define NODEICB(w, x, y) rz_config_set_i_cb(cfg, w, x, y)
25 #define SETDESC(x, y) rz_config_node_desc(x, y)
26 #define SETOPTIONS(x, ...) set_options(x, __VA_ARGS__)
27 #define SETI(x, y, z) SETDESC(rz_config_set_i(cfg, x, y), z)
28 #define SETB(x, y, z) SETDESC(rz_config_set_b(cfg, x, y), z)
29 #define SETICB(w, x, y, z) SETDESC(NODEICB(w, x, y), z)
30 #define SETPREF(x, y, z) SETDESC(rz_config_set(cfg, x, y), z)
31 #define SETCB(w, x, y, z) SETDESC(NODECB(w, x, y), z)
32 #define SETBPREF(x, y, z) SETDESC(NODECB(x, y, boolify_var_cb), z)
static static sync static getppid static getegid const char static filename char static len const char char static bufsiz static mask static vfork const void static prot static getpgrp const char static swapflags static arg static fd static protocol static who struct sockaddr static addrlen static backlog struct timeval struct timezone static tz const struct iovec static count static mode const void const struct sockaddr static tolen const char static pathname void static offset struct stat static buf void long static basep static whence static length const void static len key
RZ_API ut64 rz_config_get_i(RzConfig *cfg, RZ_NONNULL const char *name)
RZ_API bool rz_config_get_b(RzConfig *cfg, RZ_NONNULL const char *name)
RZ_API RzConfigNode * rz_config_set_cb(RzConfig *cfg, const char *name, const char *value, bool(*callback)(void *user, void *data))
RZ_API void rz_serialize_config_save(RZ_NONNULL Sdb *db, RZ_NONNULL RzConfig *config)
RZ_API bool rz_config_unserialize(RZ_NONNULL RzConfig *config, RZ_NONNULL Sdb *db, RZ_NULLABLE char **err)
RZ_API bool rz_config_eval(RZ_NONNULL RzConfig *cfg, RZ_NONNULL const char *str)
Sets the configuration variable and its value passed as argument.
static bool rz_config_node_is_bool(RzConfigNode *node)
struct rz_config_node_t RzConfigNode
RZ_API RzConfigNode * rz_config_set_i_cb(RzConfig *cfg, const char *name, int ivalue, bool(*callback)(void *user, void *data))
static bool rz_config_node_is_int(RzConfigNode *node)
RZ_API RzConfigNode * rz_config_set(RzConfig *cfg, RZ_NONNULL const char *name, const char *value)
RZ_API bool rz_config_readonly(RzConfig *cfg, const char *key)
RZ_API RzConfig * rz_config_clone(RzConfig *cfg)
RZ_API void rz_config_hold_restore(RzConfigHold *h)
Restore whatever config options were previously saved in h.
RZ_LIB_VERSION_HEADER(rz_config)
RZ_API bool rz_config_set_getter(RzConfig *cfg, const char *key, RzConfigCallback cb)
RZ_API RzConfigHold * rz_config_hold_new(RzConfig *cfg)
Create an opaque object to save/restore some configuration options.
RZ_API RZ_BORROW RzConfigNode * rz_config_node_get(RzConfig *cfg, RZ_NONNULL const char *name)
RZ_API RZ_OWN RzConfigNode * rz_config_node_new(RZ_NONNULL const char *name, RZ_NONNULL const char *value)
static bool rz_config_node_is_ro(RzConfigNode *node)
struct rz_config_t RzConfig
RZ_API bool rz_config_hold_s(RzConfigHold *h,...)
Save the current values of a list of config options that have string values.
RZ_API bool rz_config_rm(RzConfig *cfg, RZ_NONNULL const char *name)
static bool rz_config_node_is_str(RzConfigNode *node)
RZ_API const char * rz_config_node_desc(RzConfigNode *node, RZ_NULLABLE const char *desc)
struct rz_config_hold_char_t RzConfigHoldChar
RZ_API RzConfigNode * rz_config_set_i(RzConfig *cfg, RZ_NONNULL const char *name, const ut64 i)
RZ_API void rz_config_node_free(RZ_NULLABLE void *n)
RZ_API bool rz_config_add_node(RZ_BORROW RzConfig *cfg, RZ_OWN RzConfigNode *node)
Appends the given node to the config cfg.
RZ_API RZ_BORROW const char * rz_config_get(RzConfig *cfg, RZ_NONNULL const char *name)
RZ_API const char * rz_config_node_type(RzConfigNode *node)
RZ_API const char * rz_config_desc(RzConfig *cfg, RZ_NONNULL const char *name, RZ_NULLABLE const char *desc)
RZ_API RzConfig * rz_config_new(void *user)
RZ_API bool rz_config_set_setter(RzConfig *cfg, const char *key, RzConfigCallback cb)
RZ_API bool rz_config_hold_i(RzConfigHold *h,...)
Save the current values of a list of config options that have integer values.
RZ_API void rz_config_lock(RzConfig *cfg, int l)
RZ_API RzConfigNode * rz_config_set_b(RzConfig *cfg, RZ_NONNULL const char *name, bool value)
RZ_API RZ_OWN RzConfigNode * rz_config_node_clone(RzConfigNode *n)
struct rz_config_hold_num_t RzConfigHoldNum
RZ_API void rz_config_hold_free(RzConfigHold *h)
Free a RzConfigHold object h.
struct rz_config_hold_t RzConfigHold
RZ_API void rz_config_serialize(RZ_NONNULL RzConfig *config, RZ_NONNULL Sdb *db)
bool(* RzConfigCallback)(void *user, void *data)
RZ_API bool rz_serialize_config_load(RZ_NONNULL Sdb *db, RZ_NONNULL RzConfig *config, RZ_NULLABLE const char *const *exclude, RZ_NULLABLE RzSerializeResultInfo *res)
RZ_API void rz_config_bump(RzConfig *cfg, const char *key)
RZ_API void rz_config_node_value_format_i(char *buf, size_t buf_size, const ut64 i, RZ_NULLABLE RzConfigNode *node)
RZ_API bool rz_config_toggle(RzConfig *cfg, RZ_NONNULL const char *name)
RZ_API void rz_config_free(RzConfig *cfg)
ut64(WINAPI *w32_GetEnabledXStateFeatures)()