Companion

object Companion

Properties

Link copied to clipboard

The empty ledger: no topology, no supply, no accounting. The lattice bottom.

Functions

Link copied to clipboard

A ledger seeded with root supply for one mint act: each (replica, amount) in mint becomes a MintRecord credited to that replica, keyed by a MintId unique to this act.

Link copied to clipboard
fun of(records: Map<AttachmentId, Set<AttachmentRecord>> = emptyMap(), minted: Map<MintId, MintRecord> = emptyMap(), issued: Map<AttachmentId, GCounter> = emptyMap(), returned: Map<AttachmentId, GCounter> = emptyMap(), leafSpent: Map<AttachmentId, GCounter> = emptyMap(), rollupSpent: Map<AttachmentId, GCounter> = emptyMap(), transfers: Map<PathKey, Map<ReplicaId, GCounter>> = emptyMap(), lifecycle: Map<AttachmentId, Lifecycle> = emptyMap(), issuedRelocIn: Map<AttachmentId, GCounter> = emptyMap(), leafRelocIn: Map<AttachmentId, GCounter> = emptyMap(), leafRelocOut: Map<AttachmentId, GCounter> = emptyMap(), rollupRelocIn: Map<AttachmentId, GCounter> = emptyMap(), rollupRelocOut: Map<AttachmentId, GCounter> = emptyMap(), gauges: Map<AttachmentId, Gauge> = emptyMap(), transferRelocIn: Map<PathKey, Map<ReplicaId, GCounter>> = emptyMap(), transferRelocOut: Map<PathKey, Map<ReplicaId, GCounter>> = emptyMap(), @IntroducedAt(version = "0.7.5") forgottenOutflow: Map<GroupId, Map<ReplicaId, Long>> = emptyMap(), @IntroducedAt(version = "0.7.5") forgottenLeafSpend: Map<ReplicaId, Long> = emptyMap(), @IntroducedAt(version = "0.7.5") forgottenGenerationFloor: Long = -1L, @IntroducedAt(version = "0.7.5") origins: Map<GroupId, Int128> = emptyMap()): EntitlementLedger

Directly assemble a ledger from its components. internal — the public way to build a non-trivial ledger is via the mutators (a later phase); this exists so this phase's lattice-law tests can construct arbitrary states of the still-inert lattice.