@StartableByRPC class CashIssueAndPaymentFlow : AbstractCashFlow<Result>
Initiates a flow that self-issues cash and then send this to a recipient.
We issue cash only to ourselves so that all KYC/AML checks on payments are enforced consistently, rather than risk checks for issuance and payments differing. Outside of test scenarios it would be extremely unusual to issue cash and immediately transfer it, so impact of this limitation is considered minimal.
amount
- the amount of currency to issue.
issueRef
- a reference to put on the issued currency.
recipient
- the recipient of the currency
anonymous
- if true, the recipient of the cash will be anonymous. Should be true for normal usage
notary
- the notary to set on the output states.
IssueAndPaymentRequest |
class IssueAndPaymentRequest : AbstractRequest |
<init> |
CashIssueAndPaymentFlow(amount: Amount<Currency>, issueRef: OpaqueBytes, recipient: Party, anonymous: Boolean, notary: Party) CashIssueAndPaymentFlow(request: IssueAndPaymentRequest)
Initiates a flow that self-issues cash and then send this to a recipient. CashIssueAndPaymentFlow(amount: Amount<Currency>, issueRef: OpaqueBytes, recipient: Party, anonymous: Boolean, notary: Party, progressTracker: ProgressTracker) |
amount |
the amount of currency to issue. val amount: Amount<Currency> |
anonymous |
if true, the recipient of the cash will be anonymous. Should be true for normal usage val anonymous: Boolean |
issueRef |
a reference to put on the issued currency. val issueRef: OpaqueBytes |
notary |
the notary to set on the output states. val notary: Party |
recipient |
the recipient of the currency val recipient: Party |
call |
This is where you fill out your business logic. fun call(): Result |
ISSUING_CASH |
val ISSUING_CASH: Step |
PAYING_RECIPIENT |
val PAYING_RECIPIENT: Step |
tracker |
fun tracker(): ProgressTracker |
receiveAll |
Suspends until a message has been received for each session in the specified sessions. fun FlowLogic<*>.receiveAll(session: Pair<FlowSession, Class<out Any>>, vararg sessions: Pair<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>> |