OpenLayers.Format.SLD - OpenLayers

# OpenLayers. Format.SLD

Read/Wite SLD. Create a new instance with the OpenLayers.Format.SLD constructor.

#### Inherits from

- OpenLayers.Format.XML

Summary

OpenLayers. Format.SLD | Read/Wite SLD.
Properties |
defaultVersion | {String} Version number to assume if none found.
version | {String} Specify a version string if one is known.
Constructor |
OpenLayers. Format.SLD | Create a new parser for SLD.
Functions |
write | Write a SLD document given a list of styles.
read | Read and SLD doc and return an object representing the SLD.

### Properties

### defaultVersion

{String} Version number to assume if none found. Default is “1.0.0”.

### version

{String} Specify a version string if one is known.

### Constructor

### OpenLayers. Format.SLD

Create a new parser for SLD.

#### Parameters

options | {Object} An optional object whose properties will be set on this instance.

### Functions

### write

> write: function( | sld,
> | options | )

Write a SLD document given a list of styles.

#### Parameters

sld | {Object} An object representing the SLD.
options | {Object} Optional configuration object.

#### Returns

{String} An SLD document string.

### read

> read: function( | data | )

Read and SLD doc and return an object representing the SLD.

#### Parameters

data | {String | DOMElement} Data to read.

#### Returns

{Object} An object representing the SLD.

> write: function( | sld,
> | options | )

Write a SLD document given a list of styles.

> read: function( | data | )

Read and SLD doc and return an object representing the SLD.
Create a new parser for SLD.
Read and write XML.
Close