API Reference
ProgressBarFluent
The fluent methods of ProgressBar, generated from its public properties: With... sets a property and Add... adds to a collection, both returning the same instance.
Inheritance
- Object
- ProgressBarFluent
Methods
public static ProgressBar AddColumn(ProgressBar progressBar, ProgressColumn item) #ProgressBarAdds an item to ProgressBar.Columns: The columns of the bar's row (see ProgressColumns: description, bar, percent, count, elapsed, remaining time, rate, custom...), or null (default) for the classic label, bar, percentage and count. With columns set, the stream heartbeat line summarises the bar through them.
Parameters
- progressBar ConsoleMonster.Widgets.ProgressBar
- The instance.
- item ConsoleMonster.Widgets.ProgressColumn
- The item.
Returns
The same instance.
public static ProgressBar AddColumns(ProgressBar progressBar, params ProgressColumn[] items) #ProgressBarAdds items to ProgressBar.Columns: The columns of the bar's row (see ProgressColumns: description, bar, percent, count, elapsed, remaining time, rate, custom...), or null (default) for the classic label, bar, percentage and count. With columns set, the stream heartbeat line summarises the bar through them.
Parameters
- progressBar ConsoleMonster.Widgets.ProgressBar
- The instance.
- items ConsoleMonster.Widgets.ProgressColumn[]
- The items, in order.
Returns
The same instance.
public static ProgressBar AddColumns(ProgressBar progressBar, IEnumerable<ProgressColumn> items) #ProgressBarAdds items to ProgressBar.Columns: The columns of the bar's row (see ProgressColumns: description, bar, percent, count, elapsed, remaining time, rate, custom...), or null (default) for the classic label, bar, percentage and count. With columns set, the stream heartbeat line summarises the bar through them.
Parameters
- progressBar ConsoleMonster.Widgets.ProgressBar
- The instance.
- items System.Collections.Generic.IEnumerable<ConsoleMonster.Widgets.ProgressColumn>
- The items, in order.
Returns
The same instance.
public static ProgressBar WithColumns(ProgressBar progressBar, IList<ProgressColumn>? value) #ProgressBarSets ProgressBar.Columns: The columns of the bar's row (see ProgressColumns: description, bar, percent, count, elapsed, remaining time, rate, custom...), or null (default) for the classic label, bar, percentage and count. With columns set, the stream heartbeat line summarises the bar through them.
Parameters
- progressBar ConsoleMonster.Widgets.ProgressBar
- The instance.
- value System.Collections.Generic.IList<ConsoleMonster.Widgets.ProgressColumn>?
- The value.
Returns
The same instance.
public static ProgressBar WithCountColumn(ProgressBar progressBar, ColumnFormat value) #ProgressBarSets ProgressBar.CountColumn: Layout of the value in the value/total count (default right-aligned). The value reserves the width of the total, so the bar keeps its length as the value grows from 9 to 10.
Parameters
- progressBar ConsoleMonster.Widgets.ProgressBar
- The instance.
- value ConsoleMonster.Layout.ColumnFormat
- The value.
Returns
The same instance.
public static ProgressBar WithCountColumn(ProgressBar progressBar, Action<ColumnFormat> configure) #ProgressBarConfigures ProgressBar.CountColumn in place: Layout of the value in the value/total count (default right-aligned). The value reserves the width of the total, so the bar keeps its length as the value grows from 9 to 10.
Parameters
- progressBar ConsoleMonster.Widgets.ProgressBar
- The instance.
- configure System.Action<ConsoleMonster.Layout.ColumnFormat>
- Configures the value.
Returns
The same instance.
public static ProgressBar WithLabel(ProgressBar progressBar, String value) #ProgressBarSets ProgressBar.Label: The label (markup).
Parameters
- progressBar ConsoleMonster.Widgets.ProgressBar
- The instance.
- value System.String
- The value.
Returns
The same instance.
public static ProgressBar WithLabelWidth(ProgressBar progressBar, Int32? value) #ProgressBarSets ProgressBar.LabelWidth: A fixed label column width, or null to fit the label.
Parameters
- progressBar ConsoleMonster.Widgets.ProgressBar
- The instance.
- value System.Int32?
- The value.
Returns
The same instance.
public static ProgressBar WithRateWindow(ProgressBar progressBar, TimeSpan value) #ProgressBarSets ProgressBar.RateWindow: The moving window that smooths the rate and the remaining time (default 10 seconds).
Parameters
- progressBar ConsoleMonster.Widgets.ProgressBar
- The instance.
- value System.TimeSpan
- The value.
Returns
The same instance.
public static ProgressBar WithShape(ProgressBar progressBar, BarShape value) #ProgressBarSets ProgressBar.Shape: The bar shape: BarShape.Line (default, a thin stroke) or BarShape.Block (solid blocks).
Parameters
- progressBar ConsoleMonster.Widgets.ProgressBar
- The instance.
- value ConsoleMonster.Widgets.BarShape
- The value.
Returns
The same instance.
public static ProgressBar WithShowCount(ProgressBar progressBar, Boolean value = true) #ProgressBarSets ProgressBar.ShowCount: Whether the value/total count is shown (default true).
Parameters
- progressBar ConsoleMonster.Widgets.ProgressBar
- The instance.
- value System.Boolean = true
- The value (default true).
Returns
The same instance.
public static ProgressBar WithStatus(ProgressBar progressBar, StatusKind value) #ProgressBarSets ProgressBar.Status: The status; Pass/Fail/Warn change the bar colour once finished.
Parameters
- progressBar ConsoleMonster.Widgets.ProgressBar
- The instance.
- value ConsoleMonster.Styling.StatusKind
- The value.
Returns
The same instance.
public static ProgressBar WithTotal(ProgressBar progressBar, Double value) #ProgressBarSets ProgressBar.Total: The total (default 100).
Parameters
- progressBar ConsoleMonster.Widgets.ProgressBar
- The instance.
- value System.Double
- The value.
Returns
The same instance.
public static ProgressBar WithValue(ProgressBar progressBar, Double value) #ProgressBarSets ProgressBar.Value: The current value.
Parameters
- progressBar ConsoleMonster.Widgets.ProgressBar
- The instance.
- value System.Double
- The value.
Returns
The same instance.
Inherited Methods
public virtual Boolean Equals(Object? obj) #BooleanParameters
- obj Object?