Struct sortery::messages::ProgressBar [−][src]
Expand description
The command-line progress bar used when sorting.
-
completed_message
is aString
of the message to be printed whenProgressBar::complete
is called. -
message
is aString
to be shown while the progress bar is between start and finish, for example"Still working..."
total
is ausize
representing the total value of the progress bar. Bar pogress and percent completed are calculated usingtotal
. For example, if you are going to sort 20 files, you would pass 20 tototal
, and the progress bar would know to show50%
whenset_progress(10)
is called.
Fields
completed_message: String
message: String
total: usize
Implementations
Print the updated progress bar, with completed
number of items completed
out of the total. Automatically calculates percent and bar size.