reader

package
v4.1.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 19, 2023 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Overview

Package reader is a generated GoMock package.

Package reader is a generated GoMock package.

Index

Constants

View Source
const (
	DefaultBatchSize = 128
)

Variables

This section is empty.

Functions

func NewContinueError

func NewContinueError(err error) error

Types

type BatchRecordReader

type BatchRecordReader interface {
	Source() source.Source
	source.Sizer
	ReadBatch() (int, spec.Records, error)
}

func NewBatchRecordReader

func NewBatchRecordReader(rr RecordReader, opts ...Option) BatchRecordReader

type MockBatchRecordReader

type MockBatchRecordReader struct {
	// contains filtered or unexported fields
}

MockBatchRecordReader is a mock of BatchRecordReader interface.

func NewMockBatchRecordReader

func NewMockBatchRecordReader(ctrl *gomock.Controller) *MockBatchRecordReader

NewMockBatchRecordReader creates a new mock instance.

func (*MockBatchRecordReader) EXPECT

EXPECT returns an object that allows the caller to indicate expected use.

func (*MockBatchRecordReader) ReadBatch

func (m *MockBatchRecordReader) ReadBatch() (int, spec.Records, error)

ReadBatch mocks base method.

func (*MockBatchRecordReader) Size

func (m *MockBatchRecordReader) Size() (int64, error)

Size mocks base method.

func (*MockBatchRecordReader) Source

func (m *MockBatchRecordReader) Source() source.Source

Source mocks base method.

type MockBatchRecordReaderMockRecorder

type MockBatchRecordReaderMockRecorder struct {
	// contains filtered or unexported fields
}

MockBatchRecordReaderMockRecorder is the mock recorder for MockBatchRecordReader.

func (*MockBatchRecordReaderMockRecorder) ReadBatch

ReadBatch indicates an expected call of ReadBatch.

func (*MockBatchRecordReaderMockRecorder) Size

Size indicates an expected call of Size.

func (*MockBatchRecordReaderMockRecorder) Source

Source indicates an expected call of Source.

type MockRecordReader

type MockRecordReader struct {
	// contains filtered or unexported fields
}

MockRecordReader is a mock of RecordReader interface.

func NewMockRecordReader

func NewMockRecordReader(ctrl *gomock.Controller) *MockRecordReader

NewMockRecordReader creates a new mock instance.

func (*MockRecordReader) EXPECT

EXPECT returns an object that allows the caller to indicate expected use.

func (*MockRecordReader) Read

func (m *MockRecordReader) Read() (int, spec.Record, error)

Read mocks base method.

func (*MockRecordReader) Size

func (m *MockRecordReader) Size() (int64, error)

Size mocks base method.

func (*MockRecordReader) Source

func (m *MockRecordReader) Source() source.Source

Source mocks base method.

type MockRecordReaderMockRecorder

type MockRecordReaderMockRecorder struct {
	// contains filtered or unexported fields
}

MockRecordReaderMockRecorder is the mock recorder for MockRecordReader.

func (*MockRecordReaderMockRecorder) Read

Read indicates an expected call of Read.

func (*MockRecordReaderMockRecorder) Size

Size indicates an expected call of Size.

func (*MockRecordReaderMockRecorder) Source

Source indicates an expected call of Source.

type Option

type Option func(*options)

func WithBatch

func WithBatch(batch int) Option

func WithLogger

func WithLogger(l logger.Logger) Option

type RecordReader

type RecordReader interface {
	Source() source.Source
	source.Sizer
	Read() (int, spec.Record, error)
}

func NewCSVReader

func NewCSVReader(s source.Source) RecordReader

func NewRecordReader

func NewRecordReader(s source.Source) RecordReader

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL