MCPcopy Create free account
hub / github.com/OpenStarbound/OpenStarbound / putAll

Function putAll

source/test/btree_database_test.cpp:38–47  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

36 }
37
38 void putAll(BTreeDatabase& db, const List<uint32_t>& keys) {
39 for (uint32_t k : keys) {
40 ByteArray val = genBlock(k);
41 db.insert(toByteArray(k), val);
42
43 int i = Random::randi32();
44 if (i % 23 == 0)
45 db.commit();
46 }
47 }
48
49 void checkAll(BTreeDatabase& db, const List<uint32_t>& keys) {
50 for (uint32_t k : keys) {

Callers 1

testBTreeDatabaseFunction · 0.70

Calls 5

genBlockFunction · 0.85
toByteArrayFunction · 0.85
randi32Function · 0.85
commitMethod · 0.80
insertMethod · 0.45

Tested by

no test coverage detected