new ol.proj.Projection(options)
Name | Type | Description | |||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
options |
Projection options.
|
Methods
-
getCode(){string}
-
Get the code for this projection, e.g. 'EPSG:4326'.
Returns:
Code.
-
getExtent(){ol.Extent}
-
Get the validity extent for this projection.
Returns:
Extent.
-
getMetersPerUnit(){number|undefined}
-
Get the amount of meters per unit of this projection. If the projection is not configured with a units identifier, the return is
undefined
.Returns:
Meters.
-
getUnits(){ol.proj.Units}
-
Get the units of this projection.
Returns:
Units.
-
getWorldExtent(){ol.Extent} experimental
-
Get the world extent for this projection.
Returns:
Extent.
-
isGlobal(){boolean}
-
Is this projection a global projection which spans the whole world?
Returns:
Wether the projection is global.
-
setExtent(extent)
-
Set the validity extent for this projection.
Name Type Description extent
ol.Extent Extent.
-
setWorldExtent(worldExtent) experimental
-
Set the world extent for this projection.
Name Type Description worldExtent
ol.Extent World extent [minlon, minlat, maxlon, maxlat].