Skip to content

Commit

Permalink
Fix doc
Browse files Browse the repository at this point in the history
  • Loading branch information
ebocher committed Nov 4, 2024
1 parent de79472 commit 76944d0
Show file tree
Hide file tree
Showing 24 changed files with 153 additions and 168 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -44,8 +44,8 @@ public String getJavaStaticMethod() {

/**
*
* @param geometry
* @return
* @param geometry {@link Geometry}
* @return Geometry
*/
public static Geometry interpolateLine(Geometry geometry) {
if(geometry == null){
Expand All @@ -63,8 +63,8 @@ public static Geometry interpolateLine(Geometry geometry) {
* Interpolate a linestring according the start and the end coordinates z
* value. If the start or the end z is NaN return the input linestring
*
* @param lineString
* @return
* @param lineString {@link LineString}
* @return LineString
*/
private static LineString linearZInterpolation(LineString lineString) {
double startz = lineString.getStartPoint().getCoordinate().z;
Expand All @@ -81,8 +81,8 @@ private static LineString linearZInterpolation(LineString lineString) {
/**
* Interpolate each linestring of the multilinestring.
*
* @param multiLineString
* @return
* @param multiLineString {@link MultiLineString }
* @return MultiLineString
*/
private static MultiLineString linearZInterpolation(MultiLineString multiLineString) {
int nbGeom = multiLineString.getNumGeometries();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,10 +48,9 @@ public String getJavaStaticMethod() {
* Multiply the z values of the geometry by another double value. NaN values
* are not updated.
*
* @param geometry
* @param z
* @return
* @throws java.sql.SQLException
* @param geometry {@link Geometry}
* @param z z value
* @return Z {@link Geometry}
*/
public static Geometry multiplyZ(Geometry geometry, double z) throws SQLException {
if(geometry == null){
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,8 @@ public String getJavaStaticMethod() {
/**
* Returns a version of the given geometry with duplicated coordinates removed.
*
* @param geometry
* @return
* @param geometry {@link Geometry}
* @return Geometry without duplicated coordinates
*/
public static Geometry removeDuplicatedCoordinates(Geometry geometry) {
return removeCoordinates(geometry);
Expand All @@ -41,8 +41,8 @@ public static Geometry removeDuplicatedCoordinates(Geometry geometry) {
/**
* Removes duplicated coordinates within a geometry.
*
* @param geom
* @return
* @param geom {@link Geometry}
* @return Geometry without duplicated coordinates
*/
public static Geometry removeCoordinates(Geometry geom) {
if(geom ==null){
Expand Down Expand Up @@ -72,8 +72,8 @@ else if (geom instanceof MultiPoint) {
/**
* Removes duplicated coordinates within a MultiPoint.
*
* @param g
* @return
* @param g {@link MultiPoint}
* @return MultiPoint without duplicated points
*/
public static MultiPoint removeCoordinates(MultiPoint g) {
Coordinate[] coords = CoordinateUtils.removeDuplicatedCoordinates(g.getCoordinates(),false);
Expand All @@ -83,8 +83,8 @@ public static MultiPoint removeCoordinates(MultiPoint g) {
/**
* Removes duplicated coordinates within a LineString.
*
* @param g
* @return
* @param g {@link LineString}
* @return LineString without duplicated coordinates
*/
public static LineString removeCoordinates(LineString g) {
Coordinate[] coords = CoordinateUtils.removeDuplicatedCoordinates(g.getCoordinates(), false);
Expand All @@ -94,8 +94,8 @@ public static LineString removeCoordinates(LineString g) {
/**
* Removes duplicated coordinates within a linearRing.
*
* @param g
* @return
* @param g {@link LinearRing}
* @return LinearRing without duplicated coordinates
*/
public static LinearRing removeCoordinates(LinearRing g) {
Coordinate[] coords = CoordinateUtils.removeDuplicatedCoordinates(g.getCoordinates(),false);
Expand All @@ -105,8 +105,8 @@ public static LinearRing removeCoordinates(LinearRing g) {
/**
* Removes duplicated coordinates in a MultiLineString.
*
* @param g
* @return
* @param g {@link MultiLineString}
* @return MultiLineString without duplicated coordinates
*/
public static MultiLineString removeCoordinates(MultiLineString g) {
ArrayList<LineString> lines = new ArrayList<LineString>();
Expand All @@ -121,8 +121,8 @@ public static MultiLineString removeCoordinates(MultiLineString g) {
/**
* Removes duplicated coordinates within a Polygon.
*
* @param poly
* @return
* @param poly {@link Polygon}
* @return Polygon without duplicated coordinates
*/
public static Polygon removeCoordinates(Polygon poly) {
GeometryFactory factory =poly.getFactory();
Expand All @@ -139,8 +139,8 @@ public static Polygon removeCoordinates(Polygon poly) {
/**
* Removes duplicated coordinates within a MultiPolygon.
*
* @param g
* @return
* @param g {@link MultiPolygon}
* @return MultiPolygon without duplicated coordinates
*/
public static MultiPolygon removeCoordinates(MultiPolygon g) {
ArrayList<Polygon> polys = new ArrayList<Polygon>();
Expand All @@ -155,8 +155,8 @@ public static MultiPolygon removeCoordinates(MultiPolygon g) {
/**
* Removes duplicated coordinates within a GeometryCollection
*
* @param g
* @return
* @param g {@link GeometryCollection}
* @return GeometryCollection without duplicated coordinates
*/
public static GeometryCollection removeCoordinates(GeometryCollection g) {
ArrayList<Geometry> geoms = new ArrayList<Geometry>();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -78,8 +78,8 @@ public static Geometry removeHoles(Geometry geometry) {
/**
* Create a new multiPolygon without hole.
*
* @param multiPolygon
* @return
* @param multiPolygon {@link MultiPolygon}
* @return Geometry without holes
*/
public static MultiPolygon removeHolesMultiPolygon(MultiPolygon multiPolygon) {
int num = multiPolygon.getNumGeometries();
Expand All @@ -93,8 +93,8 @@ public static MultiPolygon removeHolesMultiPolygon(MultiPolygon multiPolygon) {
/**
* Create a new polygon without hole.
*
* @param polygon
* @return
* @param polygon {@link Polygon}
* @return Geometry without holes
*/
public static Polygon removeHolesPolygon(Polygon polygon) {
return new Polygon((LinearRing) polygon.getExteriorRing(), null, polygon.getFactory());
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,10 +46,9 @@ public String getJavaStaticMethod() {
/**
* Remove all vertices that are located within a polygon
*
* @param geometry
* @param polygon
* @return
* @throws SQLException
* @param geometry {@link Geometry}
* @param polygon {@link Polygon}
* @return Geometry
*/
public static Geometry removePoint(Geometry geometry, Polygon polygon) throws SQLException {
if(geometry == null){
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -47,9 +47,8 @@ public String getJavaStaticMethod() {
/**
* Returns a version of the given geometry with duplicated points removed.
*
* @param geometry
* @return
* @throws java.sql.SQLException
* @param geometry {@link Geometry}
* @return Geometry without repeated points
*/
public static Geometry removeRepeatedPoints(Geometry geometry) throws SQLException, SQLException {
return removeDuplicateCoordinates(geometry, 0);
Expand All @@ -58,10 +57,9 @@ public static Geometry removeRepeatedPoints(Geometry geometry) throws SQLExcepti
/**
* Returns a version of the given geometry with duplicated points removed.
*
* @param geometry
* @param tolerance to delete the coordinates
* @return
* @throws java.sql.SQLException
* @param geometry {@link Geometry}
* @param tolerance distance to delete the coordinates
* @return Geometry without repeated points
*/
public static Geometry removeRepeatedPoints(Geometry geometry, double tolerance) throws SQLException {
return removeDuplicateCoordinates(geometry, tolerance);
Expand All @@ -70,10 +68,9 @@ public static Geometry removeRepeatedPoints(Geometry geometry, double tolerance)
/**
* Removes duplicated points within a geometry.
*
* @param geom
* @param tolerance to delete the coordinates
* @return
* @throws java.sql.SQLException
* @param geom {@link Geometry}
* @param tolerance distance to delete the coordinates
* @return Geometry without repeated points
*/
public static Geometry removeDuplicateCoordinates(Geometry geom, double tolerance) throws SQLException {
if (geom == null) {
Expand Down Expand Up @@ -103,10 +100,9 @@ public static Geometry removeDuplicateCoordinates(Geometry geom, double toleranc
/**
* Removes duplicated coordinates within a LineString.
*
* @param linestring
* @param tolerance to delete the coordinates
* @return
* @throws java.sql.SQLException
* @param linestring {@link LineString}
* @param tolerance distance to delete the coordinates
* @return Geometry without repeated points
*/
public static LineString removeDuplicateCoordinates(LineString linestring, double tolerance) throws SQLException {
Coordinate[] coords = CoordinateUtils.removeRepeatedCoordinates(linestring.getCoordinates(), tolerance, false);
Expand All @@ -119,9 +115,9 @@ public static LineString removeDuplicateCoordinates(LineString linestring, doubl
/**
* Removes duplicated coordinates within a linearRing.
*
* @param linearRing
* @param linearRing {@link LinearRing}
* @param tolerance to delete the coordinates
* @return
* @return Geometry without repeated points
*/
public static LinearRing removeDuplicateCoordinates(LinearRing linearRing, double tolerance) {
Coordinate[] coords = CoordinateUtils.removeRepeatedCoordinates(linearRing.getCoordinates(), tolerance, true);
Expand All @@ -131,9 +127,9 @@ public static LinearRing removeDuplicateCoordinates(LinearRing linearRing, doubl
/**
* Removes duplicated coordinates in a MultiLineString.
*
* @param multiLineString
* @param multiLineString {@link MultiLineString}
* @param tolerance to delete the coordinates
* @return
* @return Geometry without repeated points
*/
public static MultiLineString removeDuplicateCoordinates(MultiLineString multiLineString, double tolerance) throws SQLException {
ArrayList<LineString> lines = new ArrayList<LineString>();
Expand All @@ -150,8 +146,7 @@ public static MultiLineString removeDuplicateCoordinates(MultiLineString multiLi
*
* @param polygon the input polygon
* @param tolerance to delete the coordinates
* @return
* @throws java.sql.SQLException
* @return Geometry without repeated points
*/
public static Polygon removeDuplicateCoordinates(Polygon polygon, double tolerance) throws SQLException {
GeometryFactory factory = polygon.getFactory();
Expand All @@ -171,10 +166,9 @@ public static Polygon removeDuplicateCoordinates(Polygon polygon, double toleran
/**
* Removes duplicated coordinates within a MultiPolygon.
*
* @param multiPolygon
* @param multiPolygon {@link MultiPolygon}
* @param tolerance to delete the coordinates
* @return
* @throws java.sql.SQLException
* @return Geometry without repeated points
*/
public static MultiPolygon removeDuplicateCoordinates(MultiPolygon multiPolygon, double tolerance) throws SQLException {
ArrayList<Polygon> polys = new ArrayList<Polygon>();
Expand All @@ -189,10 +183,9 @@ public static MultiPolygon removeDuplicateCoordinates(MultiPolygon multiPolygon,
/**
* Removes duplicated coordinates within a GeometryCollection
*
* @param geometryCollection
* @param geometryCollection {@link GeometryCollection}
* @param tolerance to delete the coordinates
* @return
* @throws java.sql.SQLException
* @return Geometry without repeated points
*/
public static GeometryCollection removeDuplicateCoordinates(GeometryCollection geometryCollection, double tolerance) throws SQLException {
ArrayList<Geometry> geoms = new ArrayList<>();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -47,8 +47,8 @@ public String getJavaStaticMethod() {
* Returns a 1 dimension geometry with vertex order reversed using the ascending
* value.
*
* @param geometry
* @return
* @param geometry {@link Geometry}
* @return Geometry
*/
public static Geometry reverse3DLine(Geometry geometry) {
return reverse3DLine(geometry, "asc");
Expand All @@ -59,9 +59,9 @@ public static Geometry reverse3DLine(Geometry geometry) {
* ascending (asc) or descending (desc)
*
*
* @param geometry
* @param order
* @return
* @param geometry {@link Geometry}
* @param order asc to reverse in ascending , desc to reverse in descending
* @return Geometry
*/
public static Geometry reverse3DLine(Geometry geometry, String order) {
if(geometry == null){
Expand All @@ -79,9 +79,9 @@ public static Geometry reverse3DLine(Geometry geometry, String order) {
* Reverses a LineString according to the z value. The z of the first point
* must be lower than the z of the end point.
*
* @param lineString
* @param lineString {@link LineString}
* @param order asc to reverse in ascending , desc to reverse in descending
* @return
* @return LineString
*/
private static LineString reverse3D(LineString lineString, String order) {
CoordinateSequence seq = lineString.getCoordinateSequence();
Expand Down Expand Up @@ -109,9 +109,9 @@ private static LineString reverse3D(LineString lineString, String order) {
* point must be lower than the z end point if desc : the z first point must
* be greater than the z end point
*
* @param multiLineString
* @param multiLineString {@link MultiLineString}
* @param order asc to reverse in ascending , desc to reverse in descending
* @return
* @return MultiLineString
*/
public static MultiLineString reverse3D(MultiLineString multiLineString, String order) {
int num = multiLineString.getNumGeometries();
Expand Down
Loading

0 comments on commit 76944d0

Please sign in to comment.