code: @NonNull
    private static List<Point> coordAllFromSingleGeometry(@NonNull List<Point> pointList,
                                                          @NonNull Geometry geometry,
                                                          @NonNull boolean excludeWrapCoord) {
      if (geometry instanceof Point) {
        pointList.add((Point) geometry);
      } else if (geometry instanceof MultiPoint) {
        pointList.addAll(((MultiPoint) geometry).coordinates());
      } else if (geometry instanceof LineString) {
        pointList.addAll(((LineString) geometry).coordinates());
      } else if (geometry instanceof MultiLineString) {
        coordAll(pointList, (MultiLineString) geometry);
      } else if (geometry instanceof Polygon) {
        coordAll(pointList, (Polygon) geometry, excludeWrapCoord);
      } else if (geometry instanceof MultiPolygon) {
        coordAll(pointList, (MultiPolygon) geometry, excludeWrapCoord);
      } else if (geometry instanceof GeometryCollection) {
        // recursive
        for (Geometry singleGeometry : ((GeometryCollection) geometry).geometries()) {
          coordAllFromSingleGeometry(pointList, singleGeometry, excludeWrapCoord);
        }
      }
      return pointList;
    }
docs: Get all coordinates from a {@link FeatureCollection} object, returning a
  {@code List} of {@link Point} objects.
  
  @param pointList        the {@code List} of {@link Point}s.
  @param geometry         the {@link Geometry} object to extract the {@link Point}s from
  @param excludeWrapCoord whether or not to include the final coordinate of LinearRings that
  wraps the ring in its iteration. Used if the {@link Feature}
  passed through the method is a {@link Polygon} or {@link MultiPolygon}
  geometry.
  @return a {@code List} made up of {@link Point}s
  @since 4.8.0