Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Reader ¶
func (*Reader) GetTransactions ¶
func (r *Reader) GetTransactions(entityID ksuid.KSUID) (*Transactions, error)
type State ¶
type State struct { Timestamp time.Time `json:"timestamp"` Balance float64 `json:"balance"` Transactions []Transaction `json:"transactions"` }
type Transaction ¶
type Transaction struct { Timestamp time.Time `json:"timestamp"` SourceEntityID ksuid.KSUID `json:"source_entity_id"` Amount float64 `json:"amount"` }
func NewTransaction ¶
func NewTransaction(sourceEntityID ksuid.KSUID, amount float64) Transaction
type Transactions ¶
type Transactions struct { Timestamp time.Time `json:"timestamp"` Transactions []Transaction `json:"transactions"` }
Click to show internal directories.
Click to hide internal directories.