projects
/
anneal.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
checkpoint
[anneal.git]
/
src
/
edu
/
berkeley
/
qfat
/
geom
/
RTree.java
diff --git
a/src/edu/berkeley/qfat/geom/RTree.java
b/src/edu/berkeley/qfat/geom/RTree.java
index
c2fd9b4
..
eaa9f69
100644
(file)
--- a/
src/edu/berkeley/qfat/geom/RTree.java
+++ b/
src/edu/berkeley/qfat/geom/RTree.java
@@
-4,7
+4,7
@@
import java.util.*;
import com.infomatiq.jsi.*;
import com.infomatiq.jsi.rtree.*;
import com.infomatiq.jsi.*;
import com.infomatiq.jsi.rtree.*;
-public class RTree<V extends HasBoundingBox> {
+public class RTree<V extends HasBoundingBox> implements Iterable<V> {
private com.infomatiq.jsi.rtree.RTree rtree =
new com.infomatiq.jsi.rtree.RTree();
private com.infomatiq.jsi.rtree.RTree rtree =
new com.infomatiq.jsi.rtree.RTree();
@@
-13,6
+13,8
@@
public class RTree<V extends HasBoundingBox> {
HashMap<Integer, V> idToV = new HashMap<Integer, V>();
HashMap<V, Integer> vToId = new HashMap<V, Integer>();
HashMap<Integer, V> idToV = new HashMap<Integer, V>();
HashMap<V, Integer> vToId = new HashMap<V, Integer>();
+ public Iterator<V> iterator() { return vToId.keySet().iterator(); }
+
public RTree() {
Properties props = new Properties();
props.put("MinNodeEntries", "1");
public RTree() {
Properties props = new Properties();
props.put("MinNodeEntries", "1");