| Safe Haskell | None | 
|---|---|
| Language | Haskell2010 | 
OpenLayers.Func
Contents
Description
- newLayerMqt :: String -> Object
 - newLayerOSM :: Object
 - newVector :: Object -> Opacity -> Fay Object
 - newFeature :: GeoFeature -> Fay Object
 - newFeatureLine :: [(Double, Double)] -> Fay Object
 - newFeaturePoint :: (Double, Double) -> Fay Object
 - newLineStyle :: GeoLineStyle -> Object
 - newPointStyle :: GeoPointStyle -> Object
 - newOlInput :: JQuery -> String -> Object -> String -> Fay ()
 - addSingleClickEventAlertCoo :: String -> Fay ()
 - addBaseLayer :: MapSource -> Fay ()
 - addMapLayer :: MapSource -> Fay ()
 - addLayer :: Object -> Fay ()
 - addStyledFeature :: GeoFeature -> Opacity -> Fay ()
 - addStyledFeatures :: [GeoFeature] -> Opacity -> Fay ()
 - addFeatures :: Object -> [Object] -> Fay ()
 - addPointFromLabels :: String -> String -> String -> String -> GeoPointStyle -> Fay ()
 - addMapWindowEvent :: String -> Fay JQuery -> Fay ()
 - addOlDomInput :: String -> String -> String -> Object -> Fay ()
 - removeLayers :: Fay ()
 - removeLayer :: a -> Fay ()
 - zoomIn :: Integer -> Fay ()
 - zoomOut :: Integer -> Fay ()
 - styleFeature :: Object -> GeoFeature -> Fay ()
 - styleFeature' :: Object -> Object -> Fay ()
 - changeBaseLayer :: MapSource -> Fay ()
 - setId :: Object -> Integer -> Integer -> Fay ()
 - setFeatureId :: Object -> GeoFeature -> Fay ()
 - setCenter :: Coordinate -> Fay ()
 - setCenter' :: (Double, Double) -> Fay ()
 - setCenterZoom :: Coordinate -> Integer -> Fay ()
 - setZoom :: Integer -> Fay ()
 - getCenter :: Projectionlike -> Integer -> Fay Text
 - getCenter' :: Fay (Double, Double)
 - getZoom :: Fay Text
 - getLayers :: Fay [Object]
 - getLayerByIndex :: Integer -> Object
 - getLayerByIndex' :: Integer -> Fay Object
 - getFeatureId :: Object -> Integer
 - getVectorFeatureAt :: Object -> Integer -> Object
 - getVectorFeatureLength :: Object -> Integer
 - transformPointTo :: Projectionlike -> (Double, Double) -> (Double, Double)
 - transformPoint :: Coordinate -> (Double, Double)
 - transformPoints :: [Coordinate] -> [(Double, Double)]
 - coordFixed :: (Double, Double) -> Integer -> Fay Text
 - toDouble :: Text -> Double
 - mapS :: (a -> Fay b) -> [a] -> Fay [b]
 - zipWithS :: (a -> b -> Fay c) -> [a] -> [b] -> Fay [c]
 
