Documentation ¶
Index ¶
- type Config
- type Exporter
- type IavlTree
- func (t *IavlTree) Close() error
- func (t *IavlTree) Commit() ([]byte, uint64, error)
- func (t *IavlTree) Export(version uint64) (commitment.Exporter, error)
- func (t *IavlTree) Get(version uint64, key []byte) ([]byte, error)
- func (t *IavlTree) GetLatestVersion() (uint64, error)
- func (t *IavlTree) GetProof(version uint64, key []byte) (*ics23.CommitmentProof, error)
- func (t *IavlTree) Hash() []byte
- func (t *IavlTree) Import(version uint64) (commitment.Importer, error)
- func (t *IavlTree) Iterator(version uint64, start, end []byte, ascending bool) (corestore.Iterator, error)
- func (t *IavlTree) LoadVersion(version uint64) error
- func (t *IavlTree) LoadVersionForOverwriting(version uint64) error
- func (t *IavlTree) PausePruning(pause bool)
- func (t *IavlTree) Prune(version uint64) error
- func (t *IavlTree) Remove(key []byte) error
- func (t *IavlTree) Set(key, value []byte) error
- func (t *IavlTree) SetInitialVersion(version uint64) error
- func (t *IavlTree) Version() uint64
- func (t *IavlTree) WorkingHash() []byte
- type Importer
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct { CacheSize int `mapstructure:"cache-size" toml:"cache-size" comment:"CacheSize set the size of the iavl tree cache."` SkipFastStorageUpgrade bool `` /* 169-byte string literal not displayed */ }
Config is the configuration for the IAVL tree.
func DefaultConfig ¶
func DefaultConfig() *Config
DefaultConfig returns the default configuration for the IAVL tree.
type Exporter ¶
type Exporter struct {
// contains filtered or unexported fields
}
Exporter is a wrapper around iavl.Exporter.
func (*Exporter) Next ¶
func (e *Exporter) Next() (*snapshotstypes.SnapshotIAVLItem, error)
Next returns the next item in the exporter.
type IavlTree ¶
type IavlTree struct {
// contains filtered or unexported fields
}
IavlTree is a wrapper around iavl.MutableTree.
func NewIavlTree ¶
NewIavlTree creates a new IavlTree instance.
func (*IavlTree) Export ¶
func (t *IavlTree) Export(version uint64) (commitment.Exporter, error)
Export exports the tree exporter at the given version.
func (*IavlTree) GetLatestVersion ¶
GetLatestVersion returns the latest version of the tree.
func (*IavlTree) Import ¶
func (t *IavlTree) Import(version uint64) (commitment.Importer, error)
Import imports the tree importer at the given version.
func (*IavlTree) Iterator ¶
func (t *IavlTree) Iterator(version uint64, start, end []byte, ascending bool) (corestore.Iterator, error)
Iterator implements the Reader interface.
func (*IavlTree) LoadVersion ¶
LoadVersion loads the state at the given version.
func (*IavlTree) LoadVersionForOverwriting ¶
LoadVersionForOverwriting loads the state at the given version. Any versions greater than targetVersion will be deleted.
func (*IavlTree) PausePruning ¶
PausePruning pauses the pruning process.
func (*IavlTree) SetInitialVersion ¶
SetInitialVersion sets the initial version of the database.
func (*IavlTree) WorkingHash ¶
WorkingHash returns the working hash of the tree. Danger! iavl.MutableTree.WorkingHash() is a mutating operation! It advances the tree version by 1.
type Importer ¶
type Importer struct {
// contains filtered or unexported fields
}
Importer is a wrapper around iavl.Importer.
func (*Importer) Add ¶
func (i *Importer) Add(item *snapshotstypes.SnapshotIAVLItem) error
Add adds the given item to the importer.