
class DoubleIntegerDBIDPairList extends Object implements ModifiableDoubleDBIDList, IntegerDBIDs
| Modifier and Type | Class and Description |
|---|---|
private class |
DoubleIntegerDBIDPairList.Itr
List iterator.
|
| Modifier and Type | Field and Description |
|---|---|
(package private) DoubleIntegerDBIDPair[] |
data
Distance values
|
(package private) int |
size
The size
|
| Modifier | Constructor and Description |
|---|---|
protected |
DoubleIntegerDBIDPairList()
Constructor.
|
protected |
DoubleIntegerDBIDPairList(int size)
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
void |
add(DoubleDBIDPair pair)
Add an element.
|
void |
add(double dist,
DBIDRef id)
Add an object to this result.
|
protected void |
addInternal(DoubleIntegerDBIDPair pair)
Add an entry, consisting of distance and internal index.
|
void |
clear()
Clear the list contents.
|
boolean |
contains(DBIDRef o)
Test whether an ID is contained.
|
DoubleIntegerDBIDPair |
get(int index)
Materialize a single pair.
|
boolean |
isEmpty()
Test for an empty DBID collection.
|
DoubleIntegerDBIDPairList.Itr |
iter()
Get an iterator
|
protected void |
reverse()
Reverse the list.
|
int |
size()
Size of list.
|
void |
sort()
Sort the result in ascending order
|
String |
toString() |
int size
DoubleIntegerDBIDPair[] data
protected DoubleIntegerDBIDPairList()
protected DoubleIntegerDBIDPairList(int size)
size - Initial sizepublic DoubleIntegerDBIDPairList.Itr iter()
DoubleDBIDListiter in interface DBIDsiter in interface DoubleDBIDListiter in interface IntegerDBIDspublic boolean contains(DBIDRef o)
DBIDspublic boolean isEmpty()
DBIDspublic int size()
DoubleDBIDListsize in interface DBIDssize in interface DoubleDBIDListpublic DoubleIntegerDBIDPair get(int index)
DoubleDBIDListget in interface DoubleDBIDListindex - Offsetprotected void addInternal(DoubleIntegerDBIDPair pair)
pair - entrypublic void add(double dist,
DBIDRef id)
ModifiableDoubleDBIDListadd in interface ModifiableDoubleDBIDListdist - Distance to addid - DBID to addpublic void add(DoubleDBIDPair pair)
ModifiableDoubleDBIDListadd in interface ModifiableDoubleDBIDListpair - Pair to addpublic void clear()
ModifiableDoubleDBIDListclear in interface ModifiableDoubleDBIDListpublic void sort()
ModifiableDoubleDBIDListsort in interface ModifiableDoubleDBIDListprotected void reverse()
Copyright © 2014 ELKI Development Team, Lehr- und Forschungseinheit für Datenbanksysteme, Ludwig-Maximilians-Universität München. License information.