toLineStringFromCoords static method

String toLineStringFromCoords(
  1. Coordinate p0,
  2. Coordinate p1
)

Generates the WKT for a LINESTRING specified by two {@link Coordinate}s.

@param p0 the first coordinate @param p1 the second coordinate

@return the WKT

Implementation

static String toLineStringFromCoords(Coordinate p0, Coordinate p1) {
  return "LINESTRING ( ${p0.x} ${p0.y}, ${p1.x} ${p1.y} )";
}