new WMSCapabilities(options)
Parameters:
Name | Type | Description | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
options |
* |
Properties
|
Fires:
- event:load
- event:capabilities
Extends
Members
-
error
-
Error list: a key/value list of error to display in the dialog Overwrite it to handle internationalization
-
labels
-
Form labels: a key/value list of form labels to display in the dialog Overwrite it to handle internationalization
Methods
-
_getParser()
-
Get service parser
-
clearForm()
-
Clear form
-
getButtonElement()
-
Get the button element
- Inherited From:
- Overrides:
Returns:
- Type
- Element
-
getCapabilities(url, options)
-
Get WMS capabilities for a server
Parameters:
Name Type Description url
string service url
options
* Properties
Name Type Argument Default Description map
string WMS map or get map in url?map=xxx
version
string <optional>
1.3.0 WMS version (yet only 1.3.0 is implemented), default 1.3.0
timeout
number <optional>
10000 timout to get the capabilities, default 10000
onload
function <optional>
callback function
-
getDialog()
-
Get the dialog
Returns:
- Type
- ol.control.Dialog
-
getLayerFromOptions(options)
-
Create a new layer using options received by getOptionsFromCap method
Parameters:
Name Type Description options
* -
getOptionsFromCap(caps, parent)
-
Return a WMS ol.layer.Tile for the given capabilities
Parameters:
Name Type Description caps
* layer capabilities (read from the capabilities)
parent
* capabilities
Returns:
options
- Type
- *
-
getRequestParam(options)
-
Get Capabilities request parameters
Parameters:
Name Type Description options
* -
loadLayer(url, layername [, onload])
-
Load a layer using service
Parameters:
Name Type Argument Description url
string service url
layername
string onload
function <optional>
callback function (or listen to 'load' event)
-
setHtml(html)
-
Set the button html
Parameters:
Name Type Description html
string - Inherited From:
- Overrides:
-
setMap(map)
-
Set the map instance the control is associated with and add its controls associated to this map.
Parameters:
Name Type Description map
_ol_Map_ The map instance.
-
setTitle(title)
-
Set the button title
Parameters:
Name Type Description title
string - Inherited From:
- Overrides:
-
setVisible(b)
-
Set the control visibility
Parameters:
Name Type Description b
boolean - Inherited From:
- Overrides:
-
showCapabilities(caps)
-
Display capabilities in the dialog
Parameters:
Name Type Description caps
* JSON capabilities
-
showDialog( [url], options)
-
Show dialog for url
Parameters:
Name Type Argument Description url
string <optional>
service url, default ask for an url
options
* capabilities options
Properties
Name Type Description map
string WMS map or get map in url?map=xxx
version
string WMS version (yet only 1.3.0 is implemented), default 1.3.0
timeout
number timout to get the capabilities, default 10000
-
showError(error)
-
Display error
Parameters:
Name Type Description error
* event
-
testUrl(url)
-
Test url and return true if it is a valid url string
Parameters:
Name Type Description url
string Returns:
- Type
- bolean