area

open fun area(@NonNull polygon: Array<Array<Array<Double>>>): Double

Given a polygon (an array of rings, where each ring is an array of points), returns the area.

var area = ruler.area([[ [-67.031, 50.458], [-67.031, 50.534], [-66.929, 50.534], [-66.929, 50.458], [-67.031, 50.458] ]]); //=area

Return

number area value in the specified units (square kilometers by default)

Parameters

polygon

open fun area(@NonNull multiPolygon: Array<Array<Array<Array<Double>>>>): Double

Return

Parameters

multiPolygon

open fun area(@NonNull southwest: LatLng, @NonNull northeast: LatLng): Double

Return

Parameters

southwest
northeast