| 1 |
/* SPDX-License-Identifier: LGPL-2.1-or-later */ |
| 2 |
|
| 3 |
#include "runtime-scope.h" |
| 4 |
#include "string-table.h" |
| 5 |
|
| 6 |
static const char* const runtime_scope_table[_RUNTIME_SCOPE_MAX] = { |
| 7 |
[RUNTIME_SCOPE_SYSTEM] = "system", |
| 8 |
[RUNTIME_SCOPE_USER] = "user", |
| 9 |
[RUNTIME_SCOPE_GLOBAL] = "global", |
| 10 |
}; |
| 11 |
|
| 12 |
DEFINE_STRING_TABLE_LOOKUP(runtime_scope, RuntimeScope); |
| 13 |
|
| 14 |
static const char* const runtime_scope_cmdline_option_table[_RUNTIME_SCOPE_MAX] = { |
| 15 |
[RUNTIME_SCOPE_SYSTEM] = "--system", |
| 16 |
[RUNTIME_SCOPE_USER] = "--user", |
| 17 |
[RUNTIME_SCOPE_GLOBAL] = "--global", |
| 18 |
}; |
| 19 |
|
| 20 |
DEFINE_STRING_TABLE_LOOKUP_TO_STRING(runtime_scope_cmdline_option, RuntimeScope); |