Package com.azure.core.http.policy
Class FixedDelayOptions
- java.lang.Object
-
- com.azure.core.http.policy.FixedDelayOptions
-
public class FixedDelayOptions extends Object
The configuration for a fixed-delay retry that has a fixed delay duration between each retry attempt.
-
-
Constructor Summary
Constructors Constructor Description FixedDelayOptions(int maxRetries, Duration delay)Creates an instance ofmaxRetries.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description DurationgetDelay()Gets the max retry attempts that can be made.intgetMaxRetries()Gets the max retry attempts that can be made.
-
-
-
Constructor Detail
-
FixedDelayOptions
public FixedDelayOptions(int maxRetries, Duration delay)Creates an instance ofmaxRetries.- Parameters:
maxRetries- The max number of retry attempts that can be made.delay- The fixed delay duration between retry attempts.- Throws:
IllegalArgumentException- IfmaxRetriesis negative.NullPointerException- Ifdelayisnull.
-
-
Method Detail
-
getMaxRetries
public int getMaxRetries()
Gets the max retry attempts that can be made.- Returns:
- The max retry attempts that can be made.
-
getDelay
public Duration getDelay()
Gets the max retry attempts that can be made.- Returns:
- The max retry attempts that can be made.
-
-