Package org.geotools.filter.function

Examples of org.geotools.filter.function.ExplicitClassifier


                    //really you can't mix the two so the ui
                    //should probably be made smarter.
                    this.styleThemePage.customBreak = new RangedClassifier(min.toArray(new Double[min.size()]), max.toArray(new Double[max.size()]));
                }else{
                    //lets make a explicit classifier
                    this.styleThemePage.customBreak = new ExplicitClassifier(values);
                }
               
               
                Combo breaks = this.styleThemePage.getCombo(StyleThemePage.COMBO_BREAKTYPE);
                String[] allBreaks = breaks.getItems();
View Full Code Here


    } catch (IOException e) {
      fail(e.getMessage());
      e.printStackTrace();
    }
        
     ExplicitClassifier classifier = new ExplicitClassifier(binValues2);
         Color[] colors = brewer.getPalette(paletteName).getColors(binValues2.length);

         // get the fts
         FeatureTypeStyle fts = StyleGenerator.createFeatureTypeStyle(classifier, expr, colors,
                 "myfts", riverFeatures[0].getFeatureType().getGeometryDescriptor(),
View Full Code Here

                Rule rule = createRuleRanged(ranged, expression, localMin, localMax,
                        geometryAttrType, i, elseMode, colors, opacity, defaultStroke);
                fts.addRule(rule);
            }
        } else if (classifier instanceof ExplicitClassifier) {
            ExplicitClassifier explicit = (ExplicitClassifier) classifier;

            // for each class
            for (int i = 0; i < explicit.getSize(); i++) {
                Set value = (Set) explicit.getValues(i);
                Rule rule = createRuleExplicit(explicit, expression, value, geometryAttrType, i,
                        elseMode, colors, opacity, defaultStroke);
                fts.addRule(rule);
            }
        } else {
View Full Code Here

    // municipal or crown parkland
    zones[1] = new HashSet(Arrays.asList(new String[] { "Zone 4", "Crown 2", }));
    // industrial
    zones[2] = new HashSet(Arrays.asList(new String[] { "Zone 3" }));
   
    Classifier landuse = new ExplicitClassifier(zones);
    landuse.setTitle(0, "urban");
    landuse.setTitle(1, "park");
    landuse.setTitle(2, "industrial");
    // explicitClassifierExample end
}
View Full Code Here

TOP

Related Classes of org.geotools.filter.function.ExplicitClassifier

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.