Implements all the methods for working with layers of OpenLayers.
OpenLayersTools. | Implements all the methods for working with layers of OpenLayers. |
Functions | |
Layer | Initialize the object of Layer. |
addMap | Creates the map elements and adds them to OpenLayers. |
addVectorLayer | Adding a custom layer to OpenLayers. |
getLayerByName | Seeking layer in OpenLayers and returns a single layer. |
getLayersByName | Seeking layer in OpenLayers and returns array of layers. |
getFeatureById | Takes out the element layer and return it. |
getFeaturesById | Takes out the element layer and return array of OpenLayers.Feature. |
addVectorLayer: function ( name, config )
Adding a custom layer to OpenLayers.
name | Name of a custom layer. |
config | The object with the parameters of the user layer. |
TRUE if function successful.
OpenLayersTools.Layer.addVectorLayer('ТÑанÑпоÑÑнÑе ÑÑедÑÑва', { styleMap: { default: { display: '${display}', label: '${label}', externalGraphic: '${externalGraphic}', graphicWidth: 32, graphicHeight: 32, graphicYOffset: -50 } } });
getFeaturesById: function ( layerName, id )
Takes out the element layer and return array of OpenLayers.Feature.
layerName | Layer name from which to take the elements layer. |
id | ID of the controls to be found. |
Array of OpenLayers.Feature.
OpenLayersTools.Layer.getFeatureById(layerName, id);
Initialize the object of Layer.
function Layer( parent )
Creates the map elements and adds them to OpenLayers.
addMap: function ( maps )
Adding a custom layer to OpenLayers.
addVectorLayer: function ( name, config )
Seeking layer in OpenLayers and returns a single layer.
getLayerByName: function ( name )
Seeking layer in OpenLayers and returns array of layers.
getLayersByName: function ( name )
Takes out the element layer and return it.
getFeatureById: function ( layerName, id )
Takes out the element layer and return array of OpenLayers.Feature.
getFeaturesById: function ( layerName, id )