Class AttemptRuleDefault
java.lang.Object
org.spincast.plugins.attemptslimiter.AttemptRuleDefault
- All Implemented Interfaces:
AttemptRule
-
Constructor Summary
ConstructorDescriptionAttemptRuleDefault
(String actionName, int nbrMaxAttemptsPerDuration, Duration duration) -
Method Summary
Modifier and TypeMethodDescriptionThe action to protect.The duration in which a maximum number of attempts is allowed.int
The number of allowed attempts in a given duration.
-
Constructor Details
-
AttemptRuleDefault
-
-
Method Details
-
getActionName
Description copied from interface:AttemptRule
The action to protect.- Specified by:
getActionName
in interfaceAttemptRule
-
getNbrMaxAttemptsPerDuration
public int getNbrMaxAttemptsPerDuration()Description copied from interface:AttemptRule
The number of allowed attempts in a given duration.- Specified by:
getNbrMaxAttemptsPerDuration
in interfaceAttemptRule
-
getDuration
Description copied from interface:AttemptRule
The duration in which a maximum number of attempts is allowed.- Specified by:
getDuration
in interfaceAttemptRule
-