public static double lineLengthMeters(CoordinateSequence sequence) {
    double total = 0;
    int numEdges = sequence.size() - 1;
    for (int i = 0; i < numEdges; i++) {
      double fromLon = sequence.getX(i);
      double toLon = sequence.getX(i + 1);
      double fromLat = sequence.getY(i);
      double toLat = sequence.getY(i + 1);
      total += metersBetween(fromLon, fromLat, toLon, toLat);
    }

    return total;
  }
Returns the sum of the length of all edges using {@link #metersBetween(double, double, double, double)}.
planetiler-core/src/main/java/com/onthegomap/planetiler/geo/GeoUtils.java