Class LocalTimeWrapperSource

java.lang.Object
io.deephaven.engine.table.impl.AbstractColumnSource<LocalTime>
io.deephaven.engine.table.impl.sources.LocalTimeWrapperSource
All Implemented Interfaces:
ChunkSource<Values>, ChunkSource.WithPrev<Values>, ColumnSource<LocalTime>, ElementSource<LocalTime>, FillContextMaker, GetContextMaker, ColumnSourceGetDefaults.ForObject<LocalTime>, DefaultChunkSource<Values>, DefaultChunkSource.WithPrev<Values>, MutableColumnSource<LocalTime>, MutableColumnSourceGetDefaults.ForObject<LocalTime>, Releasable, TupleExporter<LocalTime>, TupleSource<LocalTime>

public class LocalTimeWrapperSource extends AbstractColumnSource<LocalTime> implements MutableColumnSourceGetDefaults.ForObject<LocalTime>
A ColumnSource for LocalTimes that is backed by an inner ColumnSource of ZonedDateTime. Note that no special handling is done for timezones. The returned local time will be in the zone of each inner ZonedDateTime.
  • Constructor Details

  • Method Details

    • allowsReinterpret

      public <ALTERNATE_DATA_TYPE> boolean allowsReinterpret(@NotNull @NotNull Class<ALTERNATE_DATA_TYPE> alternateDataType)
      Description copied from interface: ColumnSource
      Test if a reinterpret call will succeed.
      Specified by:
      allowsReinterpret in interface ColumnSource<LocalTime>
      Overrides:
      allowsReinterpret in class AbstractColumnSource<LocalTime>
      Parameters:
      alternateDataType - The alternative type to consider
      Returns:
      If a reinterpret on this column source with the supplied alternateDataType will succeed.
    • doReinterpret

      protected <ALTERNATE_DATA_TYPE> ColumnSource<ALTERNATE_DATA_TYPE> doReinterpret(@NotNull @NotNull Class<ALTERNATE_DATA_TYPE> alternateDataType)
      Description copied from class: AbstractColumnSource
      Supply allowed reinterpret results. The default implementation handles the most common case to avoid code duplication.
      Overrides:
      doReinterpret in class AbstractColumnSource<LocalTime>
      Parameters:
      alternateDataType - The alternate data type
      Returns:
      The resulting ColumnSource
    • get

      @Nullable public @Nullable LocalTime get(long rowKey)
      Description copied from interface: ElementSource
      Get the value from the source. This may return boxed values for basic types. RowKeys that are not present are undefined.
      Specified by:
      get in interface ElementSource<LocalTime>
      Parameters:
      rowKey - the location in key space to get the value from.
      Returns:
      the value at the rowKey, potentially null.
    • getPrev

      @Nullable public @Nullable LocalTime getPrev(long rowKey)
      Description copied from interface: ElementSource
      Get the previous value at the rowKey. Previous values are used during an UG update cycle to process changes in data. During normal operation previous values will be identical to current values. RowKeys that were not present are undefined.
      Specified by:
      getPrev in interface ElementSource<LocalTime>
      Parameters:
      rowKey - the location in key space to get the value from.
      Returns:
      the previous value at the rowKey, potentially null.
    • makeFillContext

      public ChunkSource.FillContext makeFillContext(int chunkCapacity, SharedContext sharedContext)
      Description copied from interface: FillContextMaker
      Allocate a new ChunkSource.FillContext for filling chunks from this FillContextMaker, typically a ChunkSource.
      Specified by:
      makeFillContext in interface DefaultChunkSource<Values>
      Specified by:
      makeFillContext in interface FillContextMaker
      Parameters:
      chunkCapacity - The maximum size of any WritableChunk that will be filled with this context
      sharedContext - Shared store of intermediate results.
      Returns:
      A context for use with fill operations
    • fillChunk

      public void fillChunk(@NotNull ChunkSource.FillContext context, @NotNull @NotNull WritableChunk<? super Values> dest, @NotNull @NotNull RowSequence rowSequence)
      Description copied from interface: ChunkSource
      Populates the given destination chunk with data corresponding to the keys from the given RowSequence.
      Specified by:
      fillChunk in interface ChunkSource<Values>
      Overrides:
      fillChunk in class AbstractColumnSource<LocalTime>
      Parameters:
      context - A context containing all mutable/state related data used in retrieving the Chunk.
      dest - The chunk to be populated according to rowSequence. No assumptions shall be made about the size of the chunk shall be made. The chunk will be populated from position [0,rowSequence.size()).
      rowSequence - An RowSequence representing the keys to be fetched
    • fillPrevChunk

      public void fillPrevChunk(@NotNull ChunkSource.FillContext context, @NotNull @NotNull WritableChunk<? super Values> dest, @NotNull @NotNull RowSequence rowSequence)
      Description copied from interface: ChunkSource.WithPrev
      Populates the given destination chunk with data corresponding to the keys from the given RowSequence.
      Specified by:
      fillPrevChunk in interface ChunkSource.WithPrev<Values>
      Overrides:
      fillPrevChunk in class AbstractColumnSource<LocalTime>
      Parameters:
      context - A context containing all mutable/state related data used in retrieving the Chunk.
      dest - The chunk to be populated according to rowSequence. No assumptions shall be made about the size of the chunk shall be made. The chunk will be populated from position [0,rowSequence.size()).
      rowSequence - An RowSequence representing the keys to be fetched