progress

package
v0.2.4 Latest Latest
Warning

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

Go to latest
Published: Sep 20, 2023 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrNotProgressReport = fmt.Errorf("not a progress report")

Functions

This section is empty.

Types

type Task

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

func NewTask

func NewTask(name string, logger *log.Logger) *Task

func NewTaskFromReport

func NewTaskFromReport(report string, logger *log.Logger) (*Task, error)

func (*Task) Done

func (t *Task) Done()

func (Task) GetCompletion

func (t Task) GetCompletion() float32

func (Task) GetId

func (t Task) GetId() uint32

func (Task) GetName

func (t Task) GetName() string

func (Task) GetUpdate

func (t Task) GetUpdate() string

func (*Task) Grow

func (t *Task) Grow(i uint64)

func (Task) IsDone

func (t Task) IsDone() bool

func (*Task) Progress

func (t *Task) Progress(i uint64)

func (*Task) Update

func (t *Task) Update(format string, a ...any)

func (*Task) UpdateGrow

func (t *Task) UpdateGrow(i uint64, format string, a ...any)

func (*Task) UpdateProgress

func (t *Task) UpdateProgress(p uint64, format string, a ...any)

func (*Task) UpdateProgressGrow

func (t *Task) UpdateProgressGrow(p uint64, g uint64, format string, a ...any)

Jump to

Keyboard shortcuts

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