progressbar

package
v0.2.7 Latest Latest
Warning

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

Go to latest
Published: Jun 6, 2023 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Report added in v0.2.3

func Report(msg ChannelType)

func Run added in v0.2.3

func Run() group_waiter.Waitable

Types

type BarClose added in v0.2.3

type BarClose struct {
	BarName          string
	AllowUncompleted bool
}

func NewBarClose added in v0.2.3

func NewBarClose(name string) BarClose

NewBarClose creates a request to close an existing bar. It is used to prevent the program from being stuck if a progress bar is not completed (due to error). In case the progress bar already completed, it is just ignored.

func NewBarCloseAllowUncompleted added in v0.2.4

func NewBarCloseAllowUncompleted(name string) BarClose

type BarUpdate added in v0.2.3

type BarUpdate struct {
	BarName string
	Change  int
}

func NewUpdate added in v0.2.3

func NewUpdate(name string, change int) BarUpdate

NewUpdate creates a request to update the count for an existing bar. The change must be positive.

type ChannelType added in v0.2.3

type ChannelType = interface{}

type MinimumRequiredBars added in v0.2.3

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

func NewMinimumRequiredBars added in v0.2.3

func NewMinimumRequiredBars(count int) MinimumRequiredBars

NewMinimumRequiredBars creates a request to set the minimum number of bars. It is used to prevent the progress bar from finishing before all bars were created.

type OptionalBarCreation added in v0.2.3

type OptionalBarCreation struct {
	BarName       string
	TotalEntities int
}

func NewOptionalBar added in v0.2.3

func NewOptionalBar(name string, total int) OptionalBarCreation

NewOptionalBar creates a request to create a new optional bar. It is used to create a bar without marking it for the minimum requirement count.

type OptionalSpinnerBarCreation added in v0.2.4

type OptionalSpinnerBarCreation struct {
	BarName string
}

func NewOptionalSpinnerBar added in v0.2.4

func NewOptionalSpinnerBar(name string) OptionalSpinnerBarCreation

type RequiredBarCreation added in v0.2.3

type RequiredBarCreation OptionalBarCreation

func NewRequiredBar added in v0.2.3

func NewRequiredBar(name string, total int) RequiredBarCreation

NewRequiredBar creates a request to create a new required bar. It is used to create a bar and mark it for the minimum requirement count.

type SpinnerBarUpdate added in v0.2.4

type SpinnerBarUpdate struct {
	BarUpdate
}

func NewSpinnerBarUpdate added in v0.2.4

func NewSpinnerBarUpdate(name string, change int) SpinnerBarUpdate

type TimedBarCreation added in v0.2.3

type TimedBarCreation struct {
	BarName string
	End     time.Time
}

func NewTimedBar added in v0.2.3

func NewTimedBar(name string, end time.Time) TimedBarCreation

NewTimedBar creates a request to create a time-based bar. Timed bars are counted with seconds and removed when finished.

Jump to

Keyboard shortcuts

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