Bucket retrieves a bucket by name. Returns nil if the bucket does not exist. The bucket instance is only valid for the lifetime of the transaction.
(name []byte)
| 109 | // Returns nil if the bucket does not exist. |
| 110 | // The bucket instance is only valid for the lifetime of the transaction. |
| 111 | func (tx *Tx) Bucket(name []byte) *Bucket { |
| 112 | return tx.root.Bucket(name) |
| 113 | } |
| 114 | |
| 115 | // CreateBucket creates a new bucket. |
| 116 | // Returns an error if the bucket already exists, if the bucket name is blank, or if the bucket name is too long. |
no outgoing calls