public class RdKNNLeafEntry extends SpatialPointLeafEntry implements RdKNNEntry
NumberVector.Factory<V extends NumberVector>
Modifier and Type | Field and Description |
---|---|
private double |
knnDistance
The knn distance of the underlying data object.
|
private static long |
serialVersionUID |
Constructor and Description |
---|
RdKNNLeafEntry()
Empty constructor for serialization purposes.
|
RdKNNLeafEntry(DBID id,
NumberVector vector,
double knnDistance)
Constructs a new RDkNNLeafEntry object with the given parameters.
|
Modifier and Type | Method and Description |
---|---|
boolean |
equals(Object o)
Indicates whether some other object is "equal to" this one.
|
double |
getKnnDistance()
Returns the knn distance of this entry.
|
void |
readExternal(ObjectInput in)
Calls the super method and reads the knn distance of this entry from the
specified input stream.
|
void |
setKnnDistance(double knnDistance)
Sets the knn distance of this entry.
|
void |
writeExternal(ObjectOutput out)
Calls the super method and writes the knn distance of this entry to the
specified stream.
|
byteValue, doubleValue, floatValue, getColumnVector, getDimensionality, getMax, getMin, getValue, getValues, intValue, longValue, shortValue
getDBID, hashCode, isLeafEntry, toString
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
isLeafEntry
getDimensionality, getMax, getMin
toString
private static final long serialVersionUID
private double knnDistance
public RdKNNLeafEntry()
public RdKNNLeafEntry(DBID id, NumberVector vector, double knnDistance)
id
- the unique id of the underlying data objectvector
- the underlying data objectknnDistance
- the knn distance of the underlying data objectpublic double getKnnDistance()
RdKNNEntry
getKnnDistance
in interface RdKNNEntry
public void setKnnDistance(double knnDistance)
RdKNNEntry
setKnnDistance
in interface RdKNNEntry
knnDistance
- the knn distance to be setpublic void writeExternal(ObjectOutput out) throws IOException
writeExternal
in interface Externalizable
writeExternal
in class SpatialPointLeafEntry
out
- the stream to write the object toIOException
- Includes any I/O exceptions that may occurpublic void readExternal(ObjectInput in) throws IOException, ClassNotFoundException
readExternal
in interface Externalizable
readExternal
in class SpatialPointLeafEntry
in
- the stream to read data from in order to restore the objectIOException
- if I/O errors occurClassNotFoundException
- If the class for an object being restored
cannot be found.public boolean equals(Object o)
equals
in class AbstractLeafEntry
o
- the object to be testedCopyright © 2015 ELKI Development Team, Lehr- und Forschungseinheit für Datenbanksysteme, Ludwig-Maximilians-Universität München. License information.