MCPcopy
hub / github.com/etcd-io/bbolt / Allocate

Method Allocate

internal/freelist/freelist.go:28–28  ·  view source on GitHub ↗

Allocate tries to allocate the given number of contiguous pages from the free list pages. It returns the starting page ID if available; otherwise, it returns 0.

(txid common.Txid, numPages int)

Source from the content-addressed store, hash-verified

26 // from the free list pages. It returns the starting page ID if
27 // available; otherwise, it returns 0.
28 Allocate(txid common.Txid, numPages int) common.Pgid
29
30 // Count returns the number of free and pending pages.
31 Count() int

Calls

no outgoing calls