Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/bnyeggen/lash
/ functions
Functions
230 in github.com/bnyeggen/lash
⨍
Functions
230
◇
Types & classes
32
↓ 28 callers
Method
getLong
(long pos)
src/main/java/com/nyeggen/lash/util/MMapper.java:137
↓ 27 callers
Method
longToBytes
(long i)
src/main/java/com/nyeggen/lash/util/InsertHelper.java:10
↓ 25 callers
Method
getNextRecordPos
()
src/main/java/com/nyeggen/lash/bucket/RecordChainNode.java:28
↓ 23 callers
Method
putLong
(long pos, long val)
src/main/java/com/nyeggen/lash/util/MMapper.java:152
↓ 19 callers
Method
size
Number of inserted records. O(1).
src/main/java/com/nyeggen/lash/IDiskMap.java:35
↓ 18 callers
Method
getSecondaryRecord
Retrieves a record at the given position from the secondary. Does not validate the correctness of the position.
src/main/java/com/nyeggen/lash/VarSizeDiskMap.java:51
↓ 17 callers
Method
get
Returns the value corresponding to the given key, or null if it is not present. Zero-width values (ie, a hash set) are supported.
src/main/java/com/nyeggen/lash/IDiskMap.java:10
↓ 16 callers
Method
getUnsafe
()
src/main/java/com/nyeggen/lash/util/MMapper.java:203
↓ 16 callers
Method
murmurHash
Utility to hash a single value
src/main/java/com/nyeggen/lash/util/Hash.java:20
↓ 15 callers
Method
lockForHash
Returns the lock for the stripe for the given hash. Synchronize of this object before mutating the map.
src/main/java/com/nyeggen/lash/ADiskMap.java:92
↓ 14 callers
Method
getByteArrayOffset
()
src/main/java/com/nyeggen/lash/util/MMapper.java:206
↓ 14 callers
Method
toBytes
(T t)
src/main/java/com/nyeggen/lash/serde/Serde.java:10
↓ 12 callers
Method
idxToPos
(long idx)
src/main/java/com/nyeggen/lash/VarSizeDiskMap.java:46
↓ 12 callers
Method
writeRecord
Inserts the given record at the optimal position in the bucket. Throws IllegalStateException if you insert into a full bucket.
src/main/java/com/nyeggen/lash/BucketDiskMap.java:468
↓ 11 callers
Method
put
Inserts the given record in the map, and returns the previous value associated with the given key, or null if there was none.
src/main/java/com/nyeggen/lash/IDiskMap.java:13
↓ 10 callers
Method
getVal
(MMapper mapper)
src/main/java/com/nyeggen/lash/bucket/RecordPtr.java:49
↓ 10 callers
Method
getValue
()
src/main/java/com/nyeggen/lash/BucketDiskMap.java:400
↓ 10 callers
Method
remove
Remove the record associated with the given key, returning the previous value, or null if there was none.
src/main/java/com/nyeggen/lash/IDiskMap.java:20
↓ 9 callers
Method
nextBucket
Returns the next bucket in the chain, or null if there is none.
src/main/java/com/nyeggen/lash/BucketDiskMap.java:460
↓ 9 callers
Method
putBytes
(long pos, byte[] data)
src/main/java/com/nyeggen/lash/util/MMapper.java:163
↓ 8 callers
Method
bytesToLong
(byte[] b)
src/main/java/com/nyeggen/lash/util/InsertHelper.java:17
↓ 8 callers
Method
getKey
(MMapper mapper)
src/main/java/com/nyeggen/lash/bucket/RecordPtr.java:44
↓ 8 callers
Method
idxForHash
Returns the bucket index for the given hash. This doesn't lock - because it depends on tableLength, callers should establish some lock that precludes
src/main/java/com/nyeggen/lash/ADiskMap.java:100
↓ 7 callers
Method
fromBytes
(byte[] d)
src/main/java/com/nyeggen/lash/serde/Serde.java:11
↓ 7 callers
Method
hasNext
()
src/main/java/com/nyeggen/lash/DiskMap.java:195
↓ 7 callers
Method
iterator
Returns an iterator over key-value pairs. Neither the returned iterator nor the Map.Entry values iterated over support mutation.
src/main/java/com/nyeggen/lash/IDiskMap.java:39
↓ 7 callers
Method
keyEquals
(long oHash, byte[] oKey)
src/main/java/com/nyeggen/lash/bucket/RecordChainNode.java:34
↓ 7 callers
Method
locateRecord
Runs a search over all buckets in a chain.
src/main/java/com/nyeggen/lash/BucketDiskMap.java:93
↓ 7 callers
Method
next
()
src/main/java/com/nyeggen/lash/DiskMap.java:199
↓ 7 callers
Method
setNextRecordPos
(long nRecPos)
src/main/java/com/nyeggen/lash/bucket/WritethruRecordChainNode.java:44
↓ 7 callers
Method
writeRecord
(RecordChainNode rec, MMapper m, long pos)
src/main/java/com/nyeggen/lash/bucket/WritethruRecordChainNode.java:60
↓ 6 callers
Method
createTempDir
After Java 7, this is a built-in. We put it here so it's available for testing.
src/main/java/com/nyeggen/lash/util/MMapper.java:188
↓ 6 callers
Method
delete
Removes the associated data files, and base folder if it is empty.
src/main/java/com/nyeggen/lash/ADiskMap.java:223
↓ 6 callers
Method
writeKeyVal
(byte[] k, byte[] v)
src/main/java/com/nyeggen/lash/BucketDiskMap.java:309
↓ 5 callers
Method
allocateForRecord
Allocates sufficient space for the record to be written to secondary / at the returned position.
src/main/java/com/nyeggen/lash/VarSizeDiskMap.java:62
↓ 5 callers
Method
clear
()
src/main/java/com/nyeggen/lash/IDiskMap.java:36
↓ 5 callers
Method
close
()
src/main/java/com/nyeggen/lash/DiskMap.java:42
↓ 5 callers
Method
entrySet
()
src/main/java/com/nyeggen/lash/DiskMap.java:92
↓ 5 callers
Method
equals
(Object obj)
src/main/java/com/nyeggen/lash/DiskMap.java:116
↓ 5 callers
Method
get
(byte[] k)
src/main/java/com/nyeggen/lash/BucketDiskMap.java:176
↓ 5 callers
Method
getBytes
(long pos, byte[] data)
src/main/java/com/nyeggen/lash/util/MMapper.java:158
↓ 5 callers
Method
getInt
(long pos)
src/main/java/com/nyeggen/lash/util/MMapper.java:132
↓ 5 callers
Method
getPointer
Returns the (possibly free or deleted) record pointer at the given index in this bucket.
src/main/java/com/nyeggen/lash/BucketDiskMap.java:543
↓ 5 callers
Method
putInt
(long pos, int val)
src/main/java/com/nyeggen/lash/util/MMapper.java:147
↓ 5 callers
Method
setNextRecordPos
(long nRecPos)
src/main/java/com/nyeggen/lash/bucket/RecordChainNode.java:29
↓ 4 callers
Method
close
()
src/main/java/com/nyeggen/lash/util/MMapper.java:117
↓ 4 callers
Method
load
"Fullness" of the table. Some implementations may wish to override this to account for multiple records per bucket.
src/main/java/com/nyeggen/lash/ADiskMap.java:239
↓ 4 callers
Method
rehash
Perform incremental rehashing to keep the load under the threshold.
src/main/java/com/nyeggen/lash/ADiskMap.java:125
↓ 4 callers
Method
subPosForSubIdx
Absolute position of the nth record in the bucket at the given pos
src/main/java/com/nyeggen/lash/BucketDiskMap.java:428
↓ 3 callers
Method
allocateNextBucket
Sets the nextBucketPos to a new empty bucket, either freshly allocated from secondary or pulled from the free list. Calling this on a bucket with an e
src/main/java/com/nyeggen/lash/BucketDiskMap.java:532
↓ 3 callers
Method
allocateSecondary
Allocates the given amount of space in secondary storage, and returns a pointer to it. Expands secondary storage if necessary.
src/main/java/com/nyeggen/lash/ADiskMap.java:157
↓ 3 callers
Method
containsKey
Returns true if the given key is mapped in the table.
src/main/java/com/nyeggen/lash/IDiskMap.java:33
↓ 3 callers
Method
equals
Requires same class, reference equality for enclosing map, and the same k and v.
src/main/java/com/nyeggen/lash/BucketDiskMap.java:387
↓ 3 callers
Method
getHeaderSize
Size of the header (stored in the first part of the secondary file).
src/main/java/com/nyeggen/lash/ADiskMap.java:68
↓ 3 callers
Method
hasNext
()
src/main/java/com/nyeggen/lash/BucketDiskMap.java:342
↓ 3 callers
Method
isEmpty
()
src/main/java/com/nyeggen/lash/DiskMap.java:72
↓ 3 callers
Method
put
(byte[] k, byte[] v)
src/main/java/com/nyeggen/lash/BucketDiskMap.java:185
↓ 3 callers
Method
replace
Replace the value associated with the given key with the given value, if there was an existing value. Returns the previously associated value, or null
src/main/java/com/nyeggen/lash/IDiskMap.java:28
↓ 2 callers
Method
advance
()
src/main/java/com/nyeggen/lash/BucketDiskMap.java:325
↓ 2 callers
Method
close
Writes all header metadata and unmaps the backing mmap'd files.
src/main/java/com/nyeggen/lash/ADiskMap.java:215
↓ 2 callers
Method
doubleLength
()
src/main/java/com/nyeggen/lash/util/MMapper.java:113
↓ 2 callers
Method
getAllPointers
Adds all valid RecordPtrs in this bucket to the given list.
src/main/java/com/nyeggen/lash/BucketDiskMap.java:549
↓ 2 callers
Method
getDoubleArrayOffset
()
src/main/java/com/nyeggen/lash/util/MMapper.java:209
↓ 2 callers
Method
getHash
()
src/main/java/com/nyeggen/lash/bucket/RecordChainNode.java:30
↓ 2 callers
Method
getInstance
()
src/main/java/com/nyeggen/lash/serde/IntSerde.java:9
↓ 2 callers
Method
getIntArrayOffset
()
src/main/java/com/nyeggen/lash/util/MMapper.java:212
↓ 2 callers
Method
getKey
()
src/main/java/com/nyeggen/lash/BucketDiskMap.java:398
↓ 2 callers
Method
getLocation
()
src/main/java/com/nyeggen/lash/util/MMapper.java:168
↓ 2 callers
Method
getLongArrayOffset
()
src/main/java/com/nyeggen/lash/util/MMapper.java:215
↓ 2 callers
Method
getMethod
(Class<?> cls, String name, Class<?>... params)
src/main/java/com/nyeggen/lash/util/MMapper.java:59
↓ 2 callers
Method
getOuterType
()
src/main/java/com/nyeggen/lash/BucketDiskMap.java:418
↓ 2 callers
Method
getPos
()
src/main/java/com/nyeggen/lash/bucket/WritethruRecordChainNode.java:50
↓ 2 callers
Method
isWritable
()
src/main/java/com/nyeggen/lash/bucket/RecordPtr.java:41
↓ 2 callers
Method
load
()
src/main/java/com/nyeggen/lash/BucketDiskMap.java:57
↓ 2 callers
Method
mapAndSetOffset
()
src/main/java/com/nyeggen/lash/util/MMapper.java:72
↓ 2 callers
Method
nextPowerOf2
(long i)
src/main/java/com/nyeggen/lash/ADiskMap.java:84
↓ 2 callers
Method
overwriteChain
Overwrites the existing contents of the bucket chain starting at bucket with the given record pointers. If there are "left over" buckets, they are ad
src/main/java/com/nyeggen/lash/BucketDiskMap.java:129
↓ 2 callers
Method
put
(K key, V value)
src/main/java/com/nyeggen/lash/DiskMap.java:266
↓ 2 callers
Method
putIfAbsent
Inserts the given record in the map, only if there was no previous value associated with the key. Returns null in the case of a successful insertion,
src/main/java/com/nyeggen/lash/IDiskMap.java:17
↓ 2 callers
Method
rewriteChain
Cause each bucket to point to the subsequent one. Returns address of original, or 0 if the list was empty.
src/main/java/com/nyeggen/lash/VarSizeDiskMap.java:320
↓ 2 callers
Method
roundTo4096
(long i)
src/main/java/com/nyeggen/lash/util/MMapper.java:66
↓ 2 callers
Method
setNextBucketPos
(long v)
src/main/java/com/nyeggen/lash/BucketDiskMap.java:582
↓ 2 callers
Method
size
Returns the number of key-value mappings in this map. If the map contains more than Integer.MAX_VALUE elements, returns Integer.MAX_VALUE. Use longSiz
src/main/java/com/nyeggen/lash/DiskMap.java:64
↓ 2 callers
Method
subIdxForHash
Returns position between 0 and recordsPerBucket, based on top bits
src/main/java/com/nyeggen/lash/BucketDiskMap.java:424
↓ 2 callers
Method
writeToPos
(final long pos, final MMapper mapper)
src/main/java/com/nyeggen/lash/bucket/RecordPtr.java:29
↓ 1 callers
Method
advance
()
src/main/java/com/nyeggen/lash/VarSizeDiskMap.java:349
↓ 1 callers
Method
allocateDirect
(long size)
src/main/java/com/nyeggen/lash/util/MMapper.java:176
↓ 1 callers
Method
clear
()
src/main/java/com/nyeggen/lash/util/MMapper.java:172
↓ 1 callers
Method
clearAll
Zeroes the entire bucket.
src/main/java/com/nyeggen/lash/BucketDiskMap.java:445
↓ 1 callers
Method
clearEntries
Clears all embedded RecordPtrs, retaining header
src/main/java/com/nyeggen/lash/BucketDiskMap.java:450
↓ 1 callers
Method
completeExpansion
Recursively locks all stripes, and doubles the size of the primary mapper. On Linux your filesystem probably makes this expansion a sparse operation.
src/main/java/com/nyeggen/lash/ADiskMap.java:108
↓ 1 callers
Method
containsValue
(Object value)
src/main/java/com/nyeggen/lash/DiskMap.java:101
↓ 1 callers
Method
deallocateDirect
(long addr)
src/main/java/com/nyeggen/lash/util/MMapper.java:179
↓ 1 callers
Method
findCollision
Return a number greater than i whose bottom n bits collide when hashed.
src/main/java/com/nyeggen/lash/util/Hash.java:9
↓ 1 callers
Method
findInBucket
Searches this bucket for the given key, mutating the given SearchResult as needed, and returning true if it was found.
src/main/java/com/nyeggen/lash/BucketDiskMap.java:490
↓ 1 callers
Method
get
(Object key)
src/main/java/com/nyeggen/lash/DiskMap.java:29
↓ 1 callers
Method
get
(byte[] k)
src/main/java/com/nyeggen/lash/VarSizeDiskMap.java:67
↓ 1 callers
Method
getAllPointersInChain
Returns a List containing all valid RecordPtrs in this chain.
src/main/java/com/nyeggen/lash/BucketDiskMap.java:557
↓ 1 callers
Method
getValIfMatch
(RecordPtr recPtr, byte[] k)
src/main/java/com/nyeggen/lash/BucketDiskMap.java:87
↓ 1 callers
Method
idxToPos
(long idx)
src/main/java/com/nyeggen/lash/BucketDiskMap.java:62
next →
1–100 of 230, ranked by callers