I'm trying to create custom legend for a layer where OpenLayers.Rule objects are created dynamically and added to a layer.
new OpenLayers.Rule({
symbolizer: {
strokeColor : color,
fillColor: color
},
filter: new OpenLayers.Filter.Comparison({
type: OpenLayers.Filter.Comparison.BETWEEN,
property: p,
lowerBoundary: from,
upperBoundary: to
})
})); and so on ..
I need to extend functionality of legend where for each rule I need to extract how many vectors affected by the rule so that when user changes interval boundaries as above, drawn legend replaced by new numbers.
Is there any built-in functionality for this in OpenLayers ?