{"modulePath":"github.com/onflow/flow-archive","version":"v0.31.9-decrease-wait-interval","isLatest":false,"isStandardLibrary":false,"goos":"all","goarch":"all","docs":"# package util\n\n## Functions\n\n```go\nfunc ValidateHeightIndexed(reader archive.Reader, height uint64) error\n```\n\n## Types\n\n```go\ntype Batch struct {\n\t// contains filtered or unexported fields\n}\n```\n\n```go\nfunc NewBatch(db *badger.DB) *Batch\n```\n\n```go\nfunc (b *Batch) Flush() error\n```\nFlush will call the badger Batch's Flush method, in addition, it will call the callbacks added by OnSucceed\n\n```go\nfunc (b *Batch) GetWriter() *badger.WriteBatch\n```\n\n```go\nfunc (b *Batch) OnSucceed(callback func())\n```\nOnSucceed adds a callback to execute after the batch has been successfully flushed. useful for implementing the cache where we will only cache after the batch has been successfully flushed\n\n","path":"github.com/onflow/flow-archive/util","name":"util","synopsis":"","isRedistributable":true}
