converter

package
v0.1.2 Latest Latest
Warning

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

Go to latest
Published: Aug 19, 2024 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DataHolder

type DataHolder = interface{}

type Option

type Option func(*conf)

func WithErrWriter

func WithErrWriter(errWriter io.Writer) Option

func WithFailOnConvertErrors

func WithFailOnConvertErrors() Option

func WithThreads

func WithThreads(threads int) Option

func WithThreadsBuffer

func WithThreadsBuffer(threadBuffer int) Option

type Processor

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

func NewProcessor

func NewProcessor(strategy Strategy, opts ...Option) *Processor

func (*Processor) Process

func (p *Processor) Process(ctx context.Context) error

type Strategy

type Strategy interface {
	Read() (DataHolder, error)
	Decode(DataHolder) error

	Encode(DataHolder) error
	Write(DataHolder) error
}

Jump to

Keyboard shortcuts

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