chunker

package
v0.0.3 Latest Latest
Warning

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

Go to latest
Published: Dec 6, 2024 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Chunks

type Chunks[T any] struct {
	Cfg Config
	// contains filtered or unexported fields
}

func NewChunks

func NewChunks[T any](ctx context.Context, cfg Config) *Chunks[T]

func (*Chunks[T]) Close

func (c *Chunks[T]) Close()

func (*Chunks[T]) Ctx

func (c *Chunks[T]) Ctx() context.Context

func (*Chunks[T]) Generator

func (c *Chunks[T]) Generator()

func (*Chunks[T]) GetChunks

func (c *Chunks[T]) GetChunks() <-chan chan T

func (*Chunks[T]) Input

func (c *Chunks[T]) Input() chan<- T

func (*Chunks[T]) NewChunk

func (c *Chunks[T]) NewChunk() chan T

type Config

type Config struct {
	MaxChunkSize int
	BufferSize   int
	MaxIdleTime  time.Duration
}

Jump to

Keyboard shortcuts

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