Documentation ¶
Index ¶
- Constants
- type BloomFilter
- type FileSet
- type FilterDbFile
- func Open(fileName string, writeable bool) (f *FilterDbFile, err error)
- func OpenEach(fileName string, writeable bool, eacher func(*BloomFilter)) (f *FilterDbFile, err error)
- func OpenEachMaxPayload(fileName string, writeable bool, maxPayloadEacher uint64, ...) (f *FilterDbFile, err error)
- func OpenMaxPayload(fileName string, writeable bool, maxPayloadEacher uint64) (f *FilterDbFile, err error)
Constants ¶
View Source
const ReasonableNoCrashSize = 1000000000 // Giga byte
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BloomFilter ¶
func (*BloomFilter) KeyHash ¶
func (f *BloomFilter) KeyHash() uint64
func (*BloomFilter) PackKeyAndSize ¶
func (f *BloomFilter) PackKeyAndSize() [48]byte
func (*BloomFilter) PayloadSize ¶
func (f *BloomFilter) PayloadSize() uint64
func (*BloomFilter) Serialize ¶
func (f *BloomFilter) Serialize() string
func (*BloomFilter) SerializedSize ¶
func (f *BloomFilter) SerializedSize() uint64
type FileSet ¶
type FileSet map[*FilterDbFile]struct{}
func OpenManyEach ¶
func OpenManyEach(fileNamesWriteable, fileNamesUnwriteable []string, eacher func(*BloomFilter)) (fset FileSet, err error)
func OpenManyEachMaxPayload ¶ added in v0.0.4
func OpenManyEachMaxPayload(fileNamesWriteable, fileNamesUnwriteable []string, maxPayloadEacher uint64, eacher func(*BloomFilter)) (fset FileSet, err error)
func (*FileSet) Add ¶
func (fset *FileSet) Add(filter *BloomFilter) (err error)
func (*FileSet) Get ¶
func (fset *FileSet) Get(blockHash [32]byte, p2wshCount, minPayload, maxPayload uint64) (filter *BloomFilter)
func (*FileSet) GetSmallest ¶ added in v0.0.9
func (fset *FileSet) GetSmallest(blockHash [32]byte, p2wshCount, minPayload, maxPayload uint64) (filter *BloomFilter)
type FilterDbFile ¶
type FilterDbFile struct { Writeable bool Name string Table libcombindex.Table // contains filtered or unexported fields }
func OpenEach ¶
func OpenEach(fileName string, writeable bool, eacher func(*BloomFilter)) (f *FilterDbFile, err error)
func OpenEachMaxPayload ¶ added in v0.0.4
func OpenEachMaxPayload(fileName string, writeable bool, maxPayloadEacher uint64, eacher func(*BloomFilter)) (f *FilterDbFile, err error)
func OpenMaxPayload ¶ added in v0.0.4
func OpenMaxPayload(fileName string, writeable bool, maxPayloadEacher uint64) (f *FilterDbFile, err error)
func (*FilterDbFile) Add ¶
func (ffile *FilterDbFile) Add(filter *BloomFilter) (err error)
func (*FilterDbFile) Get ¶
func (f *FilterDbFile) Get(blockHash [32]byte, p2wshCount, minPayload, maxPayload uint64) (filter *BloomFilter)
Click to show internal directories.
Click to hide internal directories.