App-schema will return incorrect results or hang when filter on polymorphic
attribute with more than 2 mappings
---------------------------------------------------------------------------------------------------------------
Key: GEOT-3492
URL: http://jira.codehaus.org/browse/GEOT-3492
Project: GeoTools
Issue Type: Bug
Components: data app-schema
Affects Versions: 2.7.0
Reporter: Eric Sword
Attachments: Multi-map_patch.patch, test-data.zip
The issue is in NestedAttributeExpression.getValues(). The loop over the
retrieved attrMappings will increment the index of the current XPath step for
each mapping when making the recursive getValues() calls (lines 200 and 223).
You only want to do that once before the attrMappings loop.
I have attached a patch with the fix (and a minor refactor for readability),
along with a unit test and associated files. All tests pass with the fix, but
that method is a bit complicated, so there is a chance I missed something.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
------------------------------------------------------------------------------
Create and publish websites with WebMatrix
Use the most popular FREE web apps or write code yourself;
WebMatrix provides all the features you need to develop and
publish your website. http://p.sf.net/sfu/ms-webmatrix-sf
_______________________________________________
Geotools-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/geotools-devel