1
0
mirror of https://github.com/chylex/Minecraft-Phantom-Panel.git synced 2024-11-23 19:42:51 +01:00
Minecraft-Phantom-Panel/Common/Phantom.Common.Data/Backups/BackupCreationResult.cs

19 lines
600 B
C#

using MemoryPack;
namespace Phantom.Common.Data.Backups;
[MemoryPackable(GenerateType.VersionTolerant)]
public sealed partial record BackupCreationResult(
[property: MemoryPackOrder(0)] BackupCreationResultKind Kind,
[property: MemoryPackOrder(1)] BackupCreationWarnings Warnings = BackupCreationWarnings.None
) {
public sealed class Builder {
public BackupCreationResultKind Kind { get; set; } = BackupCreationResultKind.Success;
public BackupCreationWarnings Warnings { get; set; }
public BackupCreationResult Build() {
return new BackupCreationResult(Kind, Warnings);
}
}
}