ArrowWriterImpl

internal class ArrowWriterImpl(val dataFrame: DataFrame<*>, val targetSchema: Schema, val mode: ArrowWriter.Mode, val mismatchSubscriber: (ConvertingMismatch) -> Unit = ignoreMismatchMessage) : ArrowWriter

Save dataFrame content in Apache Arrow format (can be written to File, ByteArray, OutputStream or raw Channel) with targetSchema. If dataFrame content does not match with targetSchema, behaviour is specified by mode, mismatches would be sent to mismatchSubscriber

Constructors

Link copied to clipboard
constructor(dataFrame: DataFrame<*>, targetSchema: Schema, mode: ArrowWriter.Mode, mismatchSubscriber: (ConvertingMismatch) -> Unit = ignoreMismatchMessage)

Properties

Link copied to clipboard
open override val dataFrame: DataFrame<*>
Link copied to clipboard
Link copied to clipboard
open override val mode: ArrowWriter.Mode
Link copied to clipboard
open override val targetSchema: Schema

Functions

Link copied to clipboard
open override fun allocateVectorSchemaRoot(): VectorSchemaRoot

Create Arrow VectorSchemaRoot with dataFrame content cast to targetSchema according to the mode.

Link copied to clipboard
open override fun close()
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
open fun writeArrowFeather(file: File)

Save data to Arrow random access format, write to new or existing file. If file exists, it would be recreated.

Save data to Arrow random access format, write to opened stream.

Save data to Arrow random access format, write to opened channel.

open fun writeArrowFeather(path: Path)

Save data to Arrow random access format, write to a new or existing file on the given path. If file on the given path exists, it would be recreated.

Link copied to clipboard
open fun writeArrowIPC(stream: OutputStream)

Save data to Arrow interprocess streaming format, write to opened stream.

Save data to Arrow interprocess streaming format, write to opened channel.

open fun writeArrowIPC(file: File, append: Boolean = true)

Save data to Arrow interprocess streaming format, write to new or existing file. If file exists, it can be recreated or expanded.

open fun writeArrowIPC(path: Path, append: Boolean = true)

Save data to Arrow interprocess streaming format, write to a new or existing file on the given path. If file on the given path exists, it can be recreated or expanded.