| <!DOCTYPE HTML> |
| <html lang="en"> |
| <head> |
| <!-- Generated by javadoc (24) on Mon Sep 29 10:48:08 CEST 2025 --> |
| <title>Envelope2D (Apache SIS 1.5 API)</title> |
| <meta name="viewport" content="width=device-width, initial-scale=1"> |
| <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> |
| <meta name="dc.created" content="2025-09-29"> |
| <meta name="description" content="declaration: module: org.apache.sis.referencing, package: org.apache.sis.geometry, class: Envelope2D"> |
| <meta name="generator" content="javadoc/ClassWriter"> |
| <meta name="keywords" content="org.apache.sis.geometry.Envelope2D class"> |
| <meta name="keywords" content="getCoordinateReferenceSystem()"> |
| <meta name="keywords" content="setCoordinateReferenceSystem()"> |
| <meta name="keywords" content="setRect()"> |
| <meta name="keywords" content="getDimension()"> |
| <meta name="keywords" content="getLowerCorner()"> |
| <meta name="keywords" content="getUpperCorner()"> |
| <meta name="keywords" content="getMedian()"> |
| <meta name="keywords" content="getMinimum()"> |
| <meta name="keywords" content="getMaximum()"> |
| <meta name="keywords" content="getSpan()"> |
| <meta name="keywords" content="getMinX()"> |
| <meta name="keywords" content="getMinY()"> |
| <meta name="keywords" content="getMaxX()"> |
| <meta name="keywords" content="getMaxY()"> |
| <meta name="keywords" content="getCenterX()"> |
| <meta name="keywords" content="getCenterY()"> |
| <meta name="keywords" content="getWidth()"> |
| <meta name="keywords" content="getHeight()"> |
| <meta name="keywords" content="isEmpty()"> |
| <meta name="keywords" content="toRectangles()"> |
| <meta name="keywords" content="contains()"> |
| <meta name="keywords" content="intersects()"> |
| <meta name="keywords" content="createIntersection()"> |
| <meta name="keywords" content="createUnion()"> |
| <meta name="keywords" content="add()"> |
| <meta name="keywords" content="equals()"> |
| <meta name="keywords" content="boundsEquals()"> |
| <meta name="keywords" content="clone()"> |
| <meta name="keywords" content="toString()"> |
| <link rel="stylesheet" type="text/css" href="../../../../../resource-files/jquery-ui.min.css" title="Style"> |
| <link rel="stylesheet" type="text/css" href="../../../../../resource-files/stylesheet.css" title="Style"> |
| <link rel="stylesheet" type="text/css" href="../../../../../resource-files/sis.css" title="Style"> |
| <script type="text/javascript" src="../../../../../script-files/script.js"></script> |
| <script type="text/javascript" src="../../../../../script-files/jquery-3.7.1.min.js"></script> |
| <script type="text/javascript" src="../../../../../script-files/jquery-ui.min.js"></script> |
| </head> |
| <body class="class-declaration-page"> |
| <script type="text/javascript">const pathtoroot = "../../../../../"; |
| loadScripts(document, 'script');</script> |
| <noscript> |
| <div>JavaScript is disabled on your browser.</div> |
| </noscript> |
| <header role="banner"> |
| <nav role="navigation"> |
| <!-- ========= START OF TOP NAVBAR ======= --> |
| <div class="top-nav" id="navbar-top"> |
| <div class="nav-content"> |
| <div class="nav-menu-button"><button id="navbar-toggle-button" aria-controls="navbar-top" aria-expanded="false" aria-label="Toggle navigation links"><span class="nav-bar-toggle-icon"> </span><span class="nav-bar-toggle-icon"> </span><span class="nav-bar-toggle-icon"> </span></button></div> |
| <div class="skip-nav"><a href="#skip-navbar-top" title="Skip navigation links">Skip navigation links</a></div> |
| <ul id="navbar-top-firstrow" class="nav-list" title="Navigation"> |
| <li><a href="../../../../../index.html">Overview</a></li> |
| <li class="nav-bar-cell1-rev">Class</li> |
| <li><a href="class-use/Envelope2D.html">Use</a></li> |
| <li><a href="package-tree.html">Tree</a></li> |
| <li><a href="../../../../../new-list.html">New</a></li> |
| <li><a href="../../../../../deprecated-list.html">Deprecated</a></li> |
| <li><a href="../../../../../index-all.html">Index</a></li> |
| <li><a href="../../../../../search.html">Search</a></li> |
| <li><a href="../../../../../help-doc.html#class">Help</a></li> |
| </ul> |
| </div> |
| </div> |
| <div class="sub-nav"> |
| <div class="nav-content"> |
| <ol class="sub-nav-list"> |
| <li><a href="../../../../module-summary.html">org.apache.sis.referencing</a></li> |
| <li><a href="package-summary.html">org.apache.sis.geometry</a></li> |
| <li><a href="Envelope2D.html" class="current-selection">Envelope2D</a></li> |
| </ol> |
| <div class="nav-list-search"> |
| <input type="text" id="search-input" disabled placeholder="Search" aria-label="Search in documentation" autocomplete="off"> |
| <input type="reset" id="reset-search" disabled value="Reset"> |
| </div> |
| </div> |
| </div> |
| <!-- ========= END OF TOP NAVBAR ========= --> |
| <span class="skip-nav" id="skip-navbar-top"></span></nav> |
| </header> |
| <div class="main-grid"> |
| <nav role="navigation" class="toc" aria-label="Table of contents"> |
| <div class="toc-header">Contents |
| <input type="text" class="filter-input" disabled placeholder="Filter" aria-label="Filter table of contents" autocomplete="off"> |
| <input type="reset" class="reset-filter" disabled value="Reset"> |
| </div> |
| <button class="hide-sidebar"><span>Hide sidebar </span>❮</button><button class="show-sidebar">❯<span> Show sidebar</span></button> |
| <ol class="toc-list"> |
| <li><a href="#" tabindex="0">Description</a> |
| <ol class="toc-list"> |
| <li><a href="#crossing-the-anti-meridian-of-a-geographic-crs-heading" tabindex="0">Crossing the anti-meridian of a Geographic CRS</a></li> |
| </ol> |
| </li> |
| <li><a href="#nested-class-summary" tabindex="0">Nested Class Summary</a></li> |
| <li><a href="#field-summary" tabindex="0">Field Summary</a></li> |
| <li><a href="#constructor-summary" tabindex="0">Constructor Summary</a></li> |
| <li><a href="#method-summary" tabindex="0">Method Summary</a></li> |
| <li><a href="#constructor-detail" tabindex="0">Constructor Details</a> |
| <ol class="toc-list"> |
| <li><a href="#%3Cinit%3E()" tabindex="0">Envelope2D()</a></li> |
| <li><a href="#%3Cinit%3E(org.opengis.geometry.DirectPosition,org.opengis.geometry.DirectPosition)" tabindex="0">Envelope2D(DirectPosition, DirectPosition)</a></li> |
| <li><a href="#%3Cinit%3E(org.opengis.geometry.Envelope)" tabindex="0">Envelope2D(Envelope)</a></li> |
| <li><a href="#%3Cinit%3E(org.opengis.metadata.extent.GeographicBoundingBox)" tabindex="0">Envelope2D(GeographicBoundingBox)</a></li> |
| <li><a href="#%3Cinit%3E(org.opengis.referencing.crs.CoordinateReferenceSystem,java.awt.geom.Rectangle2D)" tabindex="0">Envelope2D(CoordinateReferenceSystem, Rectangle2D)</a></li> |
| <li><a href="#%3Cinit%3E(org.opengis.referencing.crs.CoordinateReferenceSystem,double,double,double,double)" tabindex="0">Envelope2D(CoordinateReferenceSystem, double, double, double, double)</a></li> |
| </ol> |
| </li> |
| <li><a href="#method-detail" tabindex="0">Method Details</a> |
| <ol class="toc-list"> |
| <li><a href="#getCoordinateReferenceSystem()" tabindex="0">getCoordinateReferenceSystem()</a></li> |
| <li><a href="#setCoordinateReferenceSystem(org.opengis.referencing.crs.CoordinateReferenceSystem)" tabindex="0">setCoordinateReferenceSystem(CoordinateReferenceSystem)</a></li> |
| <li><a href="#setRect(java.awt.geom.Rectangle2D)" tabindex="0">setRect(Rectangle2D)</a></li> |
| <li><a href="#getDimension()" tabindex="0">getDimension()</a></li> |
| <li><a href="#getLowerCorner()" tabindex="0">getLowerCorner()</a></li> |
| <li><a href="#getUpperCorner()" tabindex="0">getUpperCorner()</a></li> |
| <li><a href="#getMedian()" tabindex="0">getMedian()</a></li> |
| <li><a href="#getMinimum(int)" tabindex="0">getMinimum(int)</a></li> |
| <li><a href="#getMaximum(int)" tabindex="0">getMaximum(int)</a></li> |
| <li><a href="#getMedian(int)" tabindex="0">getMedian(int)</a></li> |
| <li><a href="#getSpan(int)" tabindex="0">getSpan(int)</a></li> |
| <li><a href="#getMinX()" tabindex="0">getMinX()</a></li> |
| <li><a href="#getMinY()" tabindex="0">getMinY()</a></li> |
| <li><a href="#getMaxX()" tabindex="0">getMaxX()</a></li> |
| <li><a href="#getMaxY()" tabindex="0">getMaxY()</a></li> |
| <li><a href="#getCenterX()" tabindex="0">getCenterX()</a></li> |
| <li><a href="#getCenterY()" tabindex="0">getCenterY()</a></li> |
| <li><a href="#getWidth()" tabindex="0">getWidth()</a></li> |
| <li><a href="#getHeight()" tabindex="0">getHeight()</a></li> |
| <li><a href="#isEmpty()" tabindex="0">isEmpty()</a></li> |
| <li><a href="#toRectangles()" tabindex="0">toRectangles()</a></li> |
| <li><a href="#contains(double,double)" tabindex="0">contains(double, double)</a></li> |
| <li><a href="#contains(java.awt.geom.Rectangle2D)" tabindex="0">contains(Rectangle2D)</a></li> |
| <li><a href="#contains(double,double,double,double)" tabindex="0">contains(double, double, double, double)</a></li> |
| <li><a href="#intersects(java.awt.geom.Rectangle2D)" tabindex="0">intersects(Rectangle2D)</a></li> |
| <li><a href="#intersects(double,double,double,double)" tabindex="0">intersects(double, double, double, double)</a></li> |
| <li><a href="#createIntersection(java.awt.geom.Rectangle2D)" tabindex="0">createIntersection(Rectangle2D)</a></li> |
| <li><a href="#createUnion(java.awt.geom.Rectangle2D)" tabindex="0">createUnion(Rectangle2D)</a></li> |
| <li><a href="#add(java.awt.geom.Rectangle2D)" tabindex="0">add(Rectangle2D)</a></li> |
| <li><a href="#add(double,double)" tabindex="0">add(double, double)</a></li> |
| <li><a href="#equals(java.lang.Object)" tabindex="0">equals(Object)</a></li> |
| <li><a href="#boundsEquals(org.opengis.geometry.Envelope,int,int,double)" tabindex="0">boundsEquals(Envelope, int, int, double)</a></li> |
| <li><a href="#clone()" tabindex="0">clone()</a></li> |
| <li><a href="#toString()" tabindex="0">toString()</a></li> |
| </ol> |
| </li> |
| </ol> |
| </nav> |
| <main role="main"> |
| <!-- ======== START OF CLASS DATA ======== --> |
| <div class="header"> |
| <h1 title="Class Envelope2D" class="title">Class Envelope2D</h1> |
| </div> |
| <div class="inheritance" title="Inheritance Tree"><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.base/java/lang/Object.html" title="class or interface in java.lang" class="external-link">Object</a> |
| <div class="inheritance"><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/RectangularShape.html" title="class or interface in java.awt.geom" class="external-link">RectangularShape</a> |
| <div class="inheritance"><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.html" title="class or interface in java.awt.geom" class="external-link">Rectangle2D</a> |
| <div class="inheritance"><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.Double.html" title="class or interface in java.awt.geom" class="external-link">Rectangle2D.Double</a> |
| <div class="inheritance">Envelope2D</div> |
| </div> |
| </div> |
| </div> |
| </div> |
| <section class="class-description" id="class-description"> |
| <dl class="notes"> |
| <dt>All Implemented Interfaces:</dt> |
| <dd><code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/Shape.html" title="class or interface in java.awt" class="external-link">Shape</a></code>, <code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.base/java/io/Serializable.html" title="class or interface in java.io" class="external-link">Serializable</a></code>, <code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.base/java/lang/Cloneable.html" title="class or interface in java.lang" class="external-link">Cloneable</a></code>, <code><a href="../../../../../org.apache.sis.util/org/apache/sis/util/Emptiable.html" title="interface in org.apache.sis.util">Emptiable</a></code>, <code><a href="https://www.geoapi.org/3.0/javadoc/org.opengis.geoapi/org/opengis/geometry/Envelope.html" title="class or interface in org.opengis.geometry" class="external-link">Envelope</a></code></dd> |
| </dl> |
| <hr> |
| <div class="horizontal-scroll"> |
| <div class="type-signature"><span class="modifiers">public class </span><span class="element-name type-name-label">Envelope2D</span> |
| <span class="extends-implements">extends <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.Double.html" title="class or interface in java.awt.geom" class="external-link">Rectangle2D.Double</a> |
| implements <a href="https://www.geoapi.org/3.0/javadoc/org.opengis.geoapi/org/opengis/geometry/Envelope.html" title="class or interface in org.opengis.geometry" class="external-link">Envelope</a>, <a href="../../../../../org.apache.sis.util/org/apache/sis/util/Emptiable.html" title="interface in org.apache.sis.util">Emptiable</a>, <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.base/java/lang/Cloneable.html" title="class or interface in java.lang" class="external-link">Cloneable</a></span></div> |
| <div class="block">A two-dimensional envelope on top of Java2D rectangle. |
| This implementation is provided for inter-operability between Java2D and GeoAPI. |
| |
| <p>This class inherits <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.Double.html#x" title="class or interface in java.awt.geom" class="external-link">x</a> and <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.Double.html#y" title="class or interface in java.awt.geom" class="external-link">y</a> fields. |
| But despite their names, they don't need to be oriented toward <a href="https://www.geoapi.org/3.0/javadoc/org.opengis.geoapi/org/opengis/referencing/cs/AxisDirection.html#EAST" title="class or interface in org.opengis.referencing.cs" class="external-link">East</a> and |
| <a href="https://www.geoapi.org/3.0/javadoc/org.opengis.geoapi/org/opengis/referencing/cs/AxisDirection.html#NORTH" title="class or interface in org.opengis.referencing.cs" class="external-link">North</a> respectively. The (<var>x</var>,<var>y</var>) axis can have any |
| direction and should be understood as <dfn>coordinate 0</dfn> and <dfn>coordinate 1</dfn> values instead. |
| This is not specific to this implementation; in Java2D too, the visual axis orientation depend |
| on the <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/Graphics2D.html#getTransform()" title="class or interface in java.awt" class="external-link">affine transform in the graphics context</a>.</p> |
| |
| <h2 id="crossing-the-anti-meridian-of-a-geographic-crs-heading">Crossing the anti-meridian of a Geographic CRS</h2> |
| The <cite>Web Coverage Service</cite> (WCS) specification authorizes (with special treatment) |
| cases where <var>upper</var> < <var>lower</var> at least in the longitude case. They are |
| envelopes crossing the anti-meridian, like the red box below (the green box is the usual case). |
| For <code>Envelope2D</code> objects, they are rectangle with negative <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.Double.html#width" title="class or interface in java.awt.geom" class="external-link">width</a> or |
| <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.Double.html#height" title="class or interface in java.awt.geom" class="external-link">height</a> field values. The default implementation of methods listed in the |
| right column can handle such cases. |
| |
| <div class="horizontal-flow"> |
| <div> |
| <img style="vertical-align: middle" src="doc-files/AntiMeridian.png" alt="Envelope crossing the anti-meridian"> |
| </div><div> |
| Supported methods: |
| <ul> |
| <li><a href="#getMinimum(int)"><code>getMinimum(int)</code></a></li> |
| <li><a href="#getMaximum(int)"><code>getMaximum(int)</code></a></li> |
| <li><a href="#getSpan(int)"><code>getSpan(int)</code></a></li> |
| <li><a href="#getMedian(int)"><code>getMedian(int)</code></a></li> |
| <li><a href="#isEmpty()"><code>isEmpty()</code></a></li> |
| <li><a href="#toRectangles()"><code>toRectangles()</code></a></li> |
| <li><a href="#contains(double,double)"><code>contains(double,double)</code></a></li> |
| <li><a href="#contains(java.awt.geom.Rectangle2D)"><code>contains(Rectangle2D)</code></a> and its variant receiving <code>double</code> arguments</li> |
| <li><a href="#intersects(java.awt.geom.Rectangle2D)"><code>intersects(Rectangle2D)</code></a> and its variant receiving <code>double</code> arguments</li> |
| <li><a href="#createIntersection(java.awt.geom.Rectangle2D)"><code>createIntersection(Rectangle2D)</code></a></li> |
| <li><a href="#createUnion(java.awt.geom.Rectangle2D)"><code>createUnion(Rectangle2D)</code></a></li> |
| <li><a href="#add(java.awt.geom.Rectangle2D)"><code>add(Rectangle2D)</code></a></li> |
| <li><a href="#add(double,double)"><code>add(double,double)</code></a></li> |
| </ul> |
| </div></div> |
| |
| The <a href="#getMinX()"><code>getMinX()</code></a>, <a href="#getMinY()"><code>getMinY()</code></a>, <a href="#getMaxX()"><code>getMaxX()</code></a>, <a href="#getMaxY()"><code>getMaxY()</code></a>, |
| <a href="#getCenterX()"><code>getCenterX()</code></a>, <a href="#getCenterY()"><code>getCenterY()</code></a>, <a href="#getWidth()"><code>getWidth()</code></a> and <a href="#getHeight()"><code>getHeight()</code></a> |
| methods delegate to the above-cited methods.</div> |
| <dl class="notes"> |
| <dt>Since:</dt> |
| <dd>0.3</dd> |
| <dt>See Also:</dt> |
| <dd> |
| <ul class="tag-list"> |
| <li><a href="GeneralEnvelope.html" title="class in org.apache.sis.geometry"><code>GeneralEnvelope</code></a></li> |
| <li><a href="../../../../../org.apache.sis.metadata/org/apache/sis/metadata/iso/extent/DefaultGeographicBoundingBox.html" title="class in org.apache.sis.metadata.iso.extent"><code>DefaultGeographicBoundingBox</code></a></li> |
| <li><a href="../../../../../serialized-form.html#org.apache.sis.geometry.Envelope2D">Serialized Form</a></li> |
| </ul> |
| </dd> |
| </dl> |
| </div> |
| </section> |
| <section class="summary"> |
| <ul class="summary-list"> |
| <!-- ======== NESTED CLASS SUMMARY ======== --> |
| <li> |
| <section class="nested-class-summary" id="nested-class-summary"> |
| <h2>Nested Class Summary</h2> |
| <div class="inherited-list"> |
| <h3 id="nested-classes-inherited-from-class-java.awt.geom.Rectangle2D">Nested classes/interfaces inherited from class <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.html" title="class or interface in java.awt.geom" class="external-link">Rectangle2D</a></h3> |
| <code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.Double.html" title="class or interface in java.awt.geom" class="external-link">Rectangle2D.Double</a>, <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.Float.html" title="class or interface in java.awt.geom" class="external-link">Rectangle2D.Float</a></code></div> |
| </section> |
| </li> |
| <!-- =========== FIELD SUMMARY =========== --> |
| <li> |
| <section class="field-summary" id="field-summary"> |
| <h2>Field Summary</h2> |
| <div class="inherited-list"> |
| <h3 id="fields-inherited-from-class-Rectangle2D.Double">Fields inherited from class <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.Double.html" title="class or interface in java.awt.geom" class="external-link">Rectangle2D.Double</a></h3> |
| <code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.Double.html#height" title="class or interface in java.awt.geom" class="external-link">height</a>, <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.Double.html#width" title="class or interface in java.awt.geom" class="external-link">width</a>, <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.Double.html#x" title="class or interface in java.awt.geom" class="external-link">x</a>, <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.Double.html#y" title="class or interface in java.awt.geom" class="external-link">y</a></code></div> |
| <div class="inherited-list"> |
| <h3 id="fields-inherited-from-class-Rectangle2D">Fields inherited from class <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.html" title="class or interface in java.awt.geom" class="external-link">Rectangle2D</a></h3> |
| <code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.html#OUT_BOTTOM" title="class or interface in java.awt.geom" class="external-link">OUT_BOTTOM</a>, <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.html#OUT_LEFT" title="class or interface in java.awt.geom" class="external-link">OUT_LEFT</a>, <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.html#OUT_RIGHT" title="class or interface in java.awt.geom" class="external-link">OUT_RIGHT</a>, <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.html#OUT_TOP" title="class or interface in java.awt.geom" class="external-link">OUT_TOP</a></code></div> |
| </section> |
| </li> |
| <!-- ======== CONSTRUCTOR SUMMARY ======== --> |
| <li> |
| <section class="constructor-summary" id="constructor-summary"> |
| <h2>Constructor Summary</h2> |
| <div class="caption"><span>Constructors</span></div> |
| <div class="summary-table two-column-summary"> |
| <div class="table-header col-first">Constructor</div> |
| <div class="table-header col-last">Description</div> |
| <div class="col-constructor-name even-row-color"><code><a href="#%3Cinit%3E()" class="member-name-link">Envelope2D</a>()</code></div> |
| <div class="col-last even-row-color"> |
| <div class="block">Constructs an initially empty envelope with no CRS.</div> |
| </div> |
| <div class="col-constructor-name odd-row-color"><code><a href="#%3Cinit%3E(org.opengis.geometry.DirectPosition,org.opengis.geometry.DirectPosition)" class="member-name-link">Envelope2D</a><wbr>(<a href="https://www.geoapi.org/3.0/javadoc/org.opengis.geoapi/org/opengis/geometry/DirectPosition.html" title="class or interface in org.opengis.geometry" class="external-link">DirectPosition</a> lowerCorner, |
| <a href="https://www.geoapi.org/3.0/javadoc/org.opengis.geoapi/org/opengis/geometry/DirectPosition.html" title="class or interface in org.opengis.geometry" class="external-link">DirectPosition</a> upperCorner)</code></div> |
| <div class="col-last odd-row-color"> |
| <div class="block">Constructs a two-dimensional envelope defined by the specified coordinates.</div> |
| </div> |
| <div class="col-constructor-name even-row-color"><code><a href="#%3Cinit%3E(org.opengis.geometry.Envelope)" class="member-name-link">Envelope2D</a><wbr>(<a href="https://www.geoapi.org/3.0/javadoc/org.opengis.geoapi/org/opengis/geometry/Envelope.html" title="class or interface in org.opengis.geometry" class="external-link">Envelope</a> envelope)</code></div> |
| <div class="col-last even-row-color"> |
| <div class="block">Constructs a two-dimensional envelope defined by another <a href="https://www.geoapi.org/3.0/javadoc/org.opengis.geoapi/org/opengis/geometry/Envelope.html" title="class or interface in org.opengis.geometry" class="external-link"><code>Envelope</code></a>.</div> |
| </div> |
| <div class="col-constructor-name odd-row-color"><code><a href="#%3Cinit%3E(org.opengis.metadata.extent.GeographicBoundingBox)" class="member-name-link">Envelope2D</a><wbr>(<a href="https://www.geoapi.org/3.0/javadoc/org.opengis.geoapi/org/opengis/metadata/extent/GeographicBoundingBox.html" title="class or interface in org.opengis.metadata.extent" class="external-link">GeographicBoundingBox</a> box)</code></div> |
| <div class="col-last odd-row-color"> |
| <div class="block">Constructs a new envelope with the same data as the specified geographic bounding box.</div> |
| </div> |
| <div class="col-constructor-name even-row-color"><code><a href="#%3Cinit%3E(org.opengis.referencing.crs.CoordinateReferenceSystem,double,double,double,double)" class="member-name-link">Envelope2D</a><wbr>(<a href="https://www.geoapi.org/3.0/javadoc/org.opengis.geoapi/org/opengis/referencing/crs/CoordinateReferenceSystem.html" title="class or interface in org.opengis.referencing.crs" class="external-link">CoordinateReferenceSystem</a> crs, |
| double x, |
| double y, |
| double width, |
| double height)</code></div> |
| <div class="col-last even-row-color"> |
| <div class="block">Constructs two-dimensional envelope defined by the specified coordinates.</div> |
| </div> |
| <div class="col-constructor-name odd-row-color"><code><a href="#%3Cinit%3E(org.opengis.referencing.crs.CoordinateReferenceSystem,java.awt.geom.Rectangle2D)" class="member-name-link">Envelope2D</a><wbr>(<a href="https://www.geoapi.org/3.0/javadoc/org.opengis.geoapi/org/opengis/referencing/crs/CoordinateReferenceSystem.html" title="class or interface in org.opengis.referencing.crs" class="external-link">CoordinateReferenceSystem</a> crs, |
| <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.html" title="class or interface in java.awt.geom" class="external-link">Rectangle2D</a> rect)</code></div> |
| <div class="col-last odd-row-color"> |
| <div class="block">Constructs two-dimensional envelope defined by another <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.html" title="class or interface in java.awt.geom" class="external-link"><code>Rectangle2D</code></a>.</div> |
| </div> |
| </div> |
| </section> |
| </li> |
| <!-- ========== METHOD SUMMARY =========== --> |
| <li> |
| <section class="method-summary" id="method-summary"> |
| <h2>Method Summary</h2> |
| <div id="method-summary-table"> |
| <div class="table-tabs" role="tablist" aria-orientation="horizontal"><button id="method-summary-table-tab0" role="tab" aria-selected="true" aria-controls="method-summary-table.tabpanel" tabindex="0" onkeydown="switchTab(event)" onclick="show('method-summary-table', 'method-summary-table', 3)" class="active-table-tab">All Methods</button><button id="method-summary-table-tab2" role="tab" aria-selected="false" aria-controls="method-summary-table.tabpanel" tabindex="-1" onkeydown="switchTab(event)" onclick="show('method-summary-table', 'method-summary-table-tab2', 3)" class="table-tab">Instance Methods</button><button id="method-summary-table-tab4" role="tab" aria-selected="false" aria-controls="method-summary-table.tabpanel" tabindex="-1" onkeydown="switchTab(event)" onclick="show('method-summary-table', 'method-summary-table-tab4', 3)" class="table-tab">Concrete Methods</button></div> |
| <div id="method-summary-table.tabpanel" role="tabpanel" aria-labelledby="method-summary-table-tab0"> |
| <div class="summary-table three-column-summary"> |
| <div class="table-header col-first">Modifier and Type</div> |
| <div class="table-header col-second">Method</div> |
| <div class="table-header col-last">Description</div> |
| <div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code>void</code></div> |
| <div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="#add(double,double)" class="member-name-link">add</a><wbr>(double px, |
| double py)</code></div> |
| <div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"> |
| <div class="block">Adds a point to this rectangle.</div> |
| </div> |
| <div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code>void</code></div> |
| <div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="#add(java.awt.geom.Rectangle2D)" class="member-name-link">add</a><wbr>(<a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.html" title="class or interface in java.awt.geom" class="external-link">Rectangle2D</a> rect)</code></div> |
| <div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"> |
| <div class="block">Adds another rectangle to this rectangle.</div> |
| </div> |
| <div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code>boolean</code></div> |
| <div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="#boundsEquals(org.opengis.geometry.Envelope,int,int,double)" class="member-name-link">boundsEquals</a><wbr>(<a href="https://www.geoapi.org/3.0/javadoc/org.opengis.geoapi/org/opengis/geometry/Envelope.html" title="class or interface in org.opengis.geometry" class="external-link">Envelope</a> that, |
| int xDim, |
| int yDim, |
| double eps)</code></div> |
| <div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"> |
| <div class="block">Returns <code>true</code> if <code>this</code> envelope bounds is equal to <code>that</code> envelope |
| bounds in two specified dimensions.</div> |
| </div> |
| <div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="Envelope2D.html" title="class in org.apache.sis.geometry">Envelope2D</a></code></div> |
| <div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="#clone()" class="member-name-link">clone</a>()</code></div> |
| <div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"> |
| <div class="block">Returns a clone of this envelope.</div> |
| </div> |
| <div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code>boolean</code></div> |
| <div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="#contains(double,double)" class="member-name-link">contains</a><wbr>(double px, |
| double py)</code></div> |
| <div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"> |
| <div class="block">Tests if a specified coordinate is inside the boundary of this envelope.</div> |
| </div> |
| <div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code>boolean</code></div> |
| <div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="#contains(double,double,double,double)" class="member-name-link">contains</a><wbr>(double rx, |
| double ry, |
| double rw, |
| double rh)</code></div> |
| <div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"> |
| <div class="block">Returns <code>true</code> if this envelope completely encloses the specified rectangle.</div> |
| </div> |
| <div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code>boolean</code></div> |
| <div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="#contains(java.awt.geom.Rectangle2D)" class="member-name-link">contains</a><wbr>(<a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.html" title="class or interface in java.awt.geom" class="external-link">Rectangle2D</a> rect)</code></div> |
| <div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"> |
| <div class="block">Returns <code>true</code> if this envelope completely encloses the specified rectangle.</div> |
| </div> |
| <div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="Envelope2D.html" title="class in org.apache.sis.geometry">Envelope2D</a></code></div> |
| <div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="#createIntersection(java.awt.geom.Rectangle2D)" class="member-name-link">createIntersection</a><wbr>(<a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.html" title="class or interface in java.awt.geom" class="external-link">Rectangle2D</a> rect)</code></div> |
| <div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"> |
| <div class="block">Returns the intersection of this envelope with the specified rectangle.</div> |
| </div> |
| <div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="Envelope2D.html" title="class in org.apache.sis.geometry">Envelope2D</a></code></div> |
| <div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="#createUnion(java.awt.geom.Rectangle2D)" class="member-name-link">createUnion</a><wbr>(<a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.html" title="class or interface in java.awt.geom" class="external-link">Rectangle2D</a> rect)</code></div> |
| <div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"> |
| <div class="block">Returns the union of this envelope with the specified rectangle.</div> |
| </div> |
| <div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code>boolean</code></div> |
| <div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="#equals(java.lang.Object)" class="member-name-link">equals</a><wbr>(<a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.base/java/lang/Object.html" title="class or interface in java.lang" class="external-link">Object</a> object)</code></div> |
| <div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"> |
| <div class="block">Compares the specified object with this envelope for equality.</div> |
| </div> |
| <div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code>double</code></div> |
| <div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="#getCenterX()" class="member-name-link">getCenterX</a>()</code></div> |
| <div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"> |
| <div class="block">Returns the <a href="#getMedian(int)">median</a> coordinate value for dimension 0.</div> |
| </div> |
| <div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code>double</code></div> |
| <div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="#getCenterY()" class="member-name-link">getCenterY</a>()</code></div> |
| <div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"> |
| <div class="block">Returns the <a href="#getMedian(int)">median</a> coordinate value for dimension 1.</div> |
| </div> |
| <div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code>final <a href="https://www.geoapi.org/3.0/javadoc/org.opengis.geoapi/org/opengis/referencing/crs/CoordinateReferenceSystem.html" title="class or interface in org.opengis.referencing.crs" class="external-link">CoordinateReferenceSystem</a></code></div> |
| <div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="#getCoordinateReferenceSystem()" class="member-name-link">getCoordinateReferenceSystem</a>()</code></div> |
| <div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"> |
| <div class="block">Returns the coordinate reference system in which the coordinates are given.</div> |
| </div> |
| <div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code>final int</code></div> |
| <div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="#getDimension()" class="member-name-link">getDimension</a>()</code></div> |
| <div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"> |
| <div class="block">Returns the number of dimensions, which is always 2.</div> |
| </div> |
| <div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code>double</code></div> |
| <div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="#getHeight()" class="member-name-link">getHeight</a>()</code></div> |
| <div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"> |
| <div class="block">Returns the <a href="#getSpan(int)">span</a> for dimension 1.</div> |
| </div> |
| <div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="DirectPosition2D.html" title="class in org.apache.sis.geometry">DirectPosition2D</a></code></div> |
| <div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="#getLowerCorner()" class="member-name-link">getLowerCorner</a>()</code></div> |
| <div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"> |
| <div class="block">The limits in the direction of decreasing coordinate values for the two dimensions.</div> |
| </div> |
| <div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code>double</code></div> |
| <div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="#getMaximum(int)" class="member-name-link">getMaximum</a><wbr>(int dimension)</code></div> |
| <div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"> |
| <div class="block">Returns the maximal coordinate along the specified dimension.</div> |
| </div> |
| <div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code>double</code></div> |
| <div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="#getMaxX()" class="member-name-link">getMaxX</a>()</code></div> |
| <div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"> |
| <div class="block">Returns the <a href="#getMaximum(int)">maximal</a> coordinate value for dimension 0.</div> |
| </div> |
| <div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code>double</code></div> |
| <div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="#getMaxY()" class="member-name-link">getMaxY</a>()</code></div> |
| <div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"> |
| <div class="block">Returns the <a href="#getMaximum(int)">maximal</a> coordinate value for dimension 1.</div> |
| </div> |
| <div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="DirectPosition2D.html" title="class in org.apache.sis.geometry">DirectPosition2D</a></code></div> |
| <div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="#getMedian()" class="member-name-link">getMedian</a>()</code></div> |
| <div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"> |
| <div class="block">A coordinate position consisting of all the median coordinate values.</div> |
| </div> |
| <div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code>double</code></div> |
| <div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="#getMedian(int)" class="member-name-link">getMedian</a><wbr>(int dimension)</code></div> |
| <div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"> |
| <div class="block">Returns the median coordinate along the specified dimension.</div> |
| </div> |
| <div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code>double</code></div> |
| <div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="#getMinimum(int)" class="member-name-link">getMinimum</a><wbr>(int dimension)</code></div> |
| <div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"> |
| <div class="block">Returns the minimal coordinate along the specified dimension.</div> |
| </div> |
| <div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code>double</code></div> |
| <div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="#getMinX()" class="member-name-link">getMinX</a>()</code></div> |
| <div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"> |
| <div class="block">Returns the <a href="#getMinimum(int)">minimal</a> coordinate value for dimension 0.</div> |
| </div> |
| <div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code>double</code></div> |
| <div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="#getMinY()" class="member-name-link">getMinY</a>()</code></div> |
| <div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"> |
| <div class="block">Returns the <a href="#getMinimum(int)">minimal</a> coordinate value for dimension 1.</div> |
| </div> |
| <div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code>double</code></div> |
| <div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="#getSpan(int)" class="member-name-link">getSpan</a><wbr>(int dimension)</code></div> |
| <div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"> |
| <div class="block">Returns the envelope span along the specified dimension.</div> |
| </div> |
| <div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="DirectPosition2D.html" title="class in org.apache.sis.geometry">DirectPosition2D</a></code></div> |
| <div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="#getUpperCorner()" class="member-name-link">getUpperCorner</a>()</code></div> |
| <div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"> |
| <div class="block">The limits in the direction of increasing coordinate values for the two dimensions.</div> |
| </div> |
| <div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code>double</code></div> |
| <div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="#getWidth()" class="member-name-link">getWidth</a>()</code></div> |
| <div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"> |
| <div class="block">Returns the <a href="#getSpan(int)">span</a> for dimension 0.</div> |
| </div> |
| <div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code>boolean</code></div> |
| <div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="#intersects(double,double,double,double)" class="member-name-link">intersects</a><wbr>(double rx, |
| double ry, |
| double rw, |
| double rh)</code></div> |
| <div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"> |
| <div class="block">Returns <code>true</code> if this envelope intersects the specified envelope.</div> |
| </div> |
| <div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code>boolean</code></div> |
| <div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="#intersects(java.awt.geom.Rectangle2D)" class="member-name-link">intersects</a><wbr>(<a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.html" title="class or interface in java.awt.geom" class="external-link">Rectangle2D</a> rect)</code></div> |
| <div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"> |
| <div class="block">Returns <code>true</code> if this envelope intersects the specified envelope.</div> |
| </div> |
| <div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code>boolean</code></div> |
| <div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="#isEmpty()" class="member-name-link">isEmpty</a>()</code></div> |
| <div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"> |
| <div class="block">Determines whether the envelope is empty.</div> |
| </div> |
| <div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code>void</code></div> |
| <div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="#setCoordinateReferenceSystem(org.opengis.referencing.crs.CoordinateReferenceSystem)" class="member-name-link">setCoordinateReferenceSystem</a><wbr>(<a href="https://www.geoapi.org/3.0/javadoc/org.opengis.geoapi/org/opengis/referencing/crs/CoordinateReferenceSystem.html" title="class or interface in org.opengis.referencing.crs" class="external-link">CoordinateReferenceSystem</a> crs)</code></div> |
| <div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"> |
| <div class="block">Sets the coordinate reference system in which the coordinate are given.</div> |
| </div> |
| <div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code>void</code></div> |
| <div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="#setRect(java.awt.geom.Rectangle2D)" class="member-name-link">setRect</a><wbr>(<a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.html" title="class or interface in java.awt.geom" class="external-link">Rectangle2D</a> rect)</code></div> |
| <div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"> |
| <div class="block">Sets this envelope to the given rectangle.</div> |
| </div> |
| <div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.Double.html" title="class or interface in java.awt.geom" class="external-link">Rectangle2D.Double</a>[]</code></div> |
| <div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="#toRectangles()" class="member-name-link">toRectangles</a>()</code></div> |
| <div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"> |
| <div class="block">Returns this envelope as non-empty Java2D rectangle objects.</div> |
| </div> |
| <div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.base/java/lang/String.html" title="class or interface in java.lang" class="external-link">String</a></code></div> |
| <div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="#toString()" class="member-name-link">toString</a>()</code></div> |
| <div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"> |
| <div class="block">Formats this envelope as a "<code>BOX</code>" element.</div> |
| </div> |
| </div> |
| </div> |
| </div> |
| <div class="inherited-list"> |
| <h3 id="methods-inherited-from-class-Rectangle2D.Double">Methods inherited from class <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.Double.html" title="class or interface in java.awt.geom" class="external-link">Rectangle2D.Double</a></h3> |
| <code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.Double.html#getBounds2D()" title="class or interface in java.awt.geom" class="external-link">getBounds2D</a>, <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.Double.html#getX()" title="class or interface in java.awt.geom" class="external-link">getX</a>, <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.Double.html#getY()" title="class or interface in java.awt.geom" class="external-link">getY</a>, <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.Double.html#outcode(double,double)" title="class or interface in java.awt.geom" class="external-link">outcode</a>, <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.Double.html#setRect(double,double,double,double)" title="class or interface in java.awt.geom" class="external-link">setRect</a></code></div> |
| <div class="inherited-list"> |
| <h3 id="methods-inherited-from-class-Rectangle2D">Methods inherited from class <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.html" title="class or interface in java.awt.geom" class="external-link">Rectangle2D</a></h3> |
| <code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.html#add(java.awt.geom.Point2D)" title="class or interface in java.awt.geom" class="external-link">add</a>, <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.html#getPathIterator(java.awt.geom.AffineTransform)" title="class or interface in java.awt.geom" class="external-link">getPathIterator</a>, <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.html#getPathIterator(java.awt.geom.AffineTransform,double)" title="class or interface in java.awt.geom" class="external-link">getPathIterator</a>, <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.html#hashCode()" title="class or interface in java.awt.geom" class="external-link">hashCode</a>, <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.html#intersect(java.awt.geom.Rectangle2D,java.awt.geom.Rectangle2D,java.awt.geom.Rectangle2D)" title="class or interface in java.awt.geom" class="external-link">intersect</a>, <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.html#intersectsLine(double,double,double,double)" title="class or interface in java.awt.geom" class="external-link">intersectsLine</a>, <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.html#intersectsLine(java.awt.geom.Line2D)" title="class or interface in java.awt.geom" class="external-link">intersectsLine</a>, <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.html#outcode(java.awt.geom.Point2D)" title="class or interface in java.awt.geom" class="external-link">outcode</a>, <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.html#setFrame(double,double,double,double)" title="class or interface in java.awt.geom" class="external-link">setFrame</a>, <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.html#union(java.awt.geom.Rectangle2D,java.awt.geom.Rectangle2D,java.awt.geom.Rectangle2D)" title="class or interface in java.awt.geom" class="external-link">union</a></code></div> |
| <div class="inherited-list"> |
| <h3 id="methods-inherited-from-class-RectangularShape">Methods inherited from class <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/RectangularShape.html" title="class or interface in java.awt.geom" class="external-link">RectangularShape</a></h3> |
| <code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/RectangularShape.html#contains(java.awt.geom.Point2D)" title="class or interface in java.awt.geom" class="external-link">contains</a>, <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/RectangularShape.html#getBounds()" title="class or interface in java.awt.geom" class="external-link">getBounds</a>, <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/RectangularShape.html#getFrame()" title="class or interface in java.awt.geom" class="external-link">getFrame</a>, <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/RectangularShape.html#setFrame(java.awt.geom.Point2D,java.awt.geom.Dimension2D)" title="class or interface in java.awt.geom" class="external-link">setFrame</a>, <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/RectangularShape.html#setFrame(java.awt.geom.Rectangle2D)" title="class or interface in java.awt.geom" class="external-link">setFrame</a>, <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/RectangularShape.html#setFrameFromCenter(double,double,double,double)" title="class or interface in java.awt.geom" class="external-link">setFrameFromCenter</a>, <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/RectangularShape.html#setFrameFromCenter(java.awt.geom.Point2D,java.awt.geom.Point2D)" title="class or interface in java.awt.geom" class="external-link">setFrameFromCenter</a>, <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/RectangularShape.html#setFrameFromDiagonal(double,double,double,double)" title="class or interface in java.awt.geom" class="external-link">setFrameFromDiagonal</a>, <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/RectangularShape.html#setFrameFromDiagonal(java.awt.geom.Point2D,java.awt.geom.Point2D)" title="class or interface in java.awt.geom" class="external-link">setFrameFromDiagonal</a></code></div> |
| <div class="inherited-list"> |
| <h3 id="methods-inherited-from-class-Object">Methods inherited from class <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.base/java/lang/Object.html" title="class or interface in java.lang" class="external-link">Object</a></h3> |
| <code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.base/java/lang/Object.html#finalize()" title="class or interface in java.lang" class="external-link">finalize</a>, <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.base/java/lang/Object.html#getClass()" title="class or interface in java.lang" class="external-link">getClass</a>, <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.base/java/lang/Object.html#notify()" title="class or interface in java.lang" class="external-link">notify</a>, <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.base/java/lang/Object.html#notifyAll()" title="class or interface in java.lang" class="external-link">notifyAll</a>, <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.base/java/lang/Object.html#wait()" title="class or interface in java.lang" class="external-link">wait</a>, <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.base/java/lang/Object.html#wait(long)" title="class or interface in java.lang" class="external-link">wait</a>, <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.base/java/lang/Object.html#wait(long,int)" title="class or interface in java.lang" class="external-link">wait</a></code></div> |
| </section> |
| </li> |
| </ul> |
| </section> |
| <section class="details"> |
| <ul class="details-list"> |
| <!-- ========= CONSTRUCTOR DETAIL ======== --> |
| <li> |
| <section class="constructor-details" id="constructor-detail"> |
| <h2>Constructor Details</h2> |
| <ul class="member-list"> |
| <li> |
| <section class="detail" id="<init>()"> |
| <h3>Envelope2D</h3> |
| <div class="horizontal-scroll"> |
| <div class="member-signature"><span class="modifiers">public</span> <span class="element-name">Envelope2D</span>()</div> |
| <div class="block">Constructs an initially empty envelope with no CRS.</div> |
| </div> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="<init>(org.opengis.geometry.DirectPosition,org.opengis.geometry.DirectPosition)"> |
| <h3>Envelope2D</h3> |
| <div class="horizontal-scroll"> |
| <div class="member-signature"><span class="modifiers">public</span> <span class="element-name">Envelope2D</span><wbr><span class="parameters">(<a href="https://www.geoapi.org/3.0/javadoc/org.opengis.geoapi/org/opengis/geometry/DirectPosition.html" title="class or interface in org.opengis.geometry" class="external-link">DirectPosition</a> lowerCorner, |
| <a href="https://www.geoapi.org/3.0/javadoc/org.opengis.geoapi/org/opengis/geometry/DirectPosition.html" title="class or interface in org.opengis.geometry" class="external-link">DirectPosition</a> upperCorner)</span> |
| throws <span class="exceptions"><a href="MismatchedReferenceSystemException.html" title="class in org.apache.sis.geometry">MismatchedReferenceSystemException</a>, |
| <a href="https://www.geoapi.org/3.0/javadoc/org.opengis.geoapi/org/opengis/geometry/MismatchedDimensionException.html" title="class or interface in org.opengis.geometry" class="external-link">MismatchedDimensionException</a></span></div> |
| <div class="block">Constructs a two-dimensional envelope defined by the specified coordinates. |
| The <code>lowerCorner</code> and <code>upperCorner</code> arguments are not necessarily |
| the minimal and maximal values respectively. |
| See the class javadoc about crossing the anti-meridian for more details.</div> |
| <dl class="notes"> |
| <dt>Parameters:</dt> |
| <dd><code>lowerCorner</code> - the first position.</dd> |
| <dd><code>upperCorner</code> - the second position.</dd> |
| <dt>Throws:</dt> |
| <dd><code><a href="MismatchedReferenceSystemException.html" title="class in org.apache.sis.geometry">MismatchedReferenceSystemException</a></code> - if the two positions don't use the same CRS.</dd> |
| <dd><code><a href="https://www.geoapi.org/3.0/javadoc/org.opengis.geoapi/org/opengis/geometry/MismatchedDimensionException.html" title="class or interface in org.opengis.geometry" class="external-link">MismatchedDimensionException</a></code> - if the two positions are not two-dimensional.</dd> |
| </dl> |
| </div> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="<init>(org.opengis.geometry.Envelope)"> |
| <h3>Envelope2D</h3> |
| <div class="horizontal-scroll"> |
| <div class="member-signature"><span class="modifiers">public</span> <span class="element-name">Envelope2D</span><wbr><span class="parameters">(<a href="https://www.geoapi.org/3.0/javadoc/org.opengis.geoapi/org/opengis/geometry/Envelope.html" title="class or interface in org.opengis.geometry" class="external-link">Envelope</a> envelope)</span> |
| throws <span class="exceptions"><a href="https://www.geoapi.org/3.0/javadoc/org.opengis.geoapi/org/opengis/geometry/MismatchedDimensionException.html" title="class or interface in org.opengis.geometry" class="external-link">MismatchedDimensionException</a></span></div> |
| <div class="block">Constructs a two-dimensional envelope defined by another <a href="https://www.geoapi.org/3.0/javadoc/org.opengis.geoapi/org/opengis/geometry/Envelope.html" title="class or interface in org.opengis.geometry" class="external-link"><code>Envelope</code></a>.</div> |
| <dl class="notes"> |
| <dt>Parameters:</dt> |
| <dd><code>envelope</code> - the envelope to copy (cannot be <code>null</code>).</dd> |
| <dt>Throws:</dt> |
| <dd><code><a href="https://www.geoapi.org/3.0/javadoc/org.opengis.geoapi/org/opengis/geometry/MismatchedDimensionException.html" title="class or interface in org.opengis.geometry" class="external-link">MismatchedDimensionException</a></code> - if the given envelope is not two-dimensional.</dd> |
| </dl> |
| </div> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="<init>(org.opengis.metadata.extent.GeographicBoundingBox)"> |
| <h3>Envelope2D</h3> |
| <div class="horizontal-scroll"> |
| <div class="member-signature"><span class="modifiers">public</span> <span class="element-name">Envelope2D</span><wbr><span class="parameters">(<a href="https://www.geoapi.org/3.0/javadoc/org.opengis.geoapi/org/opengis/metadata/extent/GeographicBoundingBox.html" title="class or interface in org.opengis.metadata.extent" class="external-link">GeographicBoundingBox</a> box)</span></div> |
| <div class="block">Constructs a new envelope with the same data as the specified geographic bounding box. |
| The coordinate reference system is set to the |
| <a href="../referencing/CommonCRS.html#defaultGeographic()">default geographic CRS</a>. |
| Axis order is (<var>longitude</var>, <var>latitude</var>).</div> |
| <dl class="notes"> |
| <dt>Parameters:</dt> |
| <dd><code>box</code> - The bounding box to copy (cannot be <code>null</code>).</dd> |
| </dl> |
| </div> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="<init>(org.opengis.referencing.crs.CoordinateReferenceSystem,java.awt.geom.Rectangle2D)"> |
| <h3>Envelope2D</h3> |
| <div class="horizontal-scroll"> |
| <div class="member-signature"><span class="modifiers">public</span> <span class="element-name">Envelope2D</span><wbr><span class="parameters">(<a href="https://www.geoapi.org/3.0/javadoc/org.opengis.geoapi/org/opengis/referencing/crs/CoordinateReferenceSystem.html" title="class or interface in org.opengis.referencing.crs" class="external-link">CoordinateReferenceSystem</a> crs, |
| <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.html" title="class or interface in java.awt.geom" class="external-link">Rectangle2D</a> rect)</span> |
| throws <span class="exceptions"><a href="https://www.geoapi.org/3.0/javadoc/org.opengis.geoapi/org/opengis/geometry/MismatchedDimensionException.html" title="class or interface in org.opengis.geometry" class="external-link">MismatchedDimensionException</a></span></div> |
| <div class="block">Constructs two-dimensional envelope defined by another <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.html" title="class or interface in java.awt.geom" class="external-link"><code>Rectangle2D</code></a>. |
| If the given rectangle has negative width or height, they will be interpreted |
| as an envelope crossing the anti-meridian.</div> |
| <dl class="notes"> |
| <dt>Parameters:</dt> |
| <dd><code>crs</code> - the coordinate reference system, or <code>null</code>.</dd> |
| <dd><code>rect</code> - the rectangle to copy (cannot be <code>null</code>).</dd> |
| <dt>Throws:</dt> |
| <dd><code><a href="https://www.geoapi.org/3.0/javadoc/org.opengis.geoapi/org/opengis/geometry/MismatchedDimensionException.html" title="class or interface in org.opengis.geometry" class="external-link">MismatchedDimensionException</a></code> - if the given CRS is not two-dimensional.</dd> |
| </dl> |
| </div> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="<init>(org.opengis.referencing.crs.CoordinateReferenceSystem,double,double,double,double)"> |
| <h3>Envelope2D</h3> |
| <div class="horizontal-scroll"> |
| <div class="member-signature"><span class="modifiers">public</span> <span class="element-name">Envelope2D</span><wbr><span class="parameters">(<a href="https://www.geoapi.org/3.0/javadoc/org.opengis.geoapi/org/opengis/referencing/crs/CoordinateReferenceSystem.html" title="class or interface in org.opengis.referencing.crs" class="external-link">CoordinateReferenceSystem</a> crs, |
| double x, |
| double y, |
| double width, |
| double height)</span> |
| throws <span class="exceptions"><a href="https://www.geoapi.org/3.0/javadoc/org.opengis.geoapi/org/opengis/geometry/MismatchedDimensionException.html" title="class or interface in org.opengis.geometry" class="external-link">MismatchedDimensionException</a></span></div> |
| <div class="block">Constructs two-dimensional envelope defined by the specified coordinates. Despite |
| their name, the (<var>x</var>,<var>y</var>) coordinates don't need to be oriented |
| toward (<a href="https://www.geoapi.org/3.0/javadoc/org.opengis.geoapi/org/opengis/referencing/cs/AxisDirection.html#EAST" title="class or interface in org.opengis.referencing.cs" class="external-link">East</a>, <a href="https://www.geoapi.org/3.0/javadoc/org.opengis.geoapi/org/opengis/referencing/cs/AxisDirection.html#NORTH" title="class or interface in org.opengis.referencing.cs" class="external-link">North</a>). |
| Those parameter names simply match the <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.Double.html#x" title="class or interface in java.awt.geom" class="external-link">x</a> and <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.Double.html#y" title="class or interface in java.awt.geom" class="external-link">y</a> fields. |
| The actual axis orientations are determined by the specified CRS. |
| See the <a href="#skip-navbar_top">class javadoc</a> for details.</div> |
| <dl class="notes"> |
| <dt>Parameters:</dt> |
| <dd><code>crs</code> - the coordinate reference system, or <code>null</code>.</dd> |
| <dd><code>x</code> - the <var>x</var> minimal value.</dd> |
| <dd><code>y</code> - the <var>y</var> minimal value.</dd> |
| <dd><code>width</code> - the envelope width. May be negative for envelope crossing the anti-meridian.</dd> |
| <dd><code>height</code> - the envelope height. May be negative for envelope crossing the anti-meridian.</dd> |
| <dt>Throws:</dt> |
| <dd><code><a href="https://www.geoapi.org/3.0/javadoc/org.opengis.geoapi/org/opengis/geometry/MismatchedDimensionException.html" title="class or interface in org.opengis.geometry" class="external-link">MismatchedDimensionException</a></code> - if the given CRS is not two-dimensional.</dd> |
| </dl> |
| </div> |
| </section> |
| </li> |
| </ul> |
| </section> |
| </li> |
| <!-- ============ METHOD DETAIL ========== --> |
| <li> |
| <section class="method-details" id="method-detail"> |
| <h2>Method Details</h2> |
| <ul class="member-list"> |
| <li> |
| <section class="detail" id="getCoordinateReferenceSystem()"> |
| <h3>getCoordinateReferenceSystem</h3> |
| <div class="horizontal-scroll"> |
| <div class="member-signature"><span class="modifiers">public final</span> <span class="return-type"><a href="https://www.geoapi.org/3.0/javadoc/org.opengis.geoapi/org/opengis/referencing/crs/CoordinateReferenceSystem.html" title="class or interface in org.opengis.referencing.crs" class="external-link">CoordinateReferenceSystem</a></span> <span class="element-name">getCoordinateReferenceSystem</span>()</div> |
| <div class="block">Returns the coordinate reference system in which the coordinates are given.</div> |
| <dl class="notes"> |
| <dt>Specified by:</dt> |
| <dd><code><a href="https://www.geoapi.org/3.0/javadoc/org.opengis.geoapi/org/opengis/geometry/Envelope.html#getCoordinateReferenceSystem()" title="class or interface in org.opengis.geometry" class="external-link">getCoordinateReferenceSystem</a></code> in interface <code><a href="https://www.geoapi.org/3.0/javadoc/org.opengis.geoapi/org/opengis/geometry/Envelope.html" title="class or interface in org.opengis.geometry" class="external-link">Envelope</a></code></dd> |
| <dt>Returns:</dt> |
| <dd>the coordinate reference system, or <code>null</code>.</dd> |
| </dl> |
| </div> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="setCoordinateReferenceSystem(org.opengis.referencing.crs.CoordinateReferenceSystem)"> |
| <h3>setCoordinateReferenceSystem</h3> |
| <div class="horizontal-scroll"> |
| <div class="member-signature"><span class="modifiers">public</span> <span class="return-type">void</span> <span class="element-name">setCoordinateReferenceSystem</span><wbr><span class="parameters">(<a href="https://www.geoapi.org/3.0/javadoc/org.opengis.geoapi/org/opengis/referencing/crs/CoordinateReferenceSystem.html" title="class or interface in org.opengis.referencing.crs" class="external-link">CoordinateReferenceSystem</a> crs)</span></div> |
| <div class="block">Sets the coordinate reference system in which the coordinate are given. |
| This method <strong>does not</strong> reproject the envelope. |
| If the envelope coordinates need to be transformed to the new CRS, consider using |
| <a href="Envelopes.html#transform(org.opengis.geometry.Envelope,org.opengis.referencing.crs.CoordinateReferenceSystem)"><code>Envelopes.transform(Envelope, CoordinateReferenceSystem)</code></a> instead.</div> |
| <dl class="notes"> |
| <dt>Parameters:</dt> |
| <dd><code>crs</code> - the new coordinate reference system, or <code>null</code>.</dd> |
| </dl> |
| </div> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="setRect(java.awt.geom.Rectangle2D)"> |
| <h3>setRect</h3> |
| <div class="horizontal-scroll"> |
| <div class="member-signature"><span class="modifiers">public</span> <span class="return-type">void</span> <span class="element-name">setRect</span><wbr><span class="parameters">(<a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.html" title="class or interface in java.awt.geom" class="external-link">Rectangle2D</a> rect)</span></div> |
| <div class="block">Sets this envelope to the given rectangle. If the given rectangle is also an instance of <a href="https://www.geoapi.org/3.0/javadoc/org.opengis.geoapi/org/opengis/geometry/Envelope.html" title="class or interface in org.opengis.geometry" class="external-link"><code>Envelope</code></a> |
| (typically as another <code>Envelope2D</code>) and has a non-null Coordinate Reference System (CRS), then the |
| CRS of this envelope will be set to the CRS of the given envelope.</div> |
| <dl class="notes"> |
| <dt>Overrides:</dt> |
| <dd><code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.Double.html#setRect(java.awt.geom.Rectangle2D)" title="class or interface in java.awt.geom" class="external-link">setRect</a></code> in class <code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.Double.html" title="class or interface in java.awt.geom" class="external-link">Rectangle2D.Double</a></code></dd> |
| <dt>Parameters:</dt> |
| <dd><code>rect</code> - the rectangle to copy coordinates from.</dd> |
| <dt>Since:</dt> |
| <dd>0.8</dd> |
| </dl> |
| </div> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="getDimension()"> |
| <h3>getDimension</h3> |
| <div class="horizontal-scroll"> |
| <div class="member-signature"><span class="modifiers">public final</span> <span class="return-type">int</span> <span class="element-name">getDimension</span>()</div> |
| <div class="block">Returns the number of dimensions, which is always 2.</div> |
| <dl class="notes"> |
| <dt>Specified by:</dt> |
| <dd><code><a href="https://www.geoapi.org/3.0/javadoc/org.opengis.geoapi/org/opengis/geometry/Envelope.html#getDimension()" title="class or interface in org.opengis.geometry" class="external-link">getDimension</a></code> in interface <code><a href="https://www.geoapi.org/3.0/javadoc/org.opengis.geoapi/org/opengis/geometry/Envelope.html" title="class or interface in org.opengis.geometry" class="external-link">Envelope</a></code></dd> |
| <dt>Returns:</dt> |
| <dd>always 2 for bi-dimensional objects.</dd> |
| </dl> |
| </div> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="getLowerCorner()"> |
| <h3>getLowerCorner</h3> |
| <div class="horizontal-scroll"> |
| <div class="member-signature"><span class="modifiers">public</span> <span class="return-type"><a href="DirectPosition2D.html" title="class in org.apache.sis.geometry">DirectPosition2D</a></span> <span class="element-name">getLowerCorner</span>()</div> |
| <div class="block">The limits in the direction of decreasing coordinate values for the two dimensions. |
| This is typically a coordinate position consisting of the minimal coordinates for |
| the two dimensions for all points within the <code>Envelope</code>. |
| |
| <p>The object returned by this method is a copy. Change in the returned position |
| will not affect this envelope, and conversely.</p> |
| |
| <h4 id="note-on-wraparound-heading">Note on wraparound</h4> |
| The <cite>Web Coverage Service</cite> (WCS) 1.1 specification uses an extended interpretation of the |
| bounding box definition. In a WCS 1.1 data structure, the lower corner defines the edges region in the |
| directions of <em>decreasing</em> coordinate values in the envelope CRS. This is usually the algebraic |
| minimum coordinates, but not always. For example, an envelope crossing the anti-meridian could have a |
| lower corner longitude greater than the upper corner longitude. Such extended interpretation applies |
| mostly to axes having <code>WRAPAROUND</code> range meaning.</div> |
| <dl class="notes"> |
| <dt>Specified by:</dt> |
| <dd><code><a href="https://www.geoapi.org/3.0/javadoc/org.opengis.geoapi/org/opengis/geometry/Envelope.html#getLowerCorner()" title="class or interface in org.opengis.geometry" class="external-link">getLowerCorner</a></code> in interface <code><a href="https://www.geoapi.org/3.0/javadoc/org.opengis.geoapi/org/opengis/geometry/Envelope.html" title="class or interface in org.opengis.geometry" class="external-link">Envelope</a></code></dd> |
| <dt>Returns:</dt> |
| <dd>a copy of the lower corner, typically (but not necessarily) containing minimal coordinate values.</dd> |
| <dt>See Also:</dt> |
| <dd> |
| <ul class="tag-list"> |
| <li><a href="#getMinX()"><code>getMinX()</code></a></li> |
| <li><a href="#getMinY()"><code>getMinY()</code></a></li> |
| <li><a href="#getMinimum(int)"><code>getMinimum(int)</code></a></li> |
| </ul> |
| </dd> |
| </dl> |
| </div> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="getUpperCorner()"> |
| <h3>getUpperCorner</h3> |
| <div class="horizontal-scroll"> |
| <div class="member-signature"><span class="modifiers">public</span> <span class="return-type"><a href="DirectPosition2D.html" title="class in org.apache.sis.geometry">DirectPosition2D</a></span> <span class="element-name">getUpperCorner</span>()</div> |
| <div class="block">The limits in the direction of increasing coordinate values for the two dimensions. |
| This is typically a coordinate position consisting of the maximal coordinates for |
| the two dimensions for all points within the <code>Envelope</code>. |
| |
| <p>The object returned by this method is a copy. Change in the returned position |
| will not affect this envelope, and conversely.</p> |
| |
| <h4 id="note-on-wraparound-heading1">Note on wraparound</h4> |
| The <cite>Web Coverage Service</cite> (WCS) 1.1 specification uses an extended interpretation of the |
| bounding box definition. In a WCS 1.1 data structure, the upper corner defines the edges region in the |
| directions of <em>increasing</em> coordinate values in the envelope CRS. This is usually the algebraic |
| maximum coordinates, but not always. For example, an envelope crossing the anti-meridian could have an |
| upper corner longitude less than the lower corner longitude. Such extended interpretation applies |
| mostly to axes having <code>WRAPAROUND</code> range meaning.</div> |
| <dl class="notes"> |
| <dt>Specified by:</dt> |
| <dd><code><a href="https://www.geoapi.org/3.0/javadoc/org.opengis.geoapi/org/opengis/geometry/Envelope.html#getUpperCorner()" title="class or interface in org.opengis.geometry" class="external-link">getUpperCorner</a></code> in interface <code><a href="https://www.geoapi.org/3.0/javadoc/org.opengis.geoapi/org/opengis/geometry/Envelope.html" title="class or interface in org.opengis.geometry" class="external-link">Envelope</a></code></dd> |
| <dt>Returns:</dt> |
| <dd>a copy of the upper corner, typically (but not necessarily) containing maximal coordinate values.</dd> |
| <dt>See Also:</dt> |
| <dd> |
| <ul class="tag-list"> |
| <li><a href="#getMaxX()"><code>getMaxX()</code></a></li> |
| <li><a href="#getMaxY()"><code>getMaxY()</code></a></li> |
| <li><a href="#getMaximum(int)"><code>getMaximum(int)</code></a></li> |
| </ul> |
| </dd> |
| </dl> |
| </div> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="getMedian()"> |
| <h3>getMedian</h3> |
| <div class="horizontal-scroll"> |
| <div class="member-signature"><span class="modifiers">public</span> <span class="return-type"><a href="DirectPosition2D.html" title="class in org.apache.sis.geometry">DirectPosition2D</a></span> <span class="element-name">getMedian</span>()</div> |
| <div class="block">A coordinate position consisting of all the median coordinate values. |
| |
| <p>The object returned by this method is a copy. Change in the returned position |
| will not affect this envelope, and conversely.</p></div> |
| <dl class="notes"> |
| <dt>Returns:</dt> |
| <dd>a copy of the median coordinates.</dd> |
| <dt>Since:</dt> |
| <dd>1.1</dd> |
| <dt>See Also:</dt> |
| <dd> |
| <ul class="tag-list"> |
| <li><a href="#getMedian(int)"><code>getMedian(int)</code></a></li> |
| </ul> |
| </dd> |
| </dl> |
| </div> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="getMinimum(int)"> |
| <h3>getMinimum</h3> |
| <div class="horizontal-scroll"> |
| <div class="member-signature"><span class="modifiers">public</span> <span class="return-type">double</span> <span class="element-name">getMinimum</span><wbr><span class="parameters">(int dimension)</span> |
| throws <span class="exceptions"><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.base/java/lang/IndexOutOfBoundsException.html" title="class or interface in java.lang" class="external-link">IndexOutOfBoundsException</a></span></div> |
| <div class="block">Returns the minimal coordinate along the specified dimension. This method handles |
| anti-meridian as documented in the <a href="AbstractEnvelope.html#getMinimum(int)"><code>AbstractEnvelope.getMinimum(int)</code></a> method.</div> |
| <dl class="notes"> |
| <dt>Specified by:</dt> |
| <dd><code><a href="https://www.geoapi.org/3.0/javadoc/org.opengis.geoapi/org/opengis/geometry/Envelope.html#getMinimum(int)" title="class or interface in org.opengis.geometry" class="external-link">getMinimum</a></code> in interface <code><a href="https://www.geoapi.org/3.0/javadoc/org.opengis.geoapi/org/opengis/geometry/Envelope.html" title="class or interface in org.opengis.geometry" class="external-link">Envelope</a></code></dd> |
| <dt>Parameters:</dt> |
| <dd><code>dimension</code> - the dimension to query.</dd> |
| <dt>Returns:</dt> |
| <dd>the minimal coordinate value along the given dimension.</dd> |
| <dt>Throws:</dt> |
| <dd><code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.base/java/lang/IndexOutOfBoundsException.html" title="class or interface in java.lang" class="external-link">IndexOutOfBoundsException</a></code> - if the given index is out of bounds.</dd> |
| <dt>See Also:</dt> |
| <dd> |
| <ul class="tag-list"> |
| <li><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/RectangularShape.html#getMinX()" title="class or interface in java.awt.geom" class="external-link"><code>RectangularShape.getMinX()</code></a></li> |
| <li><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/RectangularShape.html#getMinY()" title="class or interface in java.awt.geom" class="external-link"><code>RectangularShape.getMinY()</code></a></li> |
| </ul> |
| </dd> |
| </dl> |
| </div> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="getMaximum(int)"> |
| <h3>getMaximum</h3> |
| <div class="horizontal-scroll"> |
| <div class="member-signature"><span class="modifiers">public</span> <span class="return-type">double</span> <span class="element-name">getMaximum</span><wbr><span class="parameters">(int dimension)</span> |
| throws <span class="exceptions"><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.base/java/lang/IndexOutOfBoundsException.html" title="class or interface in java.lang" class="external-link">IndexOutOfBoundsException</a></span></div> |
| <div class="block">Returns the maximal coordinate along the specified dimension. This method handles |
| anti-meridian as documented in the <a href="AbstractEnvelope.html#getMaximum(int)"><code>AbstractEnvelope.getMaximum(int)</code></a> method.</div> |
| <dl class="notes"> |
| <dt>Specified by:</dt> |
| <dd><code><a href="https://www.geoapi.org/3.0/javadoc/org.opengis.geoapi/org/opengis/geometry/Envelope.html#getMaximum(int)" title="class or interface in org.opengis.geometry" class="external-link">getMaximum</a></code> in interface <code><a href="https://www.geoapi.org/3.0/javadoc/org.opengis.geoapi/org/opengis/geometry/Envelope.html" title="class or interface in org.opengis.geometry" class="external-link">Envelope</a></code></dd> |
| <dt>Parameters:</dt> |
| <dd><code>dimension</code> - the dimension to query.</dd> |
| <dt>Returns:</dt> |
| <dd>the maximal coordinate value along the given dimension.</dd> |
| <dt>Throws:</dt> |
| <dd><code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.base/java/lang/IndexOutOfBoundsException.html" title="class or interface in java.lang" class="external-link">IndexOutOfBoundsException</a></code> - if the given index is out of bounds.</dd> |
| <dt>See Also:</dt> |
| <dd> |
| <ul class="tag-list"> |
| <li><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/RectangularShape.html#getMaxX()" title="class or interface in java.awt.geom" class="external-link"><code>RectangularShape.getMaxX()</code></a></li> |
| <li><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/RectangularShape.html#getMaxY()" title="class or interface in java.awt.geom" class="external-link"><code>RectangularShape.getMaxY()</code></a></li> |
| </ul> |
| </dd> |
| </dl> |
| </div> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="getMedian(int)"> |
| <h3>getMedian</h3> |
| <div class="horizontal-scroll"> |
| <div class="member-signature"><span class="modifiers">public</span> <span class="return-type">double</span> <span class="element-name">getMedian</span><wbr><span class="parameters">(int dimension)</span> |
| throws <span class="exceptions"><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.base/java/lang/IndexOutOfBoundsException.html" title="class or interface in java.lang" class="external-link">IndexOutOfBoundsException</a></span></div> |
| <div class="block">Returns the median coordinate along the specified dimension. This method handles |
| anti-meridian as documented in the <a href="AbstractEnvelope.html#getMedian(int)"><code>AbstractEnvelope.getMedian(int)</code></a> method.</div> |
| <dl class="notes"> |
| <dt>Specified by:</dt> |
| <dd><code><a href="https://www.geoapi.org/3.0/javadoc/org.opengis.geoapi/org/opengis/geometry/Envelope.html#getMedian(int)" title="class or interface in org.opengis.geometry" class="external-link">getMedian</a></code> in interface <code><a href="https://www.geoapi.org/3.0/javadoc/org.opengis.geoapi/org/opengis/geometry/Envelope.html" title="class or interface in org.opengis.geometry" class="external-link">Envelope</a></code></dd> |
| <dt>Parameters:</dt> |
| <dd><code>dimension</code> - the dimension to query.</dd> |
| <dt>Returns:</dt> |
| <dd>the mid coordinate value along the given dimension.</dd> |
| <dt>Throws:</dt> |
| <dd><code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.base/java/lang/IndexOutOfBoundsException.html" title="class or interface in java.lang" class="external-link">IndexOutOfBoundsException</a></code> - if the given index is out of bounds.</dd> |
| <dt>See Also:</dt> |
| <dd> |
| <ul class="tag-list"> |
| <li><a href="#getMedian()"><code>getMedian()</code></a></li> |
| </ul> |
| </dd> |
| </dl> |
| </div> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="getSpan(int)"> |
| <h3>getSpan</h3> |
| <div class="horizontal-scroll"> |
| <div class="member-signature"><span class="modifiers">public</span> <span class="return-type">double</span> <span class="element-name">getSpan</span><wbr><span class="parameters">(int dimension)</span> |
| throws <span class="exceptions"><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.base/java/lang/IndexOutOfBoundsException.html" title="class or interface in java.lang" class="external-link">IndexOutOfBoundsException</a></span></div> |
| <div class="block">Returns the envelope span along the specified dimension. This method handles |
| anti-meridian as documented in the <a href="AbstractEnvelope.html#getSpan(int)"><code>AbstractEnvelope.getSpan(int)</code></a> method.</div> |
| <dl class="notes"> |
| <dt>Specified by:</dt> |
| <dd><code><a href="https://www.geoapi.org/3.0/javadoc/org.opengis.geoapi/org/opengis/geometry/Envelope.html#getSpan(int)" title="class or interface in org.opengis.geometry" class="external-link">getSpan</a></code> in interface <code><a href="https://www.geoapi.org/3.0/javadoc/org.opengis.geoapi/org/opengis/geometry/Envelope.html" title="class or interface in org.opengis.geometry" class="external-link">Envelope</a></code></dd> |
| <dt>Parameters:</dt> |
| <dd><code>dimension</code> - the dimension to query.</dd> |
| <dt>Returns:</dt> |
| <dd>the rectangle width or height, depending the given dimension.</dd> |
| <dt>Throws:</dt> |
| <dd><code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.base/java/lang/IndexOutOfBoundsException.html" title="class or interface in java.lang" class="external-link">IndexOutOfBoundsException</a></code> - if the given index is out of bounds.</dd> |
| <dt>See Also:</dt> |
| <dd> |
| <ul class="tag-list"> |
| <li><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/RectangularShape.html#getWidth()" title="class or interface in java.awt.geom" class="external-link"><code>RectangularShape.getWidth()</code></a></li> |
| <li><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/RectangularShape.html#getHeight()" title="class or interface in java.awt.geom" class="external-link"><code>RectangularShape.getHeight()</code></a></li> |
| </ul> |
| </dd> |
| </dl> |
| </div> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="getMinX()"> |
| <h3>getMinX</h3> |
| <div class="horizontal-scroll"> |
| <div class="member-signature"><span class="modifiers">public</span> <span class="return-type">double</span> <span class="element-name">getMinX</span>()</div> |
| <div class="block">Returns the <a href="#getMinimum(int)">minimal</a> coordinate value for dimension 0. |
| The default implementation invokes <code><a href="#getMinimum(int)">getMinimum</a>(0)</code>. |
| The result is the standard <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.html" title="class or interface in java.awt.geom" class="external-link"><code>Rectangle2D</code></a> value (namely <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.Double.html#x" title="class or interface in java.awt.geom" class="external-link">x</a>) |
| only if the envelope is not crossing the anti-meridian.</div> |
| <dl class="notes"> |
| <dt>Overrides:</dt> |
| <dd><code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/RectangularShape.html#getMinX()" title="class or interface in java.awt.geom" class="external-link">getMinX</a></code> in class <code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/RectangularShape.html" title="class or interface in java.awt.geom" class="external-link">RectangularShape</a></code></dd> |
| <dt>Returns:</dt> |
| <dd>the minimal coordinate value for dimension 0.</dd> |
| </dl> |
| </div> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="getMinY()"> |
| <h3>getMinY</h3> |
| <div class="horizontal-scroll"> |
| <div class="member-signature"><span class="modifiers">public</span> <span class="return-type">double</span> <span class="element-name">getMinY</span>()</div> |
| <div class="block">Returns the <a href="#getMinimum(int)">minimal</a> coordinate value for dimension 1. |
| The default implementation invokes <code><a href="#getMinimum(int)">getMinimum</a>(1)</code>. |
| The result is the standard <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.html" title="class or interface in java.awt.geom" class="external-link"><code>Rectangle2D</code></a> value (namely <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.Double.html#y" title="class or interface in java.awt.geom" class="external-link">y</a>) |
| only if the envelope is not crossing the anti-meridian.</div> |
| <dl class="notes"> |
| <dt>Overrides:</dt> |
| <dd><code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/RectangularShape.html#getMinY()" title="class or interface in java.awt.geom" class="external-link">getMinY</a></code> in class <code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/RectangularShape.html" title="class or interface in java.awt.geom" class="external-link">RectangularShape</a></code></dd> |
| <dt>Returns:</dt> |
| <dd>the minimal coordinate value for dimension 1.</dd> |
| </dl> |
| </div> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="getMaxX()"> |
| <h3>getMaxX</h3> |
| <div class="horizontal-scroll"> |
| <div class="member-signature"><span class="modifiers">public</span> <span class="return-type">double</span> <span class="element-name">getMaxX</span>()</div> |
| <div class="block">Returns the <a href="#getMaximum(int)">maximal</a> coordinate value for dimension 0. |
| The default implementation invokes <code><a href="#getMaximum(int)">getMinimum</a>(0)</code>. |
| The result is the standard <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.html" title="class or interface in java.awt.geom" class="external-link"><code>Rectangle2D</code></a> value (namely <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.Double.html#x" title="class or interface in java.awt.geom" class="external-link">x</a> + <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.Double.html#width" title="class or interface in java.awt.geom" class="external-link">width</a>) |
| only if the envelope is not crossing the anti-meridian.</div> |
| <dl class="notes"> |
| <dt>Overrides:</dt> |
| <dd><code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/RectangularShape.html#getMaxX()" title="class or interface in java.awt.geom" class="external-link">getMaxX</a></code> in class <code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/RectangularShape.html" title="class or interface in java.awt.geom" class="external-link">RectangularShape</a></code></dd> |
| <dt>Returns:</dt> |
| <dd>the maximal coordinate value for dimension 0.</dd> |
| </dl> |
| </div> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="getMaxY()"> |
| <h3>getMaxY</h3> |
| <div class="horizontal-scroll"> |
| <div class="member-signature"><span class="modifiers">public</span> <span class="return-type">double</span> <span class="element-name">getMaxY</span>()</div> |
| <div class="block">Returns the <a href="#getMaximum(int)">maximal</a> coordinate value for dimension 1. |
| The default implementation invokes <code><a href="#getMaximum(int)">getMinimum</a>(1)</code>. |
| The result is the standard <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.html" title="class or interface in java.awt.geom" class="external-link"><code>Rectangle2D</code></a> value (namely <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.Double.html#y" title="class or interface in java.awt.geom" class="external-link">y</a> + <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.Double.html#height" title="class or interface in java.awt.geom" class="external-link">height</a>) |
| only if the envelope is not crossing the anti-meridian.</div> |
| <dl class="notes"> |
| <dt>Overrides:</dt> |
| <dd><code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/RectangularShape.html#getMaxY()" title="class or interface in java.awt.geom" class="external-link">getMaxY</a></code> in class <code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/RectangularShape.html" title="class or interface in java.awt.geom" class="external-link">RectangularShape</a></code></dd> |
| <dt>Returns:</dt> |
| <dd>the maximal coordinate value for dimension 1.</dd> |
| </dl> |
| </div> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="getCenterX()"> |
| <h3>getCenterX</h3> |
| <div class="horizontal-scroll"> |
| <div class="member-signature"><span class="modifiers">public</span> <span class="return-type">double</span> <span class="element-name">getCenterX</span>()</div> |
| <div class="block">Returns the <a href="#getMedian(int)">median</a> coordinate value for dimension 0. |
| The default implementation invokes <code><a href="#getMedian(int)">getMedian</a>(0)</code>. |
| The result is the standard <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.html" title="class or interface in java.awt.geom" class="external-link"><code>Rectangle2D</code></a> value (namely <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.Double.html#x" title="class or interface in java.awt.geom" class="external-link">x</a> + <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.Double.html#width" title="class or interface in java.awt.geom" class="external-link">width</a>/2) |
| only if the envelope is not crossing the anti-meridian.</div> |
| <dl class="notes"> |
| <dt>Overrides:</dt> |
| <dd><code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/RectangularShape.html#getCenterX()" title="class or interface in java.awt.geom" class="external-link">getCenterX</a></code> in class <code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/RectangularShape.html" title="class or interface in java.awt.geom" class="external-link">RectangularShape</a></code></dd> |
| <dt>Returns:</dt> |
| <dd>the median coordinate value for dimension 0.</dd> |
| </dl> |
| </div> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="getCenterY()"> |
| <h3>getCenterY</h3> |
| <div class="horizontal-scroll"> |
| <div class="member-signature"><span class="modifiers">public</span> <span class="return-type">double</span> <span class="element-name">getCenterY</span>()</div> |
| <div class="block">Returns the <a href="#getMedian(int)">median</a> coordinate value for dimension 1. |
| The default implementation invokes <code><a href="#getMedian(int)">getMedian</a>(1)</code>. |
| The result is the standard <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.html" title="class or interface in java.awt.geom" class="external-link"><code>Rectangle2D</code></a> value (namely <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.Double.html#y" title="class or interface in java.awt.geom" class="external-link">y</a> + <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.Double.html#height" title="class or interface in java.awt.geom" class="external-link">height</a>/2) |
| only if the envelope is not crossing the anti-meridian.</div> |
| <dl class="notes"> |
| <dt>Overrides:</dt> |
| <dd><code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/RectangularShape.html#getCenterY()" title="class or interface in java.awt.geom" class="external-link">getCenterY</a></code> in class <code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/RectangularShape.html" title="class or interface in java.awt.geom" class="external-link">RectangularShape</a></code></dd> |
| <dt>Returns:</dt> |
| <dd>the median coordinate value for dimension 1.</dd> |
| </dl> |
| </div> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="getWidth()"> |
| <h3>getWidth</h3> |
| <div class="horizontal-scroll"> |
| <div class="member-signature"><span class="modifiers">public</span> <span class="return-type">double</span> <span class="element-name">getWidth</span>()</div> |
| <div class="block">Returns the <a href="#getSpan(int)">span</a> for dimension 0. |
| The default implementation invokes <code><a href="#getSpan(int)">getSpan</a>(0)</code>. |
| The result is the standard <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.html" title="class or interface in java.awt.geom" class="external-link"><code>Rectangle2D</code></a> value (namely <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.Double.html#width" title="class or interface in java.awt.geom" class="external-link">width</a>) |
| only if the envelope is not crossing the anti-meridian.</div> |
| <dl class="notes"> |
| <dt>Overrides:</dt> |
| <dd><code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.Double.html#getWidth()" title="class or interface in java.awt.geom" class="external-link">getWidth</a></code> in class <code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.Double.html" title="class or interface in java.awt.geom" class="external-link">Rectangle2D.Double</a></code></dd> |
| <dt>Returns:</dt> |
| <dd>the span for dimension 0.</dd> |
| </dl> |
| </div> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="getHeight()"> |
| <h3>getHeight</h3> |
| <div class="horizontal-scroll"> |
| <div class="member-signature"><span class="modifiers">public</span> <span class="return-type">double</span> <span class="element-name">getHeight</span>()</div> |
| <div class="block">Returns the <a href="#getSpan(int)">span</a> for dimension 1. |
| The default implementation invokes <code><a href="#getSpan(int)">getSpan</a>(1)</code>. |
| The result is the standard <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.html" title="class or interface in java.awt.geom" class="external-link"><code>Rectangle2D</code></a> value (namely <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.Double.html#height" title="class or interface in java.awt.geom" class="external-link">height</a>) |
| only if the envelope is not crossing the anti-meridian.</div> |
| <dl class="notes"> |
| <dt>Overrides:</dt> |
| <dd><code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.Double.html#getHeight()" title="class or interface in java.awt.geom" class="external-link">getHeight</a></code> in class <code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.Double.html" title="class or interface in java.awt.geom" class="external-link">Rectangle2D.Double</a></code></dd> |
| <dt>Returns:</dt> |
| <dd>the span for dimension 1.</dd> |
| </dl> |
| </div> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="isEmpty()"> |
| <h3>isEmpty</h3> |
| <div class="horizontal-scroll"> |
| <div class="member-signature"><span class="modifiers">public</span> <span class="return-type">boolean</span> <span class="element-name">isEmpty</span>()</div> |
| <div class="block">Determines whether the envelope is empty. A negative <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.Double.html#width" title="class or interface in java.awt.geom" class="external-link">Rectangle2D.Double.width</a> or |
| (@linkplain #height} is considered as a non-empty area if the corresponding |
| axis has the <a href="https://www.geoapi.org/3.0/javadoc/org.opengis.geoapi/org/opengis/referencing/cs/RangeMeaning.html#WRAPAROUND" title="class or interface in org.opengis.referencing.cs" class="external-link">wraparound</a> range meaning. |
| |
| <p>Note that if the <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.Double.html#width" title="class or interface in java.awt.geom" class="external-link">Rectangle2D.Double.width</a> or <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.Double.html#height" title="class or interface in java.awt.geom" class="external-link">Rectangle2D.Double.height</a> value is |
| <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.base/java/lang/Double.html#NaN" title="class or interface in java.lang" class="external-link"><code>NaN</code></a>, then the envelope is considered empty. |
| This is different than the default <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.Double.html#isEmpty()" title="class or interface in java.awt.geom" class="external-link"><code>Rectangle2D.Double.isEmpty()</code></a> |
| implementation, which doesn't check for <code>NaN</code> values.</p></div> |
| <dl class="notes"> |
| <dt>Specified by:</dt> |
| <dd><code><a href="../../../../../org.apache.sis.util/org/apache/sis/util/Emptiable.html#isEmpty()">isEmpty</a></code> in interface <code><a href="../../../../../org.apache.sis.util/org/apache/sis/util/Emptiable.html" title="interface in org.apache.sis.util">Emptiable</a></code></dd> |
| <dt>Overrides:</dt> |
| <dd><code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.Double.html#isEmpty()" title="class or interface in java.awt.geom" class="external-link">isEmpty</a></code> in class <code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.Double.html" title="class or interface in java.awt.geom" class="external-link">Rectangle2D.Double</a></code></dd> |
| <dt>Returns:</dt> |
| <dd><code>true</code> if this envelope is empty.</dd> |
| </dl> |
| </div> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="toRectangles()"> |
| <h3>toRectangles</h3> |
| <div class="horizontal-scroll"> |
| <div class="member-signature"><span class="modifiers">public</span> <span class="return-type"><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.Double.html" title="class or interface in java.awt.geom" class="external-link">Rectangle2D.Double</a>[]</span> <span class="element-name">toRectangles</span>()</div> |
| <div class="block">Returns this envelope as non-empty Java2D rectangle objects. This method returns an array of length 0, 1, |
| 2 or 4 depending on whether the envelope crosses the anti-meridian or the limit of any other axis having |
| <a href="https://www.geoapi.org/3.0/javadoc/org.opengis.geoapi/org/opengis/referencing/cs/RangeMeaning.html#WRAPAROUND" title="class or interface in org.opengis.referencing.cs" class="external-link">wraparound</a> range meaning. |
| More specifically: |
| |
| <ul> |
| <li>If this envelope <a href="#isEmpty()">is empty</a>, then this method returns an empty array.</li> |
| <li>If this envelope does not have any wraparound behavior, then this method returns a copy |
| of this envelope as an instance of <code>Rectangle2D.Double</code> in an array of length 1.</li> |
| <li>If this envelope crosses the <i>anti-meridian</i> (a.k.a. <i>date line</i>) |
| then this method represents this envelope as two separated rectangles. |
| <li>While uncommon, the envelope could theoretically crosses the limit of other axis having |
| wraparound range meaning. If wraparound occur along the two axes, then this method |
| represents this envelope as four separated rectangles. |
| </ul> |
| |
| <div class="note"><b>API note:</b> |
| The return type is the <code>Rectangle2D.Double</code> implementation class rather than the <code>Rectangle2D</code> |
| abstract class because the <code>Envelope2D</code> class hierarchy already exposes this implementation choice.</div></div> |
| <dl class="notes"> |
| <dt>Returns:</dt> |
| <dd>a representation of this envelope as an array of non-empty Java2D rectangles. |
| The array never contains <code>this</code>.</dd> |
| <dt>Since:</dt> |
| <dd>0.4</dd> |
| <dt>See Also:</dt> |
| <dd> |
| <ul class="tag-list-long"> |
| <li><a href="AbstractEnvelope.html#toSimpleEnvelopes()"><code>AbstractEnvelope.toSimpleEnvelopes()</code></a></li> |
| </ul> |
| </dd> |
| </dl> |
| </div> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="contains(double,double)"> |
| <h3>contains</h3> |
| <div class="horizontal-scroll"> |
| <div class="member-signature"><span class="modifiers">public</span> <span class="return-type">boolean</span> <span class="element-name">contains</span><wbr><span class="parameters">(double px, |
| double py)</span></div> |
| <div class="block">Tests if a specified coordinate is inside the boundary of this envelope. If it least one |
| of the given coordinate value is <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.base/java/lang/Double.html#NaN" title="class or interface in java.lang" class="external-link"><code>NaN</code></a>, then this method returns |
| <code>false</code>. |
| |
| <h4 id="crossing-the-anti-meridian-of-a-geographic-crs-heading1">Crossing the anti-meridian of a Geographic CRS</h4> |
| This method supports anti-meridian in the same way as |
| <a href="AbstractEnvelope.html#contains(org.opengis.geometry.DirectPosition)"><code>AbstractEnvelope.contains(DirectPosition)</code></a>.</div> |
| <dl class="notes"> |
| <dt>Specified by:</dt> |
| <dd><code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/Shape.html#contains(double,double)" title="class or interface in java.awt" class="external-link">contains</a></code> in interface <code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/Shape.html" title="class or interface in java.awt" class="external-link">Shape</a></code></dd> |
| <dt>Overrides:</dt> |
| <dd><code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.html#contains(double,double)" title="class or interface in java.awt.geom" class="external-link">contains</a></code> in class <code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.html" title="class or interface in java.awt.geom" class="external-link">Rectangle2D</a></code></dd> |
| <dt>Parameters:</dt> |
| <dd><code>px</code> - the first coordinate value of the point to text.</dd> |
| <dd><code>py</code> - the second coordinate value of the point to text.</dd> |
| <dt>Returns:</dt> |
| <dd><code>true</code> if the specified coordinate is inside the boundary of this envelope; |
| <code>false</code> otherwise.</dd> |
| </dl> |
| </div> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="contains(java.awt.geom.Rectangle2D)"> |
| <h3>contains</h3> |
| <div class="horizontal-scroll"> |
| <div class="member-signature"><span class="modifiers">public</span> <span class="return-type">boolean</span> <span class="element-name">contains</span><wbr><span class="parameters">(<a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.html" title="class or interface in java.awt.geom" class="external-link">Rectangle2D</a> rect)</span></div> |
| <div class="block">Returns <code>true</code> if this envelope completely encloses the specified rectangle. If this |
| envelope or the given rectangle have at least one <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.base/java/lang/Double.html#NaN" title="class or interface in java.lang" class="external-link"><code>NaN</code></a> value, |
| then this method returns <code>false</code>. |
| |
| <h4 id="crossing-the-anti-meridian-of-a-geographic-crs-heading2">Crossing the anti-meridian of a Geographic CRS</h4> |
| This method supports anti-meridian in the same way as |
| <a href="AbstractEnvelope.html#contains(org.opengis.geometry.Envelope)"><code>AbstractEnvelope.contains(Envelope)</code></a>.</div> |
| <dl class="notes"> |
| <dt>Specified by:</dt> |
| <dd><code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/Shape.html#contains(java.awt.geom.Rectangle2D)" title="class or interface in java.awt" class="external-link">contains</a></code> in interface <code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/Shape.html" title="class or interface in java.awt" class="external-link">Shape</a></code></dd> |
| <dt>Overrides:</dt> |
| <dd><code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/RectangularShape.html#contains(java.awt.geom.Rectangle2D)" title="class or interface in java.awt.geom" class="external-link">contains</a></code> in class <code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/RectangularShape.html" title="class or interface in java.awt.geom" class="external-link">RectangularShape</a></code></dd> |
| <dt>Parameters:</dt> |
| <dd><code>rect</code> - the rectangle to test for inclusion.</dd> |
| <dt>Returns:</dt> |
| <dd><code>true</code> if this envelope completely encloses the specified rectangle.</dd> |
| </dl> |
| </div> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="contains(double,double,double,double)"> |
| <h3>contains</h3> |
| <div class="horizontal-scroll"> |
| <div class="member-signature"><span class="modifiers">public</span> <span class="return-type">boolean</span> <span class="element-name">contains</span><wbr><span class="parameters">(double rx, |
| double ry, |
| double rw, |
| double rh)</span></div> |
| <div class="block">Returns <code>true</code> if this envelope completely encloses the specified rectangle. If this |
| envelope or the given rectangle have at least one <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.base/java/lang/Double.html#NaN" title="class or interface in java.lang" class="external-link"><code>NaN</code></a> value, |
| then this method returns <code>false</code>. |
| |
| <h4 id="crossing-the-anti-meridian-of-a-geographic-crs-heading3">Crossing the anti-meridian of a Geographic CRS</h4> |
| This method supports anti-meridian in the same way as |
| <a href="AbstractEnvelope.html#contains(org.opengis.geometry.Envelope)"><code>AbstractEnvelope.contains(Envelope)</code></a>.</div> |
| <dl class="notes"> |
| <dt>Specified by:</dt> |
| <dd><code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/Shape.html#contains(double,double,double,double)" title="class or interface in java.awt" class="external-link">contains</a></code> in interface <code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/Shape.html" title="class or interface in java.awt" class="external-link">Shape</a></code></dd> |
| <dt>Overrides:</dt> |
| <dd><code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.html#contains(double,double,double,double)" title="class or interface in java.awt.geom" class="external-link">contains</a></code> in class <code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.html" title="class or interface in java.awt.geom" class="external-link">Rectangle2D</a></code></dd> |
| <dt>Parameters:</dt> |
| <dd><code>rx</code> - the <var>x</var> coordinate of the lower corner of the rectangle to test for inclusion.</dd> |
| <dd><code>ry</code> - the <var>y</var> coordinate of the lower corner of the rectangle to test for inclusion.</dd> |
| <dd><code>rw</code> - the width of the rectangle to test for inclusion. May be negative if the rectangle spans the anti-meridian.</dd> |
| <dd><code>rh</code> - the height of the rectangle to test for inclusion. May be negative.</dd> |
| <dt>Returns:</dt> |
| <dd><code>true</code> if this envelope completely encloses the specified one.</dd> |
| </dl> |
| </div> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="intersects(java.awt.geom.Rectangle2D)"> |
| <h3>intersects</h3> |
| <div class="horizontal-scroll"> |
| <div class="member-signature"><span class="modifiers">public</span> <span class="return-type">boolean</span> <span class="element-name">intersects</span><wbr><span class="parameters">(<a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.html" title="class or interface in java.awt.geom" class="external-link">Rectangle2D</a> rect)</span></div> |
| <div class="block">Returns <code>true</code> if this envelope intersects the specified envelope. If this envelope |
| or the given rectangle have at least one <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.base/java/lang/Double.html#NaN" title="class or interface in java.lang" class="external-link"><code>NaN</code></a> value, then this |
| method returns <code>false</code>. |
| |
| <h4 id="crossing-the-anti-meridian-of-a-geographic-crs-heading4">Crossing the anti-meridian of a Geographic CRS</h4> |
| This method supports anti-meridian in the same way as |
| <a href="AbstractEnvelope.html#intersects(org.opengis.geometry.Envelope)"><code>AbstractEnvelope.intersects(Envelope)</code></a>.</div> |
| <dl class="notes"> |
| <dt>Specified by:</dt> |
| <dd><code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/Shape.html#intersects(java.awt.geom.Rectangle2D)" title="class or interface in java.awt" class="external-link">intersects</a></code> in interface <code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/Shape.html" title="class or interface in java.awt" class="external-link">Shape</a></code></dd> |
| <dt>Overrides:</dt> |
| <dd><code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/RectangularShape.html#intersects(java.awt.geom.Rectangle2D)" title="class or interface in java.awt.geom" class="external-link">intersects</a></code> in class <code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/RectangularShape.html" title="class or interface in java.awt.geom" class="external-link">RectangularShape</a></code></dd> |
| <dt>Parameters:</dt> |
| <dd><code>rect</code> - the rectangle to test for intersection.</dd> |
| <dt>Returns:</dt> |
| <dd><code>true</code> if this envelope intersects the specified rectangle.</dd> |
| </dl> |
| </div> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="intersects(double,double,double,double)"> |
| <h3>intersects</h3> |
| <div class="horizontal-scroll"> |
| <div class="member-signature"><span class="modifiers">public</span> <span class="return-type">boolean</span> <span class="element-name">intersects</span><wbr><span class="parameters">(double rx, |
| double ry, |
| double rw, |
| double rh)</span></div> |
| <div class="block">Returns <code>true</code> if this envelope intersects the specified envelope. If this envelope |
| or the given rectangle have at least one <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.base/java/lang/Double.html#NaN" title="class or interface in java.lang" class="external-link"><code>NaN</code></a> value, then this |
| method returns <code>false</code>. |
| |
| <h4 id="crossing-the-anti-meridian-of-a-geographic-crs-heading5">Crossing the anti-meridian of a Geographic CRS</h4> |
| This method supports anti-meridian in the same way as |
| <a href="AbstractEnvelope.html#intersects(org.opengis.geometry.Envelope)"><code>AbstractEnvelope.intersects(Envelope)</code></a>.</div> |
| <dl class="notes"> |
| <dt>Specified by:</dt> |
| <dd><code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/Shape.html#intersects(double,double,double,double)" title="class or interface in java.awt" class="external-link">intersects</a></code> in interface <code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/Shape.html" title="class or interface in java.awt" class="external-link">Shape</a></code></dd> |
| <dt>Overrides:</dt> |
| <dd><code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.html#intersects(double,double,double,double)" title="class or interface in java.awt.geom" class="external-link">intersects</a></code> in class <code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.html" title="class or interface in java.awt.geom" class="external-link">Rectangle2D</a></code></dd> |
| <dt>Parameters:</dt> |
| <dd><code>rx</code> - the <var>x</var> coordinate of the lower corner of the rectangle to test for intersection.</dd> |
| <dd><code>ry</code> - the <var>y</var> coordinate of the lower corner of the rectangle to test for intersection.</dd> |
| <dd><code>rw</code> - the width of the rectangle to test for inclusion. May be negative if the rectangle spans the anti-meridian.</dd> |
| <dd><code>rh</code> - the height of the rectangle to test for inclusion. May be negative.</dd> |
| <dt>Returns:</dt> |
| <dd><code>true</code> if this envelope intersects the specified rectangle.</dd> |
| </dl> |
| </div> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="createIntersection(java.awt.geom.Rectangle2D)"> |
| <h3>createIntersection</h3> |
| <div class="horizontal-scroll"> |
| <div class="member-signature"><span class="modifiers">public</span> <span class="return-type"><a href="Envelope2D.html" title="class in org.apache.sis.geometry">Envelope2D</a></span> <span class="element-name">createIntersection</span><wbr><span class="parameters">(<a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.html" title="class or interface in java.awt.geom" class="external-link">Rectangle2D</a> rect)</span></div> |
| <div class="block">Returns the intersection of this envelope with the specified rectangle. If this envelope |
| or the given rectangle have at least one <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.base/java/lang/Double.html#NaN" title="class or interface in java.lang" class="external-link"><code>NaN</code></a> values, then this |
| method returns an <a href="#isEmpty()">empty</a> envelope. |
| |
| <h4 id="crossing-the-anti-meridian-of-a-geographic-crs-heading6">Crossing the anti-meridian of a Geographic CRS</h4> |
| This method supports anti-meridian in the same way as |
| <a href="GeneralEnvelope.html#intersect(org.opengis.geometry.Envelope)"><code>GeneralEnvelope.intersect(Envelope)</code></a>.</div> |
| <dl class="notes"> |
| <dt>Overrides:</dt> |
| <dd><code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.Double.html#createIntersection(java.awt.geom.Rectangle2D)" title="class or interface in java.awt.geom" class="external-link">createIntersection</a></code> in class <code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.Double.html" title="class or interface in java.awt.geom" class="external-link">Rectangle2D.Double</a></code></dd> |
| <dt>Parameters:</dt> |
| <dd><code>rect</code> - the rectangle to be intersected with this envelope.</dd> |
| <dt>Returns:</dt> |
| <dd>the intersection of the given rectangle with this envelope.</dd> |
| </dl> |
| </div> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="createUnion(java.awt.geom.Rectangle2D)"> |
| <h3>createUnion</h3> |
| <div class="horizontal-scroll"> |
| <div class="member-signature"><span class="modifiers">public</span> <span class="return-type"><a href="Envelope2D.html" title="class in org.apache.sis.geometry">Envelope2D</a></span> <span class="element-name">createUnion</span><wbr><span class="parameters">(<a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.html" title="class or interface in java.awt.geom" class="external-link">Rectangle2D</a> rect)</span></div> |
| <div class="block">Returns the union of this envelope with the specified rectangle. |
| The default implementation clones this envelope, then delegates |
| to <a href="#add(java.awt.geom.Rectangle2D)"><code>add(Rectangle2D)</code></a>.</div> |
| <dl class="notes"> |
| <dt>Overrides:</dt> |
| <dd><code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.Double.html#createUnion(java.awt.geom.Rectangle2D)" title="class or interface in java.awt.geom" class="external-link">createUnion</a></code> in class <code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.Double.html" title="class or interface in java.awt.geom" class="external-link">Rectangle2D.Double</a></code></dd> |
| <dt>Parameters:</dt> |
| <dd><code>rect</code> - the rectangle to add to this envelope.</dd> |
| <dt>Returns:</dt> |
| <dd>the union of the given rectangle with this envelope.</dd> |
| </dl> |
| </div> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="add(java.awt.geom.Rectangle2D)"> |
| <h3>add</h3> |
| <div class="horizontal-scroll"> |
| <div class="member-signature"><span class="modifiers">public</span> <span class="return-type">void</span> <span class="element-name">add</span><wbr><span class="parameters">(<a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.html" title="class or interface in java.awt.geom" class="external-link">Rectangle2D</a> rect)</span></div> |
| <div class="block">Adds another rectangle to this rectangle. The resulting rectangle is the union of the |
| two <code>Rectangle</code> objects. |
| |
| <h4 id="crossing-the-anti-meridian-of-a-geographic-crs-heading7">Crossing the anti-meridian of a Geographic CRS</h4> |
| This method supports anti-meridian in the same way as <a href="GeneralEnvelope.html#add(org.opengis.geometry.Envelope)"><code>GeneralEnvelope.add(Envelope)</code></a>, |
| except if the result is a rectangle expanding to infinities. In that later case, the field values |
| are set to <code>NaN</code> because infinite values are a problematic in <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.html" title="class or interface in java.awt.geom" class="external-link"><code>Rectangle2D</code></a> objects.</div> |
| <dl class="notes"> |
| <dt>Overrides:</dt> |
| <dd><code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.html#add(java.awt.geom.Rectangle2D)" title="class or interface in java.awt.geom" class="external-link">add</a></code> in class <code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.html" title="class or interface in java.awt.geom" class="external-link">Rectangle2D</a></code></dd> |
| <dt>Parameters:</dt> |
| <dd><code>rect</code> - the rectangle to add to this envelope.</dd> |
| </dl> |
| </div> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="add(double,double)"> |
| <h3>add</h3> |
| <div class="horizontal-scroll"> |
| <div class="member-signature"><span class="modifiers">public</span> <span class="return-type">void</span> <span class="element-name">add</span><wbr><span class="parameters">(double px, |
| double py)</span></div> |
| <div class="block">Adds a point to this rectangle. The resulting rectangle is the smallest rectangle that |
| contains both the original rectangle and the specified point. |
| <p> |
| After adding a point, a call to <a href="#contains(double,double)"><code>contains(double, double)</code></a> with the added point |
| as an argument will return <code>true</code>, except if one of the point coordinates was |
| <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.base/java/lang/Double.html#NaN" title="class or interface in java.lang" class="external-link"><code>Double.NaN</code></a> in which case the corresponding coordinate has been ignored. |
| |
| <h4 id="crossing-the-anti-meridian-of-a-geographic-crs-heading8">Crossing the anti-meridian of a Geographic CRS</h4> |
| This method supports anti-meridian in the same way as |
| <a href="GeneralEnvelope.html#add(org.opengis.geometry.DirectPosition)"><code>GeneralEnvelope.add(DirectPosition)</code></a>.</div> |
| <dl class="notes"> |
| <dt>Overrides:</dt> |
| <dd><code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.html#add(double,double)" title="class or interface in java.awt.geom" class="external-link">add</a></code> in class <code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.html" title="class or interface in java.awt.geom" class="external-link">Rectangle2D</a></code></dd> |
| <dt>Parameters:</dt> |
| <dd><code>px</code> - the first coordinate of the point to add.</dd> |
| <dd><code>py</code> - the second coordinate of the point to add.</dd> |
| </dl> |
| </div> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="equals(java.lang.Object)"> |
| <h3>equals</h3> |
| <div class="horizontal-scroll"> |
| <div class="member-signature"><span class="modifiers">public</span> <span class="return-type">boolean</span> <span class="element-name">equals</span><wbr><span class="parameters">(<a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.base/java/lang/Object.html" title="class or interface in java.lang" class="external-link">Object</a> object)</span></div> |
| <div class="block">Compares the specified object with this envelope for equality. If the given object is not |
| an instance of <code>Envelope2D</code>, then the two objects are compared as plain rectangles, |
| i.e. the <a href="#getCoordinateReferenceSystem()">coordinate reference system</a> of this |
| envelope is ignored. |
| |
| <h4 id="note-on-hashcode--heading">Note on <code>hashCode()</code></h4> |
| This class does not override the <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.html#hashCode()" title="class or interface in java.awt.geom" class="external-link"><code>Rectangle2D.hashCode()</code></a> method for consistency with the |
| <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.html#equals(java.lang.Object)" title="class or interface in java.awt.geom" class="external-link"><code>Rectangle2D.equals(Object)</code></a> method, which compare arbitrary <code>Rectangle2D</code> |
| implementations.</div> |
| <dl class="notes"> |
| <dt>Overrides:</dt> |
| <dd><code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.html#equals(java.lang.Object)" title="class or interface in java.awt.geom" class="external-link">equals</a></code> in class <code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.html" title="class or interface in java.awt.geom" class="external-link">Rectangle2D</a></code></dd> |
| <dt>Parameters:</dt> |
| <dd><code>object</code> - the object to compare with this envelope.</dd> |
| <dt>Returns:</dt> |
| <dd><code>true</code> if the given object is equal to this envelope.</dd> |
| </dl> |
| </div> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="boundsEquals(org.opengis.geometry.Envelope,int,int,double)"> |
| <h3>boundsEquals</h3> |
| <div class="horizontal-scroll"> |
| <div class="member-signature"><span class="modifiers">public</span> <span class="return-type">boolean</span> <span class="element-name">boundsEquals</span><wbr><span class="parameters">(<a href="https://www.geoapi.org/3.0/javadoc/org.opengis.geoapi/org/opengis/geometry/Envelope.html" title="class or interface in org.opengis.geometry" class="external-link">Envelope</a> that, |
| int xDim, |
| int yDim, |
| double eps)</span></div> |
| <div class="block">Returns <code>true</code> if <code>this</code> envelope bounds is equal to <code>that</code> envelope |
| bounds in two specified dimensions. The coordinate reference system is not compared, since |
| it doesn't need to have the same number of dimensions.</div> |
| <dl class="notes"> |
| <dt>Parameters:</dt> |
| <dd><code>that</code> - the envelope to compare to.</dd> |
| <dd><code>xDim</code> - the dimension of <code>that</code> envelope to compare to the <var>x</var> dimension of <code>this</code> envelope.</dd> |
| <dd><code>yDim</code> - the dimension of <code>that</code> envelope to compare to the <var>y</var> dimension of <code>this</code> envelope.</dd> |
| <dd><code>eps</code> - a small tolerance number for floating point number comparisons. This value will be scaled |
| according this envelope <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.Double.html#width" title="class or interface in java.awt.geom" class="external-link">width</a> and <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.Double.html#height" title="class or interface in java.awt.geom" class="external-link">height</a>.</dd> |
| <dt>Returns:</dt> |
| <dd><code>true</code> if the envelope bounds are the same (up to the specified tolerance |
| level) in the specified dimensions, or <code>false</code> otherwise.</dd> |
| </dl> |
| </div> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="clone()"> |
| <h3>clone</h3> |
| <div class="horizontal-scroll"> |
| <div class="member-signature"><span class="modifiers">public</span> <span class="return-type"><a href="Envelope2D.html" title="class in org.apache.sis.geometry">Envelope2D</a></span> <span class="element-name">clone</span>()</div> |
| <div class="block">Returns a clone of this envelope.</div> |
| <dl class="notes"> |
| <dt>Overrides:</dt> |
| <dd><code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/RectangularShape.html#clone()" title="class or interface in java.awt.geom" class="external-link">clone</a></code> in class <code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/RectangularShape.html" title="class or interface in java.awt.geom" class="external-link">RectangularShape</a></code></dd> |
| <dt>Returns:</dt> |
| <dd>a clone of this envelope.</dd> |
| </dl> |
| </div> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="toString()"> |
| <h3>toString</h3> |
| <div class="horizontal-scroll"> |
| <div class="member-signature"><span class="modifiers">public</span> <span class="return-type"><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.base/java/lang/String.html" title="class or interface in java.lang" class="external-link">String</a></span> <span class="element-name">toString</span>()</div> |
| <div class="block">Formats this envelope as a "<code>BOX</code>" element. |
| The output is of the form "<code>BOX(</code><a href="#getLowerCorner()">lower corner</a><code>,</code><a href="#getUpperCorner()">upper corner</a><code>)</code>". |
| Example: |
| |
| |
| <div class="snippet-container"><button class="copy snippet-copy" aria-label="Copy snippet" onclick="copySnippet(this)"><span data-copied="Copied!">Copy</span><img src="../../../../../resource-files/copy.svg" alt="Copy snippet"></button> |
| <pre class="snippet" id="snippet-toString()6"><code class="language-wkt">BOX(-90 -180, 90 180) |
| </code></pre> |
| </div> |
| </div> |
| <dl class="notes"> |
| <dt>Overrides:</dt> |
| <dd><code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.Double.html#toString()" title="class or interface in java.awt.geom" class="external-link">toString</a></code> in class <code><a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.desktop/java/awt/geom/Rectangle2D.Double.html" title="class or interface in java.awt.geom" class="external-link">Rectangle2D.Double</a></code></dd> |
| <dt>See Also:</dt> |
| <dd> |
| <ul class="tag-list"> |
| <li><a href="Envelopes.html#toString(org.opengis.geometry.Envelope)"><code>Envelopes.toString(Envelope)</code></a></li> |
| </ul> |
| </dd> |
| </dl> |
| </div> |
| </section> |
| </li> |
| </ul> |
| </section> |
| </li> |
| </ul> |
| </section> |
| <!-- ========= END OF CLASS DATA ========= --> |
| </main> |
| </div> |
| </body> |
| </html> |