Documentation ¶
Index ¶
- type Cache
- func (c *Cache) AddClaimInfo(claimInfo *types.ClaimInfo)
- func (c *Cache) AddSwapInfo(swapInfo *types.SwapInfo)
- func (c *Cache) AddTransaction(transaction []*types.Transaction)
- func (c *Cache) Flush()
- func (c *Cache) GetClaimInfos() []*types.ClaimInfo
- func (c *Cache) GetSwapInfos() []*types.SwapInfo
- func (c *Cache) GetTransactions() []*types.Transaction
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Cache ¶
type Cache struct { // Flush at EndBlock Transactions []*types.Transaction // persist in memory LatestTicker map[string]*types.Ticker // contains filtered or unexported fields }
Cache defines struct to store data in memory
func (*Cache) AddClaimInfo ¶
AddClaimInfo appends claimInfo to cache ClaimInfos
func (*Cache) AddSwapInfo ¶
AddSwapInfo appends swapInfo to cache SwapInfos
func (*Cache) AddTransaction ¶
func (c *Cache) AddTransaction(transaction []*types.Transaction)
AddTransaction append transaction to cache Transactions
Click to show internal directories.
Click to hide internal directories.