NanoByte.Common  2.6.1
NanoByte.Common.Cli.ProgressBar Class Reference

A progress bar rendered on the Console. More...

Inheritance diagram for NanoByte.Common.Cli.ProgressBar:
NanoByte.Common.Cli.TaskProgressBar

Public Member Functions

void Draw ()
 Draws the progress-bar to Console.Error. More...
 
virtual void Done ()
 Stops the progress bar by writing a line break to the Console. More...
 

Protected Member Functions

virtual void DrawPretty ()
 

Properties

int Maximum [get, set]
 The maximum valid value for Value; must be greater than 0. Determines the length of the progress bar in console characters. More...
 
int Value [get, set]
 The progress of the task as a value between 0 and Maximum; -1 when unknown. More...
 

Detailed Description

A progress bar rendered on the Console.

Member Function Documentation

◆ Done()

virtual void NanoByte.Common.Cli.ProgressBar.Done ( )
virtual

Stops the progress bar by writing a line break to the Console.

◆ Draw()

void NanoByte.Common.Cli.ProgressBar.Draw ( )
inline

Draws the progress-bar to Console.Error.

The current line is overwritten.

Exceptions
IOExceptionThe progress bar could not be drawn to the Console (e.g. if it isn't a TTY).

Property Documentation

◆ Maximum

int NanoByte.Common.Cli.ProgressBar.Maximum
getset

The maximum valid value for Value; must be greater than 0. Determines the length of the progress bar in console characters.

◆ Value

int NanoByte.Common.Cli.ProgressBar.Value
getset

The progress of the task as a value between 0 and Maximum; -1 when unknown.


The documentation for this class was generated from the following file: