public class LogarithmicMapping
extends java.lang.Object
IndexMapping that is memory-optimal, that is to say that given a targeted
relative accuracy, it requires the least number of indices to cover a given range of values. This
is done by logarithmically mapping floating-point values to integers.| Constructor and Description |
|---|
LogarithmicMapping(double relativeAccuracy) |
| Modifier and Type | Method and Description |
|---|---|
void |
encode(Output output) |
boolean |
equals(java.lang.Object o) |
int |
hashCode() |
int |
index(double value) |
double |
lowerBound(int index) |
double |
maxIndexableValue() |
double |
minIndexableValue() |
double |
relativeAccuracy() |
void |
serialize(Serializer serializer) |
int |
serializedSize() |
double |
upperBound(int index) |
double |
value(int index) |
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, waitdecodepublic final int index(double value)
index in interface IndexMappingpublic final double value(int index)
value in interface IndexMappingpublic double lowerBound(int index)
lowerBound in interface IndexMappingpublic double upperBound(int index)
upperBound in interface IndexMappingpublic final double relativeAccuracy()
relativeAccuracy in interface IndexMappingpublic double minIndexableValue()
minIndexableValue in interface IndexMappingpublic double maxIndexableValue()
maxIndexableValue in interface IndexMappingpublic boolean equals(java.lang.Object o)
equals in class java.lang.Objectpublic int hashCode()
hashCode in class java.lang.Objectpublic void encode(Output output) throws java.io.IOException
encode in interface IndexMappingjava.io.IOExceptionpublic int serializedSize()
serializedSize in interface IndexMappingpublic void serialize(Serializer serializer)
serialize in interface IndexMapping