39 lines
1.0 KiB
C#
39 lines
1.0 KiB
C#
namespace StellaOps.AirGap.Bundle.Services;
|
|
|
|
/// <summary>
|
|
/// Result of creating a knowledge snapshot bundle.
|
|
/// </summary>
|
|
public sealed record SnapshotBundleResult
|
|
{
|
|
public bool Success { get; init; }
|
|
public string? OutputPath { get; init; }
|
|
public string? BundleId { get; init; }
|
|
public string? MerkleRoot { get; init; }
|
|
public string? BundleDigest { get; init; }
|
|
public long TotalSizeBytes { get; init; }
|
|
public int EntryCount { get; init; }
|
|
public DateTimeOffset CreatedAt { get; init; }
|
|
public string? Error { get; init; }
|
|
|
|
/// <summary>
|
|
/// Whether the manifest was signed.
|
|
/// </summary>
|
|
public bool Signed { get; init; }
|
|
|
|
/// <summary>
|
|
/// Key ID used for signing.
|
|
/// </summary>
|
|
public string? SigningKeyId { get; init; }
|
|
|
|
/// <summary>
|
|
/// Algorithm used for signing.
|
|
/// </summary>
|
|
public string? SigningAlgorithm { get; init; }
|
|
|
|
public static SnapshotBundleResult Failed(string error) => new()
|
|
{
|
|
Success = false,
|
|
Error = error
|
|
};
|
|
}
|