<< Click to Display Table of Contents >>
new sg.geometry.LinearRing()
Description
create a linear ring.
Position
Geometry.js
Properties
Properties |
Type |
Description |
extent |
sg.geometry.Extent |
Name |
length |
Number |
pt |
path |
Array.<sg.geometry.Point> |
Array of the path |
type |
String |
Geometry type |
Methods
Methods |
Type |
Description |
||||||
addPoint(pt) |
Returns: sg.geometry.Point |
add vertexes
|
||||||
toWkt() |
Returns: String |
return WKT string Returns:
|
||||||
getExtent() |
Returns: sg.geometry.Extent |
return geometry extent Returns:
|
||||||
getLength() |
Returns: Number |
return line length Returns:
|
||||||
getMidPoint() |
Returns: sg.geometry.Point |
return the middle point of a line Returns:
|
||||||
setPath(path) |
Returns: Array.<sg.geometry.Point> |
set line path
|
||||||
getCentroid() |
Returns: sg.geometry.Point |
return the centroid of a ring Returns:
|
||||||
Clone() |
Returns: sg.geometry.LineString |
Copy the geomtery object Returns:
|
||||||
forEachVertex(callback) |
Returns: sg.geometry.Point |
Get each verttex of a ring
callback(context) { //Vertex Context.point; //Vertex index Context.pointIndex; } |
||||||
getFirstPoint_() |
Returns: sg.geometry.point |
Get the first vertex of a ring Return:
|
||||||
update() |
update line attribute |
Example
|
©2015 Supergeo Technologies Inc.