[OpenLayers-Trac] [OpenLayers] #533: Style vector layers with SLD

OpenLayers trac at openlayers.org
Tue Nov 6 07:50:36 EST 2007


#533: Style vector layers with SLD
----------------------+-----------------------------------------------------
  Reporter:  sderle   |       Owner:             
      Type:  feature  |      Status:  new        
  Priority:  minor    |   Milestone:  2.6 Release
 Component:  Layer    |     Version:             
Resolution:           |    Keywords:  review     
----------------------+-----------------------------------------------------
Comment (by elemoine):

 Hello!

 I've started reviewing Andreas' code. My first comments:

  * (line 234) !OpenLayers.Format.SLD's parseFilter() is annotated to
 return a String (line 234). This isn't correct, a rule is returnd by that
 method.

  * (line 405) The style property of an !OpenLayers.Layer.Vector object may
 cover multiple layers whereas only the part related to that object (layer)
 is relevant. Wouldn't it make sense to store only what's necessary? By
 doing so, we could also avoid the lookup done in getDefaultStyle().

  * !OpenLayers.Layer.WFS is part of the patch while it's untouched.

  * (line 21) !OpenLayers/Rule/Comparison.js: the type of APIProperty type
 is wrong, should be {<!OpenLayers.Rule.Comparison.Type>}

  * On a more general note, I don't like too much the fact that
 !OpenLayers.Layer.Vector's style property can be a hash or an
 !OpenLayers.Style object (instanceof must be used). Wouldn't be possible
 to use !OpenLayers.Style everywhere - !OpenLayers.Style looks pretty
 generic. Maybe you're concerned with backward compatibility here.

 I haven't reviewed the tests yet, but will do.

 Anyway, thanks for this excellent work Andreas.

-- 
Ticket URL: <http://trac.openlayers.org/ticket/533#comment:5>
OpenLayers <http://openlayers.org/>
A free AJAX map viewer


More information about the Trac mailing list