Package org.HdrHistogram.packedarray
Class ConcurrentPackedArrayContext
java.lang.Object
org.HdrHistogram.packedarray.AbstractPackedArrayContext
org.HdrHistogram.packedarray.PackedArrayContext
org.HdrHistogram.packedarray.ConcurrentPackedArrayContext
- All Implemented Interfaces:
Serializable
-
Nested Class Summary
Nested classes/interfaces inherited from class org.HdrHistogram.packedarray.AbstractPackedArrayContext
AbstractPackedArrayContext.NonZeroValuesIterator -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate AtomicLongArrayprivate intprivate static final AtomicIntegerFieldUpdater<ConcurrentPackedArrayContext> Fields inherited from class org.HdrHistogram.packedarray.AbstractPackedArrayContext
MAX_SUPPORTED_PACKED_COUNTS_ARRAY_LENGTH, MINIMUM_INITIAL_PACKED_ARRAY_CAPACITY -
Constructor Summary
ConstructorsConstructorDescriptionConcurrentPackedArrayContext(int virtualLength, int initialPhysicalLength) ConcurrentPackedArrayContext(int virtualLength, int initialPhysicalLength, boolean allocateArray) ConcurrentPackedArrayContext(int newVirtualCountsArraySize, AbstractPackedArrayContext from, int arrayLength) -
Method Summary
Modifier and TypeMethodDescription(package private) longaddAndGetAtUnpackedIndex(int index, long valueToAdd) (package private) booleancasAtLongIndex(int longIndex, long expectedValue, long newValue) (package private) booleancasPopulatedLongLength(int expectedPopulatedLongLength, int newPopulatedLongLength) (package private) booleancasPopulatedShortLength(int expectedPopulatedShortLength, int newPopulatedShortLength) (package private) void(package private) longgetAtLongIndex(int longIndex) (package private) longgetAtUnpackedIndex(int index) (package private) int(package private) longincrementAndGetAtUnpackedIndex(int index) (package private) voidlazySetAtLongIndex(int longIndex, long newValue) (package private) voidlazySetAtUnpackedIndex(int index, long newValue) (package private) intlength()(package private) voidresizeArray(int newLength) (package private) voidsetAtUnpackedIndex(int index, long newValue) (package private) StringMethods inherited from class org.HdrHistogram.packedarray.AbstractPackedArrayContext
addAtByteIndex, casAtShortIndex, determineTopLevelShiftForVirtualLength, getAtByteIndex, getAtShortIndex, getIndexAtShortIndex, getPackedIndex, getPhysicalLength, getPopulatedByteLength, getPopulatedLongLength, getTopLevelShift, getVirtualLength, init, isPacked, nonZeroValues, populateEquivalentEntriesWithZerosFromOther, setAtByteIndex, setAtShortIndex, setValuePart, setVirtualLength, toString
-
Field Details
-
array
-
populatedShortLength
private volatile int populatedShortLength -
populatedShortLengthUpdater
private static final AtomicIntegerFieldUpdater<ConcurrentPackedArrayContext> populatedShortLengthUpdater
-
-
Constructor Details
-
ConcurrentPackedArrayContext
ConcurrentPackedArrayContext(int virtualLength, int initialPhysicalLength, boolean allocateArray) -
ConcurrentPackedArrayContext
ConcurrentPackedArrayContext(int virtualLength, int initialPhysicalLength) -
ConcurrentPackedArrayContext
ConcurrentPackedArrayContext(int newVirtualCountsArraySize, AbstractPackedArrayContext from, int arrayLength)
-
-
Method Details
-
length
int length()- Overrides:
lengthin classPackedArrayContext
-
getPopulatedShortLength
int getPopulatedShortLength()- Overrides:
getPopulatedShortLengthin classPackedArrayContext
-
casPopulatedShortLength
boolean casPopulatedShortLength(int expectedPopulatedShortLength, int newPopulatedShortLength) - Overrides:
casPopulatedShortLengthin classPackedArrayContext
-
casPopulatedLongLength
boolean casPopulatedLongLength(int expectedPopulatedLongLength, int newPopulatedLongLength) - Overrides:
casPopulatedLongLengthin classPackedArrayContext
-
getAtLongIndex
long getAtLongIndex(int longIndex) - Overrides:
getAtLongIndexin classPackedArrayContext
-
casAtLongIndex
boolean casAtLongIndex(int longIndex, long expectedValue, long newValue) - Overrides:
casAtLongIndexin classPackedArrayContext
-
lazySetAtLongIndex
void lazySetAtLongIndex(int longIndex, long newValue) - Overrides:
lazySetAtLongIndexin classPackedArrayContext
-
clearContents
void clearContents()- Overrides:
clearContentsin classPackedArrayContext
-
resizeArray
void resizeArray(int newLength) - Overrides:
resizeArrayin classPackedArrayContext
-
getAtUnpackedIndex
long getAtUnpackedIndex(int index) - Overrides:
getAtUnpackedIndexin classPackedArrayContext
-
setAtUnpackedIndex
void setAtUnpackedIndex(int index, long newValue) - Overrides:
setAtUnpackedIndexin classPackedArrayContext
-
lazySetAtUnpackedIndex
void lazySetAtUnpackedIndex(int index, long newValue) - Overrides:
lazySetAtUnpackedIndexin classPackedArrayContext
-
incrementAndGetAtUnpackedIndex
long incrementAndGetAtUnpackedIndex(int index) - Overrides:
incrementAndGetAtUnpackedIndexin classPackedArrayContext
-
addAndGetAtUnpackedIndex
long addAndGetAtUnpackedIndex(int index, long valueToAdd) - Overrides:
addAndGetAtUnpackedIndexin classPackedArrayContext
-
unpackedToString
String unpackedToString()- Overrides:
unpackedToStringin classPackedArrayContext
-