/[schmitzm]/trunk/src/skrueger/geotools/StyledLayerUtil.java
ViewVC logotype

Diff of /trunk/src/skrueger/geotools/StyledLayerUtil.java

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

branches/2.0-RC2/src/skrueger/geotools/StyledLayerUtil.java revision 677 by alfonx, Fri Feb 5 15:03:17 2010 UTC trunk/src/skrueger/geotools/StyledLayerUtil.java revision 714 by alfonx, Sun Feb 21 19:17:34 2010 UTC
# Line 914  public class StyledLayerUtil { Line 914  public class StyledLayerUtil {
914          }          }
915    
916          /**          /**
917             * *If appended to the name of a rule, this rule shall not be shown in the
918             * legend
919             */
920            public final static String HIDE_IN_LAYER_LEGEND_HINT = "HIDE_IN_LEGEND";
921    
922            /**
923           * Creates a {@link JPanel} that shows a legend for a list of           * Creates a {@link JPanel} that shows a legend for a list of
924           * {@link FeatureTypeStyle}s and a targeted featureType           * {@link FeatureTypeStyle}s and a targeted featureType
925           *           *
# Line 944  public class StyledLayerUtil { Line 950  public class StyledLayerUtil {
950                          final List<Rule> rules = ftStyle.rules();                          final List<Rule> rules = ftStyle.rules();
951                          for (final Rule rule : rules) {                          for (final Rule rule : rules) {
952    
953                                    // Check if this RULE shall actually appear in the legend
954                                    if (rule.getName() != null && rule.getName().endsWith(HIDE_IN_LAYER_LEGEND_HINT))
955                                            continue;
956    
957                                  /**                                  /**
958                                   * Let's not create a hbox for Rules that only contain                                   * Let's not create a hbox for Rules that only contain
959                                   * TextSymbolizers                                   * TextSymbolizers
# Line 1231  public class StyledLayerUtil { Line 1241  public class StyledLayerUtil {
1241           */           */
1242          public static void checkAttribMetaData(          public static void checkAttribMetaData(
1243                          AttributeMetadataMap attributeMetaDataMap, SimpleFeatureType schema) {                          AttributeMetadataMap attributeMetaDataMap, SimpleFeatureType schema) {
1244                    
1245                    if (schema == null) throw new IllegalArgumentException("schmema may not be null!");
1246    
1247                  ArrayList<Name> willRemove = new ArrayList<Name>();                  ArrayList<Name> willRemove = new ArrayList<Name>();
1248    

Legend:
Removed from v.677  
changed lines
  Added in v.714

[email protected]
ViewVC Help
Powered by ViewVC 1.1.26