MCPcopy Create free account
hub / github.com/BaseXdb/basex / indexFor

Method indexFor

basex-core/src/main/java/org/basex/index/IndexCache.java:199–201  ·  view source on GitHub ↗

Returns buckets index for a hash code. @param h hash code @param n number of available buckets @return index of a buckets

(final int h, final int n)

Source from the content-addressed store, hash-verified

197 * @return index of a buckets
198 */
199 private static int indexFor(final int h, final int n) {
200 return h & n - 1;
201 }
202
203 /**
204 * Cache buckets entry. Used to implement a linked list of cache entries for each bucket.

Callers 5

getMethod · 0.95
addMethod · 0.95
deleteMethod · 0.95
purgeMethod · 0.95
rehashMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected