com.r3corda.core.contracts / DealState

# DealState

`interface DealState : LinearState`

Interface representing an agreement that exposes various attributes that are common. Implementing it simplifies implementation of general protocols that manipulate many agreement types.

### Properties

parties | `abstract val parties: List<Party>` Exposes the Parties involved in a generic way
ref | `abstract val ref: String` Human readable well known reference (e.g. trade reference)

### Inherited Properties

linearId | `abstract val linearId: UniqueIdentifier` Unique id shared by all LinearState states throughout history within the wallets of all parties. Verify methods should check that one input and one output share the id in a transaction, except at issuance/termination.

### Functions

generateAgreement | `abstract fun generateAgreement(notary: Party): TransactionBuilder` Generate a partial transaction representing an agreement (command) to this deal, allowing a general deal/agreement protocol to generate the necessary transaction for potential implementations.
withPublicKey | `abstract fun withPublicKey(before: Party, after: PublicKey): DealState`

### Inherited Functions

isRelevant | `abstract fun isRelevant(ourKeys: Set<PublicKey>): Boolean` True if this should be tracked by our wallet(s).

### Extension Functions

hash | `fun ContractState.hash(): SecureHash` Returns the SHA-256 hash of the serialised contents of this state (not cached)

### Inheritors

FixableDealState | `interface FixableDealState : DealState` Interface adding fixing specific methods.