package arrio
import "git.sr.ht/~sbinet/go-arrow/arrio"
Package arrio exposes functions to manipulate records, exposing and using interfaces not unlike the ones defined in the stdlib io package.
Index ¶
- func Copy(dst Writer, src Reader) (n int64, err error)
- func CopyN(dst Writer, src Reader, n int64) (written int64, err error)
- type Reader
- type ReaderAt
- type Writer
Functions ¶
func Copy ¶
Copy copies all the records available from src to dst. Copy returns the number of records copied and the first error encountered while copying, if any.
A successful Copy returns err == nil, not err == EOF. Because Copy is defined to read from src until EOF, it does not treat an EOF from Read as an error to be reported.
func CopyN ¶
CopyN copies n records (or until an error) from src to dst. It returns the number of records copied and the earliest error encountered while copying. On return, written == n if and only if err == nil.
Types ¶
type Reader ¶
type Reader interface { // Read reads the current record from the underlying stream and an error, if any. // When the Reader reaches the end of the underlying stream, it returns (nil, io.EOF). Read() (array.Record, error) }
Reader is the interface that wraps the Read method.
type ReaderAt ¶
type ReaderAt interface { // ReadAt reads the i-th record from the underlying stream and an error, if any. ReadAt(i int64) (array.Record, error) }
ReaderAt is the interface that wraps the ReadAt method.
type Writer ¶
Writer is the interface that wraps the Write method.
Source Files ¶
- Version
- v0.3.0 (latest)
- Published
- Feb 17, 2025
- Platform
- linux/amd64
- Imports
- 2 packages
- Last checked
- 2 months ago –
Tools for package owners.