Safe Haskell | None |
---|---|
Language | Haskell98 |
- mkByteStringProgressBar :: ByteString -> (String -> IO ()) -> ℤ -> ℤ -> Label -> Label -> IO ByteString
- mkByteStringProgressWriter :: ByteString -> Handle -> ℤ -> ℤ -> Label -> Label -> IO ByteString
- fileReadProgressBar :: FilePath -> (String -> IO ()) -> ℤ -> Label -> Label -> IO ByteString
- fileReadProgressWriter :: FilePath -> Handle -> ℤ -> Label -> Label -> IO ByteString
Documentation
mkByteStringProgressBar Source #
:: ByteString | |
-> (String -> IO ()) | Function to call on update. |
-> ℤ | Progress bar width |
-> ℤ | The size of the ByteString |
-> Label | Prefixed label |
-> Label | Postfixed label |
-> IO ByteString |
Track the progress of a ByteString as it is consumed by some computation. This is the most general version in the library, and will render a progress string and pass it to the given function. See other functions for interacting with fixed-size files, the console, or generic Handles.
mkByteStringProgressWriter Source #
:: ByteString | The ByteString to track. |
-> Handle | Handle to write to |
-> ℤ | Progress bar width |
-> ℤ | The size of the ByteString |
-> Label | Prefixed label |
-> Label | Postfixed label |
-> IO ByteString |
As mkByteStringProgressBar, but simply print the output to the given Handle instead of using a callback.
:: FilePath | The file to load. |
-> (String -> IO ()) | Function to call on update. |
-> ℤ | Progress bar width |
-> Label | Prefixed label |
-> Label | Postfixed label |
-> IO ByteString |
Track the loading of a file as it is consumed by some computation. The use of this function should be essentially similar to ByteString's readFile, but with a lot more arguments and side effects.
fileReadProgressWriter Source #
:: FilePath | The file to load. |
-> Handle | Handle to write to |
-> ℤ | Progress bar width |
-> Label | Prefixed label |
-> Label | Postfixed label |
-> IO ByteString |
As fileReadProgressBar, but simply write the progress bar to the given Handle instead of calling a generic function.