/* SPDX-License-Identifier: LGPL-2.1+ */
#pragma once
-/***
- This file is part of systemd.
-
- Copyright 2011 Lennart Poettering
-***/
-
typedef enum UnitFileScope UnitFileScope;
typedef enum UnitFileState UnitFileState;
typedef enum UnitFilePresetMode UnitFilePresetMode;
};
enum UnitFileFlags {
- UNIT_FILE_RUNTIME = 1U << 0,
- UNIT_FILE_FORCE = 1U << 1,
- UNIT_FILE_DRY_RUN = 1U << 2,
+ UNIT_FILE_RUNTIME = 1 << 0,
+ UNIT_FILE_FORCE = 1 << 1,
+ UNIT_FILE_DRY_RUN = 1 << 2,
};
/* type can either one of the UnitFileChangeTypes listed above, or a negative error.
UnitFileChange **changes,
size_t *n_changes);
+int unit_file_lookup_state(
+ UnitFileScope scope,
+ const LookupPaths *paths,
+ const char *name,
+ UnitFileState *ret);
+
int unit_file_get_state(UnitFileScope scope, const char *root_dir, const char *filename, UnitFileState *ret);
int unit_file_exists(UnitFileScope scope, const LookupPaths *paths, const char *name);