dhconnelly / rtreego

an R-Tree library for Go

Home Page:http://dhconnelly.github.com/rtreego

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Filters should stop looping as soon as first refuses entry

db7 opened this issue · comments

Currently, when one is performing a search with filters, the ApplyFilters function will execute every single filter even though some of them might already have refused the item. If the loop would stop as soon as the first filter refuses the item, one can achieve great performance improvements by placing the most expensive filters at the end of the list of filters. So I'd suggest breaking the loop on the first refuse or abort.