public class HashTreeKdMap<DataType> extends java.lang.Object implements KdMap<DataType>
DataType identified by KdPoint KdPoint. Designed to speed up finding these
objects by their corresponding coordinates using a tree managed by a HashMap for each coordinate-axis. The method
add(KdPoint, Object) may be a bit slow. KdPoint.getDimensionCount() must fit dimensionCount
specified for this map!| Modifier and Type | Method and Description |
|---|---|
void |
add(KdPoint key,
DataType data)
Adds an item to the map.
|
void |
clear()
Destroys all entries within this map by recreating nodes and indices.
|
boolean |
containsKey(KdPoint key)
Checks, if a specific
KdPoint does exist. |
DataType |
get(KdPoint key)
Returns an object of Type
DataType identified by key. |
int |
getSize() |
java.util.Iterator<DataType> |
iterator()
Returns an iterator over elements of type
DataType. |
public int getSize()
public void add(KdPoint key, DataType data)
KdMappublic boolean containsKey(KdPoint key)
KdMapKdPoint does exist.containsKey in interface KdMap<DataType>key - The KdPoint being asked for.public DataType get(KdPoint key)
KdMapDataType identified by key.get in interface KdMap<DataType>key - The KdPoint being asked for.KdMap.add(KdPoint, Object).public void clear()
KdMap