2using System.Threading.Tasks;
25 : this(
Uri, Legal, null)
39 this.senderValidation = SenderValidation;
53 if (!(this.senderValidation is
null) &&
57 Contract = await this.senderValidation.GetContractAsync();
61 KeyValuePair<Contract,IqResultEventArgs> P = await this.legal.GetContract(this.
Uri.
ContractCondition);
72 Uri.
State.Error(Uris.States.EDalerUriErrorType.BadRequest,
"Conditional contract not found: " + ContractId,
false);
81 Uri.
State.Error(Uris.States.EDalerUriErrorType.Conflict,
"Conditional contract is approved, but not signed.",
true);
85 Uri.
State.Error(Uris.States.EDalerUriErrorType.Conflict,
"Conditional contract is being signed, but not all parties have signed yet.",
true);
89 Uri.
State.Error(Uris.States.EDalerUriErrorType.BadRequest,
"Conditional contract has been deleted.",
false);
93 Uri.
State.Error(Uris.States.EDalerUriErrorType.BadRequest,
"Conditional contract has been obsoleted.",
false);
97 Uri.
State.Error(Uris.States.EDalerUriErrorType.Conflict,
"Conditional contract has been proposed, but has not been approved and signed yet.",
true);
101 Uri.
State.Error(Uris.States.EDalerUriErrorType.BadRequest,
"Conditional contract has been rejected.",
false);
105 Uri.
State.Error(Uris.States.EDalerUriErrorType.BadRequest,
"Conditional contract has failed.",
false);
111 Uri.
State.Error(Uris.States.EDalerUriErrorType.BadRequest,
"Contract not legally binding at the current time.",
false);
118 Uri.
State.Error(Uris.States.EDalerUriErrorType.BadRequest,
"Conditional contract is in an invalid state.",
false);
129 return Task.FromResult(
true);
138 return Task.FromResult(
true);
147 return Task.FromResult(
true);
Represents a case-insensitive string.
static bool IsNullOrEmpty(CaseInsensitiveString value)
Indicates whether the specified string is null or an CaseInsensitiveString.Empty string.
Abstract base class for eDaler transactions.
Validates a contract has been signed before a transaction can be realized.
override Task< bool > DoRollback()
Performs actual rollback.
override Task< bool > DoExecute()
Performs actual execution.
override Task< bool > DoCommit()
Performs actual commit.
ValidateContractSigned(EDalerUri Uri, LegalComponent Legal)
Validates a contract has been signed before a transaction can be realized.
override async Task< bool > DoPrepare()
Performs actual preparation.
ValidateContractSigned(EDalerUri Uri, LegalComponent Legal, ValidateSenderContractSignature SenderValidation)
Validates a contract has been signed before a transaction can be realized.
Validates that the sender has signed the contract and that the contract is valid.
Abstract base class for eDaler URIs
CaseInsensitiveString ContractCondition
Optional Contract defining conditions that must be met before payment can be realized....
EDalerUriState State
URI State object.
Contains the definition of a contract
async Task< bool > IsLegallyBinding(bool CheckCurrentTime, bool ExcludeSigningStage, LegalComponent Legal)
Checks if a contract is legally binding.
Legal (digital identities, smart contracts) service component.
Service Module hosting the XMPP broker and its components.
Interface for eDaler URIs for contractual payments
CaseInsensitiveString ContractWithSignatures
ID of contract containing signatures authorizing payment.
ContractState
Recognized contract states