mirror of
https://github.com/corda/corda.git
synced 2024-12-18 20:47:57 +00:00
Harmonises the names of the parameters across CashExitFlow constructors.
This commit is contained in:
parent
412fead02e
commit
63734aa3ed
@ -29,8 +29,8 @@ import java.util.*
|
||||
class CashExitFlow(private val amount: Amount<Currency>,
|
||||
private val issuerRef: OpaqueBytes,
|
||||
progressTracker: ProgressTracker) : AbstractCashFlow<AbstractCashFlow.Result>(progressTracker) {
|
||||
constructor(amount: Amount<Currency>, issueRef: OpaqueBytes) : this(amount, issueRef, tracker())
|
||||
constructor(request: ExitRequest) : this(request.amount, request.issueRef, tracker())
|
||||
constructor(amount: Amount<Currency>, issuerRef: OpaqueBytes) : this(amount, issuerRef, tracker())
|
||||
constructor(request: ExitRequest) : this(request.amount, request.issuerRef, tracker())
|
||||
|
||||
companion object {
|
||||
fun tracker() = ProgressTracker(GENERATING_TX, SIGNING_TX, FINALISING_TX)
|
||||
@ -78,5 +78,5 @@ class CashExitFlow(private val amount: Amount<Currency>,
|
||||
}
|
||||
|
||||
@CordaSerializable
|
||||
class ExitRequest(amount: Amount<Currency>, val issueRef: OpaqueBytes) : AbstractRequest(amount)
|
||||
class ExitRequest(amount: Amount<Currency>, val issuerRef: OpaqueBytes) : AbstractRequest(amount)
|
||||
}
|
||||
|
@ -141,7 +141,7 @@ class ExplorerSimulation(private val options: OptionSet) {
|
||||
it.startFlow(::CashIssueAndPaymentFlow, request).log(i, "${request.amount.token}Issuer")
|
||||
}
|
||||
is ExitRequest -> issuers[request.amount.token]?.let {
|
||||
println("${Instant.now()} [$i] EXITING ${request.amount} with ref ${request.issueRef}")
|
||||
println("${Instant.now()} [$i] EXITING ${request.amount} with ref ${request.issuerRef}")
|
||||
it.startFlow(::CashExitFlow, request).log(i, "${request.amount.token}Exit")
|
||||
}
|
||||
else -> throw IllegalArgumentException("Unsupported command: $request")
|
||||
|
Loading…
Reference in New Issue
Block a user