Documentation ¶
Index ¶
- type BlockNumPlugin
- type IBlockPlugin
- type IReceiptLogPlugin
- type ITxPlugin
- type ITxReceiptPlugin
- type ReceiptLogPlugin
- func (p *ReceiptLogPlugin) Accept(receiptLog *structs.RemovableReceiptLog)
- func (p *ReceiptLogPlugin) AddInterestedTopics(position int, topics []common.Hash)
- func (p *ReceiptLogPlugin) FromContracts() []common.Address
- func (p *ReceiptLogPlugin) InterestedTopics() [][]common.Hash
- func (p *ReceiptLogPlugin) NeedReceiptLog(receiptLog *structs.RemovableReceiptLog) bool
- func (p *ReceiptLogPlugin) RemoveInterestedTopics(position int, topics []common.Hash)
- type SimpleBlockPlugin
- type TxHashPlugin
- type TxPlugin
- type TxReceiptPlugin
- type TxReceiptPluginWithFilter
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BlockNumPlugin ¶
type BlockNumPlugin struct {
// contains filtered or unexported fields
}
func NewBlockNumPlugin ¶
func NewBlockNumPlugin(callback func(uint64, bool)) BlockNumPlugin
func (BlockNumPlugin) AcceptBlock ¶
func (p BlockNumPlugin) AcceptBlock(b *structs.RemovableBlock)
type IBlockPlugin ¶
type IBlockPlugin interface {
AcceptBlock(block *structs.RemovableBlock)
}
type IReceiptLogPlugin ¶
type IReceiptLogPlugin interface { FromContracts() []common.Address InterestedTopics() [][]common.Hash NeedReceiptLog(receiptLog *structs.RemovableReceiptLog) bool Accept(receiptLog *structs.RemovableReceiptLog) }
type ITxPlugin ¶
type ITxPlugin interface {
AcceptTx(transaction structs.RemovableTx)
}
type ITxReceiptPlugin ¶
type ITxReceiptPlugin interface {
Accept(tx *structs.RemovableTxAndReceipt)
}
type ReceiptLogPlugin ¶
type ReceiptLogPlugin struct {
// contains filtered or unexported fields
}
func NewReceiptLogPlugin ¶
func NewReceiptLogPlugin( contracts []common.Address, topics [][]common.Hash, callback func(receiptLog *structs.RemovableReceiptLog), ) *ReceiptLogPlugin
func (*ReceiptLogPlugin) Accept ¶
func (p *ReceiptLogPlugin) Accept(receiptLog *structs.RemovableReceiptLog)
func (*ReceiptLogPlugin) AddInterestedTopics ¶
func (p *ReceiptLogPlugin) AddInterestedTopics(position int, topics []common.Hash)
AddInterestedTopics add more topics to match indexed topic in given position (0 based)
func (*ReceiptLogPlugin) FromContracts ¶
func (p *ReceiptLogPlugin) FromContracts() []common.Address
func (*ReceiptLogPlugin) InterestedTopics ¶
func (p *ReceiptLogPlugin) InterestedTopics() [][]common.Hash
func (*ReceiptLogPlugin) NeedReceiptLog ¶
func (p *ReceiptLogPlugin) NeedReceiptLog(receiptLog *structs.RemovableReceiptLog) bool
simplified version of specifying topic filters https://github.com/ethereum/wiki/wiki/JSON-RPC#a-note-on-specifying-topic-filters
func (*ReceiptLogPlugin) RemoveInterestedTopics ¶
func (p *ReceiptLogPlugin) RemoveInterestedTopics(position int, topics []common.Hash)
RemoveInterestedTopics remove topics to match indexed topic in given position (0 based)
type SimpleBlockPlugin ¶
type SimpleBlockPlugin struct {
// contains filtered or unexported fields
}
provide block info with tx basic infos
func NewSimpleBlockPlugin ¶
func NewSimpleBlockPlugin(callback func(block *structs.RemovableBlock)) SimpleBlockPlugin
func (SimpleBlockPlugin) AcceptBlock ¶
func (p SimpleBlockPlugin) AcceptBlock(b *structs.RemovableBlock)
type TxHashPlugin ¶
type TxHashPlugin struct {
// contains filtered or unexported fields
}
func NewTxHashPlugin ¶
func NewTxHashPlugin(callback func(txHash common.Hash, isRemoved bool)) TxHashPlugin
func (TxHashPlugin) AcceptTx ¶
func (p TxHashPlugin) AcceptTx(transaction structs.RemovableTx)
type TxPlugin ¶
type TxPlugin struct {
// contains filtered or unexported fields
}
func NewTxPlugin ¶
func NewTxPlugin(callback func(tx structs.RemovableTx)) TxPlugin
func (TxPlugin) AcceptTx ¶
func (p TxPlugin) AcceptTx(transaction structs.RemovableTx)
type TxReceiptPlugin ¶
type TxReceiptPlugin struct {
// contains filtered or unexported fields
}
func NewTxReceiptPlugin ¶
func NewTxReceiptPlugin(callback func(tx *structs.RemovableTxAndReceipt)) *TxReceiptPlugin
func (TxReceiptPlugin) Accept ¶
func (p TxReceiptPlugin) Accept(tx *structs.RemovableTxAndReceipt)
type TxReceiptPluginWithFilter ¶
type TxReceiptPluginWithFilter struct { ITxReceiptPlugin // contains filtered or unexported fields }
func NewTxReceiptPluginWithFilter ¶
func NewTxReceiptPluginWithFilter( callback func(tx *structs.RemovableTxAndReceipt), filterFunc func(transaction *types.Transaction) bool) *TxReceiptPluginWithFilter
func (TxReceiptPluginWithFilter) NeedReceipt ¶
func (p TxReceiptPluginWithFilter) NeedReceipt(tx *types.Transaction) bool
Click to show internal directories.
Click to hide internal directories.