Safe Haskell | None |
---|---|
Language | Haskell2010 |
- data ProgressBar = ProgressBar ProgressBarInfo (Async ())
- data Options = Options {
- pgFormat :: String
- pgCompletedChar :: Char
- pgPendingChar :: Char
- pgTotal :: Int
- pgWidth :: Int
- data Stats = Stats {}
- isComplete :: ProgressBar -> IO Bool
- newProgressBar :: Options -> IO ProgressBar
- tick :: ProgressBar -> IO ()
- tickN :: ProgressBar -> Int -> IO ()
- getProgressStrIO :: ProgressBar -> IO String
- getProgressStats :: ProgressBar -> IO Stats
- getProgressStr :: Options -> Stats -> String
- class Default a where
- def :: a
Documentation
data ProgressBar Source
The progress bar's options.
Options | |
|
Represents a point in time for the progress bar.
isComplete :: ProgressBar -> IO Bool Source
Returns if the progress bar rendering thread has exited (it has done enough ticks)
newProgressBar :: Options -> IO ProgressBar Source
Creates a new progress bar with the given Options
tick :: ProgressBar -> IO () Source
Tick the progress bar
tickN :: ProgressBar -> Int -> IO () Source
Tick the progress bar N times
getProgressStrIO :: ProgressBar -> IO String Source
Like getProgressStr
but works on the ProgressBar
object and uses the IO
monad.
getProgressStats :: ProgressBar -> IO Stats Source
Gets the progress bar current Stats
object
getProgressStr :: Options -> Stats -> String Source
Gets the string to be printed given the options object and a certain stats object representing the rendering moment.
class Default a where
A class for types with a default value.
def :: a
The default value for this type.