Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Database ¶
type Database struct {
// contains filtered or unexported fields
}
Database is an in-memory implementation of HeightIndex. It provides thread-safe height-based key-value storage for testing and high-performance paths.
func (*Database) Close ¶
Close releases resources and clears all stored data. Subsequent operations will return database.ErrClosed.
func (*Database) Delete ¶
Delete removes the value at the given height. Does not return an error if the height does not exist.
func (*Database) Get ¶
Get retrieves the value at the given height. Returns database.ErrNotFound if the height does not exist. The returned byte slice is safe to read, but cannot be modified.
Click to show internal directories.
Click to hide internal directories.