See: Description
| Interface | Description |
|---|---|
| OffHeapStructAccessor |
Interface for accessing fields of a single struct
|
| OffHeapStructCollection |
Base interface for off-heap struct (memory areas of equal sizes) collection.
|
| Class | Description |
|---|---|
| LimitedInvoker |
Auxiliary class that limits the number of
Executor threads
those can be used simultaneously. |
| OffHeapStructArray |
Implementation of off-heap array of structs (memory areas of equal sizes).
|
| OffHeapStructArrayList |
Implementation of off-heap array list of structs (memory areas of equal sizes).
|
| OffHeapStructBinarySearch |
Binary search implementation borrowed from
https://android.googlesource.com/platform/libcore/+/android-4.2.2_r1/luni/src/main/java/java/util/Arrays.java
and adapted to OffHeapStructCollection |
| OffHeapStructBinarySearch.IndexRange |
OffHeapStructCollection index range representation. |
| OffHeapStructBinarySearchWithComparator |
Binary search implementation borrowed from
https://android.googlesource.com/platform/libcore/+/android-4.2.2_r1/luni/src/main/java/java/util/Arrays.java
and adapted to OffHeapStructCollection with comparators. |
| OffHeapStructComparator |
Internal wrapper for user-provided comparator.
|
| OffHeapStructComparator.OffHeapStructByteArrayAccessor |
Struct's accessor implementation for byte array structs
|
| OffHeapStructComparator.OffHeapStructIndexAccessor |
Struct's accessor implementation for off-heap stored structs
|
| OffHeapStructIterator |
Iterator implementation for unsafe long collections.
|
| OffHeapStructSorter |
alexkasko: borrowed from
https://android.googlesource.com/platform/libcore/+/android-4.2.2_r1/luni/src/main/java/java/util/DualPivotQuicksort.java
and adapted to OffHeapStructCollection. |
| OffHeapStructSorterByReference |
alexkasko: borrowed from
https://android.googlesource.com/platform/libcore/+/android-4.2.2_r1/luni/src/main/java/java/util/DualPivotQuicksort.java
and adapted to OffHeapStructCollection to sort it by reference. |
| OffHeapStructSorterByReference.OffHeapReferenceComparator |
Comparator wrapper to use with references, not thread-safe
|
| OffHeapStructSorterByReference.OffHeapStructIndexAccessor |
Struct's accessor implementation for off-heap stored structs
|
| OffHeapStructSorterByReference.ReferenceIterable |
Iterable over the data collection using indices from specified array
|
| OffHeapStructSorterByReference.ReferenceIterator |
Iterator returning data elements in the order specified by indices array
|
| OffHeapStructSorterInt |
alexkasko: borrowed from
https://android.googlesource.com/platform/libcore/+/android-4.2.2_r1/luni/src/main/java/java/util/DualPivotQuicksort.java
and adapted to OffHeapStructCollection with signed int keys. |
| OffHeapStructSorterInt.MergeIter |
Merge-sort iterator over partly sorted collection
|
| OffHeapStructSorterInt.Worker |
Worker, sorts part of the collection
|
| OffHeapStructSorterLong |
alexkasko: borrowed from
https://android.googlesource.com/platform/libcore/+/android-4.2.2_r1/luni/src/main/java/java/util/DualPivotQuicksort.java
and adapted to OffHeapStructCollection with signed long keys. |
| OffHeapStructSorterLong.KeyWorker |
Worker for two long keys sort
|
| OffHeapStructSorterLong.MergeIter |
Merge-sort iterator over partly sorted collection
|
| OffHeapStructSorterLong.Worker |
Worker, sorts part of the collection
|
| OffHeapStructSorterUnsignedInt |
alexkasko: borrowed from
https://android.googlesource.com/platform/libcore/+/android-4.2.2_r1/luni/src/main/java/java/util/DualPivotQuicksort.java
and adapted to OffHeapStructCollection with unsigned int keys. |
| OffHeapStructSorterUnsignedLong |
alexkasko: borrowed from
https://android.googlesource.com/platform/libcore/+/android-4.2.2_r1/luni/src/main/java/java/util/DualPivotQuicksort.java
and adapted to OffHeapStructCollection with unsigned long keys. |
| OffHeapStructSorterWithComparator |
alexkasko: borrowed from
https://android.googlesource.com/platform/libcore/+/android-4.2.2_r1/luni/src/main/java/java/util/DualPivotQuicksort.java
and adapted to OffHeapStructCollection with comparator. |
| OffHeapStructSorterWithComparator.MergeIter |
Merge-sort iterator over partly sorted collection
|
| OffHeapStructSorterWithComparator.Worker |
Worker, sorts part of the collection
|
This package contains implementations of fixed-sized array of "structs" (OffHeapStructArray)
and growing array list of structs (OffHeapStructArrayList). Both classes are implemented on top of
OffHeapMemory.
Struct here means a memory area (located in off-heap memory or loaded into byte array) of limited size with predefined locations of primitive "fields" in it. Such memory areas may be used like C structs (this library doesn't enforce memory alighment so they are more alike to packed C structs).
Integer.MAX_VALUE)OffHeapMemory
will free allocated memory when it's instance will be garbage collected)Both collections implements Iterable returning elements copying it into one predefined byte array.
OffHeapStructSorter: implementation of Dual-Pivot quicksort algorithm
adapted to off-heap collections. May use long or int fields from struct as sort keys with signed or unsigned comparison.
May also use user-provided Comparator's for structs.OffHeapLongArray
to hold collection indices. Indices are sorted using data from the collection, collection itself stays
unchanged. This sorter returns OffHeapDisposableIterable over the data.OffHeapStructBinarySearch.
May use long or int field from struct to search on it. May also use user-provided Comparator's for structs.OffHeapStructBinarySearch.binarySearchRangeByLongKey(com.alexkasko.unsafe.offheapstruct.OffHeapStructCollection, long, int, com.alexkasko.unsafe.offheapstruct.OffHeapStructBinarySearch.IndexRange)Copyright © 2014. All Rights Reserved.