Documentation ¶
Index ¶
- type BlockBatch
- type Event
- type EventCriteria
- type EventFilter
- type LogDB
- func (db *LogDB) Close()
- func (db *LogDB) FilterEvents(ctx context.Context, filter *EventFilter) ([]*Event, error)
- func (db *LogDB) FilterTransfers(ctx context.Context, filter *TransferFilter) ([]*Transfer, error)
- func (db *LogDB) Path() string
- func (db *LogDB) Prepare(header *block.Header) *BlockBatch
- type Options
- type Order
- type Range
- type RangeType
- type Transfer
- type TransferCriteria
- type TransferFilter
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BlockBatch ¶
type BlockBatch struct {
// contains filtered or unexported fields
}
func (*BlockBatch) ForTransaction ¶
func (bb *BlockBatch) ForTransaction(txID meter.Bytes32, txOrigin meter.Address) struct { Insert func(tx.Events, tx.Transfers) *BlockBatch }
type Event ¶
type Event struct { BlockID meter.Bytes32 Index uint32 BlockNumber uint32 BlockTime uint64 TxID meter.Bytes32 TxOrigin meter.Address //contract caller Address meter.Address // always a contract address Topics [5]*meter.Bytes32 Data []byte }
Event represents tx.Event that can be stored in db.
type EventCriteria ¶
type EventFilter ¶
type EventFilter struct { CriteriaSet []*EventCriteria Range *Range Options *Options Order Order //default asc }
EventFilter filter
type LogDB ¶
type LogDB struct {
// contains filtered or unexported fields
}
var (
GlobalLogDBInstance *LogDB
)
func GetGlobalLogDBInstance ¶
func GetGlobalLogDBInstance() *LogDB
func (*LogDB) FilterEvents ¶
func (*LogDB) FilterTransfers ¶
type Transfer ¶
type Transfer struct { BlockID meter.Bytes32 Index uint32 BlockNumber uint32 BlockTime uint64 TxID meter.Bytes32 TxOrigin meter.Address Sender meter.Address Recipient meter.Address Amount *big.Int Token uint32 }
Transfer represents tx.Transfer that can be stored in db.
type TransferCriteria ¶
type TransferFilter ¶
Click to show internal directories.
Click to hide internal directories.