Class AcknowledgmentChallengeResult
- Namespace
- AsiBackbone.AspNetCore.Acknowledgments
- Assembly
- AsiBackbone.AspNetCore.dll
Represents the result of handling a host-submitted acknowledgment challenge response.
public sealed class AcknowledgmentChallengeResult
- Inheritance
-
AcknowledgmentChallengeResult
- Inherited Members
Properties
Acknowledged
Gets a value indicating whether the response was accepted by the actor.
public bool Acknowledged { get; }
Property Value
Acknowledgment
Gets the Core acknowledgment response when one was created.
public AcknowledgmentResponse? Acknowledgment { get; }
Property Value
CanProceed
Gets a value indicating whether the operation that required acknowledgment may continue.
public bool CanProceed { get; }
Property Value
Remarks
This is true only when the response was handled successfully and the actor accepted. A handled refusal and every handling failure yield false. It is the single check a host should gate the consequential operation on, matching CanProceed.
Rejected
Gets a value indicating whether the response was rejected by the actor.
public bool Rejected { get; }
Property Value
Result
Gets the operation result describing response handling success or failure.
public OperationResult Result { get; }
Property Value
Succeeded
Gets a value indicating whether the response was handled successfully.
public bool Succeeded { get; }
Property Value
Remarks
This reports only that the response was valid and produced an acknowledgment record. It is true when the actor explicitly declined, because a refusal is recorded as a AcknowledgmentResponse just like an acceptance. Do not use it to decide whether the operation may continue; use CanProceed instead.
Methods
Failure(string, string)
Creates a failed acknowledgment challenge result.
public static AcknowledgmentChallengeResult Failure(string code, string message)
Parameters
Returns
- AcknowledgmentChallengeResult
A failed challenge result.
Success(AcknowledgmentResponse)
Creates a successful acknowledgment challenge result.
public static AcknowledgmentChallengeResult Success(AcknowledgmentResponse acknowledgment)
Parameters
acknowledgmentAcknowledgmentResponseThe Core acknowledgment response.
Returns
- AcknowledgmentChallengeResult
A successful challenge result.