| <!DOCTYPE HTML> |
| <html lang="en"> |
| <head> |
| <!-- Generated by javadoc (24) on Mon Sep 29 10:48:08 CEST 2025 --> |
| <title>CoverageCombiner (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.feature, package: org.apache.sis.coverage, class: CoverageCombiner"> |
| <meta name="generator" content="javadoc/ClassWriter"> |
| <meta name="keywords" content="org.apache.sis.coverage.CoverageCombiner class"> |
| <meta name="keywords" content="getInterpolation()"> |
| <meta name="keywords" content="setInterpolation()"> |
| <meta name="keywords" content="acceptAll()"> |
| <meta name="keywords" content="result()"> |
| <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/CoverageCombiner.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.feature</a></li> |
| <li><a href="package-summary.html">org.apache.sis.coverage</a></li> |
| <li><a href="CoverageCombiner.html" class="current-selection">CoverageCombiner</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="#limitations-heading" tabindex="0">Limitations</a></li> |
| </ol> |
| </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(org.apache.sis.coverage.grid.GridCoverage)" tabindex="0">CoverageCombiner(GridCoverage)</a></li> |
| </ol> |
| </li> |
| <li><a href="#method-detail" tabindex="0">Method Details</a> |
| <ol class="toc-list"> |
| <li><a href="#getInterpolation()" tabindex="0">getInterpolation()</a></li> |
| <li><a href="#setInterpolation(org.apache.sis.image.Interpolation)" tabindex="0">setInterpolation(Interpolation)</a></li> |
| <li><a href="#acceptAll(org.apache.sis.coverage.grid.GridCoverage...)" tabindex="0">acceptAll(GridCoverage...)</a></li> |
| <li><a href="#result()" tabindex="0">result()</a></li> |
| </ol> |
| </li> |
| </ol> |
| </nav> |
| <main role="main"> |
| <!-- ======== START OF CLASS DATA ======== --> |
| <div class="header"> |
| <h1 title="Class CoverageCombiner" class="title">Class CoverageCombiner</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">CoverageCombiner</div> |
| </div> |
| <section class="class-description" id="class-description"> |
| <hr> |
| <div class="horizontal-scroll"> |
| <div class="type-signature"><span class="modifiers">public class </span><span class="element-name type-name-label">CoverageCombiner</span> |
| <span class="extends-implements">extends <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></span></div> |
| <div class="block">Combines an arbitrary number of coverages into a single one. |
| The combined coverages may use different coordinate systems. |
| The workflow is as below: |
| |
| <ol> |
| <li>Creates a <code>CoverageCombiner</code> with the destination coverage where to write.</li> |
| <li>Configure with methods such as <a href="#setInterpolation(org.apache.sis.image.Interpolation)"><code>setInterpolation(…)</code></a>.</li> |
| <li>Invoke <a href="#acceptAll(org.apache.sis.coverage.grid.GridCoverage...)"><code>acceptAll(…)</code></a> methods for each list of coverages to combine.</li> |
| <li>Get the combined coverage with <a href="#result()"><code>result()</code></a>.</li> |
| </ol> |
| |
| Coverage domains can have any number of dimensions. |
| Coverages are combined in the order they are specified. |
| For each coverage, sample dimensions are combined in the order they appear, regardless their names. |
| For each sample dimension, values are converted to the unit of measurement of the destination coverage. |
| |
| <h2 id="limitations-heading">Limitations</h2> |
| The current implementation has the following limitations. |
| Those restrictions may be resolved progressively in future Apache SIS versions. |
| |
| <ul> |
| <li>Supports only <a href="grid/GridCoverage.html" title="class in org.apache.sis.coverage.grid"><code>GridCoverage</code></a> instances, not yet more generic coverages.</li> |
| <li>No interpolation except in the two dimensions having the largest size (usually the 2 first). |
| For all other dimensions, data are taken from the nearest neighbor two-dimensional slice.</li> |
| <li>No expansion of the destination coverage for accommodating data of source coverages |
| that are outside the destination coverage bounds.</li> |
| </ul></div> |
| <dl class="notes"> |
| <dt>Since:</dt> |
| <dd>1.4</dd> |
| <dt>See Also:</dt> |
| <dd> |
| <ul class="tag-list"> |
| <li><a href="../image/ImageCombiner.html" title="class in org.apache.sis.image"><code>ImageCombiner</code></a></li> |
| </ul> |
| </dd> |
| </dl> |
| </div> |
| </section> |
| <section class="summary"> |
| <ul class="summary-list"> |
| <!-- ======== 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(org.apache.sis.coverage.grid.GridCoverage)" class="member-name-link">CoverageCombiner</a><wbr>(<a href="grid/GridCoverage.html" title="class in org.apache.sis.coverage.grid">GridCoverage</a> destination)</code></div> |
| <div class="col-last even-row-color"> |
| <div class="block">Creates a coverage combiner which will write in the given coverage.</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>boolean</code></div> |
| <div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="#acceptAll(org.apache.sis.coverage.grid.GridCoverage...)" class="member-name-link">acceptAll</a><wbr>(<a href="grid/GridCoverage.html" title="class in org.apache.sis.coverage.grid">GridCoverage</a>... sources)</code></div> |
| <div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"> |
| <div class="block">Writes the given coverages on top of the destination coverage.</div> |
| </div> |
| <div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="../image/Interpolation.html" title="class in org.apache.sis.image">Interpolation</a></code></div> |
| <div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="#getInterpolation()" class="member-name-link">getInterpolation</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 interpolation method to use during resample operations.</div> |
| </div> |
| <div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="grid/GridCoverage.html" title="class in org.apache.sis.coverage.grid">GridCoverage</a></code></div> |
| <div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="#result()" class="member-name-link">result</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 combination of destination coverage with all coverages specified to <code>CoverageCombiner</code> methods.</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="#setInterpolation(org.apache.sis.image.Interpolation)" class="member-name-link">setInterpolation</a><wbr>(<a href="../image/Interpolation.html" title="class in org.apache.sis.image">Interpolation</a> method)</code></div> |
| <div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"> |
| <div class="block">Sets the interpolation method to use during resample operations.</div> |
| </div> |
| </div> |
| </div> |
| </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#clone()" title="class or interface in java.lang" class="external-link">clone</a>, <a href="https://docs.oracle.com/en/java/javase/25/docs/api/java.base/java/lang/Object.html#equals(java.lang.Object)" title="class or interface in java.lang" class="external-link">equals</a>, <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#hashCode()" title="class or interface in java.lang" class="external-link">hashCode</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#toString()" title="class or interface in java.lang" class="external-link">toString</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>(org.apache.sis.coverage.grid.GridCoverage)"> |
| <h3>CoverageCombiner</h3> |
| <div class="horizontal-scroll"> |
| <div class="member-signature"><span class="modifiers">public</span> <span class="element-name">CoverageCombiner</span><wbr><span class="parameters">(<a href="grid/GridCoverage.html" title="class in org.apache.sis.coverage.grid">GridCoverage</a> destination)</span></div> |
| <div class="block">Creates a coverage combiner which will write in the given coverage. |
| The coverage is not cleared: cells that are not overwritten by calls |
| to the <code>accept(…)</code> method will be left unchanged.</div> |
| <dl class="notes"> |
| <dt>Parameters:</dt> |
| <dd><code>destination</code> - the destination coverage where to combine source coverages.</dd> |
| <dt>Throws:</dt> |
| <dd><code><a href="CannotEvaluateException.html" title="class in org.apache.sis.coverage">CannotEvaluateException</a></code> - if the coverage does not have at least 2 dimensions.</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="getInterpolation()"> |
| <h3>getInterpolation</h3> |
| <div class="horizontal-scroll"> |
| <div class="member-signature"><span class="modifiers">public</span> <span class="return-type"><a href="../image/Interpolation.html" title="class in org.apache.sis.image">Interpolation</a></span> <span class="element-name">getInterpolation</span>()</div> |
| <div class="block">Returns the interpolation method to use during resample operations. |
| |
| <h4 id="limitations-heading1">Limitations</h4> |
| In current version, the interpolation is applied only in the <code>xdim</code> and <code>ydim</code> dimensions |
| specified at construction time. For all other dimensions, nearest neighbor interpolation is applied.</div> |
| <dl class="notes"> |
| <dt>Returns:</dt> |
| <dd>interpolation method to use during resample operations.</dd> |
| </dl> |
| </div> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="setInterpolation(org.apache.sis.image.Interpolation)"> |
| <h3>setInterpolation</h3> |
| <div class="horizontal-scroll"> |
| <div class="member-signature"><span class="modifiers">public</span> <span class="return-type">void</span> <span class="element-name">setInterpolation</span><wbr><span class="parameters">(<a href="../image/Interpolation.html" title="class in org.apache.sis.image">Interpolation</a> method)</span></div> |
| <div class="block">Sets the interpolation method to use during resample operations. |
| |
| <h4 id="limitations-heading2">Limitations</h4> |
| In current version, the interpolation is applied only in the <code>xdim</code> and <code>ydim</code> dimensions |
| specified at construction time. For all other dimensions, nearest neighbor interpolation is applied.</div> |
| <dl class="notes"> |
| <dt>Parameters:</dt> |
| <dd><code>method</code> - interpolation method to use during resample operations.</dd> |
| </dl> |
| </div> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="acceptAll(org.apache.sis.coverage.grid.GridCoverage...)"> |
| <h3>acceptAll</h3> |
| <div class="horizontal-scroll"> |
| <div class="member-signature"><span class="modifiers">public</span> <span class="return-type">boolean</span> <span class="element-name">acceptAll</span><wbr><span class="parameters">(<a href="grid/GridCoverage.html" title="class in org.apache.sis.coverage.grid">GridCoverage</a>... sources)</span> |
| throws <span class="exceptions"><a href="https://www.geoapi.org/3.0/javadoc/org.opengis.geoapi/org/opengis/referencing/operation/TransformException.html" title="class or interface in org.opengis.referencing.operation" class="external-link">TransformException</a>, |
| <a href="https://unitsofmeasurement.github.io/unit-api/site/apidocs/javax/measure/IncommensurableException.html" title="class or interface in javax.measure" class="external-link">IncommensurableException</a></span></div> |
| <div class="block">Writes the given coverages on top of the destination coverage. |
| The given coverages are resampled to the grid geometry of the destination coverage. |
| Coverages that do not intercept with the destination coverage are silently ignored. |
| |
| <h4 id="performance-note-heading">Performance note</h4> |
| If there is many coverages to write, they should be specified in a single |
| call to <code>acceptAll(…)</code> instead of invoking this method multiple times. |
| Bulk operations can reduce the number of calls to <a href="grid/GridCoverage.html#render(org.apache.sis.coverage.grid.GridExtent)"><code>GridCoverage.render(GridExtent)</code></a>.</div> |
| <dl class="notes"> |
| <dt>Parameters:</dt> |
| <dd><code>sources</code> - the coverages to write on top of destination coverage.</dd> |
| <dt>Returns:</dt> |
| <dd><code>true</code> on success, or <code>false</code> if at least one slice |
| in the destination coverage is not writable.</dd> |
| <dt>Throws:</dt> |
| <dd><code><a href="https://www.geoapi.org/3.0/javadoc/org.opengis.geoapi/org/opengis/referencing/operation/TransformException.html" title="class or interface in org.opengis.referencing.operation" class="external-link">TransformException</a></code> - if the coordinates of a given coverage cannot be transformed |
| to the coordinates of destination coverage.</dd> |
| <dd><code><a href="https://unitsofmeasurement.github.io/unit-api/site/apidocs/javax/measure/IncommensurableException.html" title="class or interface in javax.measure" class="external-link">IncommensurableException</a></code> - if the unit of measurement of at least one source sample dimension |
| is not convertible to the unit of measurement of the corresponding target sample dimension.</dd> |
| </dl> |
| </div> |
| </section> |
| </li> |
| <li> |
| <section class="detail" id="result()"> |
| <h3>result</h3> |
| <div class="horizontal-scroll"> |
| <div class="member-signature"><span class="modifiers">public</span> <span class="return-type"><a href="grid/GridCoverage.html" title="class in org.apache.sis.coverage.grid">GridCoverage</a></span> <span class="element-name">result</span>()</div> |
| <div class="block">Returns the combination of destination coverage with all coverages specified to <code>CoverageCombiner</code> methods. |
| This may be the destination coverage specified at construction time, but may also be a larger coverage if the |
| destination has been dynamically expanded for accommodating larger sources. |
| |
| <p><b>Note:</b> dynamic expansion is not yet implemented in current version. |
| If a future version implements it, we shall guarantee that the coordinate of each cell is unchanged |
| (i.e. the grid extent <code>minX</code> and <code>minY</code> may become negative, but the cell identified by |
| coordinates (0,0) for instance will stay the same cell.)</p></div> |
| <dl class="notes"> |
| <dt>Returns:</dt> |
| <dd>the combination of destination coverage with all source coverages.</dd> |
| </dl> |
| </div> |
| </section> |
| </li> |
| </ul> |
| </section> |
| </li> |
| </ul> |
| </section> |
| <!-- ========= END OF CLASS DATA ========= --> |
| </main> |
| </div> |
| </body> |
| </html> |