Opened 19 years ago

Last modified 15 years ago

#1076 assigned enhancement

sld:ParameterValueType : support both literal expression instead of propertyname

Reported by: assefa Owned by: assefa
Priority: high Milestone: 6.0 release
Component: WMS Server Version: svn-trunk (development)
Severity: normal Keywords:
Cc:

Description

Here is an e-mail discussing concerning this :



>Tom,
>> 
>>   Here is my understanding of the specs concerning the 
>> sld:ParameterValueType" (which is taken form the sld 1.0 doc 
>> section 11.1.3)
>> 
>> 
>> <xs:element name="CssParameter" 
>> type="sld:ParameterValueType"/> <xs:complexType 
>> name="ParameterValueType" mixed="true"> <xs:choice 
>> minOccurs="0" maxOccurs="unbounded"> <xs:element 
>> ref="ogc:expression"/> </xs:choice> </xs:complexType>
>> 
>> The parameter values are allowed to be complex expressions 
>> for maximum 
>> flexibility.
>> The 'mixed="true"' definition means that regular text may be mixed in 
>> with various sub-expressions, implying a text-substitution model for 
>> parameter values. Numeric and character-string data types are not 
>> distinguished, which may cause some complications.
>> 
>> Here are some usage examples:
>> 
>> <CssParameter name="stroke-width">3</CssParameter>
>> 
>> <CssParameter name="stroke-width">
>> <ogc:Literal>3</ogc:Literal>
>> </CssParameter>
>> 
>> <CssParameter name="stroke-width">
>> <ogc:Add>
>> <ogc:PropertyName>A</ogc:PropertyName>
>> <ogc:Literal>2</ogc:Literal>
>> </ogc:Add>
>> </CssParameter>
>> 
>> <Label>This is city "<ogc:PropertyName>NAME</ogc:PropertyName>"
>> of state <ogc:PropertyName>STATE</ogc:PropertyName></Label>
>> 
>> 
>> I think supporting <Label>label_value</Label> should be valid. I 
>> downladed your sld file and fter adding the schemas at the 
>> top, It did 
>> valiadte using xml-spy. Does It make sense ?
>> (Note that I initially was supporting  the label inside a 
>> propertyName 
>> and the code is still there but commented out).
>> 


I retried this with just:

<Label>OBSDATE</Label>

..and it validated.

So both constructs are valid; should we support both when ingesting SLD
XML, and output one style when producing?

Change History (3)

comment:1 by assefa, 19 years ago

Cc: Tom.Kralidis@… added
Milestone: FUTURE
Setting this to 4.6 release. Should not be difficult to do but It is late for 
4.4.

comment:2 by assefa, 15 years ago

Milestone: FUTURE5.4 release
Owner: changed from mapserverbugs to assefa
Status: newassigned
Type: defectenhancement
Version: 4.4svn-trunk (development)

first pass at this is to support:

<CssParameter name="stroke-width"> <ogc:Literal>3</ogc:Literal> </CssParameter>

instead of only <CssParameter name="stroke-width">3</CssParameter>

<ogc:Literal>2</ogc:Literal>

comment:3 by assefa, 15 years ago

Milestone: 5.6 release6.0 release
Note: See TracTickets for help on using tickets.