| Package | com.esri.ags.geometry |
| Class | public class MapPoint |
| Inheritance | MapPoint Geometry Object |
| Subclasses | WebMercatorMapPoint |
Default MXML PropertyspatialReference
See also
| Property | Defined By | ||
|---|---|---|---|
| extent : Extent [override] [read-only]
The extent of a MapPoint is always null. | MapPoint | ||
![]() | spatialReference : SpatialReference
The spatial reference of the geometry. | Geometry | |
| type : String [override] [read-only]
The type of geometry is MAPPOINT. | MapPoint | ||
| x : Number = 0.0
The x coordinate of the MapPoint. | MapPoint | ||
| y : Number = 0.0
The y coordinate of the MapPoint. | MapPoint | ||
| Method | Defined By | ||
|---|---|---|---|
MapPoint(x:Number = 0, y:Number = 0, spatialReference:SpatialReference = null)
Creates a new MapPoint object. | MapPoint | ||
Shifts "x" to within +/- 180 span
| MapPoint | ||
Returns a new point that is offset with specified x and y distance. | MapPoint | ||
update(x:Number, y:Number, spatialReference:SpatialReference = null):void
Updates the point with new values. | MapPoint | ||
| extent | property |
extent:Extent [read-only] [override] The extent of a MapPoint is always null.
public function get extent():Extent| type | property |
type:String [read-only] [override] The type of geometry is MAPPOINT.
public function get type():String| x | property |
public var x:Number = 0.0The x coordinate of the MapPoint.
| y | property |
public var y:Number = 0.0The y coordinate of the MapPoint.
| MapPoint | () | Constructor |
public function MapPoint(x:Number = 0, y:Number = 0, spatialReference:SpatialReference = null)Creates a new MapPoint object.
Parametersx:Number (default = 0) — The x-coordinate.
| |
y:Number (default = 0) — The y-coordinate.
| |
spatialReference:SpatialReference (default = null) — The spatial reference of the point.
|
| normalize | () | method |
public function normalize():MapPoint| Since : | ArcGIS API for Flex 2.3 |
Shifts "x" to within +/- 180 span
ReturnsMapPoint — A new normalized point.
|
| offset | () | method |
public function offset(dx:Number, dy:Number):MapPointReturns a new point that is offset with specified x and y distance. Units are map units.
Parameters
dx:Number — The offset distance in map units for the x-coordinate.
| |
dy:Number — The offset distance in map units for the y-coordinate.
|
MapPoint — A new point with the given offset from this point.
|
| update | () | method |
public function update(x:Number, y:Number, spatialReference:SpatialReference = null):voidUpdates the point with new values.
Parameters
x:Number — The new x-coordinate value.
| |
y:Number — The new y-coordinate value.
| |
spatialReference:SpatialReference (default = null) — The new spatial reference.
|
<esri:Graphic>
<esri:MapPoint x="37.229" y="-3.107" spatialReference="{new SpatialReference(4326)}"/>
</esri:Graphic>
<esri:Graphic>
<esri:MapPoint x="37.229" y="-3.107">
<esri:SpatialReference wkid="4326"/>
</esri:MapPoint>
</esri:Graphic>