Apache Arrow - v21.1.0
    正在准备搜索索引...

    函数 builderThroughIterable

    • 将同步的任意 JavaScript 值 Iterable 转换为 Arrow Vector 序列遵循所提供的 options 参数中定义的块划分语义。

      此函数返回一个函数,该函数接受一个要转换的值 Iterable。当调用时,此函数返回一个 Vector<T> 的 Iterator。

      生成的 Iterator<Vector<T>> 根据 options 参数中指定的 queueingStrategyhighWaterMark 生成 Vector。

      • 如果 queueingStrategy"count"(或省略),则 Iterator<Vector<T>> 将在 Builder 的 length 达到或超过所提供的 highWaterMark 时刷新底层 Builder(并生成新的 Vector<T>)。
      • 如果 queueingStrategy"bytes",则 Iterator<Vector<T>> 将在 byteLength 达到或超过所提供的 highWaterMark 时刷新底层 Builder(并生成新的 Vector<T>)。

      类型参数

      参数

      • options: IterableBuilderOptions<T, TNull>

        一个属性对象,用于确定要创建的 Builder 和要使用的分块语义。

      返回 ThroughIterable<T, TNull>

      一个函数,它接受一个要写入的 JavaScript 值 Iterable,并根据 options 参数中定义的分块语义返回一个生成 Vector 的 Iterator