PeanutButter
|
Provides a wrapping context around retried code. More...
Public Member Functions | |
MaxAttemptsRetryContext (int maxAttempts, Func< IBackoffStrategy > defaultBackoffStrategy) | |
Creates a RetryContext for the specified maxRetries. | |
void | Times (Action toRun, [CallerMemberName] string caller=null) |
Run the code... | |
void | Times (Action toRun, IBackoffStrategy backoffStrategy, [CallerMemberName] string caller=null) |
Run the code... | |
void | Times (Action toRun, Func< Exception, ExceptionHandlingStrategies > exceptionHandler, [CallerMemberName] string caller=null) |
Run the code... | |
async Task | TimesAsync (Func< Task > toRun, [CallerMemberName] string caller=null) |
Run the provided func up to the specified number of times, or until it completes successfully. | |
async Task | TimesAsync (Func< Task > toRun, Func< Exception, Task< ExceptionHandlingStrategies > > exceptionHandler, [CallerMemberName] string caller=null) |
Run the code... | |
async Task | TimesAsync (Func< int, Task > toRun, Func< Exception, Task< ExceptionHandlingStrategies > > exceptionHandler, [CallerMemberName] string caller=null) |
Run the code... | |
async Task | TimesAsync (Func< int, Task > toRun, IBackoffStrategy backoffStrategy, Func< Exception, Task< ExceptionHandlingStrategies > > exceptionHandler, [CallerMemberName] string caller=null) |
void | Times (Action toRun, IBackoffStrategy backoffStrategy, Func< Exception, ExceptionHandlingStrategies > exceptionHandler, [CallerMemberName] string caller=null) |
Run the code... | |
void | Times (Action< int > toRun, [CallerMemberName] string caller=null) |
Run the code... | |
void | Times (Action< int > toRun, IBackoffStrategy backoffStrategy, [CallerMemberName] string caller=null) |
Run the code... | |
void | Times (Action< int > toRun, Func< Exception, ExceptionHandlingStrategies > exceptionHandler, [CallerMemberName] string caller=null) |
Run the code... | |
void | Times (Action< int > toRun, IBackoffStrategy backoffStrategy, Func< Exception, ExceptionHandlingStrategies > exceptionHandler, [CallerMemberName] string caller=null) |
Run the code... | |
async Task< T > | Times< T > (Func< int, Task< T > > toRun, [CallerMemberName] string caller=null) |
Run the code... | |
async Task< T > | Times< T > (Func< int, Task< T > > toRun, IBackoffStrategy backoffStrategy, [CallerMemberName] string caller=null) |
Run the code... | |
async Task< T > | Times< T > (Func< int, Task< T > > toRun, IBackoffStrategy backoffStrategy, Func< Exception, ExceptionHandlingStrategies > exceptionHandler=null, [CallerMemberName] string caller=null) |
Run the code... | |
T | Times< T > (Func< T > toRun, [CallerMemberName] string caller=null) |
Run the code... | |
T | Times< T > (Func< T > toRun, IBackoffStrategy backoffStrategy, [CallerMemberName] string caller=null) |
Run the code... | |
T | Times< T > (Func< T > toRun, Func< Exception, ExceptionHandlingStrategies > exceptionHandler, [CallerMemberName] string caller=null) |
Run the code... | |
T | Times< T > (Func< int, T > toRun, [CallerMemberName] string caller=null) |
Run the code... | |
T | Times< T > (Func< int, T > toRun, IBackoffStrategy backoffStrategy, [CallerMemberName] string caller=null) |
Run the code... | |
T | Times< T > (Func< int, T > toRun, Func< Exception, ExceptionHandlingStrategies > exceptionHandler=null, [CallerMemberName] string caller=null) |
Run the code... | |
T | Times< T > (Func< int, T > toRun, IBackoffStrategy backoffStrategy, Func< Exception, ExceptionHandlingStrategies > exceptionHandler=null, [CallerMemberName] string caller=null) |
Run the code... | |
async Task | Times (Func< int, Task > toRun, [CallerMemberName] string caller=null) |
Run the code... | |
async Task | Times (Func< int, Task > toRun, IBackoffStrategy backoffStrategy, [CallerMemberName] string caller=null) |
Run the code... | |
async Task | Times (Func< int, Task > toRun, Func< Exception, ExceptionHandlingStrategies > exceptionHandler, [CallerMemberName] string caller=null) |
Run the code... | |
async Task | Times (Func< Task > toRun, [CallerMemberName] string caller=null) |
Run the code... | |
async Task | Times (Func< Task > toRun, IBackoffStrategy backoffStrategy, [CallerMemberName] string caller=null) |
Run the code... | |
async Task | Times (Func< Task > toRun, Func< Exception, ExceptionHandlingStrategies > exceptionHandler, [CallerMemberName] string caller=null) |
Run the code... | |
async Task | Times (Func< int, Task > toRun, IBackoffStrategy backoffStrategy, Func< Exception, ExceptionHandlingStrategies > exceptionHandler, [CallerMemberName] string caller=null) |
Run the code... |
Properties | |
int | MaxAttempts [get] |
Maximum number of times to try before giving up. |
Provides a wrapping context around retried code.
PeanutButter.Utils.MaxAttemptsRetryContext.MaxAttemptsRetryContext | ( | int | maxAttempts, |
Func< IBackoffStrategy > | defaultBackoffStrategy ) |
Creates a RetryContext for the specified maxRetries.
maxAttempts | |
defaultBackoffStrategy |
void PeanutButter.Utils.MaxAttemptsRetryContext.Times | ( | Action | toRun, |
[CallerMemberName] string | caller = null ) |
Run the code...
toRun | |
caller |
void PeanutButter.Utils.MaxAttemptsRetryContext.Times | ( | Action | toRun, |
Func< Exception, ExceptionHandlingStrategies > | exceptionHandler, | ||
[CallerMemberName] string | caller = null ) |
Run the code...
toRun | |
exceptionHandler | |
caller |
void PeanutButter.Utils.MaxAttemptsRetryContext.Times | ( | Action | toRun, |
IBackoffStrategy | backoffStrategy, | ||
[CallerMemberName] string | caller = null ) |
Run the code...
toRun | |
backoffStrategy | |
caller |
void PeanutButter.Utils.MaxAttemptsRetryContext.Times | ( | Action | toRun, |
IBackoffStrategy | backoffStrategy, | ||
Func< Exception, ExceptionHandlingStrategies > | exceptionHandler, | ||
[CallerMemberName] string | caller = null ) |
Run the code...
toRun | |
backoffStrategy | |
exceptionHandler | |
caller |
void PeanutButter.Utils.MaxAttemptsRetryContext.Times | ( | Action< int > | toRun, |
[CallerMemberName] string | caller = null ) |
Run the code...
toRun | |
caller |
void PeanutButter.Utils.MaxAttemptsRetryContext.Times | ( | Action< int > | toRun, |
Func< Exception, ExceptionHandlingStrategies > | exceptionHandler, | ||
[CallerMemberName] string | caller = null ) |
Run the code...
toRun | |
exceptionHandler | |
caller |
void PeanutButter.Utils.MaxAttemptsRetryContext.Times | ( | Action< int > | toRun, |
IBackoffStrategy | backoffStrategy, | ||
[CallerMemberName] string | caller = null ) |
Run the code...
toRun | |
backoffStrategy | |
caller |
void PeanutButter.Utils.MaxAttemptsRetryContext.Times | ( | Action< int > | toRun, |
IBackoffStrategy | backoffStrategy, | ||
Func< Exception, ExceptionHandlingStrategies > | exceptionHandler, | ||
[CallerMemberName] string | caller = null ) |
Run the code...
toRun | |
backoffStrategy | |
exceptionHandler | |
caller |
async Task PeanutButter.Utils.MaxAttemptsRetryContext.Times | ( | Func< int, Task > | toRun, |
[CallerMemberName] string | caller = null ) |
Run the code...
toRun | |
caller |
async Task PeanutButter.Utils.MaxAttemptsRetryContext.Times | ( | Func< int, Task > | toRun, |
Func< Exception, ExceptionHandlingStrategies > | exceptionHandler, | ||
[CallerMemberName] string | caller = null ) |
Run the code...
toRun | |
exceptionHandler | |
caller |
async Task PeanutButter.Utils.MaxAttemptsRetryContext.Times | ( | Func< int, Task > | toRun, |
IBackoffStrategy | backoffStrategy, | ||
[CallerMemberName] string | caller = null ) |
Run the code...
toRun | |
backoffStrategy | |
caller |
async Task PeanutButter.Utils.MaxAttemptsRetryContext.Times | ( | Func< int, Task > | toRun, |
IBackoffStrategy | backoffStrategy, | ||
Func< Exception, ExceptionHandlingStrategies > | exceptionHandler, | ||
[CallerMemberName] string | caller = null ) |
Run the code...
toRun | |
backoffStrategy | |
exceptionHandler | |
caller |
async Task PeanutButter.Utils.MaxAttemptsRetryContext.Times | ( | Func< Task > | toRun, |
[CallerMemberName] string | caller = null ) |
Run the code...
toRun | |
caller |
async Task PeanutButter.Utils.MaxAttemptsRetryContext.Times | ( | Func< Task > | toRun, |
Func< Exception, ExceptionHandlingStrategies > | exceptionHandler, | ||
[CallerMemberName] string | caller = null ) |
Run the code...
toRun | |
exceptionHandler | |
caller |
async Task PeanutButter.Utils.MaxAttemptsRetryContext.Times | ( | Func< Task > | toRun, |
IBackoffStrategy | backoffStrategy, | ||
[CallerMemberName] string | caller = null ) |
Run the code...
toRun | |
backoffStrategy | |
caller |
T PeanutButter.Utils.MaxAttemptsRetryContext.Times< T > | ( | Func< int, T > | toRun, |
[CallerMemberName] string | caller = null ) |
Run the code...
toRun | |
caller |
T PeanutButter.Utils.MaxAttemptsRetryContext.Times< T > | ( | Func< int, T > | toRun, |
Func< Exception, ExceptionHandlingStrategies > | exceptionHandler = null, | ||
[CallerMemberName] string | caller = null ) |
Run the code...
toRun | |
exceptionHandler | |
caller |
T PeanutButter.Utils.MaxAttemptsRetryContext.Times< T > | ( | Func< int, T > | toRun, |
IBackoffStrategy | backoffStrategy, | ||
[CallerMemberName] string | caller = null ) |
Run the code...
toRun | |
backoffStrategy | |
caller |
T PeanutButter.Utils.MaxAttemptsRetryContext.Times< T > | ( | Func< int, T > | toRun, |
IBackoffStrategy | backoffStrategy, | ||
Func< Exception, ExceptionHandlingStrategies > | exceptionHandler = null, | ||
[CallerMemberName] string | caller = null ) |
Run the code...
toRun | |
backoffStrategy | |
exceptionHandler | |
caller |
async Task< T > PeanutButter.Utils.MaxAttemptsRetryContext.Times< T > | ( | Func< int, Task< T > > | toRun, |
[CallerMemberName] string | caller = null ) |
Run the code...
toRun | |
caller |
async Task< T > PeanutButter.Utils.MaxAttemptsRetryContext.Times< T > | ( | Func< int, Task< T > > | toRun, |
IBackoffStrategy | backoffStrategy, | ||
[CallerMemberName] string | caller = null ) |
Run the code...
toRun | |
backoffStrategy | |
caller |
async Task< T > PeanutButter.Utils.MaxAttemptsRetryContext.Times< T > | ( | Func< int, Task< T > > | toRun, |
IBackoffStrategy | backoffStrategy, | ||
Func< Exception, ExceptionHandlingStrategies > | exceptionHandler = null, | ||
[CallerMemberName] string | caller = null ) |
Run the code...
toRun | |
backoffStrategy | |
exceptionHandler | |
caller |
T PeanutButter.Utils.MaxAttemptsRetryContext.Times< T > | ( | Func< T > | toRun, |
[CallerMemberName] string | caller = null ) |
Run the code...
toRun | |
caller |
T PeanutButter.Utils.MaxAttemptsRetryContext.Times< T > | ( | Func< T > | toRun, |
Func< Exception, ExceptionHandlingStrategies > | exceptionHandler, | ||
[CallerMemberName] string | caller = null ) |
Run the code...
toRun | |
exceptionHandler | |
caller |
T PeanutButter.Utils.MaxAttemptsRetryContext.Times< T > | ( | Func< T > | toRun, |
IBackoffStrategy | backoffStrategy, | ||
[CallerMemberName] string | caller = null ) |
Run the code...
toRun | |
backoffStrategy | |
caller |
async Task PeanutButter.Utils.MaxAttemptsRetryContext.TimesAsync | ( | Func< int, Task > | toRun, |
Func< Exception, Task< ExceptionHandlingStrategies > > | exceptionHandler, | ||
[CallerMemberName] string | caller = null ) |
Run the code...
toRun | |
exceptionHandler | |
caller |
async Task PeanutButter.Utils.MaxAttemptsRetryContext.TimesAsync | ( | Func< int, Task > | toRun, |
IBackoffStrategy | backoffStrategy, | ||
Func< Exception, Task< ExceptionHandlingStrategies > > | exceptionHandler, | ||
[CallerMemberName] string | caller = null ) |
toRun | |
backoffStrategy | |
exceptionHandler | |
caller |
async Task PeanutButter.Utils.MaxAttemptsRetryContext.TimesAsync | ( | Func< Task > | toRun, |
[CallerMemberName] string | caller = null ) |
Run the provided func up to the specified number of times, or until it completes successfully.
toRun | |
caller |
async Task PeanutButter.Utils.MaxAttemptsRetryContext.TimesAsync | ( | Func< Task > | toRun, |
Func< Exception, Task< ExceptionHandlingStrategies > > | exceptionHandler, | ||
[CallerMemberName] string | caller = null ) |
Run the code...
toRun | |
exceptionHandler | |
caller |