Class Rounding
java.lang.Object
org.elasticsearch.common.rounding.Rounding
- All Implemented Interfaces:
Writeable
@Deprecated public abstract class Rounding extends java.lang.Object implements Writeable
Deprecated.
A strategy for rounding long values.
Use the java based Rounding class where applicable
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
Rounding.Builder
Deprecated.static class
Rounding.Streams
Deprecated.Nested classes/interfaces inherited from interface org.elasticsearch.common.io.stream.Writeable
Writeable.Reader<V>, Writeable.Writer<V>
-
Constructor Summary
Constructors Constructor Description Rounding()
Deprecated. -
Method Summary
Modifier and Type Method Description static Rounding.Builder
builder(DateTimeUnit unit)
Deprecated.static Rounding.Builder
builder(org.elasticsearch.common.unit.TimeValue interval)
Deprecated.abstract boolean
equals(java.lang.Object obj)
Deprecated.abstract int
hashCode()
Deprecated.abstract byte
id()
Deprecated.abstract long
nextRoundingValue(long value)
Deprecated.Given the rounded value (which was potentially generated byround(long)
, returns the next rounding value.abstract long
round(long value)
Deprecated.Rounds the given value.Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
-
Constructor Details
-
Rounding
public Rounding()Deprecated.
-
-
Method Details
-
id
public abstract byte id()Deprecated. -
round
public abstract long round(long value)Deprecated.Rounds the given value. -
nextRoundingValue
public abstract long nextRoundingValue(long value)Deprecated.Given the rounded value (which was potentially generated byround(long)
, returns the next rounding value. For example, with interval based rounding, if the interval is 3,nextRoundValue(6) = 9
.- Parameters:
value
- The current rounding value- Returns:
- The next rounding value;
-
equals
public abstract boolean equals(java.lang.Object obj)Deprecated.- Overrides:
equals
in classjava.lang.Object
-
hashCode
public abstract int hashCode()Deprecated.- Overrides:
hashCode
in classjava.lang.Object
-
builder
Deprecated. -
builder
Deprecated.
-