Skip to content

Potential Misleading Name or Behavior of LengthIndexedLine#extractPoint(double) #1150

@MariiaSaltykova

Description

@MariiaSaltykova

The expected behavior of the method org.locationtech.jts.linearref.LengthIndexedLine#extractPoint(double) is to return the coordinate of the point on the line at the given index. However, the actual result is the coordinate corresponding to a LinearLocation for the specified length along the linear geometry. This is because the method internally uses org.locationtech.jts.linearref.LengthLocationMap#getLocation(org.locationtech.jts.geom.Geometry, double).

Therefore, there are two possible issues:

  1. The name and documentation of LengthIndexedLine#extractPoint(double) are incorrect or misleading.
  2. The behavior of LengthIndexedLine#extractPoint(double) does not match its intended or described purpose.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions