code: private Point parsePoint(ValueGetter data, boolean haveZ, boolean haveM) {
          double X = data.getDouble();
          double Y = data.getDouble();
          Point result;
          if (haveZ) {
              double Z = data.getDouble();
              result = JtsGeometry.geofac.createPoint(new Coordinate(X, Y, Z));
          } else {
              result = JtsGeometry.geofac.createPoint(new Coordinate(X, Y));
          }
  
          if (haveM) {
              data.getDouble();
          }
  
          return result;
      }
docs: Parse the given {@link org.postgis.binary.ValueGetter} into a JTS {@link org.locationtech.jts.geom.Point}.
  
  @param data {@link org.postgis.binary.ValueGetter} to parse.
  @param haveZ True if the {@link org.locationtech.jts.geom.Point} has a Z component.
  @param haveM True if the {@link org.locationtech.jts.geom.Point} has a M component.
  
  @return The parsed {@link org.locationtech.jts.geom.Point}.