From: Rob Hranac <robhranac@vf...> - 2002-07-09 18:30:42
Bucking recent personal trends, I have actually done substantial work on
GeoTools this week and finished up the filters, with a massive assist
from James. Note that when I say filters, I mean OGC Filter spec
01-067, which encompasses BBOXes as well as other non-spatial attribute
queries. This turned out to be more complicated than I originally
thought and they still need a fair amount of work, but the framework is
now there. The filters are implemented using GoF composition and
chain-of-responsibility patterns. All the stuff that is relevant is
committed. For those who care, here is a short history of filters (as I
wrote some stuff that compiled but didn't really work
made all expressions work
made a couple of filters work
wrote some unit tests
made the rest of the filters work
wrote the rest of the unit tests
wrote an XML parser
Here are shortcomings/what needs to be done, in order of my priority:
(1) Finish XML parser unit tests. Right now they parse the first 3
examples from the spec. Soon to parse all 14 examples.
(2) Tighter coupling with schemas: this is pretty important. Basically,
filters are now implemented with only very weak reference to a schema,
which must be changed. However, the changes here cascade into other
things (for example, I think that it makes sense to make a bad feature
attribute access an unchecked exception or error), so this needs to be
hashed out first. Weak coupling leads to all sorts of stupid
assumptions. In particular, classes for the literals are essentially
guessed, using very bad things like error handling routines and this
needs to be fixed.
(3) Much room for various efficiency improvements. In particular, the
chain-of-responsibility design is not great for larger data sets.
Another must is to translate as much of the filters into SQL for spatial
databases as possible. This is actually a tricky question, but is
relatively high on my list for efficiency reasons.
(4) The whole issue of how data sources manage features in the context
of filters. This is essentially the interesting discussion raised by
Ray and Martin a couple of weeks ago. I don't claim to have definitive
answers, but I do have suggestions as to how it relates to filters.
(5) XQuery parser, which appears to be the long-term direction for the
filter encoding by the OGC.
James should fill in the blanks here and note where I am telling lies.
I will give a brief update to everyone at the IRC this afternoon, but I
will assume knowledge of this email.
The Open Planning Project
NY, NY 10013