TransactionBuilder.addOutputState - corda

corda / net.corda.core.transactions / TransactionBuilder / addOutputState

# addOutputState

`fun addOutputState(state: TransactionState<*>): TransactionBuilder`

Adds an output state to the transaction.

`@JvmOverloads fun addOutputState(state: ContractState, contract: ContractClassName = requireNotNullContractClassName(state), notary: Party, encumbrance: Int? = null, constraint: AttachmentConstraint = AutomaticPlaceholderConstraint): TransactionBuilder`

Adds an output state, with associated contract code (and constraints), and notary, to the transaction.

`@JvmOverloads fun addOutputState(state: ContractState, contract: ContractClassName = requireNotNullContractClassName(state), constraint: AttachmentConstraint = AutomaticPlaceholderConstraint): TransactionBuilder`

Adds an output state. A default notary must be specified during builder construction to use this method

`fun addOutputState(state: ContractState, constraint: AttachmentConstraint): TransactionBuilder`

Adds an output state with the specified constraint.