Package nz.org.riskscape.engine.geo
Class GeometryAreaOp
java.lang.Object
nz.org.riskscape.engine.geo.GeometryAreaOp
-
Constructor Summary
ConstructorDescriptionGeometryAreaOp
(nz.org.riskscape.engine.SRIDSet sridSet) GeometryAreaOp
(nz.org.riskscape.engine.SRIDSet sridSet, ProjectGeometryOp projectionOp) -
Method Summary
Modifier and TypeMethodDescriptiondouble
apply
(org.locationtech.jts.geom.Geometry geometry, javax.measure.Unit<javax.measure.quantity.Area> targetUnit) Calculates the area of geometry in targetUnit.
-
Constructor Details
-
GeometryAreaOp
public GeometryAreaOp(nz.org.riskscape.engine.SRIDSet sridSet) -
GeometryAreaOp
-
-
Method Details
-
apply
public double apply(org.locationtech.jts.geom.Geometry geometry, javax.measure.Unit<javax.measure.quantity.Area> targetUnit) Calculates the area of geometry in targetUnit.
This method will re-project geometry if that is deemed necessary.
- Parameters:
geometry
- to calculate length oftargetUnit
- units to return the area in (e.g. hectares)- Returns:
- area of geometry
-