com.r3corda.protocols / AbstractStateReplacementProtocol

# AbstractStateReplacementProtocol

`abstract class AbstractStateReplacementProtocol<T>`

Abstract protocol to be used for replacing one state with another, for example when changing the notary of a state. Notably this requires a one to one replacement of states, states cannot be split, merged or issued as part of these protocols.

The Instigator assembles the transaction for state replacement and sends out change proposals to all participants (Acceptor) of that state. If participants agree to the proposed change, they each sign the transaction. Finally, Instigator sends the transaction containing all signatures back to each participant so they can record it and use the new updated state for future transactions.

### Types

Acceptor | `abstract class Acceptor<T> : ProtocolLogic<Unit>`
Instigator | `abstract class Instigator<out S : ContractState, T> : ProtocolLogic<StateAndRef<S>>`
Proposal | `interface Proposal<out T>`
Result | `data class Result`

### Constructors

<init> | `AbstractStateReplacementProtocol()` Abstract protocol to be used for replacing one state with another, for example when changing the notary of a state. Notably this requires a one to one replacement of states, states cannot be split, merged or issued as part of these protocols.

### Inheritors

NotaryChangeProtocol | `object NotaryChangeProtocol : AbstractStateReplacementProtocol<Party>` A protocol to be used for changing a states Notary. This is required since all input states to a transaction must point to the same notary.