mirror of
https://github.com/MindWorkAI/AI-Studio.git
synced 2026-11-11 07:07:22 +00:00
Generated the JSON contracts of the stored data at compile time (#1148)
This commit is contained in:
1 parent
fc7399e81b
commit
e954881fda
75 files changed
+5437
-298
No files matched your search
@@ -26,11 +26,12 @@ public sealed class SettingsManager
|
||||
|
||||
private readonly record struct CurrentSettingsReadResult(Data? SettingsData, SettingsWriteBlockReason FailureReason);
|
||||
|
||||
internal static readonly JsonSerializerOptions JSON_OPTIONS = new()
|
||||
internal static readonly JsonSerializerOptions JSON_OPTIONS = new JsonSerializerOptions
|
||||
{
|
||||
WriteIndented = true,
|
||||
Converters = { new TolerantEnumConverter() },
|
||||
};
|
||||
TypeInfoResolver = SettingsJsonContext.Default,
|
||||
}.AsReadOnly();
|
||||
|
||||
/// <summary>
|
||||
/// From this duration on, storing the settings is reported as slow.
|
||||
|
||||
Reference in new issue
Block a user