Documentation ¶
Overview ¶
uses crc64 of recent blocks to produce a deterministic number for the issue hashing verification system
Index ¶
- Constants
- func CRC(height uint64, packed []byte) uint64
- func Clear(log *logger.L) error
- func DigestForBlock(number uint64) *blockdigest.Digest
- func Finalise() error
- func GetLatestCRC() uint64
- func Initialise() error
- func Put(number uint64, digest blockdigest.Digest, packedBlock []byte)
- type RingReader
Constants ¶
View Source
const (
Size = 20 // size of ring buffer
)
internal constants
Variables ¶
This section is empty.
Functions ¶
func DigestForBlock ¶
func DigestForBlock(number uint64) *blockdigest.Digest
fetch a digest from the ring if present
Types ¶
type RingReader ¶
type RingReader struct {
// contains filtered or unexported fields
}
to iterate though the ring
func (*RingReader) GetCRC ¶ added in v0.5.7
func (r *RingReader) GetCRC() uint64
read the fetched value
func (*RingReader) Next ¶ added in v0.5.7
func (r *RingReader) Next() bool
fetch item from ring works in reverse, fetching older items
Click to show internal directories.
Click to hide internal directories.