Skip to content

Commit

Permalink
Added comment around usage of 'parties' in DealStates.
Browse files Browse the repository at this point in the history
  • Loading branch information
RogerWillis committed Nov 21, 2016
1 parent e34820a commit 1be32da
Showing 1 changed file with 13 additions and 1 deletion.
14 changes: 13 additions & 1 deletion core/src/main/kotlin/net/corda/core/contracts/Structures.kt
Original file line number Diff line number Diff line change
Expand Up @@ -276,7 +276,19 @@ interface DealState : LinearState {
/** Human readable well known reference (e.g. trade reference) */
val ref: String

/** Exposes the Parties involved in a generic way */
/**
* Exposes the Parties involved in a generic way.
*
* Appears to duplicate [participants] a property of [ContractState]. However [participants] only holds public keys.
* Currently we need to hard code Party objects into [ContractState]s. [Party] objects are a wrapper for public
* keys which also contain some identity information about the public key owner. You can keep track of individual
* parties by adding a property for each one to the state, or you can append parties to the [parties] list if you
* are implementing [DealState]. We need to do this as identity management in Corda is currently incomplete,
* therefore the only way to record identity information is in the [ContractState]s themselves. When identity
* management is completed, parties to a transaction will only record public keys in the [DealState] and through a
* separate process exchange certificates to ascertain identities. Thus decoupling identities from
* [ContractState]s.
* */
val parties: List<Party>

/**
Expand Down

0 comments on commit 1be32da

Please sign in to comment.