Versions in this module Expand all Collapse all v1 v1.3.0 Jul 10, 2019 Changes in this version + const Version + var UnknownSuffix error = errors.New("Unknown suffix") + var VarintNotEnoughBytes error = errors.New("Not enough bytes in varint") + func BytesToVILP(data []byte) []byte + func CreateFile(outfile string) (io.WriteCloser, error) + func CreateFileBuffered(outfile string, size int) (io.WriteCloser, error) + func CreateFileSync(outfile string) (io.WriteCloser, error) + func DecodeVarint(data_in []byte) (uint64, int, error) + func EncodeVarint(int_in uint64) []byte + func Errorf(fmt_str string, args ...interface{}) error + func ErrorfLong(fmt_str string, args ...interface{}) error + func NewPrefixLenScanner(r io.Reader) *bufio.Scanner + func NewVILPScanner(r io.Reader) *bufio.Scanner + func NewVILPWriterF(file_path string) (*VILPWriter, CloseFunc, error) + func OpenFile(infile string) (io.ReadCloser, error) + func ScannerPrefixLenScan(data []byte, at_eof bool) (int, []byte, error) + func ScannerVILPScan(data []byte, at_eof bool) (int, []byte, error) + type CloseFunc func() + func AddCompressionLayer(w io.Writer, suffix string) (io.Writer, CloseFunc, error) + func AddDecompressionLayer(r io.Reader, suffix string) (io.Reader, CloseFunc, error) + func NewVILPScannerF(file_path string) (*bufio.Scanner, CloseFunc, error) + func OpenFileRO(infile string) (io.Reader, CloseFunc, error) + func OpenFileW(outfile string) (io.Writer, CloseFunc, error) + func OpenPipesToWriter(final_writer io.Writer, progs [][]string) (io.Writer, CloseFunc, error) + type KeyedRecord struct + func NewKeyedRecordFromBytes(raw_rec_bytes []byte, decoder KeyedRecordDecoder) *KeyedRecord + func NewKeyedRecordFromKeyVal(key []byte, val interface{}) *KeyedRecord + func (kr *KeyedRecord) Key() ([]byte, error) + func (kr *KeyedRecord) KeyString() (string, error) + func (kr *KeyedRecord) KeyVal() ([]byte, interface{}, error) + func (kr *KeyedRecord) MarkDirty() + func (kr *KeyedRecord) RecordBytesOut(encoder KeyedRecordEncoder) ([]byte, error) + func (kr *KeyedRecord) SetDecoder(dec KeyedRecordDecoder) + func (kr *KeyedRecord) SetEncoder(enc KeyedRecordEncoder) + func (kr *KeyedRecord) Val() (interface{}, error) + type KeyedRecordDecoder interface + SplitKV func([]byte) ([]byte, []byte, error) + UnmarshalVal func([]byte) (interface{}, error) + type KeyedRecordEncoder interface + CodecSame func() bool + JoinKV func(key []byte, val []byte) ([]byte, error) + MarshalVal func(interface{}) ([]byte, error) + type KeyedRecordScanner interface + Err func() error + Record func() *KeyedRecord + Scan func() bool + type KeyedRecordWriter interface + Write func(*KeyedRecord) (int, error) + type PrefixLenWriter struct + func NewPrefixLenWriter(w io.Writer) *PrefixLenWriter + func (plw *PrefixLenWriter) Write(p []byte) (int, error) + func (plw *PrefixLenWriter) WriteString(s string) (int, error) + type ReaderCloser struct + func (rc *ReaderCloser) Close() error + func (rc *ReaderCloser) Read(p []byte) (n int, err error) + type TabColsKRCodec struct + func NewTabColsKRCodec() *TabColsKRCodec + func (krc *TabColsKRCodec) CodecSame() bool + func (krc *TabColsKRCodec) JoinKV(key, val []byte) ([]byte, error) + func (krc *TabColsKRCodec) MarshalVal(data interface{}) ([]byte, error) + func (krc *TabColsKRCodec) SplitKV(wire_data []byte) ([]byte, []byte, error) + func (krc *TabColsKRCodec) UnmarshalVal(val_bytes []byte) (interface{}, error) + type TabColsKRScanner struct + func NewTabColsKRScanner(r io.Reader) *TabColsKRScanner + func (krs *TabColsKRScanner) Err() error + func (krs *TabColsKRScanner) Record() *KeyedRecord + func (krs *TabColsKRScanner) Scan() bool + type TabColsKRWriter struct + func NewTabColsKRWriter(w io.Writer) *TabColsKRWriter + func (krw *TabColsKRWriter) Write(rec *KeyedRecord) (int, error) + type VILPColsKRCodec struct + func NewVILPColsKRCodec() *VILPColsKRCodec + func (krc *VILPColsKRCodec) CodecSame() bool + func (krc *VILPColsKRCodec) JoinKV(key, val []byte) ([]byte, error) + func (krc *VILPColsKRCodec) MarshalVal(data interface{}) ([]byte, error) + func (krc *VILPColsKRCodec) SplitKV(wire_data []byte) ([]byte, []byte, error) + func (krc *VILPColsKRCodec) UnmarshalVal(val_bytes []byte) (interface{}, error) + type VILPColsKRScanner struct + func NewVILPColsKRScanner(r io.Reader) *VILPColsKRScanner + func (krs *VILPColsKRScanner) Err() error + func (krs *VILPColsKRScanner) Record() *KeyedRecord + func (krs *VILPColsKRScanner) Scan() bool + type VILPColsKRWriter struct + func NewVILPColsKRWriter(w io.Writer) *VILPColsKRWriter + func (krw *VILPColsKRWriter) Write(rec *KeyedRecord) (int, error) + type VILPWriter struct + func NewVILPWriter(w io.Writer) *VILPWriter + func (plw *VILPWriter) Write(p []byte) (int, error) + func (plw *VILPWriter) WriteString(s string) (int, error) + type WriterCloser struct + func (wc *WriterCloser) Close() error + func (wc *WriterCloser) Write(p []byte) (n int, err error)