Using 2.1-RC4 I'm trying to test SLD/SE 1.1 functionality but the validator
complains and when trying to use the styles anyway the visualization uses
the default style. Do I need to enable 1.1 support somehow? The validator
says that StyledLayerDescriptor "version" is a fixed value of "1.0.0" so
that's why I'm wondering if my setup does not have 1.1 enabled.
Examples 1:
<StyledLayerDescriptor version="1.1.0"
xsi:schemaLocation="
http://schemas.opengis.net/sld/1.1/StyledLayerDescriptor.xsd"
xmlns="http://www.opengis.net/sld"
xmlns:sld="http://www.opengis.net/sld"
xmlns:ogc="http://www.opengis.net/ogc"
xmlns:se="http://www.opengis.net/se"
xmlns:xlink="http://www.w3.org/1999/xlink"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<NamedLayer>
<se:Name>nyc_roads/nyc_roads</se:Name>
<UserStyle>
<se:Name>Test</se:Name>
<IsDefault>1</IsDefault>
<se:FeatureTypeStyle>
<se:FeatureTypeName>
LN_Road_AllWeather_HardSurface_Operational_NoMedian__MultipleLanes</
se:FeatureTypeName>
<se:Rule>
<se:LineSymbolizer>
<se:Stroke>
<se:SvgParameter name="stroke">#782327</se:SvgParameter>
<se:SvgParameter name="stroke-width">2</se:SvgParameter>
</se:Stroke>
</se:LineSymbolizer>
</se:Rule>
</se:FeatureTypeStyle>
</UserStyle>
</NamedLayer>
</StyledLayerDescriptor>
Gives:
- org.xml.sax.SAXParseException: cvc-complex-type.3.1: Value '1.1.0' of
attribute 'version' of element 'StyledLayerDescriptor' is not valid with
respect to the corresponding attribute use. Attribute 'version' has a fixed
value of '1.0.0'.
- org.xml.sax.SAXParseException: cvc-complex-type.2.4.a: Invalid content
was found starting with element 'se:Name'. One of '{"
http://www.opengis.net/sld":Name}' is expected.
- org.xml.sax.SAXParseException: cvc-complex-type.2.4.a: Invalid content
was found starting with element 'se:Name'. One of '{"
http://www.opengis.net/sld":Name, "http://www.opengis.net/sld":Title, "
http://www.opengis.net/sld":Abstract,
"http://www.opengis.net/sld":IsDefault,
"http://www.opengis.net/sld":FeatureTypeStyle}' is expected.
- org.xml.sax.SAXParseException: TargetNamespace.2: Expecting no
namespace, but the schema document has a target namespace of '
http://www.opengis.net/sld'.
- org.xml.sax.SAXParseException: TargetNamespace.2: Expecting no
namespace, but the schema document has a target namespace of '
http://www.opengis.net/sld'.
- org.xml.sax.SAXParseException: TargetNamespace.2: Expecting no
namespace, but the schema document has a target namespace of '
http://www.opengis.net/sld'.
Example 2:
<?xml version="1.0" encoding="UTF-8"?>
<StyledLayerDescriptor version="1.1.0"
xmlns="http://www.opengis.net/sld"
xmlns:se="http://www.opengis.net/se"
xmlns:ogc="http://www.opengis.net/ogc"
xmlns:xlink="http://www.w3.org/1999/xlink"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.opengis.net/sld
http://schemas.opengis.net/sld/1.1.0/StyledLayerDescriptor.xsd">
<NamedLayer>
<se:Name>country_bounds</se:Name>
<UserStyle>
<se:Name>xxx</se:Name>
<se:FeatureTypeStyle>
<se:Rule>
<se:LineSymbolizer>
<se:Geometry>
<ogc:PropertyName>center-line</ogc:PropertyName>
</se:Geometry>
<se:Stroke>
<se:SvgParameter name="stroke">#0000ff</se:SvgParameter>
</se:Stroke>
</se:LineSymbolizer>
</se:Rule>
</se:FeatureTypeStyle>
</UserStyle>
</NamedLayer>
</StyledLayerDescriptor>
Gives:
- org.xml.sax.SAXParseException: cvc-complex-type.3.1: Value '1.1.0' of
attribute 'version' of element 'StyledLayerDescriptor' is not valid with
respect to the corresponding attribute use. Attribute 'version' has a fixed
value of '1.0.0'.
- org.xml.sax.SAXParseException: cvc-complex-type.2.4.a: Invalid content
was found starting with element 'se:Name'. One of '{"
http://www.opengis.net/sld":Name}' is expected.
- org.xml.sax.SAXParseException: cvc-complex-type.2.4.a: Invalid content
was found starting with element 'se:Name'. One of '{"
http://www.opengis.net/sld":Name, "http://www.opengis.net/sld":Title, "
http://www.opengis.net/sld":Abstract,
"http://www.opengis.net/sld":IsDefault,
"http://www.opengis.net/sld":FeatureTypeStyle}' is expected.
- org.xml.sax.SAXParseException: TargetNamespace.2: Expecting no
namespace, but the schema document has a target namespace of '
http://www.opengis.net/sld'.
Regards,
Karl Hedlund
------------------------------------------------------------------------------
Forrester Wave Report - Recovery time is now measured in hours and minutes
not days. Key insights are discussed in the 2010 Forrester Wave Report as
part of an in-depth evaluation of disaster recovery service providers.
Forrester found the best-in-class provider in terms of services and vision.
Read this report now! http://p.sf.net/sfu/ibm-webcastpromo
_______________________________________________
Geoserver-users mailing list
Geoserver-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geoserver-users