Ecosyste.ms: Packages

An open API service providing package, version and dependency metadata of many open source software ecosystems and registries.

Top 4.4% on proxy.golang.org
Top 0.2% dependent packages on proxy.golang.org
Top 0.1% dependent repos on proxy.golang.org
Top 0.4% docker downloads on proxy.golang.org

proxy.golang.org : modernc.org/b

Package b implements the B+tree flavor of a BTree. available at https://modern-c.appspot.com/-/builder/?importpath=modernc.org%2fb 2016-07-16: Update benchmark results to newer Go version. Add a note on concurrency. 2014-06-26: Lower GC presure by recycling things. 2014-04-18: Added new method Put. Tree.{Clear,Delete,Put,Set} mutate the tree. One can use eg. a sync.Mutex.Lock/Unlock (or sync.RWMutex.Lock/Unlock) to wrap those calls if they are to be invoked concurrently. Tree.{First,Get,Last,Len,Seek,SeekFirst,SekLast} read but do not mutate the tree. One can use eg. a sync.RWMutex.RLock/RUnlock to wrap those calls if they are to be invoked concurrently with any of the tree mutating methods. Enumerator.{Next,Prev} mutate the enumerator and read but not mutate the tree. One can use eg. a sync.RWMutex.RLock/RUnlock to wrap those calls if they are to be invoked concurrently with any of the tree mutating methods. A separate mutex for the enumerator, or the whole tree in a simplified variant, is necessary if the enumerator's Next/Prev methods per se are to be invoked concurrently. Keys and their associated values are interface{} typed, similar to all of the containers in the standard library. Semiautomatic production of a type specific variant of this package is supported via This command will write to stdout a version of the btree.go file where every key type occurrence is replaced by the word 'KEY' and every value type occurrence is replaced by the word 'VALUE'. Then you have to replace these tokens with your desired type(s), using any technique you're comfortable with. This is how, for example, 'example/int.go' was created: No other changes to int.go are necessary, it compiles just fine. Running the benchmarks for 1000 keys on a machine with Intel i5-4670 CPU @ 3.4GHz, Go 1.7rc1.

Registry - Source - Documentation - JSON
purl: pkg:golang/modernc.org/b
License: BSD-3-Clause
Latest release: 10 months ago
First release: over 5 years ago
Namespace: modernc.org
Dependent packages: 297
Dependent repositories: 2,791
Stars: 10 on GitLab.com
Forks: 2 on GitLab.com
Docker dependents: 36
Docker downloads: 15,571,946
See more repository details: repos.ecosyste.ms
Last synced: 21 days ago

    Loading...
    Readme
    Loading...