ReceiveFinalityFlow.<init> - corda

corda / net.corda.core.flows / ReceiveFinalityFlow / <init>

# <init>

`ReceiveFinalityFlow(otherSideSession: FlowSession, expectedTxId: SecureHash? = null, statesToRecord: StatesToRecord = ONLY_RELEVANT)`

The receiving counterpart to FinalityFlow.

All parties who are receiving a finalised transaction from a sender flow must subcall this flow in their own flows.

It's typical to have already signed the transaction proposal in the same workflow using SignTransactionFlow. If so then the transaction ID can be passed in as an extra check to ensure the finalised transaction is the one that was signed before it's committed to the vault.

### Parameters

`otherSideSession` - The session which is providing the transaction to record.

`expectedTxId` - Expected ID of the transaction that's about to be received. This is typically retrieved from SignTransactionFlow. Setting it to null disables the expected transaction ID check.

`statesToRecord` - Which states to commit to the vault. Defaults to StatesToRecord.ONLY_RELEVANT.