MCPcopy Index your code
hub / github.com/SpectoLabs/hoverfly / RecordsCount

Method RecordsCount

core/cache/boltdb_cache.go:110–123  ·  view source on GitHub ↗

RecordsCount - returns records count

()

Source from the content-addressed store, hash-verified

108
109// RecordsCount - returns records count
110func (c *BoltCache) RecordsCount() (count int, err error) {
111 err = c.DS.View(func(tx *bolt.Tx) error {
112 b := tx.Bucket(c.CurrentBucket)
113 if b == nil {
114 // bucket doesn't exist
115 return nil
116 }
117
118 count = b.Stats().KeyN
119
120 return nil
121 })
122 return
123}
124
125// Delete - deletes specified key
126func (c *BoltCache) Delete(key []byte) error {

Callers

nothing calls this directly

Calls 1

ViewMethod · 0.65

Tested by

no test coverage detected