Safe Haskell | Safe-Inferred |
---|---|
Language | Haskell2010 |
Synopsis
- data RetryLog step fail done
- toProgress :: RetryLog step fail done -> Progress step fail done
- fromProgress :: Progress step fail done -> RetryLog step fail done
- mapFailure :: (fail1 -> fail2) -> RetryLog step fail1 done -> RetryLog step fail2 done
- retry :: RetryLog step fail1 done -> (fail1 -> RetryLog step fail2 done) -> RetryLog step fail2 done
- failWith :: step -> fail -> RetryLog step fail done
- succeedWith :: step -> done -> RetryLog step fail done
- continueWith :: step -> RetryLog step fail done -> RetryLog step fail done
- tryWith :: Message -> RetryLog Message fail done -> RetryLog Message fail done
Documentation
data RetryLog step fail done Source #
Progress
as a difference list that allows efficient appends at failures.
toProgress :: RetryLog step fail done -> Progress step fail done Source #
fromProgress :: Progress step fail done -> RetryLog step fail done Source #
mapFailure :: (fail1 -> fail2) -> RetryLog step fail1 done -> RetryLog step fail2 done Source #
O(1). Apply a function to the failure value in a log.
retry :: RetryLog step fail1 done -> (fail1 -> RetryLog step fail2 done) -> RetryLog step fail2 done Source #
O(1). If the first log leads to failure, continue with the second.
failWith :: step -> fail -> RetryLog step fail done Source #
O(1). Create a log with one message before a failure.
succeedWith :: step -> done -> RetryLog step fail done Source #
O(1). Create a log with one message before a success.
continueWith :: step -> RetryLog step fail done -> RetryLog step fail done Source #
O(1). Prepend a message to a log.