• Nick Johnson's avatar
    eth/filters: add FindOnce for iterator-like operation (#3435) · 1fe67c12
    Nick Johnson authored
    This commit introduces a FindOnce method for filters. FindOnce finds the next block that
    matches the filter and returns all matching logs from that block. If there are no further
    matching logs, it returns a nil slice. This method allows callers to iterate over large
    sets of logs progressively.
    
    The changes introduce a small inefficiency relating to mipmaps: the first time a filter is
    called, it acts as if all mipmaps are matched, and thus iterates several blocks near the
    requested start point. This is in the interest of simplicity and avoiding duplicate mipmap
    lookups each time FindOnce is called.
    1fe67c12
Name
Last commit
Last update
..
downloader Loading commit data...
fetcher Loading commit data...
filters Loading commit data...
gasprice Loading commit data...
api.go Loading commit data...
api_backend.go Loading commit data...
backend.go Loading commit data...
backend_test.go Loading commit data...
bad_block.go Loading commit data...
bind.go Loading commit data...
db_upgrade.go Loading commit data...
handler.go Loading commit data...
handler_test.go Loading commit data...
helper_test.go Loading commit data...
metrics.go Loading commit data...
peer.go Loading commit data...
protocol.go Loading commit data...
protocol_test.go Loading commit data...
sync.go Loading commit data...
sync_test.go Loading commit data...