sudo apt update
sudo apt install -y -V ca-certificates lsb-release wget
-apache-arrow-glib wget https://apache.bintray.com/arrow/$(lsb_release --id --short | tr 'A-Z' 'a-z')/apache-arrow-archive-keyring-latest-$(lsb_release --codename --short).deb
sudo apt install -y -V ./apache-arrow-archive-keyring-latest-$(lsb_release --codename --short).deb
sudo apt update
sudo apt install -y -V libarrow-glib-dev
sudo apt list libarrow-glib-dev
brew install apache-arrow-glib
brew list --versions apache-arrow-glib
swift build
swift test
/usr/lib/x86_64-linux-gnu/pkgconfig/arrow.pc
pkg-config --cflags arrow-glib
Date
, String
, Double
, Float
, Int
, Int64
, and Bool
.
let array: [Float] = (0..<10).map { _ in Float.random(in: 0.0...1.0) }
try array.toFeather(filePath: "./data/array.feather")
let arrayFromFeather = try [Float](fromFeather: "./data/array.feather")
PTable
s: Double
, String
, Int64
, Bool
let row1: [Any] = ["e12fe9879b95b35479a1195bd2190b10", 2137.8 as Double, false]
let row2: [Any] = ["02528b1bca6c637a9d725488efa1de80", 2137.4 as Double, true]
let row3: [Any] = ["1de820d72a41bf02fdc55a8991797991", 879.5 as Double, true]
let rows = [row1, row2, row3]
let columnNames = ["id", "ask", "prohibited"]
let columns = rows.transposed()
let table = try PTable([columnNames[0]: PColumn(columns[0] as! [String]),
columnNames[1]: PColumn(columns[1] as! [Double]),
columnNames[2]: PColumn(columns[2] as! [Bool])])
assert(table.columnNames == columnNames.sorted())
let filePath = "tableMultiple.feather"
try table.toFeather(filePath: filePath)
let columnsDecoded = try PTable(fromFeather: filePath)
let doubleColumnDecoded: PTypedColumn
Further data types can be supported, the code just needs to be extended for them.