Class ST_3DLength
java.lang.Object
org.h2gis.api.AbstractFunction
org.h2gis.api.DeterministicScalarFunction
org.h2gis.functions.spatial.properties.ST_3DLength
- All Implemented Interfaces:
org.h2gis.api.Function,org.h2gis.api.ScalarFunction
public class ST_3DLength
extends org.h2gis.api.DeterministicScalarFunction
ST_3DLength returns the 3D length (of a LineString) or the 3D perimeter (of a Polygon).
In the case of a 2D geometry, ST_3DLength returns the same value as ST_Length.
- Author:
- Adam Gouge
-
Field Summary
Fields inherited from interface org.h2gis.api.Function
PROP_NAME, PROP_REMARKSFields inherited from interface org.h2gis.api.ScalarFunction
PROP_DETERMINISTIC -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic doublelength3D(org.locationtech.jts.geom.CoordinateSequence points) Computes the length of a LineString specified by a sequence of coordinates.static doublelength3D(org.locationtech.jts.geom.Geometry geom) Returns the 3D length of the given geometry.static doublelength3D(org.locationtech.jts.geom.LineString lineString) Returns the 3D perimeter of the given LineString.static doublelength3D(org.locationtech.jts.geom.Polygon polygon) Returns the 3D perimeter of the given polygon.static DoublestLength3D(org.locationtech.jts.geom.Geometry geom) Returns the 3D length (of a LineString or MultiLineString) ortherwise 0.Methods inherited from class org.h2gis.api.AbstractFunction
addProperty, getProperty, removePropertyMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.h2gis.api.Function
getProperty
-
Constructor Details
-
ST_3DLength
public ST_3DLength()
-
-
Method Details
-
getJavaStaticMethod
-
stLength3D
Returns the 3D length (of a LineString or MultiLineString) ortherwise 0.- Parameters:
geom- Geometry- Returns:
- The 3D length (of a LineString or MultiLineString) ortherwise 0
-
length3D
public static double length3D(org.locationtech.jts.geom.Geometry geom) Returns the 3D length of the given geometry.- Parameters:
geom- Geometry- Returns:
- The 3D length of the given geometry
-
length3D
public static double length3D(org.locationtech.jts.geom.Polygon polygon) Returns the 3D perimeter of the given polygon.- Parameters:
polygon- Polygon- Returns:
- The 3D perimeter of the given polygon
-
length3D
public static double length3D(org.locationtech.jts.geom.LineString lineString) Returns the 3D perimeter of the given LineString.- Parameters:
lineString- LineString- Returns:
- The 3D perimeter of the given LineString
-
length3D
public static double length3D(org.locationtech.jts.geom.CoordinateSequence points) Computes the length of a LineString specified by a sequence of coordinates.- Parameters:
points- The coordinate sequence- Returns:
- The length of the corresponding LineString
-