Class Backoff.Constant
java.lang.Object
org.apache.bookkeeper.common.util.Backoff.Constant
- All Implemented Interfaces:
Backoff.Policy
- Enclosing class:
- Backoff
A constant backoff policy.
-
Field Summary
Fields inherited from interface org.apache.bookkeeper.common.util.Backoff.Policy
NONE -
Method Summary
Modifier and TypeMethodDescriptionprotected booleanbooleanlonggetLimit()longgetMs()inthashCode()static Backoff.Constantof(long ms) Create infinite constant backoff stream.static Backoff.Constantof(long ms, long limit) Convert the policy into a series of backoff values.toString()
-
Method Details
-
of
Create infinite constant backoff stream.It is the infinite version of
of(long, long).- Parameters:
ms- constant backoff time in milliseconds.- Returns:
- constant backoff policy.
-
toBackoffs
Description copied from interface:Backoff.PolicyConvert the policy into a series of backoff values.- Specified by:
toBackoffsin interfaceBackoff.Policy- Returns:
- a series of backoff values.
-
of
-
getMs
public long getMs() -
getLimit
public long getLimit() -
equals
-
canEqual
-
hashCode
public int hashCode() -
toString
-