Package com.illumon.iris.db.v2.hashing
Interface ToLongCast<T extends Attributes.Any>
- All Superinterfaces:
AutoCloseable
,Context
,SafeCloseable
,ToLongFunctor<T>
-
Nested Class Summary
Nested classes/interfaces inherited from interface com.illumon.iris.db.v2.hashing.ToLongFunctor
ToLongFunctor.Identity<T extends Attributes.Any>
-
Method Summary
Modifier and TypeMethodDescriptionApply this function to the input chunk, returning an output chunk.static <T extends Attributes.Any>
ToLongFunctor<T>makeToLongCast
(ChunkType type, int size, long offset) Create an LongFunctor that casts the values in an input chunk to an long.
-
Method Details
-
apply
Description copied from interface:ToLongFunctor
Apply this function to the input chunk, returning an output chunk. The result is owned by thisContext
.- Specified by:
apply
in interfaceToLongFunctor<T extends Attributes.Any>
- Parameters:
input
- the chunk to transform- Returns:
- the result LongChunk
-
makeToLongCast
static <T extends Attributes.Any> ToLongFunctor<T> makeToLongCast(ChunkType type, int size, long offset) Create an LongFunctor that casts the values in an input chunk to an long. An optional offset is applied to each value after the cast.- Type Parameters:
T
- the chunk's attribute- Parameters:
type
- the type of chunk, must be an integral primitive typesize
- the size of the largest chunk that can be cast by this functoroffset
- an offset to add to each casted result- Returns:
- a
ToLongFunctor
that can be applied to chunks of type in order to produce an LongChunk of values
-