Uses of Class
com.github.cowwoc.tokenbucket.Limit
Packages that use Limit
-
Uses of Limit in com.github.cowwoc.tokenbucket
Methods in com.github.cowwoc.tokenbucket that return LimitModifier and TypeMethodDescriptionLimit.Builder.build()
Builds a new Limit.Bucket.getLimitWithLowestRefillRate()
Returns the limit with the lowest refill rate.Methods in com.github.cowwoc.tokenbucket that return types with arguments of type LimitModifier and TypeMethodDescriptionConsumptionResult.getBottlenecks()
Returns the list of limits that are preventing tokens from being consumed.Bucket.getLimits()
Returns the limits associated with this bucket.Bucket.Builder.limits()
Returns the limits that the bucket must respect.Bucket.ConfigurationUpdater.limits()
Returns the limits that the bucket must respect.Methods in com.github.cowwoc.tokenbucket with parameters of type LimitModifier and TypeMethodDescriptionBucket.ConfigurationUpdater.removeLimit
(Limit limit) Removes a limit that the bucket must respect.Method parameters in com.github.cowwoc.tokenbucket with type arguments of type LimitModifier and TypeMethodDescriptionBucket.Builder.addLimit
(Function<Limit.Builder, Limit> limitBuilder) Adds a limit that the bucket must respect.Bucket.ConfigurationUpdater.addLimit
(Function<Limit.Builder, Limit> limitBuilder) Adds a limit that the bucket must respect.default void
ContainerListener.beforeSleep
(Container container, long tokens, Instant requestedAt, Instant availableAt, List<Limit> bottlenecks) Invoked before sleeping to wait for more tokens.Constructor parameters in com.github.cowwoc.tokenbucket with type arguments of type LimitModifierConstructorDescriptionConsumptionResult
(Container container, long minimumTokensRequested, long maximumTokensRequested, long tokensConsumed, Instant requestedAt, Instant consumedAt, Instant availableAt, long tokensLeft, List<Limit> bottlenecks) Creates a result of a request to consume tokens.