|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.esri.adf.web.data.geometry.WebGeometry
com.esri.adf.web.data.geometry.WebPolyline
public class WebPolyline
WebPolyline is a class for representing polyline's, i.e. complex lines composed of multiple line
segments. WebPolyline holds a list of WebPaths.
| Field Summary |
|---|
| Fields inherited from class com.esri.adf.web.data.geometry.WebGeometry |
|---|
spatialReference |
| Constructor Summary | |
|---|---|
WebPolyline()
Constructs an empty WebPolyline instance. |
|
WebPolyline(java.util.List<WebPath> paths)
Constructs a WebPolyline instance with the given paths. |
|
WebPolyline(WebSpatialReference spatialReference)
Constructs an empty WebPolyline instance with a given spatial reference. |
|
| Method Summary | |
|---|---|
void |
addPath(WebPath path)
Adds the given WebPath instance to the list of WebPaths of this polyline. |
void |
addPaths(java.util.List<? extends WebPath> webPaths)
Adds all the WebPaths from the submitted list to the list of WebPaths of this polyline. |
boolean |
equals(java.lang.Object obj)
|
WebPolyline |
fromMapGeometry(WebExtent extent,
int width,
int height)
Converts a geometry in map coordinates to a geometry of the same type in screen coordinates. |
WebPolyline |
fromMapGeometry(WebMap webMap)
Converts a geometry in map coordinates to a geometry of the same type in screen coordinates. |
java.lang.String |
getGeometryType()
Returns a text representing the type of the geometry. |
WebPath |
getPath(int index)
Returns a WebPath with the given index. |
java.util.List<WebPath> |
getPaths()
Returns a list with WebPaths constituting the polyline. |
int |
hashCode()
|
WebPolyline |
project(WebSpatialReference toSpatialReference)
Converts the geometry in map coordinates from the spatialReference of this geometry to a geometry in
the desired spatial reference. |
WebPolyline |
toMapGeometry(WebExtent extent,
int width,
int height)
Converts a geometry in screen coordinates to a geometry of the same type in map coordinates. |
WebPolyline |
toMapGeometry(WebMap webMap)
Converts a geometry in screen coordinates to a geometry of the same type in map coordinates. |
java.lang.String |
toString()
|
| Methods inherited from class com.esri.adf.web.data.geometry.WebGeometry |
|---|
getSpatialReference, setSpatialReference |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public WebPolyline(java.util.List<WebPath> paths)
paths - WebPaths constituting the polylinepublic WebPolyline(WebSpatialReference spatialReference)
spatialReference - a spatial reference to be used by the resulting WebPolyline instancepublic WebPolyline()
| Method Detail |
|---|
public java.lang.String getGeometryType()
WebGeometry
Returns a text representing the type of the geometry. WebGeometry objects of the same type must
return the same text.
getGeometryType in class WebGeometrypublic java.util.List<WebPath> getPaths()
public WebPath getPath(int index)
index - index of the path
public void addPath(WebPath path)
path - a WebPath to addpublic void addPaths(java.util.List<? extends WebPath> webPaths)
webPaths - a list of WebPaths to addpublic WebPolyline toMapGeometry(WebMap webMap)
WebGeometry
Converts a geometry in screen coordinates to a geometry of the same type in map coordinates. The coordinate system
of the converted geometry is the same as the coordinate system of the WebMap.
toMapGeometry in class WebGeometrywebMap - The WebMap based on which the coordinates need to be converted
WebGeometry in map coordinates
public WebPolyline toMapGeometry(WebExtent extent,
int width,
int height)
WebGeometryConverts a geometry in screen coordinates to a geometry of the same type in map coordinates. The coordinate system of the converted geometry is the same as the coordinate system of the specified extent.
toMapGeometry in class WebGeometryextent - the WebExtent of the map imagewidth - the width of the map imageheight - the height of the map image
WebGeometry in map coordinatespublic WebPolyline fromMapGeometry(WebMap webMap)
WebGeometry
Converts a geometry in map coordinates to a geometry of the same type in screen coordinates. Since the converted
geometry is a screen geometry, the coordinate system of the converted geometry will be null.
fromMapGeometry in class WebGeometrywebMap - The WebMap based on which the coordinates need to be converted
WebGeometry in screen coordinates
public WebPolyline fromMapGeometry(WebExtent extent,
int width,
int height)
WebGeometry
Converts a geometry in map coordinates to a geometry of the same type in screen coordinates. Since the converted
geometry is a screen geometry, the coordinate system of the converted geometry will be null.
fromMapGeometry in class WebGeometryextent - the WebExtent of the map imagewidth - the width of the map imageheight - the height of the map image
WebGeometry in screen coordinatespublic java.lang.String toString()
toString in class java.lang.Objectpublic WebPolyline project(WebSpatialReference toSpatialReference)
WebGeometry
Converts the geometry in map coordinates from the spatialReference of this geometry to a geometry in
the desired spatial reference. If the desired spatial reference is same as that of this geometry, this same
geometry is returned. Otherwise, a new WebGeometry object is created and populated with the converted
coordinates. The type of the projected geometry is same as this geometry.
project in class WebGeometrytoSpatialReference - the desired spatial reference of the projected geometry
WebGeometrypublic int hashCode()
hashCode in class WebGeometrypublic boolean equals(java.lang.Object obj)
equals in class WebGeometry
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||