throttle

package
v1.0.0-next.2 Latest Latest
Warning

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

Go to latest
Published: Sep 3, 2024 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ReaderChain

type ReaderChain = func(writer io.Reader) (io.Reader, error)

func SpeedlimitReader

func SpeedlimitReader(maxSpeed int64) ReaderChain

SpeedlimitReader limits the reader to the maxSpeed of bytes per second.

type WriterChain

type WriterChain = func(writer io.Writer) (io.Writer, error)

func SpeedlimitWriter

func SpeedlimitWriter(maxSpeed int64) WriterChain

SpeedlimitWriter limits the writer to the maxSpeed of bytes per second.

Jump to

Keyboard shortcuts

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