Documentation ¶
Index ¶
Constants ¶
View Source
const ( // FTBloom indicates the TxFilter's Filter is a bloom filter. FTBloom = iota // FTTxType indicates the TxFilter's Filter is a transaction type filter. FTTxType )
Variables ¶
This section is empty.
Functions ¶
func CheckMerkleBlock ¶
func CheckMerkleBlock(m msg.MerkleBlock) ([]*common.Uint256, error)
take in a merkle block, parse through it, and return txids indicated If there's any problem return an error. Checks self-consistency only. doing it with a stack instead of recursion. Because... OK I don't know why I'm just not in to recursion OK?
func NewMerkleBlock ¶
NewMerkleBlock returns a new *MerkleBlock
Types ¶
type Filter ¶
type Filter struct {
// contains filtered or unexported fields
}
func New ¶
func New(newFilter func(filterType TxFilterType) TxFilter) *Filter
type TxFilter ¶
type TxFilter interface { // Load loads the transaction filter. Load(filter []byte) error // Add adds new data into filter. Add(data []byte) error // Match returns if a transaction matches the filter. Match(tx *types.Transaction) bool }
TxFilter indicates the methods a transaction filter should implement.
func NewTxTypeFilter ¶
func NewTxTypeFilter() TxFilter
type TxFilterType ¶
type TxFilterType uint8
func (TxFilterType) String ¶
func (f TxFilterType) String() string
String returns the TxFilterType in human-readable form.
Click to show internal directories.
Click to hide internal directories.