< Summary

Information
Class: AsiBackbone.Samples.NcatAuditCompletionAdapter.NcatAuditCompletionDeliveryResult
Assembly: AsiBackbone.Samples.NcatAuditCompletionAdapter
File(s): /home/runner/work/AsiBackbone/AsiBackbone/samples/NcatAuditCompletionAdapter/NcatAuditCompletionDeliveryResult.cs
Line coverage
100%
Covered lines: 8
Uncovered lines: 0
Coverable lines: 8
Total lines: 46
Line coverage: 100%
Branch coverage
100%
Covered branches: 4
Total branches: 4
Branch coverage: 100%
Method coverage

Feature is only available for sponsors

Upgrade to PRO version

Metrics

MethodBranch coverage Crap Score Cyclomatic complexity Line coverage
.ctor(...)100%11100%
get_Disposition()100%11100%
get_ReasonCode()100%11100%
get_LifecycleEventId()100%11100%
get_Receipt()100%11100%
get_LifecycleEvent()100%11100%
get_FailureType()100%11100%
get_ShouldAcknowledgeSource()100%44100%

File(s)

/home/runner/work/AsiBackbone/AsiBackbone/samples/NcatAuditCompletionAdapter/NcatAuditCompletionDeliveryResult.cs

#LineLine coverage
 1using AsiBackbone.Core.Audit;
 2using AsiBackbone.Core.HostIntegration;
 3
 4namespace AsiBackbone.Samples.NcatAuditCompletionAdapter;
 5
 6/// <summary>
 7/// Identifies how the NCAT source dispatcher should treat one completion handoff attempt.
 8/// </summary>
 9public enum NcatAuditCompletionDeliveryDisposition
 10{
 11    /// <summary>The lifecycle event was durably appended and the source entry may be acknowledged.</summary>
 12    Delivered = 100,
 13
 14    /// <summary>An equivalent lifecycle event already exists and the source entry may be acknowledged.</summary>
 15    Duplicate = 200,
 16
 17    /// <summary>The handoff should be attempted again because lifecycle persistence did not complete.</summary>
 18    Retryable = 300,
 19
 20    /// <summary>The handoff is valid but required decision evidence is not available yet.</summary>
 21    Deferred = 400,
 22
 23    /// <summary>The handoff is invalid or conflicts with previously persisted idempotency evidence.</summary>
 24    Terminal = 500,
 25
 26    /// <summary>The configured retry threshold was reached without a successful lifecycle append.</summary>
 27    DeadLetter = 600
 28}
 29
 30/// <summary>
 31/// Reports the normalized result of one NCAT audit-completion handoff attempt.
 32/// </summary>
 3033public sealed record NcatAuditCompletionDeliveryResult(
 4234    NcatAuditCompletionDeliveryDisposition Disposition,
 1235    string ReasonCode,
 436    string? LifecycleEventId = null,
 2637    GovernedOperationExecutionReceipt? Receipt = null,
 1838    AuditResidueLifecycleEvent? LifecycleEvent = null,
 3239    string? FailureType = null)
 40{
 41    /// <summary>
 42    /// Gets a value indicating whether the source completion entry may be marked delivered.
 43    /// </summary>
 44    public bool ShouldAcknowledgeSource =>
 1245        Disposition is NcatAuditCompletionDeliveryDisposition.Delivered or NcatAuditCompletionDeliveryDisposition.Duplic
 46}