Loading...
Searching...
No Matches
com.navigine.idl.java.GeometryUtils Class Referenceabstract

A set of functions for working with geometries. More...

Static Public Member Functions

static float distanceBetweenGlobalPoints (GlobalPoint from, GlobalPoint to)
 Get distance between GPS points.
 
static float distanceBetweenPoints (Point from, Point to)
 Get distance between points.
 
static float segmentLength (Segment segment)
 Get length of segment.
 
static float polygonArea (Polygon polygon)
 Get polygon area.
 
static Point polygonCenter (Polygon polygon)
 Get polygon geometric center.
 
static boolean polygonContainsPoint (Polygon polygon, Point point)
 Checks that polygon contains point.
 
static float segmentPointDistance (Segment segment, Point point)
 Get distance from segment to point.
 
static boolean segmentIntersectsSegment (Segment segment1, Segment segment2)
 Checks the intersection of two segments.
 
static Point segmentIntersectionSegment (Segment segment1, Segment segment2)
 Calculate the intersection point of two segments.
 
static float divisionRatioBySegment (Segment segment1, Segment segment2)
 Calculate the division ratio of a segment by a given segment(if intersects)
 
static Point getRatioPoint (Segment segment, double r)
 Calculate projection point on a segment.
 
static double getProjectionRatio (Segment segment, Point point)
 Calculate the division ratio of a segment by a given point Calculate projection point on a segment.
 

Detailed Description

A set of functions for working with geometries.

Definition at line 16 of file GeometryUtils.java.

Member Function Documentation

◆ distanceBetweenGlobalPoints()

static float com.navigine.idl.java.GeometryUtils.distanceBetweenGlobalPoints ( GlobalPoint from,
GlobalPoint to )
inlinestatic

Get distance between GPS points.

Parameters
fromstart point of calculation GlobalPoint
toend point of calculation GlobalPoint
Returns
distance in meters

Definition at line 23 of file GeometryUtils.java.

◆ distanceBetweenPoints()

static float com.navigine.idl.java.GeometryUtils.distanceBetweenPoints ( Point from,
Point to )
inlinestatic

Get distance between points.

Parameters
fromstart point of calculation Point
toend point of calculation Point
Returns
distance in meters

Definition at line 35 of file GeometryUtils.java.

◆ divisionRatioBySegment()

static float com.navigine.idl.java.GeometryUtils.divisionRatioBySegment ( Segment segment1,
Segment segment2 )
inlinestatic

Calculate the division ratio of a segment by a given segment(if intersects)

Parameters
segment1first segment of calculation Segment
segment2second segment of calculation Segment
Returns
division ratio

Definition at line 125 of file GeometryUtils.java.

◆ getProjectionRatio()

static double com.navigine.idl.java.GeometryUtils.getProjectionRatio ( Segment segment,
Point point )
inlinestatic

Calculate the division ratio of a segment by a given point Calculate projection point on a segment.

Parameters
segmentsegment of calculation Segment
pointpoint of calculation Point
Returns
division ratio

Definition at line 150 of file GeometryUtils.java.

◆ getRatioPoint()

static Point com.navigine.idl.java.GeometryUtils.getRatioPoint ( Segment segment,
double r )
inlinestatic

Calculate projection point on a segment.

Parameters
segmentsegment of calculation Segment
rdivision ratio
Returns
ratio point Point

Definition at line 137 of file GeometryUtils.java.

◆ polygonArea()

static float com.navigine.idl.java.GeometryUtils.polygonArea ( Polygon polygon)
inlinestatic

Get polygon area.

Parameters
polygonpolygon object for calculation Polygon
Returns
area in meters

Definition at line 56 of file GeometryUtils.java.

◆ polygonCenter()

static Point com.navigine.idl.java.GeometryUtils.polygonCenter ( Polygon polygon)
inlinestatic

Get polygon geometric center.

Parameters
polygonpolygon object for calculation Polygon
Returns
center point Point

Definition at line 66 of file GeometryUtils.java.

◆ polygonContainsPoint()

static boolean com.navigine.idl.java.GeometryUtils.polygonContainsPoint ( Polygon polygon,
Point point )
inlinestatic

Checks that polygon contains point.

Parameters
polygonpolygon object in which looking for contents Polygon
pointchecking point object Point
Returns
contains or not

Definition at line 77 of file GeometryUtils.java.

◆ segmentIntersectionSegment()

static Point com.navigine.idl.java.GeometryUtils.segmentIntersectionSegment ( Segment segment1,
Segment segment2 )
inlinestatic

Calculate the intersection point of two segments.

Parameters
segment1first segment of calculation Segment
segment2second segment of calculation Segment
Returns
intersection point Point

Definition at line 113 of file GeometryUtils.java.

◆ segmentIntersectsSegment()

static boolean com.navigine.idl.java.GeometryUtils.segmentIntersectsSegment ( Segment segment1,
Segment segment2 )
inlinestatic

Checks the intersection of two segments.

Parameters
segment1first segment of calculation Segment
segment2second segment of calculation Segment
Returns
intersects or not

Definition at line 101 of file GeometryUtils.java.

◆ segmentLength()

static float com.navigine.idl.java.GeometryUtils.segmentLength ( Segment segment)
inlinestatic

Get length of segment.

Parameters
segmentsegment object for calculation Segment
Returns
length in meters

Definition at line 46 of file GeometryUtils.java.

◆ segmentPointDistance()

static float com.navigine.idl.java.GeometryUtils.segmentPointDistance ( Segment segment,
Point point )
inlinestatic

Get distance from segment to point.

Parameters
segmentstart segment of calculation Segment
pointend point of calculation Point
Returns
distance in meters

Definition at line 89 of file GeometryUtils.java.


The documentation for this class was generated from the following file: