public class Extents extends Object
| Modifier and Type | Method and Description |
|---|---|
static org.opengis.geometry.Envelope |
antipodalEnvelope(org.opengis.geometry.Envelope envelope)
Returns an envelope that is diametrically opposite to the specified
envelope.
|
static org.opengis.geometry.Envelope |
calculateEnvelope(NodeList geomNodes)
Calculates the envelope that covers the given collection of GML geometry
elements.
|
static org.opengis.geometry.Envelope |
calculateEnvelopeUsingSingleGeometry(NodeList geomNodes)
Calculates the envelope using single GML geometry element.
|
static org.opengis.geometry.Envelope |
coalesceBoundingBoxes(List<Node> bboxNodes)
Coalesces a sequence of bounding boxes so as to create an envelope that
covers all of them.
|
static org.opengis.geometry.Envelope |
createEnvelope(Node envelopeNode)
Creates an Envelope from the given XML representation of a spatial extent
(ows:BoundingBox, ows:WGS84BoundingBox, or gml:Envelope).
|
static Document |
envelopeAsGML(org.opengis.geometry.Envelope envelope)
Generates a standard GML representation (gml:Envelope) of an Envelope
object.
|
static com.vividsolutions.jts.geom.Polygon |
envelopeAsPolygon(org.opengis.geometry.Envelope envelope)
Creates a JTS Polygon having the same extent as the given envelope.
|
static String |
envelopeToString(org.opengis.geometry.Envelope envelope)
Returns a String representation of a bounding box suitable for use as a
query parameter value (KVP syntax).
|
static double[] |
getAntipode(double[] coordTuple)
Returns the antipode of the specified coordinate tuple.
|
public static org.opengis.geometry.Envelope calculateEnvelope(NodeList geomNodes) throws JAXBException
geomNodes - A NodeList containing GML geometry elements; it is assumed
these all refer to the same CRS.JAXBException - If a node cannot be unmarshalled to a geometry object.public static org.opengis.geometry.Envelope calculateEnvelopeUsingSingleGeometry(NodeList geomNodes) throws JAXBException
geomNodes - A NodeList containing GML geometry elements; it is assumed
these all refer to the same CRS.JAXBException - If a node cannot be unmarshalled to a geometry object.public static Document envelopeAsGML(org.opengis.geometry.Envelope envelope)
envelope - An Envelope defining a bounding rectangle (or prism).public static com.vividsolutions.jts.geom.Polygon envelopeAsPolygon(org.opengis.geometry.Envelope envelope)
envelope - An Envelope defining a bounding rectangle.public static org.opengis.geometry.Envelope coalesceBoundingBoxes(List<Node> bboxNodes) throws org.opengis.util.FactoryException, org.opengis.referencing.operation.TransformException
bboxNodes - A list of elements representing common bounding boxes
(ows:BoundingBox, ows:WGS84BoundingBox, or gml:Envelope).org.opengis.util.FactoryException - If an unrecognized CRS reference is encountered or a
corresponding CoordinateReferenceSystem cannot be
constructed.org.opengis.referencing.operation.TransformException - If an attempt to perform a coordinate transformation fails
for some reason.public static org.opengis.geometry.Envelope createEnvelope(Node envelopeNode) throws org.opengis.util.FactoryException
envelopeNode - A DOM Node (Document or Element) representing a spatial
envelope.org.opengis.util.FactoryException - If an unrecognized CRS reference is encountered or a
corresponding CoordinateReferenceSystem cannot be constructed
for some reason.public static String envelopeToString(org.opengis.geometry.Envelope envelope)
LowerCorner coordinate 1 LowerCorner coordinate 2 LowerCorner coordinate N ... UpperCorner coordinate 1 UpperCorner coordinate 2 UpperCorner coordinate N crs URI (optional - default "urn:ogc:def:crs:OGC:1.3:CRS84")
Note: The colon character (":") is allowed in the query component of a URI and thus does not need to be escaped. See RFC 3986, sec. 3.4.
envelope - An envelope specifying a geographic extent.public static org.opengis.geometry.Envelope antipodalEnvelope(org.opengis.geometry.Envelope envelope)
envelope - An envelope (rectangle or cuboid).public static double[] getAntipode(double[] coordTuple)
coordTuple - An array containing a sequence of coordinate values.Copyright © 2024 Open Geospatial Consortium. All rights reserved.