r3prototyping / core.node.services / Wallet

Wallet

data class Wallet

A wallet (name may be temporary) wraps a set of states that are useful for us to keep track of, for instance, because we own them. This class represents an immutable, stable state of a wallet: it is guaranteed not to change out from underneath you, even though the canonical currently-best-known wallet may change as we learn about new transactions from our peers and generate new transactions that consume states ourselves.



Constructors

<init> Wallet(states: List<StateAndRef<OwnableState>>)

A wallet (name may be temporary) wraps a set of states that are useful for us to keep track of, for instance, because we own them. This class represents an immutable, stable state of a wallet: it is guaranteed not to change out from underneath you, even though the canonical currently-best-known wallet may change as we learn about new transactions from our peers and generate new transactions that consume states ourselves.

Properties

states val states: List<StateAndRef<OwnableState>>

Functions

statesOfType fun <T : OwnableState> statesOfType(): List<StateAndRef<T>>