Versions in this module Expand all Collapse all v3 v3.3.5 May 9, 2020 Changes in this version + const DefaultPoolSize + const DefaultSegmentCount + type BaseHasher func() hash.Hash + type EOC struct + Hash []byte + func NewEOC(hash []byte) *EOC + func (e *EOC) Error() string + type Hasher struct + func New(p *TreePool) *Hasher + func (hr *Hasher) BlockSize() int + func (hr *Hasher) Hash() []byte + func (hr *Hasher) ReadFrom(r io.Reader) (m int64, err error) + func (hr *Hasher) Reset() + func (hr *Hasher) ResetWithLength(l []byte) + func (hr *Hasher) Size() int + func (hr *Hasher) Sum(b []byte) (r []byte) + func (hr *Hasher) Write(b []byte) (int, error) + type Node struct + func NewNode(level, index int, parent *Node) *Node + type RefHasher struct + func NewRefHasher(hasher BaseHasher, count int) *RefHasher + func (rh *RefHasher) Hash(d []byte) []byte + type Tree struct + func NewTree(hasher BaseHasher, segmentSize, segmentCount int) *Tree + func (t *Tree) Draw(hash []byte, d int) string + type TreePool struct + Capacity int + SegmentCount int + SegmentSize int + func NewTreePool(hasher BaseHasher, segmentCount, capacity int) *TreePool + func (tp *TreePool) Drain(n int) + func (tp *TreePool) Release(t *Tree) + func (tp *TreePool) Reserve() *Tree Other modules containing this package github.com/beyonderyue/gochain