namespace Moli.Desktop.Plugins; /// Strongly typed plugin identifier. public readonly record struct PluginId(string Value) { public override string ToString() => Value; } /// Supported plugin entry category. public enum PluginType { Wallpaper, Widget } /// Lifecycle state persisted for a plugin. public enum PluginState { Discovered, Loaded, Running, Paused, Enabled, Disabled, Invalid, Error, Removed } public sealed record PluginRuntimeState { public required PluginId Id { get; init; } public required string Name { get; init; } public required PluginType Type { get; init; } public required PluginState State { get; init; } public string? ErrorCode { get; init; } public string? Entry { get; init; } }