]> wimlib.net Git - wimlib/blob - include/wimlib/registry.h
3de81956fccadfb11284a223c84ae4134b31ad32
[wimlib] / include / wimlib / registry.h
1 #ifndef _WIMLIB_REGISTRY_H
2 #define _WIMLIB_REGISTRY_H
3
4 #include "wimlib/types.h"
5
6 struct regf;
7
8 enum hive_status {
9         HIVE_OK,
10         HIVE_CORRUPT,
11         HIVE_UNSUPPORTED,
12         HIVE_KEY_NOT_FOUND,
13         HIVE_VALUE_NOT_FOUND,
14         HIVE_VALUE_IS_WRONG_TYPE,
15         HIVE_OUT_OF_MEMORY,
16 };
17
18 extern enum hive_status
19 hive_validate(const void *hive_mem, size_t hive_size);
20
21 extern enum hive_status
22 hive_get_string(const struct regf *regf, const tchar *key_name,
23                 const tchar *value_name, tchar **value_ret);
24
25 extern enum hive_status
26 hive_get_number(const struct regf *regf, const tchar *key_name,
27                 const tchar *value_name, s64 *value_ret);
28
29 extern enum hive_status
30 hive_list_subkeys(const struct regf *regf, const tchar *key_name,
31                   tchar ***subkeys_ret);
32
33 extern void
34 hive_free_subkeys_list(tchar **subkeys);
35
36 extern const char *
37 hive_status_to_string(enum hive_status status);
38
39 #endif /* _WIMLIB_REGISTRY_H */