Interface ChunkedBackingStoreExposedWritableSource
- All Known Implementing Classes:
ArrayBackedColumnSource
,BooleanArraySource
,ByteArraySource
,CharacterArraySource
,DoubleArraySource
,FloatArraySource
,Immutable2DByteArraySource
,Immutable2DCharArraySource
,Immutable2DDoubleArraySource
,Immutable2DFloatArraySource
,Immutable2DIntArraySource
,Immutable2DLongArraySource
,Immutable2DObjectArraySource
,Immutable2DShortArraySource
,ImmutableByteArraySource
,ImmutableCharArraySource
,ImmutableDoubleArraySource
,ImmutableFloatArraySource
,ImmutableIntArraySource
,ImmutableLongArraySource
,ImmutableObjectArraySource
,ImmutableShortArraySource
,IntegerArraySource
,LongArraySource
,ObjectArraySource
,ShortArraySource
public interface ChunkedBackingStoreExposedWritableSource
Writable sources that use simple arrays to back contiguous regions may implement this interface, allowing callers to
reach directly into their storage in order to fill them without the need for additional array copies.
-
Method Summary
Modifier and TypeMethodDescriptiondefault boolean
Does this column source provide a chunked exposed backing store?static boolean
Returns true if a given column source exposes a chunked backing storelong
resetWritableChunkToBackingStore
(@NotNull ResettableWritableChunk<?> chunk, long position) Resets the given chunk to provide a write-through reference to our backing array.long
resetWritableChunkToBackingStoreSlice
(@NotNull ResettableWritableChunk<?> chunk, long position) Resets the given chunk to provide a write-through reference to our backing array.
-
Method Details
-
exposesChunkedBackingStore
Returns true if a given column source exposes a chunked backing store- Parameters:
cs
- the column source to test- Returns:
- true if the column source exposes a chunked backing store
-
exposesChunkedBackingStore
default boolean exposesChunkedBackingStore()Does this column source provide a chunked exposed backing store?- Returns:
- true if this column source provides a chunked backing store, false otherwise
-
resetWritableChunkToBackingStore
long resetWritableChunkToBackingStore(@NotNull @NotNull ResettableWritableChunk<?> chunk, long position) Resets the given chunk to provide a write-through reference to our backing array.Note: This is unsafe to use if previous tracking has been enabled!
- Parameters:
chunk
- the writable chunk to reset to our backing array.position
- position that we require- Returns:
- the first position addressable by the chunk
-
resetWritableChunkToBackingStoreSlice
long resetWritableChunkToBackingStoreSlice(@NotNull @NotNull ResettableWritableChunk<?> chunk, long position) Resets the given chunk to provide a write-through reference to our backing array.Note: This is unsafe to use if previous tracking has been enabled!
- Parameters:
chunk
- the writable chunk to reset to a slice of our backing array.position
- position of the first value in the returned chunk- Returns:
- the capacity of the returned chunk
-