Savarese Software Research

com.savarese.algorithms.spatial
Class RangeSearchTreeTestCase<Coord extends java.lang.Number & java.lang.Comparable<? super Coord>>

java.lang.Object
  extended by TestCase
      extended by com.savarese.algorithms.spatial.RangeSearchTreeTestCase<Coord>
Direct Known Subclasses:
KDTreeTest

public abstract class RangeSearchTreeTestCase<Coord extends java.lang.Number & java.lang.Comparable<? super Coord>>
extends TestCase

KDTreeTest tests the KDTree class.

Author:
Daniel F. Savarese

Field Summary
protected  com.savarese.algorithms.spatial.RangeSearchTree<Coord,com.savarese.algorithms.spatial.GenericPoint<Coord>,com.savarese.algorithms.spatial.GenericPoint<Coord>> _tree_
           
 
Constructor Summary
RangeSearchTreeTestCase()
           
 
Method Summary
protected
<M extends java.util.Map<com.savarese.algorithms.spatial.GenericPoint<Coord>,com.savarese.algorithms.spatial.GenericPoint<Coord>>>
void
_fillMap_(M map)
          Inserts a set of points into a map.
protected abstract  com.savarese.algorithms.spatial.RangeSearchTree<Coord,com.savarese.algorithms.spatial.GenericPoint<Coord>,com.savarese.algorithms.spatial.GenericPoint<Coord>> _newTreeFixture_()
          Creates a new RangeSearchTree instance for testing.
abstract  Coord getMaxCoord()
           
abstract  Coord getMinCoord()
           
abstract  int getNumPoints()
           
abstract  Coord newCoord(int val)
           
protected  void setUp()
          Instantiates _tree_ to use as a fixture for tests.
protected  void tearDown()
          Clears the tree fixture, removing all its contents so that a subsequent test will not be affected by the previous one.
 void testClear()
           
 void testContainsKey()
           
 void testContainsValue()
           
 void testEntrySet()
           
 void testEquals()
           
 void testGet()
           
 void testIterator()
           
 void testKeySet()
           
 void testPutAll()
           
 void testRemove()
           
 void testSize()
           
 void testValues()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

_tree_

protected com.savarese.algorithms.spatial.RangeSearchTree<Coord extends java.lang.Number & java.lang.Comparable<? super Coord>,com.savarese.algorithms.spatial.GenericPoint<Coord extends java.lang.Number & java.lang.Comparable<? super Coord>>,com.savarese.algorithms.spatial.GenericPoint<Coord extends java.lang.Number & java.lang.Comparable<? super Coord>>> _tree_
Constructor Detail

RangeSearchTreeTestCase

public RangeSearchTreeTestCase()
Method Detail

_newTreeFixture_

protected abstract com.savarese.algorithms.spatial.RangeSearchTree<Coord,com.savarese.algorithms.spatial.GenericPoint<Coord>,com.savarese.algorithms.spatial.GenericPoint<Coord>> _newTreeFixture_()
Creates a new RangeSearchTree instance for testing.

Returns:
A new RangeSearchTree instance for testing.

setUp

protected void setUp()
Instantiates _tree_ to use as a fixture for tests.


tearDown

protected void tearDown()
Clears the tree fixture, removing all its contents so that a subsequent test will not be affected by the previous one.


_fillMap_

protected <M extends java.util.Map<com.savarese.algorithms.spatial.GenericPoint<Coord>,com.savarese.algorithms.spatial.GenericPoint<Coord>>> void _fillMap_(M map)
Inserts a set of points into a map.

Parameters:
map - The map to fill with points.

newCoord

public abstract Coord newCoord(int val)

getMaxCoord

public abstract Coord getMaxCoord()

getMinCoord

public abstract Coord getMinCoord()

getNumPoints

public abstract int getNumPoints()

testSize

public void testSize()

testClear

public void testClear()

testContainsKey

public void testContainsKey()

testContainsValue

public void testContainsValue()

testGet

public void testGet()

testRemove

public void testRemove()

testPutAll

public void testPutAll()

testEntrySet

public void testEntrySet()

testKeySet

public void testKeySet()

testValues

public void testValues()

testIterator

public void testIterator()

testEquals

public void testEquals()

Savarese Software Research

Copyright © 2004-2005 Savarese Software Research and Daniel F. Savarese. All Rights Reserved.