Class Index | File Index

Classes


Class eniro.maps.Polygon


Extends eniro.maps.Drawn.

Defined in: Polygon.js.

Class Summary
Constructor Attributes Constructor Name and Description
 
A Polygon is a connected set of strings making an exterior.
Method Summary
Method Attributes Method Name and Description
 
Returns the exterior points.
 
Returns the interior holes.
 
setExterior(array)
Sets the points making the exterior ring.
 
setInterior(interior)
Sets the interior array of arrays representing the holes in the exterior.
 
setOptions(opts)
Sets all options using an options object.
Methods borrowed from class eniro.maps.Drawn:
getFillColor, getFillOpacity, getMap, getStrokeColor, getStrokeOpacity, getStrokeWeight, getZIndex, setFillColor, setFillOpacity, setMap, setStrokeColor, setStrokeOpacity, setStrokeWeight, setZIndex
Events borrowed from class eniro.maps.Drawn:
click, mouseout, mouseover
Class Detail
eniro.maps.Polygon(opts)
A Polygon is a connected set of strings making an exterior. Optionally there can be more line strings making holes in the interior. Constructs from the given array.
Parameters:
{PolygonOptions} opts
creates a line from the given options.
Method Detail
{eniro.maps.MapArray} getExterior()
Returns the exterior points.

{eniro.maps.MapArray<eniro.maps.MapArray>} getInterior()
Returns the interior holes.

This is a MapArray<MapArray<LatLng>>


setExterior(array)
Sets the points making the exterior ring. Argument can either be an Array of eniro.maps.LatLng or an eniro.maps.MapArray of the same. Either way the internal representation will be a MapArray. Changes to such a MapArray will be immediately drawn.
Parameters:
{eniro.maps.MapArray|Array} array
of eniro.maps.LatLng.

setInterior(interior)
Sets the interior array of arrays representing the holes in the exterior.

This is a MapArray<MapArray<LatLng>>

Argument can either be an normal javascript array of array, in which case the arguments will be turned into MapArray of MapArray. Changes any array (outer or inner) will be immediately drawn.

Parameters:
{eniro.maps.MapArray<eniro.maps.MapArray>|Array<Array>} interior
the holes.

setOptions(opts)
Sets all options using an options object.
Parameters:
{PolygonOptions} opts
wrapper object of options.

Documentation generated by JsDoc Toolkit 2.3.2 on Mon Mar 30 2020 12:10:04 GMT+0200 (CEST)