Open tbonfort opened 12 years ago
Author: assefa Date: 2007/05/25 - 23:23 The intention is to do the following :
Add support in the Filter encoding to parse the spatial filters and call the query function. Additional gilters that will be supported are Equals, Disjoint, Touches, Crosses, Within, Contains, Overlaps (plus what was alreasy there : DWithin and Intersect). "Beyond" is not supported (not sure what that is).
The intention right now that all types of geometries (point, line, polygon) can be given in the filter. Not sure if I need to validate geomatries per type of operator.
Any comments ?
Author: tomkralidis Date: 2007/05/27 - 01:32
To confirm: this would be for Filter 1.0.0 (and not Filter 1.1.0), correct?
Here are the supported spatial filters from Filter 1.0.0 (specification: http://portal.opengeospatial.org/files/?artifact_id=1171, schema: http://schemas.opengis.net/filter/1.0.0/filter.xsd):
Equals (from SFSQL) Disjoint (from SFSQL) Touches (from SFSQL) Within (from SFSQL) Overlaps (from SFSQL) Crosses (from SFSQL) Intersects (from SFSQL) Contains (from SFSQL) DWithin Beyond BBOX
Explanations can be seen in Section 8 of the specification. FYI, geos fully supports the SFSQL spatial predicate functions. I wonder if geos supports DWithin or Beyond. BBOX is easy enough.
Note that, for the specifications which publish !GetCapabilities output (like WFS and SOS), these routines will also need to be looked over, and the correct !FilterCapabilities will have to be output.
Question: if someone builds !MapServer without geos, will any spatial filters be available, or are we moving all filters to geos?
Author: tomkralidis Date: 2007/05/27 - 23:23 Here's what Peter Vretanos (FES 1.0.0 spec editor) says about DWithin and Beyond:
"According to the BNF in the Cat 1.0 specification DWithin tests to see whether geometry A is completely within a certain distance of geometry B.
I interpret this to mean a "buffer" query. That is you create a buffer around A at the specified distance and then do a WITHIN (as defined in SFSQL) between this new buffer-expanded geometry (A') and the test geometry B. If B is completely within A' then the operator evaluates to true
BEYOND is the opposite of DWITHIN. If B is completely outside of A' then the operator evaluates to true."
Author: assefa Date: 2007/05/28 - 15:34
Author: nsavard Date: 2007/05/28 - 17:03 Replying to [comment:8 nsavard]:
As Assefa wrote there are two existing tests in msautotest and I'll work with him to add the tests to validate the other spatial filters.
Author: tomkralidis Date: 2007/05/28 - 18:36
For information / clarification:
GML 3:
GML 2:
ogc:SortBy ogc:SortProperty ogc:PropertyNametitle/ogc:PropertyName ogc:SortOrderDESC/ogc:SortOrder /ogc:SortProperty /ogc:SortBy
Other notes:
Note that most of the !MapServer OGC codebase leverages Filter 1.0.0, with the exception of SOS (to which we've basically implemented Filter 1.1.0 without the new features (i.e. looks like Filter 1.0.0).
We should discuss WFS 1.1.0 upgrading in a new ticket.
Author: assefa Date: 2007/06/04 - 16:27 Guys, I would like to do a commit on this. I have not tested all the operators but would like to use the upgrade/use the existing tests in msautotest to integrate additional operators. It is my hope that Norm (or others) would help me on building the tests and It feel It would be easier to build/test test cases when the functionality is available in cvs. What do you think ?
Tom : Are you opening a ticket for upgrade to WFS 1.1.0 and Filter 1.1. Depending on the amount of work, I am willing to do it before the 5.0. We need though to define it before June 15th and submit an RFC.
Author: tomkralidis Date: 2007/06/04 - 17:52
I think WFS 1.1.0 and Filter 1.1.0 would be a big piece of work for 5.0 (which shows for July 2007 for a final?). We would have to ensure that folks have time to get this going and implemented.
I'll open Filter 1.1.0 and WFS 1.1.0 tickets.
As for this ticket, sounds good. We'll have to test them for sure via WFS/SOS, through SLD, as well as the mapscript functions.
Author: tomkralidis Date: 2007/06/04 - 18:22 P.S. let's make sure we advertise these in the OGC code !FilterCapabilities. Currently, querying WFS or SOS !GetCapabilities in trunk returns only:
ogc:Filter_Capabilities ogc:Spatial_Capabilities ogc:Spatial_Operators ogc:Intersect/ ogc:DWithin/ ogc:BBOX/ /ogc:Spatial_Operators /ogc:Spatial_Capabilities ogc:Scalar_Capabilities
ogc:Comparison_Operators
<ogc:Simple_Comparisons />
<ogc:Like />
<ogc:Between />
/ogc:Comparison_Operators
/ogc:Scalar_Capabilities /ogc:Filter_Capabilities
Author: assefa Date: 2007/06/04 - 18:54 Commited first version (1d8b6f8c5c95823abbd6dfe5bcf4cef2bd31795a (r6169)) : tests done with Intersect and Dwithin using the msaoutotest tests/data. Capabilities updated Need to build tests for other operators. Need to upgrade docs.
Author: assefa Date: 2007/06/06 - 15:22 Steve,
I need to call up msGEOSSetup and I realise that there is a call to it inside function msSetup. But msSetup is not called from anywhere except from mapscript. Does it make sense to call this function when mapserver starts ?
Author: nsavard Date: 2007/06/21 - 19:37 Replying to [comment:7 assefa]:
- One of the major things for implemeting this is to create the tests data sets and integrate them in the msautotest. There is already some tests to filter encoding (Intersects and DWithin) and this should be expanded.
The tests for all spatial operators have been created and after their execution they produced the expected results.
Author: assefa Date: 2007/06/21 - 19:44 Need to update mapserver docs.
Author: assefa Date: 2007/08/08 - 15:51 Adding missing entry in HISTORY.txt 7f9285a69dbeab643966dca17bd257622b2f7dff (r6502)
Author: assefa Date: 2007/08/08 - 16:23 Added missing operators in doc. Closing.
Reporter: assefa Date: 2007/05/25 - 22:55 Filter encoding can use geos to support spatial operators.