Package com.arubanetworks.meridian.util
Class Polygon
java.lang.Object
com.arubanetworks.meridian.util.Polygon
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionboolean
contains
(float x, float y) boolean
containsPoint
(android.graphics.PointF point) android.graphics.PointF
findClosestPointFromPoint
(android.graphics.PointF point) static Polygon
fromCSVPoints
(String csvPoints) static Polygon
fromPolygon
(Polygon src) android.graphics.Path
getPath()
List
<android.graphics.PointF> static float[]
getPolygonAsPoints
(Polygon poly) Convenience routine to convert a Polygon to an array of points
-
Constructor Details
-
Polygon
-
-
Method Details
-
fromPolygon
-
fromCSVPoints
-
toCSVPoints
-
contains
public boolean contains(float x, float y) -
containsPoint
public boolean containsPoint(android.graphics.PointF point) -
findClosestPointFromPoint
public android.graphics.PointF findClosestPointFromPoint(android.graphics.PointF point) -
getPath
public android.graphics.Path getPath() -
getPoints
-
getPolygonAsPoints
Convenience routine to convert a Polygon to an array of points- Parameters:
poly
-- the Polygon to be connverted
- Returns:
- Array of floats with the length of the array as the first item [num, x1, y1, x2, y2, …]
-