Each rendering appends an additional "AND Filter.NONE" to each 
style.fts.rule.filter
------------------------------------------------------------------------------------

         Key: GEOT-747
         URL: http://jira.codehaus.org/browse/GEOT-747
     Project: GeoTools
        Type: Bug
  Components: shapefilerenderer  
 Reporter: Cory Horner
    Priority: Minor


The method findStyleAttributes(Query, Style, FeatureType) causes the filter to 
to grow on each rendering of the style.  When query.getFilter() == Filter.NONE, 
the filter quickly starts to look like this after a few uses:

[[[[[ PARTY = LIB ] AND Filter.NONE] AND Filter.NONE] AND Filter.NONE] AND 
Filter.NONE]

Looking at the code:

public void visit(Rule rule) {
  if ((query != Query.ALL) || !query.getFilter().equals(Filter.NONE)) {
    if (rule.getFilter() == null) {
      rule.setFilter(query.getFilter());
    } else {
      rule.setFilter(rule.getFilter().and(query.getFilter()));
    }
  }
...
}

...I would guess the second line should read:

  if ((query != Query.ALL) && !query.getFilter().equals(Filter.NONE)) {


-- 
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



-------------------------------------------------------
SF.Net email is sponsored by:
Tame your development challenges with Apache's Geronimo App Server. Download
it for free - -and be entered to win a 42" plasma tv or your very own
Sony(tm)PSP.  Click here to play: http://sourceforge.net/geronimo.php
_______________________________________________
Geotools-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/geotools-devel

Reply via email to