for (Layer layer : mapContext.layers()) { Rule[] applicableRules = LegendUtils.getApplicableRules( layer.getStyle().featureTypeStyles().toArray(new FeatureTypeStyle[0]), scaleDenominator);
applicableRules = LegendUtils.getApplicableRules(ftStyles, scaleDenominator);
applicableRules = LegendUtils.getApplicableRules(ftStyles, scaleDenominator);
applicableRules = LegendUtils.getApplicableRules(ftStyles, scaleDenominator);