Initializer
init(options:)
Creates a chainstate manager from options.
init(options: ChainstateManagerOptions) throws
Parameters
-
options
-
Preconfigured options — including context, data directory, worker-thread count, and in-memory-DB flags.
Discussion
Opens (or creates) the block-index and chainstate LevelDB databases in the paths configured on options. On a fresh data directory this initializes them with the genesis block for the configured ChainType; on an existing directory it loads the state left behind by the previous run.
Throws
KernelError.chainstateManagerCreationFailed if opening the databases fails. Common causes are documented on the error case.