NEW FUNCTION
new Layer as vector
newFeature :: GeoFeature -> Fay Object Source
new GeoFeature (GeoPoint or GeoLine)
new map source GeoJSON as LineString
new map source GeoJSON as Point
newLineStyle :: GeoLineStyle -> Object Source
new styled GeoLine
newPointStyle :: GeoPointStyle -> Object Source
new styled GeoPoint
Arguments
| :: JQuery | element to bind to  | 
| -> String | case (f.e. "checked" by Checkbox)  | 
| -> Object | map object (f.e. 'getLayerByIndex 0')  | 
| -> String | attribute of map object to change (f.e. "visible")  | 
| -> Fay () | return type is void  | 
new OpenLayers DOM binding
ADD FUNCTION
addSingleClickEventAlertCoo Source
add an event on "singleclick" to display pop-up with coordinates in mercator and custom projection
addBaseLayer :: MapSource -> Fay () Source
add a layer to the map, and remove all layers before inserting (baselayer has now index 0)
addMapLayer :: MapSource -> Fay () Source
add a MapSource to the map
Arguments
| :: GeoFeature | |
| -> Opacity | opacity for the GeoFeature  | 
| -> Fay () | 
add a GeoFeature to a new layer to the map (first add coordinates to a new feature and then add the style and the id to this new feature, at least create a layer with the feature and add the layer to the map)
Arguments
| :: [GeoFeature] | |
| -> Opacity | global opacity for the GeoFeatures  | 
| -> Fay () | 
add more than one GeoFeature to a new layer (similar to the addStyledFeature function)
add an array with features to a layer
Arguments
| :: String | id of the HTML element for the first coordinate (element need value, must be a double, see   | 
| -> String | id of the HTML element for the seconde coordinate (element need value, must be a double, see   | 
| -> String | id of the HTML element for the opacity (element need value, must be an integer, see   | 
| -> String | id of the HTML element for the feature id (element need value, must be a positive integer, see   | 
| -> GeoPointStyle | define the style of the feature  | 
| -> Fay () | 
add a new point feature (and a new layer) by defining from HTML elements
add a map event listener (f.e. when zoom or pan)
Arguments
| :: String | id of the HTML element which triggers  | 
| -> String | HTML value to trigger (f.e. "checked")  | 
| -> String | layer attribute to manipulate (f.e. "visible")  | 
| -> Object | layer to manipulate  | 
| -> Fay () | 
add a connection between HTML and OpenLayers to manipulate layer attributes
REMOVE FUNCTION
removeLayers :: Fay () Source
remove all layers from the map
Arguments
| :: a | layer to remove  | 
| -> Fay () | 
remove a layer object (only use with layers)
CHANGE FUNCTION
zoom IN and specify levels to change
zoom OUT and specify levels to change
Arguments
| :: Object | the prevoiusly created new feature  | 
| -> GeoFeature | the GeoFeature object of the prevoiusly created feature  | 
| -> Fay () | 
style a feature after creating a new feature and before adding to a new layer (this is an internal function for addStyledFeature and addStyledFeatures)
styleFeature' :: Object -> Object -> Fay () Source
style a feature FFI function
change the baselayer at layerindex 0
SET FUNCTION
Arguments
| :: Object | layer with the requested feature  | 
| -> Integer | new id for the feature ( > 0)  | 
| -> Integer | index of the feature in the layer (Layer.getFeatures()[i] , i >= 0)  | 
| -> Fay () | 
set the id of a feature, get the feature by layer and featureindex
Arguments
| :: Object | vector  | 
| -> GeoFeature | input for the id  | 
| -> Fay () | 
set the id of the first feature of the vector
setCenter :: Coordinate -> Fay () Source
set map center with a Coordinate
setCenter' :: (Double, Double) -> Fay () Source
set map center FFI function
Arguments
| :: Coordinate | center position  | 
| -> Integer | zoomlevel  | 
| -> Fay () | return type is void  | 
set the map center and the zoomlevel at the same time
GET FUNCTION
Arguments
| :: Projectionlike | requested projection  | 
| -> Integer | decimal places  | 
| -> Fay Text | 
get map center in requested projection with n decimal places
getCenter' :: Fay (Double, Double) Source
get map center FFI function
getLayerByIndex :: Integer -> Object Source
get a layer by index and return a object
getLayerByIndex' :: Integer -> Fay Object Source
get a layer by index and return a fay object
getFeatureId :: Object -> Integer Source
get the id of a feature (OpenLayers Feature)
get a feature from a vector at index position
get the number of features in a vector
TRANSFORM FUNCTION
Arguments
| :: Projectionlike | target projection  | 
| -> (Double, Double) | input  | 
| -> (Double, Double) | output  | 
transform coordinates from mercator to requested projection
Arguments
| :: Coordinate | input  | 
| -> (Double, Double) | output  | 
transform Coordinate to mercator (EPSG:3857)
transformPoints :: [Coordinate] -> [(Double, Double)] Source
transform Coordinates to mercator (EPSG:3857)