View definition

(Bucket).CreateBucketIfNotExists

Defined in github.com/btcsuite/btcd/database/interface.go

Description

CreateBucketIfNotExists creates and returns a new nested bucket with the given key if it does not already exist.

The interface contract guarantees at least the following errors will be returned (other implementation-specific errors are possible):

- ErrBucketNameRequired if the key is empty
- ErrIncompatibleValue if the key is otherwise invalid for the
  particular implementation
- ErrTxNotWritable if attempted against a read-only transaction
- ErrTxClosed if the transaction has already been closed

CreateBucketIfNotExists is referenced in 2 repositories

github.com/btcsuite/btcd

...