MCPcopy Create free account
hub / github.com/antlr/codebuff / initTable

Method initTable

output/java_guava/1.4.13/LocalCache.java:2199–2206  ·  view source on GitHub ↗
(AtomicReferenceArray<ReferenceEntry<K, V>> newTable)

Source from the content-addressed store, hash-verified

2197
2198
2199 void initTable(AtomicReferenceArray<ReferenceEntry<K, V>> newTable) {
2200 this.threshold = newTable.length() * 3 / 4; // 0.75
2201 if (!map.customWeigher() && this.threshold == maxSegmentWeight) {
2202 // prevent spurious expansion before eviction
2203 this.threshold++;
2204 }
2205 this.table = newTable;
2206 }
2207
2208 @GuardedBy("this")
2209 ReferenceEntry<K, V> newEntry(K key, int hash, @Nullable ReferenceEntry<K, V> next) {

Callers 1

SegmentMethod · 0.95

Calls 2

lengthMethod · 0.45
customWeigherMethod · 0.45

Tested by

no test coverage detected