pb

package
v0.3.11-8 Latest Latest
Warning

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

Go to latest
Published: Oct 12, 2024 License: Apache-2.0 Imports: 4 Imported by: 2

Documentation

Index

Constants

View Source
const (
	BURSTS = 1024 * 1024 * 1024
)

Variables

This section is empty.

Functions

This section is empty.

Types

type SProxyReader

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

func NewProxyReader

func NewProxyReader(reader io.Reader, size int64) *SProxyReader

func (*SProxyReader) AvgRate

func (self *SProxyReader) AvgRate() float64

func (*SProxyReader) Percent

func (self *SProxyReader) Percent() float64

func (*SProxyReader) Rate

func (self *SProxyReader) Rate() float64

func (*SProxyReader) Read

func (self *SProxyReader) Read(p []byte) (n int, err error)

func (*SProxyReader) SetCallback

func (self *SProxyReader) SetCallback(callback func())

func (*SProxyReader) SetRateLimit

func (self *SProxyReader) SetRateLimit(mb int)

func (*SProxyReader) SetRefreshRate

func (self *SProxyReader) SetRefreshRate(rate time.Duration)

设置刷新频率 仅在读取数据前生效

Jump to

Keyboard shortcuts

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