MCPcopy Create free account
hub / github.com/devaccuracy/ledgerforge / Distribution

Struct Distribution

model/transaction.go:38–43  ·  view source on GitHub ↗

Distribution defines how a transaction amount is allocated to a specific source or destination.

Source from the content-addressed store, hash-verified

36
37// Distribution defines how a transaction amount is allocated to a specific source or destination.
38type Distribution struct {
39 Identifier string `json:"identifier"`
40 Distribution string `json:"distribution"` // Can be a percentage (e.g., "10%"), a fixed amount (e.g., "100"), or "left"
41 PreciseDistribution string `json:"precise_distribution,omitempty"` // Fixed amount in minor units (e.g., "1006" for 1006 cents)
42 TransactionID string `json:"transaction_id"`
43}
44
45// distributionState holds the shared state during distribution calculation
46type distributionState struct {

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected