@StartableByRPC @InitiatingFlow open class CashPaymentFlow : AbstractCashFlow<Result>
Initiates a flow that sends cash to a recipient.
amount
- the amount of a currency to pay to the recipient.
recipient
- the party to pay the currency to.
issuerConstraint
- if specified, the payment will be made using only cash issued by the given parties.
anonymous
- whether to anonymous the recipient party. Should be true for normal usage, but may be false
notary
- if not specified, the first notary of the network map is selected
for testing purposes.
class PaymentRequest : AbstractRequest |
CashPaymentFlow(amount: Amount<Currency>, recipient: Party) CashPaymentFlow(amount: Amount<Currency>, recipient: Party, anonymous: Boolean)
A straightforward constructor that constructs spends using cash states of any issuer. CashPaymentFlow(amount: Amount<Currency>, recipient: Party, anonymous: Boolean, notary: Party) CashPaymentFlow(request: PaymentRequest) CashPaymentFlow(amount: Amount<Currency>, recipient: Party, anonymous: Boolean, progressTracker: ProgressTracker, issuerConstraint: Set<Party> = emptySet(), notary: Party? = null)
Initiates a flow that sends cash to a recipient. |
val amount: Amount<Currency>
the amount of a currency to pay to the recipient. |
|
val anonymous: Boolean
whether to anonymous the recipient party. Should be true for normal usage, but may be false |
|
val issuerConstraint: Set<Party>
if specified, the payment will be made using only cash issued by the given parties. |
|
val notary: Party?
if not specified, the first notary of the network map is selected for testing purposes. |
|
val recipient: Party
the party to pay the currency to. |
open val progressTracker: ProgressTracker
Override this to provide a ProgressTracker. If one is provided and stepped, the framework will do something helpful with the progress reports e.g record to the audit service. If this flow is invoked as a subflow of another, then the tracker will be made a child of the current step in the parent. If it's null, this flow doesn't track progress. |
open fun call(): Result
This is where you fill out your business logic. |
fun finaliseTx(tx: SignedTransaction, sessions: Collection<FlowSession>, message: String): SignedTransaction |
fun Any.contextLogger(): <ERROR CLASS>
When called from a companion object, returns the logger for the enclosing class. |
|
fun FlowLogic<*>.receiveAll(session: <ERROR CLASS><FlowSession, Class<out Any>>, vararg sessions: <ERROR CLASS><FlowSession, Class<out Any>>): Map<FlowSession, UntrustworthyData<Any>> fun <R : Any> FlowLogic<*>.receiveAll(receiveType: Class<R>, session: FlowSession, vararg sessions: FlowSession): List<UntrustworthyData<R>> fun <R : Any> FlowLogic<*>.receiveAll(session: FlowSession, vararg sessions: FlowSession): List<UntrustworthyData<R>>
Suspends until a message has been received for each session in the specified sessions. |