core / WireTransaction

# WireTransaction

`data class WireTransaction : NamedByHash`

Transaction ready for serialisation, without any signatures attached.

### Constructors

<init> | `WireTransaction(inputs: List<StateRef>, attachments: List<SecureHash>, outputs: List<ContractState>, commands: List<Command>)` Transaction ready for serialisation, without any signatures attached.

### Properties

attachments | `val attachments: List<SecureHash>`
commands | `val commands: List<Command>`
id | `val id: SecureHash`
inputs | `val inputs: List<StateRef>`
outputs | `val outputs: List<ContractState>`
serialized | `val serialized: SerializedBytes<WireTransaction>`

### Functions

outRef | `fun <T : ContractState> outRef(index: Int): StateAndRef<T>` Returns a StateAndRef for the given output index. `fun <T : ContractState> outRef(state: ContractState): StateAndRef<T>` Returns a StateAndRef for the requested output state, or throws IllegalArgumentException if not found.
toString | `fun toString(): String`

### Companion Object Functions

deserialize | `fun deserialize(bits: SerializedBytes<WireTransaction>, kryo: <ERROR CLASS> = THREAD_LOCAL_KRYO.get()): WireTransaction`

### Extension Functions

toLedgerTransaction | `fun WireTransaction.toLedgerTransaction(identityService: IdentityService, attachmentStorage: AttachmentStorage): LedgerTransaction` Looks up identities and attachments from storage to generate a LedgerTransaction.