mirror of
https://github.com/RGBCube/serenity
synced 2025-05-31 19:58:11 +00:00

This API lets applications specify which configuration domains they will be accessing throughout their lifetime. It works similarly in spirit to the kernel's pledge(). You cannot pledge_domains() more than once, and once you have used it, it's no longer possible to access any other configuration domain. This is obviously just a first cut of this mechanism, and we may need to tweak it further as we go.
12 lines
571 B
Text
12 lines
571 B
Text
endpoint ConfigServer
|
|
{
|
|
pledge_domains(Vector<String> domains) =|
|
|
|
|
read_string_value(String domain, String group, String key) => (Optional<String> value)
|
|
read_i32_value(String domain, String group, String key) => (Optional<i32> value)
|
|
read_bool_value(String domain, String group, String key) => (Optional<bool> value)
|
|
|
|
write_string_value(String domain, String group, String key, String value) =|
|
|
write_i32_value(String domain, String group, String key, i32 value) =|
|
|
write_bool_value(String domain, String group, String key, bool value) =|
|
|
}
|