pond-ts API Reference (core)
    Preparing search index...

    Class IntervalKeyColumn

    Implements

    • KeyColumnBase<"interval">
    Index

    Constructors

    Properties

    begin: Float64Array

    Half-open interval start in epoch milliseconds.

    end: Float64Array

    Half-open interval end. For time keys, equal to begin.

    kind: "interval" = ...
    length: number

    Row count.

    Methods

    • Returns { begin, end, label } at row i, or undefined for out-of-range. The label type matches the column's labelKind ('string'string; 'number'number), preserving the string | number IntervalValue semantics the schema declared.

      Parameters

      • i: number

      Returns IntervalKeyAt | undefined

    • Direct label read. Returns the underlying string | number value per the label-column kind, or undefined only if a caller violated the buffer-immutability contract.

      Parameters

      • i: number

      Returns string | number | undefined

    • Gathers rows by index into a new IntervalKeyColumn. The label column is sliceByIndices'd as well — for string labels the dictionary is shared by reference (cheap), for numeric labels the buffer is materialized via Float64Column.sliceByIndices.

      Out-of-range source indices would produce undefined labels in the output column; the constructor's label-defined check then rejects them. Callers must therefore ensure indices covers only valid source rows.

      Parameters

      • indices: Int32Array

      Returns IntervalKeyColumn

    • Zero-copy index-range view: returns an IntervalKeyColumn over begin.subarray(s, e), end.subarray(s, e), and the labels column's sliceByRange(s, e) (string-dict shared by reference; numeric-label buffer subarrayed). Same trusted-buffer- immutability contract as the source.

      Same caveat as TimeRangeKeyColumn.sliceByRange for max-end: the slice preserves per-row begin[i] <= end[i] but does NOT compute the maximum end across the slice (which may exceed end[length - 1]).

      Parameters

      • start: number
      • end: number

      Returns IntervalKeyColumn