Untitled
By: a guest | Mar 15th, 2010 | Syntax:
Java | Size: 0.87 KB | Hits: 33 | Expires: Never
if(q.contains(s)){
for(int i = 0; i < Llist.size(); i++){
returnList.add(i, Llist.get(i));
}
IntervalTreeNode tempr = rsub;
float sr = tempr.splitValue;
while(tempr!=null){
if(q.contains(sr)){
for(int i = 0; i<tempr.rightIntervals.size(); i++){
returnList.add(returnList.size(), tempr.rightIntervals.get(i));
}
}
else if(sr < q.leftEndPoint){
tempr = tempr.rightChild;
}
else{
tempr = tempr.leftChild;
}
}
IntervalTreeNode templ = lsub;
float sl = templ.splitValue;
while(templ!=null){
if(q.contains(sl)){
for(int i = 0; i<templ.leftIntervals.size(); i++){
returnList.add(returnList.size(), templ.leftIntervals.get(i));
}
}
else if(sl < q.leftEndPoint){
templ = templ.rightChild;
}
else{
templ = templ.leftChild;
}
}
}