barpool

package
v0.20.1-victorialogs Latest Latest
Warning

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

Go to latest
Published: Jun 17, 2024 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Overview

Package barpool provides access to the global pool of progress bars, so they could be rendered altogether.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Disable added in v1.97.7

func Disable(v bool)

Disable sets progress bar to be no-op if v==true

func Start

func Start() error

Start starts the global pool Must be called after all progress bars were added

func Stop

func Stop()

Stop stops the global pool

Types

type Bar added in v1.97.7

type Bar interface {
	Add(value int)
	Increment()
	Start()
	Finish()
	NewProxyReader(r io.Reader) *pb.Reader
}

Bar is an interface for progress bar

func AddWithTemplate

func AddWithTemplate(format string, total int) Bar

AddWithTemplate adds bar with the given template to the global pool

func NewSingleProgress added in v1.92.0

func NewSingleProgress(format string, total int) Bar

NewSingleProgress returns progress bar with given template

Jump to

Keyboard shortcuts

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