main/src/georegression/metric/Distance2D_F64.java
public static double distance( LineSegment2D_F64 line, Point2D_F64 p ) {
		return Math.sqrt(distanceSq(line, p));
	}
public static double distance( LineSegment2D_F64 line, Point2D_F64 p ) {
		return Math.sqrt(distanceSq(line, p));
	}
public static double distance ( LineSegment2D_F64 line , Point2D_F64 p ) { return Math . sqrt ( distanceSq ( line , p ) ) ; }
<p>
Returns the Euclidean distance of the closest point on a line segment to the specified point.
</p>

@param line A line segment. Not modified.
@param p The point. Not modified.
@return Euclidean distance of the closest point on a line is away from a point.
<p > Returns the Euclidean distance of the closest point on a line segment to the specified point . < / p >