| <!DOCTYPE HTML> |
| <!-- NewPage --> |
| <html lang="en"> |
| <head> |
| <!-- Generated by javadoc (11.0.4) on Fri Sep 20 12:10:30 CEST 2019 --> |
| <title>RangeSet (Apache SIS 1.0 API)</title> |
| <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> |
| <meta name="dc.created" content="2019-09-20"> |
| <meta name="keywords" content="org.apache.sis.util.collection.RangeSet class"> |
| <meta name="keywords" content="elementType"> |
| <meta name="keywords" content="isMinIncluded"> |
| <meta name="keywords" content="isMaxIncluded"> |
| <meta name="keywords" content="create()"> |
| <meta name="keywords" content="getElementType()"> |
| <meta name="keywords" content="comparator()"> |
| <meta name="keywords" content="clear()"> |
| <meta name="keywords" content="size()"> |
| <meta name="keywords" content="trimToSize()"> |
| <meta name="keywords" content="add()"> |
| <meta name="keywords" content="remove()"> |
| <meta name="keywords" content="contains()"> |
| <meta name="keywords" content="first()"> |
| <meta name="keywords" content="last()"> |
| <meta name="keywords" content="intersect()"> |
| <meta name="keywords" content="subSet()"> |
| <meta name="keywords" content="headSet()"> |
| <meta name="keywords" content="tailSet()"> |
| <meta name="keywords" content="iterator()"> |
| <meta name="keywords" content="indexOfRange()"> |
| <meta name="keywords" content="getMinLong()"> |
| <meta name="keywords" content="getMinDouble()"> |
| <meta name="keywords" content="getMaxLong()"> |
| <meta name="keywords" content="getMaxDouble()"> |
| <meta name="keywords" content="newRange()"> |
| <meta name="keywords" content="equals()"> |
| <meta name="keywords" content="clone()"> |
| <link rel="stylesheet" type="text/css" href="../../../../../stylesheet.css" title="Style"> |
| <link rel="stylesheet" type="text/css" href="../../../../../sis.css" title="Style"> |
| <link rel="stylesheet" type="text/css" href="../../../../../jquery/jquery-ui.css" title="Style"> |
| <script type="text/javascript" src="../../../../../script.js"></script> |
| <script type="text/javascript" src="../../../../../jquery/jszip/dist/jszip.min.js"></script> |
| <script type="text/javascript" src="../../../../../jquery/jszip-utils/dist/jszip-utils.min.js"></script> |
| <!--[if IE]> |
| <script type="text/javascript" src="../../../../../jquery/jszip-utils/dist/jszip-utils-ie.min.js"></script> |
| <![endif]--> |
| <script type="text/javascript" src="../../../../../jquery/jquery-3.3.1.js"></script> |
| <script type="text/javascript" src="../../../../../jquery/jquery-migrate-3.0.1.js"></script> |
| <script type="text/javascript" src="../../../../../jquery/jquery-ui.js"></script> |
| </head> |
| <body> |
| <script type="text/javascript"><!-- |
| try { |
| if (location.href.indexOf('is-external=true') == -1) { |
| parent.document.title="RangeSet (Apache SIS 1.0 API)"; |
| } |
| } |
| catch(err) { |
| } |
| //--> |
| var data = {"i0":10,"i1":10,"i2":10,"i3":10,"i4":10,"i5":10,"i6":10,"i7":9,"i8":10,"i9":10,"i10":10,"i11":10,"i12":10,"i13":10,"i14":10,"i15":10,"i16":10,"i17":10,"i18":10,"i19":10,"i20":10,"i21":10,"i22":10,"i23":10,"i24":10,"i25":10,"i26":10}; |
| var tabs = {65535:["t0","All Methods"],1:["t1","Static Methods"],2:["t2","Instance Methods"],8:["t4","Concrete Methods"]}; |
| var altColor = "altColor"; |
| var rowColor = "rowColor"; |
| var tableTab = "tableTab"; |
| var activeTableTab = "activeTableTab"; |
| var pathtoroot = "../../../../../"; |
| var useModuleDirectories = false; |
| loadScripts(document, 'script');</script> |
| <noscript> |
| <div>JavaScript is disabled on your browser.</div> |
| </noscript> |
| <header role="banner"> |
| <nav role="navigation"> |
| <div class="fixedNav"> |
| <!-- ========= START OF TOP NAVBAR ======= --> |
| <div class="topNav"><a id="navbar.top"> |
| <!-- --> |
| </a> |
| <div class="skipNav"><a href="#skip.navbar.top" title="Skip navigation links">Skip navigation links</a></div> |
| <a id="navbar.top.firstrow"> |
| <!-- --> |
| </a> |
| <ul class="navList" title="Navigation"> |
| <li><a href="../../../../../index.html">Overview</a></li> |
| <li><a href="package-summary.html">Package</a></li> |
| <li class="navBarCell1Rev">Class</li> |
| <li><a href="class-use/RangeSet.html">Use</a></li> |
| <li><a href="package-tree.html">Tree</a></li> |
| <li><a href="../../../../../deprecated-list.html">Deprecated</a></li> |
| <li><a href="../../../../../index-all.html">Index</a></li> |
| <li><a href="../../../../../help-doc.html">Help</a></li> |
| </ul> |
| </div> |
| <div class="subNav"> |
| <ul class="navList" id="allclasses_navbar_top"> |
| <li><a href="../../../../../allclasses.html">All Classes</a></li> |
| </ul> |
| <ul class="navListSearch"> |
| <li><label for="search">SEARCH:</label> |
| <input type="text" id="search" value="search" disabled="disabled"> |
| <input type="reset" id="reset" value="reset" disabled="disabled"> |
| </li> |
| </ul> |
| <div> |
| <script type="text/javascript"><!-- |
| allClassesLink = document.getElementById("allclasses_navbar_top"); |
| if(window==top) { |
| allClassesLink.style.display = "block"; |
| } |
| else { |
| allClassesLink.style.display = "none"; |
| } |
| //--> |
| </script> |
| <noscript> |
| <div>JavaScript is disabled on your browser.</div> |
| </noscript> |
| </div> |
| <div> |
| <ul class="subNavList"> |
| <li>Summary: </li> |
| <li>Nested | </li> |
| <li><a href="#field.summary">Field</a> | </li> |
| <li><a href="#constructor.summary">Constr</a> | </li> |
| <li><a href="#method.summary">Method</a></li> |
| </ul> |
| <ul class="subNavList"> |
| <li>Detail: </li> |
| <li><a href="#field.detail">Field</a> | </li> |
| <li><a href="#constructor.detail">Constr</a> | </li> |
| <li><a href="#method.detail">Method</a></li> |
| </ul> |
| </div> |
| <a id="skip.navbar.top"> |
| <!-- --> |
| </a></div> |
| <!-- ========= END OF TOP NAVBAR ========= --> |
| </div> |
| <div class="navPadding"> </div> |
| <script type="text/javascript"><!-- |
| $('.navPadding').css('padding-top', $('.fixedNav').css("height")); |
| //--> |
| </script> |
| </nav> |
| </header> |
| <!-- ======== START OF CLASS DATA ======== --> |
| <main role="main"> |
| <div class="header"> |
| <div class="subTitle"><span class="packageLabelInType">Package</span> <a href="package-summary.html">org.apache.sis.util.collection</a></div> |
| <h2 title="Class RangeSet" class="title">Class RangeSet<E extends <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Comparable.html?is-external=true" title="class or interface in java.lang" class="externalLink">Comparable</a><? super E>></h2> |
| </div> |
| <div class="contentContainer"> |
| <ul class="inheritance"> |
| <li><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang" class="externalLink">Object</a></li> |
| <li> |
| <ul class="inheritance"> |
| <li><a href="https://docs.oracle.com/javase/8/docs/api/java/util/AbstractCollection.html?is-external=true" title="class or interface in java.util" class="externalLink">AbstractCollection</a><E></li> |
| <li> |
| <ul class="inheritance"> |
| <li><a href="https://docs.oracle.com/javase/8/docs/api/java/util/AbstractSet.html?is-external=true" title="class or interface in java.util" class="externalLink">AbstractSet</a><<a href="../../measure/Range.html" title="class in org.apache.sis.measure">Range</a><E>></li> |
| <li> |
| <ul class="inheritance"> |
| <li>RangeSet<E></li> |
| </ul> |
| </li> |
| </ul> |
| </li> |
| </ul> |
| </li> |
| </ul> |
| <div class="description"> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <dl> |
| <dt><span class="paramLabel">Type Parameters:</span></dt> |
| <dd><code>E</code> - the type of range elements.</dd> |
| </dl> |
| <dl> |
| <dt>All Implemented Interfaces:</dt> |
| <dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/io/Serializable.html?is-external=true" title="class or interface in java.io" class="externalLink">Serializable</a></code>, <code><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Cloneable.html?is-external=true" title="class or interface in java.lang" class="externalLink">Cloneable</a></code>, <code><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Iterable.html?is-external=true" title="class or interface in java.lang" class="externalLink">Iterable</a><<a href="../../measure/Range.html" title="class in org.apache.sis.measure">Range</a><E>></code>, <code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/Collection.html?is-external=true" title="class or interface in java.util" class="externalLink">Collection</a><<a href="../../measure/Range.html" title="class in org.apache.sis.measure">Range</a><E>></code>, <code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/Set.html?is-external=true" title="class or interface in java.util" class="externalLink">Set</a><<a href="../../measure/Range.html" title="class in org.apache.sis.measure">Range</a><E>></code>, <code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/SortedSet.html?is-external=true" title="class or interface in java.util" class="externalLink">SortedSet</a><<a href="../../measure/Range.html" title="class in org.apache.sis.measure">Range</a><E>></code>, <code><a href="CheckedContainer.html" title="interface in org.apache.sis.util.collection">CheckedContainer</a><<a href="../../measure/Range.html" title="class in org.apache.sis.measure">Range</a><E>></code></dd> |
| </dl> |
| <hr> |
| <pre>public class <span class="typeNameLabel">RangeSet<E extends <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Comparable.html?is-external=true" title="class or interface in java.lang" class="externalLink">Comparable</a><? super E>></span> |
| extends <a href="https://docs.oracle.com/javase/8/docs/api/java/util/AbstractSet.html?is-external=true" title="class or interface in java.util" class="externalLink">AbstractSet</a><<a href="../../measure/Range.html" title="class in org.apache.sis.measure">Range</a><E>> |
| implements <a href="CheckedContainer.html" title="interface in org.apache.sis.util.collection">CheckedContainer</a><<a href="../../measure/Range.html" title="class in org.apache.sis.measure">Range</a><E>>, <a href="https://docs.oracle.com/javase/8/docs/api/java/util/SortedSet.html?is-external=true" title="class or interface in java.util" class="externalLink">SortedSet</a><<a href="../../measure/Range.html" title="class in org.apache.sis.measure">Range</a><E>>, <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Cloneable.html?is-external=true" title="class or interface in java.lang" class="externalLink">Cloneable</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/io/Serializable.html?is-external=true" title="class or interface in java.io" class="externalLink">Serializable</a></pre> |
| <div class="block">An ordered set of disjoint ranges where overlapping ranges are merged. |
| All <code>add</code> and <code>remove</code> operations defined in this class interact with the existing |
| ranges, merging or splitting previously added ranges in order to ensure that every ranges in a |
| <code>RangeSet</code> are always disjoint. More specifically: |
| |
| <ul> |
| <li>When a range is <a href="#add(org.apache.sis.measure.Range)">added</a>, <code>RangeSet</code> first looks for existing |
| ranges overlapping the specified range. If overlapping ranges are found, then those ranges |
| are merged as of <a href="../../measure/Range.html#union(org.apache.sis.measure.Range)"><code>Range.union(Range)</code></a>. Consequently, adding ranges may in some |
| circumstances <strong>reduce</strong> the <a href="#size()">size</a> of this set.</li> |
| <li>Conversely, when a range is <a href="#remove(java.lang.Object)">removed</a>, <code>RangeSet</code> first |
| looks if that range is in the middle of an existing range. If such range is found, then |
| the enclosing range is splitted as of <a href="../../measure/Range.html#subtract(org.apache.sis.measure.Range)"><code>Range.subtract(Range)</code></a>. Consequently, removing |
| ranges may in some circumstances <strong>increase</strong> the size of this set.</li> |
| </ul> |
| |
| <div class="section">Inclusive or exclusive endpoints</div> |
| <code>RangeSet</code> requires that <a href="../../measure/Range.html#isMinIncluded()"><code>Range.isMinIncluded()</code></a> and <a href="../../measure/Range.html#isMaxIncluded()"><code>Range.isMaxIncluded()</code></a> |
| return the same values for all instances added to this set. Those values need to be specified |
| at construction time. If a user needs to store mixed kind of ranges, then he needs to subclass |
| this <code>RangeSet</code> class and override the <a href="#add(org.apache.sis.measure.Range)"><code>add(Range)</code></a>, <a href="#remove(java.lang.Object)"><code>remove(Object)</code></a> and |
| <a href="#newRange(E,E)"><code>newRange(Comparable, Comparable)</code></a> methods. |
| |
| <div class="note"><b>Note:</b> |
| Current implementation does not yet support open intervals. The ranges shall be either closed intervals, |
| or half-open. This limitation exists because supporting open intervals implies that the internal array |
| shall support duplicated values.</div> |
| |
| <div class="section">Extensions to <code>SortedSet</code> API</div> |
| This class contains some methods not found in standard <a href="https://docs.oracle.com/javase/8/docs/api/java/util/SortedSet.html?is-external=true" title="class or interface in java.util" class="externalLink"><code>SortedSet</code></a> API. |
| Some of those methods look like <a href="https://docs.oracle.com/javase/8/docs/api/java/util/List.html?is-external=true" title="class or interface in java.util" class="externalLink"><code>List</code></a> API, in that they work |
| with the index of a <code>Range</code> instance in the sequence of ranges returned |
| by the iterator. |
| |
| <ul> |
| <li><a href="#indexOfRange(E)"><code>indexOfRange(Comparable)</code></a> returns the index of the range containing |
| the given value (if any).</li> |
| <li><a href="#getMinDouble(int)"><code>getMinDouble(int)</code></a> and <a href="#getMaxDouble(int)"><code>getMaxDouble(int)</code></a> return the endpoint values |
| in the range at the given index as a <code>double</code> without the cost of creating a |
| <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Number.html?is-external=true" title="class or interface in java.lang" class="externalLink"><code>Number</code></a> instance.</li> |
| <li><a href="#getMinLong(int)"><code>getMinLong(int)</code></a> and <a href="#getMaxLong(int)"><code>getMaxLong(int)</code></a> are equivalent to the above |
| methods for the <code>long</code> primitive type, used mostly for <a href="https://docs.oracle.com/javase/8/docs/api/java/util/Date.html?is-external=true" title="class or interface in java.util" class="externalLink"><code>Date</code></a> |
| values (see implementation note below).</li> |
| <li><a href="#intersect(org.apache.sis.measure.Range)"><code>intersect(Range)</code></a> provides a more convenient way than <code>subSet(…)</code>, |
| <code>headSet(…)</code> and <code>tailSet(…)</code> for creating views over subsets of a |
| <code>RangeSet</code>.</li> |
| <li><a href="#trimToSize()"><code>trimToSize()</code></a> frees unused space.</li> |
| </ul> |
| |
| <div class="section">Implementation note</div> |
| For efficiency reasons, this set stores the range values in a Java array of primitive type if |
| possible. The <code>Range</code> instances given in argument to the <a href="#add(org.apache.sis.measure.Range)"><code>add(Range)</code></a> method are |
| not retained by this class. Ranges are recreated during iterations by calls to the |
| <a href="#newRange(E,E)"><code>newRange(Comparable, Comparable)</code></a> method. Subclasses can override that method if they |
| need to customize the range objects to be created. |
| |
| <p>While it is possible to create <code>RangeSet<Date></code> instances, it is more efficient to |
| use <code>RangeSet<Long></code> with millisecond values because <code>RangeSet</code> will internally |
| use <code>long[]</code> arrays in the later case.</p></div> |
| <dl> |
| <dt><span class="simpleTagLabel">Since:</span></dt> |
| <dd>0.3</dd> |
| <dt><span class="seeLabel">See Also:</span></dt> |
| <dd><a href="../../measure/Range.html" title="class in org.apache.sis.measure"><code>Range</code></a>, |
| <a href="../../../../../serialized-form.html#org.apache.sis.util.collection.RangeSet">Serialized Form</a></dd> |
| |
| <p><font size="-1">Defined in the <code>sis-utility</code> module</font></p> |
| </dl> |
| </li> |
| </ul> |
| </div> |
| <div class="summary"> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <!-- =========== FIELD SUMMARY =========== --> |
| <section role="region"> |
| <ul class="blockList"> |
| <li class="blockList"><a id="field.summary"> |
| <!-- --> |
| </a> |
| <h3>Field Summary</h3> |
| <table class="memberSummary"> |
| <caption><span>Fields</span><span class="tabEnd"> </span></caption> |
| <tr> |
| <th class="colFirst" scope="col">Modifier and Type</th> |
| <th class="colSecond" scope="col">Field</th> |
| <th class="colLast" scope="col">Description</th> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><code>protected <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Class.html?is-external=true" title="class or interface in java.lang" class="externalLink">Class</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a>></code></td> |
| <th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#elementType">elementType</a></span></code></th> |
| <td class="colLast"> |
| <div class="block">The type of elements in the ranges.</div> |
| </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><code>protected boolean</code></td> |
| <th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#isMaxIncluded">isMaxIncluded</a></span></code></th> |
| <td class="colLast"> |
| <div class="block"><code>true</code> if the maximal values of ranges in this set are inclusive, or <code>false</code> |
| if exclusive.</div> |
| </td> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><code>protected boolean</code></td> |
| <th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#isMinIncluded">isMinIncluded</a></span></code></th> |
| <td class="colLast"> |
| <div class="block"><code>true</code> if the minimal values of ranges in this set are inclusive, or <code>false</code> |
| if exclusive.</div> |
| </td> |
| </tr> |
| </table> |
| </li> |
| </ul> |
| </section> |
| <!-- ======== CONSTRUCTOR SUMMARY ======== --> |
| <section role="region"> |
| <ul class="blockList"> |
| <li class="blockList"><a id="constructor.summary"> |
| <!-- --> |
| </a> |
| <h3>Constructor Summary</h3> |
| <table class="memberSummary"> |
| <caption><span>Constructors</span><span class="tabEnd"> </span></caption> |
| <tr> |
| <th class="colFirst" scope="col">Modifier</th> |
| <th class="colSecond" scope="col">Constructor</th> |
| <th class="colLast" scope="col">Description</th> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><code>protected </code></td> |
| <th class="colConstructorName" scope="row"><code><span class="memberNameLink"><a href="#%3Cinit%3E(java.lang.Class,boolean,boolean)">RangeSet</a></span>​(<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Class.html?is-external=true" title="class or interface in java.lang" class="externalLink">Class</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a>> elementType, |
| boolean isMinIncluded, |
| boolean isMaxIncluded)</code></th> |
| <td class="colLast"> |
| <div class="block">Constructs an initially empty set of ranges.</div> |
| </td> |
| </tr> |
| </table> |
| </li> |
| </ul> |
| </section> |
| <!-- ========== METHOD SUMMARY =========== --> |
| <section role="region"> |
| <ul class="blockList"> |
| <li class="blockList"><a id="method.summary"> |
| <!-- --> |
| </a> |
| <h3>Method Summary</h3> |
| <table class="memberSummary"> |
| <caption><span id="t0" class="activeTableTab"><span>All Methods</span><span class="tabEnd"> </span></span><span id="t1" class="tableTab"><span><a href="javascript:show(1);">Static Methods</a></span><span class="tabEnd"> </span></span><span id="t2" class="tableTab"><span><a href="javascript:show(2);">Instance Methods</a></span><span class="tabEnd"> </span></span><span id="t4" class="tableTab"><span><a href="javascript:show(8);">Concrete Methods</a></span><span class="tabEnd"> </span></span></caption> |
| <tr> |
| <th class="colFirst" scope="col">Modifier and Type</th> |
| <th class="colSecond" scope="col">Method</th> |
| <th class="colLast" scope="col">Description</th> |
| </tr> |
| <tr id="i0" class="altColor"> |
| <td class="colFirst"><code>boolean</code></td> |
| <th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#add(E,E)">add</a></span>​(<a href="RangeSet.html" title="type parameter in RangeSet">E</a> minValue, |
| <a href="RangeSet.html" title="type parameter in RangeSet">E</a> maxValue)</code></th> |
| <td class="colLast"> |
| <div class="block">Adds a range of values to this set.</div> |
| </td> |
| </tr> |
| <tr id="i1" class="rowColor"> |
| <td class="colFirst"><code>boolean</code></td> |
| <th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#add(org.apache.sis.measure.Range)">add</a></span>​(<a href="../../measure/Range.html" title="class in org.apache.sis.measure">Range</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a>> range)</code></th> |
| <td class="colLast"> |
| <div class="block">Adds a range to this set.</div> |
| </td> |
| </tr> |
| <tr id="i2" class="altColor"> |
| <td class="colFirst"><code>void</code></td> |
| <th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#clear()">clear</a></span>()</code></th> |
| <td class="colLast"> |
| <div class="block">Removes all elements from this set of ranges.</div> |
| </td> |
| </tr> |
| <tr id="i3" class="rowColor"> |
| <td class="colFirst"><code><a href="RangeSet.html" title="class in org.apache.sis.util.collection">RangeSet</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a>></code></td> |
| <th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#clone()">clone</a></span>()</code></th> |
| <td class="colLast"> |
| <div class="block">Returns a clone of this range set.</div> |
| </td> |
| </tr> |
| <tr id="i4" class="altColor"> |
| <td class="colFirst"><code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/Comparator.html?is-external=true" title="class or interface in java.util" class="externalLink">Comparator</a><<a href="../../measure/Range.html" title="class in org.apache.sis.measure">Range</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a>>></code></td> |
| <th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#comparator()">comparator</a></span>()</code></th> |
| <td class="colLast"> |
| <div class="block">Returns the comparator associated with this sorted set.</div> |
| </td> |
| </tr> |
| <tr id="i5" class="rowColor"> |
| <td class="colFirst"><code>boolean</code></td> |
| <th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#contains(java.lang.Object)">contains</a></span>​(<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang" class="externalLink">Object</a> object)</code></th> |
| <td class="colLast"> |
| <div class="block">Returns <code>true</code> if the given object is an instance of <a href="../../measure/Range.html" title="class in org.apache.sis.measure"><code>Range</code></a> compatible |
| with this set and contained inside one of the range elements of this set.</div> |
| </td> |
| </tr> |
| <tr id="i6" class="altColor"> |
| <td class="colFirst"><code>boolean</code></td> |
| <th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#contains(org.apache.sis.measure.Range,boolean)">contains</a></span>​(<a href="../../measure/Range.html" title="class in org.apache.sis.measure">Range</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a>> range, |
| boolean exact)</code></th> |
| <td class="colLast"> |
| <div class="block">Returns <code>true</code> if this set contains the specified element.</div> |
| </td> |
| </tr> |
| <tr id="i7" class="rowColor"> |
| <td class="colFirst"><code>static <E extends <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Comparable.html?is-external=true" title="class or interface in java.lang" class="externalLink">Comparable</a><? super E>><br><a href="RangeSet.html" title="class in org.apache.sis.util.collection">RangeSet</a><E></code></td> |
| <th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#create(java.lang.Class,boolean,boolean)">create</a></span>​(<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Class.html?is-external=true" title="class or interface in java.lang" class="externalLink">Class</a><E> elementType, |
| boolean isMinIncluded, |
| boolean isMaxIncluded)</code></th> |
| <td class="colLast"> |
| <div class="block">Constructs an initially empty set of ranges.</div> |
| </td> |
| </tr> |
| <tr id="i8" class="altColor"> |
| <td class="colFirst"><code>boolean</code></td> |
| <th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#equals(java.lang.Object)">equals</a></span>​(<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang" class="externalLink">Object</a> object)</code></th> |
| <td class="colLast"> |
| <div class="block">Compares the specified object with this set of ranges for equality.</div> |
| </td> |
| </tr> |
| <tr id="i9" class="rowColor"> |
| <td class="colFirst"><code><a href="../../measure/Range.html" title="class in org.apache.sis.measure">Range</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a>></code></td> |
| <th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#first()">first</a></span>()</code></th> |
| <td class="colLast"> |
| <div class="block">Returns the first (lowest) range currently in this sorted set.</div> |
| </td> |
| </tr> |
| <tr id="i10" class="altColor"> |
| <td class="colFirst"><code><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Class.html?is-external=true" title="class or interface in java.lang" class="externalLink">Class</a><<a href="../../measure/Range.html" title="class in org.apache.sis.measure">Range</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a>>></code></td> |
| <th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#getElementType()">getElementType</a></span>()</code></th> |
| <td class="colLast"> |
| <div class="block">Returns the type of elements in this <em>collection</em>, which is always <code>Range</code>.</div> |
| </td> |
| </tr> |
| <tr id="i11" class="rowColor"> |
| <td class="colFirst"><code>double</code></td> |
| <th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#getMaxDouble(int)">getMaxDouble</a></span>​(int index)</code></th> |
| <td class="colLast"> |
| <div class="block">Returns a <a href="../../measure/Range.html#getMaxValue()">range maximum value</a> as a <code>double</code>.</div> |
| </td> |
| </tr> |
| <tr id="i12" class="altColor"> |
| <td class="colFirst"><code>long</code></td> |
| <th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#getMaxLong(int)">getMaxLong</a></span>​(int index)</code></th> |
| <td class="colLast"> |
| <div class="block">Returns a <a href="../../measure/Range.html#getMaxValue()">range maximum value</a> as a <code>long</code>.</div> |
| </td> |
| </tr> |
| <tr id="i13" class="rowColor"> |
| <td class="colFirst"><code>double</code></td> |
| <th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#getMinDouble(int)">getMinDouble</a></span>​(int index)</code></th> |
| <td class="colLast"> |
| <div class="block">Returns a <a href="../../measure/Range.html#getMinValue()">range minimum value</a> as a <code>double</code>.</div> |
| </td> |
| </tr> |
| <tr id="i14" class="altColor"> |
| <td class="colFirst"><code>long</code></td> |
| <th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#getMinLong(int)">getMinLong</a></span>​(int index)</code></th> |
| <td class="colLast"> |
| <div class="block">Returns a <a href="../../measure/Range.html#getMinValue()">range minimum value</a> as a <code>long</code>.</div> |
| </td> |
| </tr> |
| <tr id="i15" class="rowColor"> |
| <td class="colFirst"><code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/SortedSet.html?is-external=true" title="class or interface in java.util" class="externalLink">SortedSet</a><<a href="../../measure/Range.html" title="class in org.apache.sis.measure">Range</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a>>></code></td> |
| <th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#headSet(org.apache.sis.measure.Range)">headSet</a></span>​(<a href="../../measure/Range.html" title="class in org.apache.sis.measure">Range</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a>> upper)</code></th> |
| <td class="colLast"> |
| <div class="block">Returns a view of the portion of this sorted set whose elements are |
| strictly less than <code>upper</code>.</div> |
| </td> |
| </tr> |
| <tr id="i16" class="altColor"> |
| <td class="colFirst"><code>int</code></td> |
| <th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#indexOfRange(E)">indexOfRange</a></span>​(<a href="RangeSet.html" title="type parameter in RangeSet">E</a> value)</code></th> |
| <td class="colLast"> |
| <div class="block">If the specified value is inside a range, returns the index of this range.</div> |
| </td> |
| </tr> |
| <tr id="i17" class="rowColor"> |
| <td class="colFirst"><code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/SortedSet.html?is-external=true" title="class or interface in java.util" class="externalLink">SortedSet</a><<a href="../../measure/Range.html" title="class in org.apache.sis.measure">Range</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a>>></code></td> |
| <th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#intersect(org.apache.sis.measure.Range)">intersect</a></span>​(<a href="../../measure/Range.html" title="class in org.apache.sis.measure">Range</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a>> subRange)</code></th> |
| <td class="colLast"> |
| <div class="block">Returns a view of the portion of this range set which is the intersection of |
| this <code>RangeSet</code> with the given range.</div> |
| </td> |
| </tr> |
| <tr id="i18" class="altColor"> |
| <td class="colFirst"><code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/Iterator.html?is-external=true" title="class or interface in java.util" class="externalLink">Iterator</a><<a href="../../measure/Range.html" title="class in org.apache.sis.measure">Range</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a>>></code></td> |
| <th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#iterator()">iterator</a></span>()</code></th> |
| <td class="colLast"> |
| <div class="block">Returns an iterator over the elements in this set of ranges.</div> |
| </td> |
| </tr> |
| <tr id="i19" class="rowColor"> |
| <td class="colFirst"><code><a href="../../measure/Range.html" title="class in org.apache.sis.measure">Range</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a>></code></td> |
| <th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#last()">last</a></span>()</code></th> |
| <td class="colLast"> |
| <div class="block">Returns the last (highest) range currently in this sorted set.</div> |
| </td> |
| </tr> |
| <tr id="i20" class="altColor"> |
| <td class="colFirst"><code>protected <a href="../../measure/Range.html" title="class in org.apache.sis.measure">Range</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a>></code></td> |
| <th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#newRange(E,E)">newRange</a></span>​(<a href="RangeSet.html" title="type parameter in RangeSet">E</a> lower, |
| <a href="RangeSet.html" title="type parameter in RangeSet">E</a> upper)</code></th> |
| <td class="colLast"> |
| <div class="block">Returns a new <a href="../../measure/Range.html" title="class in org.apache.sis.measure"><code>Range</code></a> object initialized with the given values.</div> |
| </td> |
| </tr> |
| <tr id="i21" class="rowColor"> |
| <td class="colFirst"><code>boolean</code></td> |
| <th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#remove(E,E)">remove</a></span>​(<a href="RangeSet.html" title="type parameter in RangeSet">E</a> minValue, |
| <a href="RangeSet.html" title="type parameter in RangeSet">E</a> maxValue)</code></th> |
| <td class="colLast"> |
| <div class="block">Removes a range of values to this set.</div> |
| </td> |
| </tr> |
| <tr id="i22" class="altColor"> |
| <td class="colFirst"><code>boolean</code></td> |
| <th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#remove(java.lang.Object)">remove</a></span>​(<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang" class="externalLink">Object</a> object)</code></th> |
| <td class="colLast"> |
| <div class="block">Removes a range from this set.</div> |
| </td> |
| </tr> |
| <tr id="i23" class="rowColor"> |
| <td class="colFirst"><code>int</code></td> |
| <th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#size()">size</a></span>()</code></th> |
| <td class="colLast"> |
| <div class="block">Returns the number of ranges in this set.</div> |
| </td> |
| </tr> |
| <tr id="i24" class="altColor"> |
| <td class="colFirst"><code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/SortedSet.html?is-external=true" title="class or interface in java.util" class="externalLink">SortedSet</a><<a href="../../measure/Range.html" title="class in org.apache.sis.measure">Range</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a>>></code></td> |
| <th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#subSet(org.apache.sis.measure.Range,org.apache.sis.measure.Range)">subSet</a></span>​(<a href="../../measure/Range.html" title="class in org.apache.sis.measure">Range</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a>> lower, |
| <a href="../../measure/Range.html" title="class in org.apache.sis.measure">Range</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a>> upper)</code></th> |
| <td class="colLast"> |
| <div class="block">Returns a view of the portion of this sorted set whose elements range |
| from <code>lower</code>, inclusive, to <code>upper</code>, exclusive.</div> |
| </td> |
| </tr> |
| <tr id="i25" class="rowColor"> |
| <td class="colFirst"><code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/SortedSet.html?is-external=true" title="class or interface in java.util" class="externalLink">SortedSet</a><<a href="../../measure/Range.html" title="class in org.apache.sis.measure">Range</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a>>></code></td> |
| <th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#tailSet(org.apache.sis.measure.Range)">tailSet</a></span>​(<a href="../../measure/Range.html" title="class in org.apache.sis.measure">Range</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a>> lower)</code></th> |
| <td class="colLast"> |
| <div class="block">Returns a view of the portion of this sorted set whose elements are |
| greater than or equal to <code>lower</code>.</div> |
| </td> |
| </tr> |
| <tr id="i26" class="altColor"> |
| <td class="colFirst"><code>void</code></td> |
| <th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#trimToSize()">trimToSize</a></span>()</code></th> |
| <td class="colLast"> |
| <div class="block">Trims this set to the minimal amount of memory required for holding its data.</div> |
| </td> |
| </tr> |
| </table> |
| <ul class="blockList"> |
| <li class="blockList"><a id="methods.inherited.from.class.AbstractSet"> |
| <!-- --> |
| </a> |
| <h3>Methods inherited from class <a href="https://docs.oracle.com/javase/8/docs/api/java/util/AbstractSet.html?is-external=true" title="class or interface in java.util" class="externalLink">AbstractSet</a></h3> |
| <code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/AbstractSet.html?is-external=true#hashCode()" title="class or interface in java.util" class="externalLink">hashCode</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/util/AbstractSet.html?is-external=true#removeAll(java.util.Collection)" title="class or interface in java.util" class="externalLink">removeAll</a></code></li> |
| </ul> |
| <ul class="blockList"> |
| <li class="blockList"><a id="methods.inherited.from.class.AbstractCollection"> |
| <!-- --> |
| </a> |
| <h3>Methods inherited from class <a href="https://docs.oracle.com/javase/8/docs/api/java/util/AbstractCollection.html?is-external=true" title="class or interface in java.util" class="externalLink">AbstractCollection</a></h3> |
| <code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/AbstractCollection.html?is-external=true#addAll(java.util.Collection)" title="class or interface in java.util" class="externalLink">addAll</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/util/AbstractCollection.html?is-external=true#containsAll(java.util.Collection)" title="class or interface in java.util" class="externalLink">containsAll</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/util/AbstractCollection.html?is-external=true#isEmpty()" title="class or interface in java.util" class="externalLink">isEmpty</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/util/AbstractCollection.html?is-external=true#retainAll(java.util.Collection)" title="class or interface in java.util" class="externalLink">retainAll</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/util/AbstractCollection.html?is-external=true#toArray()" title="class or interface in java.util" class="externalLink">toArray</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/util/AbstractCollection.html?is-external=true#toArray(T%5B%5D)" title="class or interface in java.util" class="externalLink">toArray</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/util/AbstractCollection.html?is-external=true#toString()" title="class or interface in java.util" class="externalLink">toString</a></code></li> |
| </ul> |
| <ul class="blockList"> |
| <li class="blockList"><a id="methods.inherited.from.class.Object"> |
| <!-- --> |
| </a> |
| <h3>Methods inherited from class <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang" class="externalLink">Object</a></h3> |
| <code><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true#finalize()" title="class or interface in java.lang" class="externalLink">finalize</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true#getClass()" title="class or interface in java.lang" class="externalLink">getClass</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true#notify()" title="class or interface in java.lang" class="externalLink">notify</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true#notifyAll()" title="class or interface in java.lang" class="externalLink">notifyAll</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true#wait()" title="class or interface in java.lang" class="externalLink">wait</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true#wait(long)" title="class or interface in java.lang" class="externalLink">wait</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true#wait(long,int)" title="class or interface in java.lang" class="externalLink">wait</a></code></li> |
| </ul> |
| <ul class="blockList"> |
| <li class="blockList"><a id="methods.inherited.from.class.Collection"> |
| <!-- --> |
| </a> |
| <h3>Methods inherited from interface <a href="https://docs.oracle.com/javase/8/docs/api/java/util/Collection.html?is-external=true" title="class or interface in java.util" class="externalLink">Collection</a></h3> |
| <code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/Collection.html?is-external=true#parallelStream()" title="class or interface in java.util" class="externalLink">parallelStream</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/util/Collection.html?is-external=true#removeIf(java.util.function.Predicate)" title="class or interface in java.util" class="externalLink">removeIf</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/util/Collection.html?is-external=true#stream()" title="class or interface in java.util" class="externalLink">stream</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/util/Collection.html?is-external=true#toArray(java.util.function.IntFunction)" title="class or interface in java.util" class="externalLink">toArray</a></code></li> |
| </ul> |
| <ul class="blockList"> |
| <li class="blockList"><a id="methods.inherited.from.class.Iterable"> |
| <!-- --> |
| </a> |
| <h3>Methods inherited from interface <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Iterable.html?is-external=true" title="class or interface in java.lang" class="externalLink">Iterable</a></h3> |
| <code><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Iterable.html?is-external=true#forEach(java.util.function.Consumer)" title="class or interface in java.lang" class="externalLink">forEach</a></code></li> |
| </ul> |
| <ul class="blockList"> |
| <li class="blockList"><a id="methods.inherited.from.class.Set"> |
| <!-- --> |
| </a> |
| <h3>Methods inherited from interface <a href="https://docs.oracle.com/javase/8/docs/api/java/util/Set.html?is-external=true" title="class or interface in java.util" class="externalLink">Set</a></h3> |
| <code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/Set.html?is-external=true#addAll(java.util.Collection)" title="class or interface in java.util" class="externalLink">addAll</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/util/Set.html?is-external=true#containsAll(java.util.Collection)" title="class or interface in java.util" class="externalLink">containsAll</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/util/Set.html?is-external=true#hashCode()" title="class or interface in java.util" class="externalLink">hashCode</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/util/Set.html?is-external=true#isEmpty()" title="class or interface in java.util" class="externalLink">isEmpty</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/util/Set.html?is-external=true#removeAll(java.util.Collection)" title="class or interface in java.util" class="externalLink">removeAll</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/util/Set.html?is-external=true#retainAll(java.util.Collection)" title="class or interface in java.util" class="externalLink">retainAll</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/util/Set.html?is-external=true#toArray()" title="class or interface in java.util" class="externalLink">toArray</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/util/Set.html?is-external=true#toArray(T%5B%5D)" title="class or interface in java.util" class="externalLink">toArray</a></code></li> |
| </ul> |
| <ul class="blockList"> |
| <li class="blockList"><a id="methods.inherited.from.class.SortedSet"> |
| <!-- --> |
| </a> |
| <h3>Methods inherited from interface <a href="https://docs.oracle.com/javase/8/docs/api/java/util/SortedSet.html?is-external=true" title="class or interface in java.util" class="externalLink">SortedSet</a></h3> |
| <code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/SortedSet.html?is-external=true#spliterator()" title="class or interface in java.util" class="externalLink">spliterator</a></code></li> |
| </ul> |
| </li> |
| </ul> |
| </section> |
| </li> |
| </ul> |
| </div> |
| <div class="details"> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <!-- ============ FIELD DETAIL =========== --> |
| <section role="region"> |
| <ul class="blockList"> |
| <li class="blockList"><a id="field.detail"> |
| <!-- --> |
| </a> |
| <h3>Field Detail</h3> |
| <a id="elementType"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>elementType</h4> |
| <pre>protected final <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Class.html?is-external=true" title="class or interface in java.lang" class="externalLink">Class</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a> extends <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Comparable.html?is-external=true" title="class or interface in java.lang" class="externalLink">Comparable</a><? super <a href="RangeSet.html" title="type parameter in RangeSet">E</a>>> elementType</pre> |
| <div class="block">The type of elements in the ranges. If the element are numbers, |
| then the value is the wrapper type (not the primitive type).</div> |
| <dl> |
| <dt><span class="seeLabel">See Also:</span></dt> |
| <dd><a href="../../measure/Range.html#getElementType()"><code>Range.getElementType()</code></a></dd> |
| </dl> |
| </li> |
| </ul> |
| <a id="isMinIncluded"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>isMinIncluded</h4> |
| <pre>protected final boolean isMinIncluded</pre> |
| <div class="block"><code>true</code> if the minimal values of ranges in this set are inclusive, or <code>false</code> |
| if exclusive. This value is specified at construction time and enforced when ranges are |
| added or removed.</div> |
| <dl> |
| <dt><span class="seeLabel">See Also:</span></dt> |
| <dd><a href="../../measure/Range.html#isMinIncluded()"><code>Range.isMinIncluded()</code></a></dd> |
| </dl> |
| </li> |
| </ul> |
| <a id="isMaxIncluded"> |
| <!-- --> |
| </a> |
| <ul class="blockListLast"> |
| <li class="blockList"> |
| <h4>isMaxIncluded</h4> |
| <pre>protected final boolean isMaxIncluded</pre> |
| <div class="block"><code>true</code> if the maximal values of ranges in this set are inclusive, or <code>false</code> |
| if exclusive. This value is specified at construction time and enforced when ranges are |
| added or removed.</div> |
| <dl> |
| <dt><span class="seeLabel">See Also:</span></dt> |
| <dd><a href="../../measure/Range.html#isMaxIncluded()"><code>Range.isMaxIncluded()</code></a></dd> |
| </dl> |
| </li> |
| </ul> |
| </li> |
| </ul> |
| </section> |
| <!-- ========= CONSTRUCTOR DETAIL ======== --> |
| <section role="region"> |
| <ul class="blockList"> |
| <li class="blockList"><a id="constructor.detail"> |
| <!-- --> |
| </a> |
| <h3>Constructor Detail</h3> |
| <a id="<init>(java.lang.Class,boolean,boolean)"> |
| <!-- --> |
| </a> |
| <ul class="blockListLast"> |
| <li class="blockList"> |
| <h4>RangeSet</h4> |
| <pre>protected RangeSet​(<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Class.html?is-external=true" title="class or interface in java.lang" class="externalLink">Class</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a>> elementType, |
| boolean isMinIncluded, |
| boolean isMaxIncluded)</pre> |
| <div class="block">Constructs an initially empty set of ranges. |
| This constructor is provided for sub-classing only. |
| Client code should use the static <a href="#create(java.lang.Class,boolean,boolean)"><code>create(Class, boolean, boolean)</code></a> method instead.</div> |
| <dl> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>elementType</code> - the type of the range elements.</dd> |
| <dd><code>isMinIncluded</code> - <code>true</code> if the minimal values are inclusive, or <code>false</code> if exclusive.</dd> |
| <dd><code>isMaxIncluded</code> - <code>true</code> if the maximal values are inclusive, or <code>false</code> if exclusive.</dd> |
| </dl> |
| </li> |
| </ul> |
| </li> |
| </ul> |
| </section> |
| <!-- ============ METHOD DETAIL ========== --> |
| <section role="region"> |
| <ul class="blockList"> |
| <li class="blockList"><a id="method.detail"> |
| <!-- --> |
| </a> |
| <h3>Method Detail</h3> |
| <a id="create(java.lang.Class,boolean,boolean)"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>create</h4> |
| <pre class="methodSignature">public static <E extends <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Comparable.html?is-external=true" title="class or interface in java.lang" class="externalLink">Comparable</a><? super E>> <a href="RangeSet.html" title="class in org.apache.sis.util.collection">RangeSet</a><E> create​(<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Class.html?is-external=true" title="class or interface in java.lang" class="externalLink">Class</a><E> elementType, |
| boolean isMinIncluded, |
| boolean isMaxIncluded)</pre> |
| <div class="block">Constructs an initially empty set of ranges.</div> |
| <dl> |
| <dt><span class="paramLabel">Type Parameters:</span></dt> |
| <dd><code>E</code> - the type of range elements.</dd> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>elementType</code> - the type of the range elements.</dd> |
| <dd><code>isMinIncluded</code> - <code>true</code> if the minimal values are inclusive, or <code>false</code> if exclusive.</dd> |
| <dd><code>isMaxIncluded</code> - <code>true</code> if the maximal values are inclusive, or <code>false</code> if exclusive.</dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>a new range set for range elements of the given type.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a id="getElementType()"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getElementType</h4> |
| <pre class="methodSignature">public final <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Class.html?is-external=true" title="class or interface in java.lang" class="externalLink">Class</a><<a href="../../measure/Range.html" title="class in org.apache.sis.measure">Range</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a>>> getElementType()</pre> |
| <div class="block">Returns the type of elements in this <em>collection</em>, which is always <code>Range</code>. |
| This is not the type of minimal and maximal values in range objects.</div> |
| <dl> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="CheckedContainer.html#getElementType()">getElementType</a></code> in interface <code><a href="CheckedContainer.html" title="interface in org.apache.sis.util.collection">CheckedContainer</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a> extends <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Comparable.html?is-external=true" title="class or interface in java.lang" class="externalLink">Comparable</a><? super <a href="RangeSet.html" title="type parameter in RangeSet">E</a>>></code></dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>the element type.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a id="comparator()"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>comparator</h4> |
| <pre class="methodSignature">public <a href="https://docs.oracle.com/javase/8/docs/api/java/util/Comparator.html?is-external=true" title="class or interface in java.util" class="externalLink">Comparator</a><<a href="../../measure/Range.html" title="class in org.apache.sis.measure">Range</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a>>> comparator()</pre> |
| <div class="block">Returns the comparator associated with this sorted set.</div> |
| <dl> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/SortedSet.html?is-external=true#comparator()" title="class or interface in java.util" class="externalLink">comparator</a></code> in interface <code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/SortedSet.html?is-external=true" title="class or interface in java.util" class="externalLink">SortedSet</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a> extends <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Comparable.html?is-external=true" title="class or interface in java.lang" class="externalLink">Comparable</a><? super <a href="RangeSet.html" title="type parameter in RangeSet">E</a>>></code></dd> |
| </dl> |
| </li> |
| </ul> |
| <a id="clear()"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>clear</h4> |
| <pre class="methodSignature">public void clear()</pre> |
| <div class="block">Removes all elements from this set of ranges.</div> |
| <dl> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/Collection.html?is-external=true#clear()" title="class or interface in java.util" class="externalLink">clear</a></code> in interface <code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/Collection.html?is-external=true" title="class or interface in java.util" class="externalLink">Collection</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a> extends <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Comparable.html?is-external=true" title="class or interface in java.lang" class="externalLink">Comparable</a><? super <a href="RangeSet.html" title="type parameter in RangeSet">E</a>>></code></dd> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/Set.html?is-external=true#clear()" title="class or interface in java.util" class="externalLink">clear</a></code> in interface <code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/Set.html?is-external=true" title="class or interface in java.util" class="externalLink">Set</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a> extends <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Comparable.html?is-external=true" title="class or interface in java.lang" class="externalLink">Comparable</a><? super <a href="RangeSet.html" title="type parameter in RangeSet">E</a>>></code></dd> |
| <dt><span class="overrideSpecifyLabel">Overrides:</span></dt> |
| <dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/AbstractCollection.html?is-external=true#clear()" title="class or interface in java.util" class="externalLink">clear</a></code> in class <code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/AbstractCollection.html?is-external=true" title="class or interface in java.util" class="externalLink">AbstractCollection</a><<a href="../../measure/Range.html" title="class in org.apache.sis.measure">Range</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a> extends <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Comparable.html?is-external=true" title="class or interface in java.lang" class="externalLink">Comparable</a><? super <a href="RangeSet.html" title="type parameter in RangeSet">E</a>>>></code></dd> |
| </dl> |
| </li> |
| </ul> |
| <a id="size()"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>size</h4> |
| <pre class="methodSignature">public int size()</pre> |
| <div class="block">Returns the number of ranges in this set.</div> |
| <dl> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/Collection.html?is-external=true#size()" title="class or interface in java.util" class="externalLink">size</a></code> in interface <code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/Collection.html?is-external=true" title="class or interface in java.util" class="externalLink">Collection</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a> extends <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Comparable.html?is-external=true" title="class or interface in java.lang" class="externalLink">Comparable</a><? super <a href="RangeSet.html" title="type parameter in RangeSet">E</a>>></code></dd> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/Set.html?is-external=true#size()" title="class or interface in java.util" class="externalLink">size</a></code> in interface <code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/Set.html?is-external=true" title="class or interface in java.util" class="externalLink">Set</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a> extends <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Comparable.html?is-external=true" title="class or interface in java.lang" class="externalLink">Comparable</a><? super <a href="RangeSet.html" title="type parameter in RangeSet">E</a>>></code></dd> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/AbstractCollection.html?is-external=true#size()" title="class or interface in java.util" class="externalLink">size</a></code> in class <code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/AbstractCollection.html?is-external=true" title="class or interface in java.util" class="externalLink">AbstractCollection</a><<a href="../../measure/Range.html" title="class in org.apache.sis.measure">Range</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a> extends <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Comparable.html?is-external=true" title="class or interface in java.lang" class="externalLink">Comparable</a><? super <a href="RangeSet.html" title="type parameter in RangeSet">E</a>>>></code></dd> |
| </dl> |
| </li> |
| </ul> |
| <a id="trimToSize()"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>trimToSize</h4> |
| <pre class="methodSignature">public final void trimToSize()</pre> |
| <div class="block">Trims this set to the minimal amount of memory required for holding its data. |
| This method may be invoked after all elements have been <a href="#add(org.apache.sis.measure.Range)">added</a> |
| in order to free unused memory.</div> |
| </li> |
| </ul> |
| <a id="add(org.apache.sis.measure.Range)"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>add</h4> |
| <pre class="methodSignature">public boolean add​(<a href="../../measure/Range.html" title="class in org.apache.sis.measure">Range</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a>> range) |
| throws <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/IllegalArgumentException.html?is-external=true" title="class or interface in java.lang" class="externalLink">IllegalArgumentException</a></pre> |
| <div class="block">Adds a range to this set. If the specified range overlaps existing ranges, |
| then the existing ranges will be merged as of <a href="../../measure/Range.html#union(org.apache.sis.measure.Range)"><code>Range.union(Range)</code></a>. |
| In other words, invoking this method may <strong>reduce</strong> the |
| <a href="#size()">size</a> of this set. |
| |
| <p>The default implementation does nothing if the given range <a href="../../measure/Range.html#isEmpty()">is |
| empty</a>. Otherwise this method ensures that the <code>isMinIncluded</code> and <code>isMaxIncluded</code> |
| match the ones given to the constructor of this <code>RangeSet</code>, then delegates to |
| <a href="#add(E,E)"><code>add(Comparable, Comparable)</code></a>.</p></div> |
| <dl> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/Collection.html?is-external=true#add(E)" title="class or interface in java.util" class="externalLink">add</a></code> in interface <code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/Collection.html?is-external=true" title="class or interface in java.util" class="externalLink">Collection</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a> extends <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Comparable.html?is-external=true" title="class or interface in java.lang" class="externalLink">Comparable</a><? super <a href="RangeSet.html" title="type parameter in RangeSet">E</a>>></code></dd> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/Set.html?is-external=true#add(E)" title="class or interface in java.util" class="externalLink">add</a></code> in interface <code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/Set.html?is-external=true" title="class or interface in java.util" class="externalLink">Set</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a> extends <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Comparable.html?is-external=true" title="class or interface in java.lang" class="externalLink">Comparable</a><? super <a href="RangeSet.html" title="type parameter in RangeSet">E</a>>></code></dd> |
| <dt><span class="overrideSpecifyLabel">Overrides:</span></dt> |
| <dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/AbstractCollection.html?is-external=true#add(E)" title="class or interface in java.util" class="externalLink">add</a></code> in class <code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/AbstractCollection.html?is-external=true" title="class or interface in java.util" class="externalLink">AbstractCollection</a><<a href="../../measure/Range.html" title="class in org.apache.sis.measure">Range</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a> extends <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Comparable.html?is-external=true" title="class or interface in java.lang" class="externalLink">Comparable</a><? super <a href="RangeSet.html" title="type parameter in RangeSet">E</a>>>></code></dd> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>range</code> - the range to add.</dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd><code>true</code> if this set changed as a result of this method call.</dd> |
| <dt><span class="throwsLabel">Throws:</span></dt> |
| <dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/IllegalArgumentException.html?is-external=true" title="class or interface in java.lang" class="externalLink">IllegalArgumentException</a></code> - if the <code>isMinIncluded</code> or <code>isMaxIncluded</code> |
| property does not match the one given at this <code>RangeSet</code> constructor.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a id="add(java.lang.Comparable,java.lang.Comparable)"> |
| <!-- --> |
| </a><a id="add(E,E)"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>add</h4> |
| <pre class="methodSignature">public boolean add​(<a href="RangeSet.html" title="type parameter in RangeSet">E</a> minValue, |
| <a href="RangeSet.html" title="type parameter in RangeSet">E</a> maxValue) |
| throws <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/IllegalArgumentException.html?is-external=true" title="class or interface in java.lang" class="externalLink">IllegalArgumentException</a></pre> |
| <div class="block">Adds a range of values to this set. If the specified range overlaps existing ranges, then |
| the existing ranges will be merged. This may result in smaller <a href="#size()">size</a> |
| of this set.</div> |
| <dl> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>minValue</code> - the minimal value.</dd> |
| <dd><code>maxValue</code> - the maximal value.</dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd><code>true</code> if this set changed as a result of this method call.</dd> |
| <dt><span class="throwsLabel">Throws:</span></dt> |
| <dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/IllegalArgumentException.html?is-external=true" title="class or interface in java.lang" class="externalLink">IllegalArgumentException</a></code> - if <code>minValue</code> is greater than <code>maxValue</code>.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a id="remove(java.lang.Object)"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>remove</h4> |
| <pre class="methodSignature">public boolean remove​(<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang" class="externalLink">Object</a> object)</pre> |
| <div class="block">Removes a range from this set. If the specified range is inside an existing range, then the |
| existing range may be splitted in two smaller ranges as of <a href="../../measure/Range.html#subtract(org.apache.sis.measure.Range)"><code>Range.subtract(Range)</code></a>. |
| In other words, invoking this method may <strong>increase</strong> the |
| <a href="#size()">size</a> of this set. |
| |
| <p>The <code>isMinIncluded</code> and <code>isMaxIncluded</code> properties of the given range |
| shall be the complement of the ones given to the constructor of this <code>RangeSet</code>:</p> |
| <table class="sis"> |
| <caption>Expected bounds inclusion</caption> |
| <tr><th><code>add(…)</code> values</th> <th><code>remove(…)</code> values</th></tr> |
| <tr><td><code>[min … max]</code></td> <td><code>(min … max)</code></td></tr> |
| <tr><td><code>(min … max)</code></td> <td><code>[min … max]</code></td></tr> |
| <tr><td><code>[min … max)</code></td> <td><code>(min … max]</code></td></tr> |
| <tr><td><code>(min … max]</code></td> <td><code>[min … max)</code></td></tr> |
| </table> |
| |
| <p>The default implementation does nothing if the given object is <code>null</code>, or is not an |
| instance of <code>Range</code>, or <a href="../../measure/Range.html#isEmpty()">is empty</a>, or its element type is |
| not equals to the element type of the ranges of this set. Otherwise this method ensures that |
| the <code>isMinIncluded</code> and <code>isMaxIncluded</code> are consistent with the ones given to the |
| constructor of this <code>RangeSet</code>, then delegates to <a href="#remove(E,E)"><code>remove(Comparable, Comparable)</code></a>.</p></div> |
| <dl> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/Collection.html?is-external=true#remove(java.lang.Object)" title="class or interface in java.util" class="externalLink">remove</a></code> in interface <code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/Collection.html?is-external=true" title="class or interface in java.util" class="externalLink">Collection</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a> extends <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Comparable.html?is-external=true" title="class or interface in java.lang" class="externalLink">Comparable</a><? super <a href="RangeSet.html" title="type parameter in RangeSet">E</a>>></code></dd> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/Set.html?is-external=true#remove(java.lang.Object)" title="class or interface in java.util" class="externalLink">remove</a></code> in interface <code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/Set.html?is-external=true" title="class or interface in java.util" class="externalLink">Set</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a> extends <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Comparable.html?is-external=true" title="class or interface in java.lang" class="externalLink">Comparable</a><? super <a href="RangeSet.html" title="type parameter in RangeSet">E</a>>></code></dd> |
| <dt><span class="overrideSpecifyLabel">Overrides:</span></dt> |
| <dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/AbstractCollection.html?is-external=true#remove(java.lang.Object)" title="class or interface in java.util" class="externalLink">remove</a></code> in class <code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/AbstractCollection.html?is-external=true" title="class or interface in java.util" class="externalLink">AbstractCollection</a><<a href="../../measure/Range.html" title="class in org.apache.sis.measure">Range</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a> extends <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Comparable.html?is-external=true" title="class or interface in java.lang" class="externalLink">Comparable</a><? super <a href="RangeSet.html" title="type parameter in RangeSet">E</a>>>></code></dd> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>object</code> - the range to remove.</dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd><code>true</code> if this set changed as a result of this method call.</dd> |
| <dt><span class="throwsLabel">Throws:</span></dt> |
| <dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/IllegalArgumentException.html?is-external=true" title="class or interface in java.lang" class="externalLink">IllegalArgumentException</a></code> - if the <code>isMinIncluded</code> or <code>isMaxIncluded</code> |
| property is not the complement of the one given at this <code>RangeSet</code> constructor.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a id="remove(java.lang.Comparable,java.lang.Comparable)"> |
| <!-- --> |
| </a><a id="remove(E,E)"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>remove</h4> |
| <pre class="methodSignature">public boolean remove​(<a href="RangeSet.html" title="type parameter in RangeSet">E</a> minValue, |
| <a href="RangeSet.html" title="type parameter in RangeSet">E</a> maxValue) |
| throws <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/IllegalArgumentException.html?is-external=true" title="class or interface in java.lang" class="externalLink">IllegalArgumentException</a></pre> |
| <div class="block">Removes a range of values to this set. If the specified range in inside an existing ranges, |
| then the existing range may be splitted in two smaller ranges. This may result in greater |
| <a href="#size()">size</a> of this set.</div> |
| <dl> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>minValue</code> - the minimal value.</dd> |
| <dd><code>maxValue</code> - the maximal value.</dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd><code>true</code> if this set changed as a result of this method call.</dd> |
| <dt><span class="throwsLabel">Throws:</span></dt> |
| <dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/IllegalArgumentException.html?is-external=true" title="class or interface in java.lang" class="externalLink">IllegalArgumentException</a></code> - if <code>minValue</code> is greater than <code>maxValue</code>.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a id="contains(java.lang.Object)"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>contains</h4> |
| <pre class="methodSignature">public boolean contains​(<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang" class="externalLink">Object</a> object)</pre> |
| <div class="block">Returns <code>true</code> if the given object is an instance of <a href="../../measure/Range.html" title="class in org.apache.sis.measure"><code>Range</code></a> compatible |
| with this set and contained inside one of the range elements of this set. |
| If this method returns <code>true</code>, then: |
| |
| <ul> |
| <li>Invoking <a href="#add(org.apache.sis.measure.Range)"><code>add(Range)</code></a> is guaranteed to have no effect.</li> |
| <li>Invoking <a href="#remove(java.lang.Object)"><code>remove(Object)</code></a> is guaranteed to modify this set.</li> |
| </ul> |
| |
| Conversely, if this method returns <code>false</code>, then: |
| |
| <ul> |
| <li>Invoking <a href="#add(org.apache.sis.measure.Range)"><code>add(Range)</code></a> is guaranteed to modify this set.</li> |
| <li>Invoking <a href="#remove(java.lang.Object)"><code>remove(Object)</code></a> may or may not modify this set. |
| The consequence of invoking <code>remove(…)</code> is undetermined because it |
| depends on whether the given range is outside every ranges in this set, |
| or if it overlaps with at least one range.</li> |
| </ul> |
| |
| The default implementation checks the type of the given object, then delegates to |
| <code><a href="#contains(org.apache.sis.measure.Range,boolean)">contains</a>(object, false)</code>.</div> |
| <dl> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/Collection.html?is-external=true#contains(java.lang.Object)" title="class or interface in java.util" class="externalLink">contains</a></code> in interface <code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/Collection.html?is-external=true" title="class or interface in java.util" class="externalLink">Collection</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a> extends <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Comparable.html?is-external=true" title="class or interface in java.lang" class="externalLink">Comparable</a><? super <a href="RangeSet.html" title="type parameter in RangeSet">E</a>>></code></dd> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/Set.html?is-external=true#contains(java.lang.Object)" title="class or interface in java.util" class="externalLink">contains</a></code> in interface <code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/Set.html?is-external=true" title="class or interface in java.util" class="externalLink">Set</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a> extends <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Comparable.html?is-external=true" title="class or interface in java.lang" class="externalLink">Comparable</a><? super <a href="RangeSet.html" title="type parameter in RangeSet">E</a>>></code></dd> |
| <dt><span class="overrideSpecifyLabel">Overrides:</span></dt> |
| <dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/AbstractCollection.html?is-external=true#contains(java.lang.Object)" title="class or interface in java.util" class="externalLink">contains</a></code> in class <code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/AbstractCollection.html?is-external=true" title="class or interface in java.util" class="externalLink">AbstractCollection</a><<a href="../../measure/Range.html" title="class in org.apache.sis.measure">Range</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a> extends <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Comparable.html?is-external=true" title="class or interface in java.lang" class="externalLink">Comparable</a><? super <a href="RangeSet.html" title="type parameter in RangeSet">E</a>>>></code></dd> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>object</code> - the object to check for inclusion in this set.</dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd><code>true</code> if the given object is contained in this set.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a id="contains(org.apache.sis.measure.Range,boolean)"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>contains</h4> |
| <pre class="methodSignature">public boolean contains​(<a href="../../measure/Range.html" title="class in org.apache.sis.measure">Range</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a>> range, |
| boolean exact)</pre> |
| <div class="block">Returns <code>true</code> if this set contains the specified element. |
| |
| <ul> |
| <li>If the <code>exact</code> argument is <code>true</code>, then this method searches |
| for an exact match (i.e. this method doesn't check if the given range is |
| contained in a larger range).</li> |
| <li>If the <code>exact</code> argument is <code>false</code>, then this method |
| behaves as documented in the <a href="#contains(java.lang.Object)"><code>contains(Object)</code></a> method.</li> |
| </ul></div> |
| <dl> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>range</code> - the range to check for inclusion in this set.</dd> |
| <dd><code>exact</code> - <code>true</code> for searching for an exact match, |
| or <code>false</code> for searching for inclusion in any range.</dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd><code>true</code> if the given object is contained in this set.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a id="first()"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>first</h4> |
| <pre class="methodSignature">public <a href="../../measure/Range.html" title="class in org.apache.sis.measure">Range</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a>> first() |
| throws <a href="https://docs.oracle.com/javase/8/docs/api/java/util/NoSuchElementException.html?is-external=true" title="class or interface in java.util" class="externalLink">NoSuchElementException</a></pre> |
| <div class="block">Returns the first (lowest) range currently in this sorted set.</div> |
| <dl> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/SortedSet.html?is-external=true#first()" title="class or interface in java.util" class="externalLink">first</a></code> in interface <code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/SortedSet.html?is-external=true" title="class or interface in java.util" class="externalLink">SortedSet</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a> extends <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Comparable.html?is-external=true" title="class or interface in java.lang" class="externalLink">Comparable</a><? super <a href="RangeSet.html" title="type parameter in RangeSet">E</a>>></code></dd> |
| <dt><span class="throwsLabel">Throws:</span></dt> |
| <dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/NoSuchElementException.html?is-external=true" title="class or interface in java.util" class="externalLink">NoSuchElementException</a></code> - if this set is empty.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a id="last()"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>last</h4> |
| <pre class="methodSignature">public <a href="../../measure/Range.html" title="class in org.apache.sis.measure">Range</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a>> last() |
| throws <a href="https://docs.oracle.com/javase/8/docs/api/java/util/NoSuchElementException.html?is-external=true" title="class or interface in java.util" class="externalLink">NoSuchElementException</a></pre> |
| <div class="block">Returns the last (highest) range currently in this sorted set.</div> |
| <dl> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/SortedSet.html?is-external=true#last()" title="class or interface in java.util" class="externalLink">last</a></code> in interface <code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/SortedSet.html?is-external=true" title="class or interface in java.util" class="externalLink">SortedSet</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a> extends <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Comparable.html?is-external=true" title="class or interface in java.lang" class="externalLink">Comparable</a><? super <a href="RangeSet.html" title="type parameter in RangeSet">E</a>>></code></dd> |
| <dt><span class="throwsLabel">Throws:</span></dt> |
| <dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/NoSuchElementException.html?is-external=true" title="class or interface in java.util" class="externalLink">NoSuchElementException</a></code> - if the set is empty.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a id="intersect(org.apache.sis.measure.Range)"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>intersect</h4> |
| <pre class="methodSignature">public <a href="https://docs.oracle.com/javase/8/docs/api/java/util/SortedSet.html?is-external=true" title="class or interface in java.util" class="externalLink">SortedSet</a><<a href="../../measure/Range.html" title="class in org.apache.sis.measure">Range</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a>>> intersect​(<a href="../../measure/Range.html" title="class in org.apache.sis.measure">Range</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a>> subRange)</pre> |
| <div class="block">Returns a view of the portion of this range set which is the intersection of |
| this <code>RangeSet</code> with the given range. Changes in this <code>RangeSet</code> |
| will be reflected in the returned view, and conversely.</div> |
| <dl> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>subRange</code> - the range to intersect with this <code>RangeSet</code>.</dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>a view of the specified range within this range set.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a id="subSet(org.apache.sis.measure.Range,org.apache.sis.measure.Range)"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>subSet</h4> |
| <pre class="methodSignature">public <a href="https://docs.oracle.com/javase/8/docs/api/java/util/SortedSet.html?is-external=true" title="class or interface in java.util" class="externalLink">SortedSet</a><<a href="../../measure/Range.html" title="class in org.apache.sis.measure">Range</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a>>> subSet​(<a href="../../measure/Range.html" title="class in org.apache.sis.measure">Range</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a>> lower, |
| <a href="../../measure/Range.html" title="class in org.apache.sis.measure">Range</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a>> upper)</pre> |
| <div class="block">Returns a view of the portion of this sorted set whose elements range |
| from <code>lower</code>, inclusive, to <code>upper</code>, exclusive. |
| The default implementation is equivalent to the following pseudo-code |
| (omitting argument checks): |
| |
| <blockquote><pre><font color="green">return</font> <b>intersect</b>(<font color="green">new</font> Range<E>(elementType, |
| lower.minValue, lower.isMinIncluded, |
| upper.minValue, !upper.isMinIncluded));</pre></blockquote> |
| |
| <div class="note"><b>API note:</b> |
| This method takes the minimal value of the <code>upper</code> argument instead |
| than the maximal value because the upper endpoint is exclusive.</div></div> |
| <dl> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/SortedSet.html?is-external=true#subSet(E,E)" title="class or interface in java.util" class="externalLink">subSet</a></code> in interface <code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/SortedSet.html?is-external=true" title="class or interface in java.util" class="externalLink">SortedSet</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a> extends <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Comparable.html?is-external=true" title="class or interface in java.lang" class="externalLink">Comparable</a><? super <a href="RangeSet.html" title="type parameter in RangeSet">E</a>>></code></dd> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>lower</code> - low endpoint (inclusive) of the sub set.</dd> |
| <dd><code>upper</code> - high endpoint (exclusive) of the sub set.</dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>a view of the specified range within this sorted set.</dd> |
| <dt><span class="seeLabel">See Also:</span></dt> |
| <dd><a href="#intersect(org.apache.sis.measure.Range)"><code>intersect(Range)</code></a></dd> |
| </dl> |
| </li> |
| </ul> |
| <a id="headSet(org.apache.sis.measure.Range)"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>headSet</h4> |
| <pre class="methodSignature">public <a href="https://docs.oracle.com/javase/8/docs/api/java/util/SortedSet.html?is-external=true" title="class or interface in java.util" class="externalLink">SortedSet</a><<a href="../../measure/Range.html" title="class in org.apache.sis.measure">Range</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a>>> headSet​(<a href="../../measure/Range.html" title="class in org.apache.sis.measure">Range</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a>> upper)</pre> |
| <div class="block">Returns a view of the portion of this sorted set whose elements are |
| strictly less than <code>upper</code>. |
| The default implementation is equivalent to the same pseudo-code than the one |
| documented in the <a href="#subSet(org.apache.sis.measure.Range,org.apache.sis.measure.Range)"><code>subSet(Range, Range)</code></a> method, except that the lower |
| endpoint is <code>null</code>.</div> |
| <dl> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/SortedSet.html?is-external=true#headSet(E)" title="class or interface in java.util" class="externalLink">headSet</a></code> in interface <code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/SortedSet.html?is-external=true" title="class or interface in java.util" class="externalLink">SortedSet</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a> extends <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Comparable.html?is-external=true" title="class or interface in java.lang" class="externalLink">Comparable</a><? super <a href="RangeSet.html" title="type parameter in RangeSet">E</a>>></code></dd> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>upper</code> - high endpoint (exclusive) of the headSet.</dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>a view of the specified initial range of this sorted set.</dd> |
| <dt><span class="seeLabel">See Also:</span></dt> |
| <dd><a href="#intersect(org.apache.sis.measure.Range)"><code>intersect(Range)</code></a></dd> |
| </dl> |
| </li> |
| </ul> |
| <a id="tailSet(org.apache.sis.measure.Range)"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>tailSet</h4> |
| <pre class="methodSignature">public <a href="https://docs.oracle.com/javase/8/docs/api/java/util/SortedSet.html?is-external=true" title="class or interface in java.util" class="externalLink">SortedSet</a><<a href="../../measure/Range.html" title="class in org.apache.sis.measure">Range</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a>>> tailSet​(<a href="../../measure/Range.html" title="class in org.apache.sis.measure">Range</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a>> lower)</pre> |
| <div class="block">Returns a view of the portion of this sorted set whose elements are |
| greater than or equal to <code>lower</code>. |
| The default implementation is equivalent to the same pseudo-code than the one |
| documented in the <a href="#subSet(org.apache.sis.measure.Range,org.apache.sis.measure.Range)"><code>subSet(Range, Range)</code></a> method, except that the upper |
| endpoint is <code>null</code>.</div> |
| <dl> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/SortedSet.html?is-external=true#tailSet(E)" title="class or interface in java.util" class="externalLink">tailSet</a></code> in interface <code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/SortedSet.html?is-external=true" title="class or interface in java.util" class="externalLink">SortedSet</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a> extends <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Comparable.html?is-external=true" title="class or interface in java.lang" class="externalLink">Comparable</a><? super <a href="RangeSet.html" title="type parameter in RangeSet">E</a>>></code></dd> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>lower</code> - low endpoint (inclusive) of the tailSet.</dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>a view of the specified final range of this sorted set.</dd> |
| <dt><span class="seeLabel">See Also:</span></dt> |
| <dd><a href="#intersect(org.apache.sis.measure.Range)"><code>intersect(Range)</code></a></dd> |
| </dl> |
| </li> |
| </ul> |
| <a id="iterator()"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>iterator</h4> |
| <pre class="methodSignature">public <a href="https://docs.oracle.com/javase/8/docs/api/java/util/Iterator.html?is-external=true" title="class or interface in java.util" class="externalLink">Iterator</a><<a href="../../measure/Range.html" title="class in org.apache.sis.measure">Range</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a>>> iterator()</pre> |
| <div class="block">Returns an iterator over the elements in this set of ranges. |
| All elements are <a href="../../measure/Range.html" title="class in org.apache.sis.measure"><code>Range</code></a> objects.</div> |
| <dl> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/Collection.html?is-external=true#iterator()" title="class or interface in java.util" class="externalLink">iterator</a></code> in interface <code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/Collection.html?is-external=true" title="class or interface in java.util" class="externalLink">Collection</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a> extends <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Comparable.html?is-external=true" title="class or interface in java.lang" class="externalLink">Comparable</a><? super <a href="RangeSet.html" title="type parameter in RangeSet">E</a>>></code></dd> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Iterable.html?is-external=true#iterator()" title="class or interface in java.lang" class="externalLink">iterator</a></code> in interface <code><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Iterable.html?is-external=true" title="class or interface in java.lang" class="externalLink">Iterable</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a> extends <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Comparable.html?is-external=true" title="class or interface in java.lang" class="externalLink">Comparable</a><? super <a href="RangeSet.html" title="type parameter in RangeSet">E</a>>></code></dd> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/Set.html?is-external=true#iterator()" title="class or interface in java.util" class="externalLink">iterator</a></code> in interface <code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/Set.html?is-external=true" title="class or interface in java.util" class="externalLink">Set</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a> extends <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Comparable.html?is-external=true" title="class or interface in java.lang" class="externalLink">Comparable</a><? super <a href="RangeSet.html" title="type parameter in RangeSet">E</a>>></code></dd> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/AbstractCollection.html?is-external=true#iterator()" title="class or interface in java.util" class="externalLink">iterator</a></code> in class <code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/AbstractCollection.html?is-external=true" title="class or interface in java.util" class="externalLink">AbstractCollection</a><<a href="../../measure/Range.html" title="class in org.apache.sis.measure">Range</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a> extends <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Comparable.html?is-external=true" title="class or interface in java.lang" class="externalLink">Comparable</a><? super <a href="RangeSet.html" title="type parameter in RangeSet">E</a>>>></code></dd> |
| </dl> |
| </li> |
| </ul> |
| <a id="indexOfRange(java.lang.Comparable)"> |
| <!-- --> |
| </a><a id="indexOfRange(E)"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>indexOfRange</h4> |
| <pre class="methodSignature">public int indexOfRange​(<a href="RangeSet.html" title="type parameter in RangeSet">E</a> value)</pre> |
| <div class="block">If the specified value is inside a range, returns the index of this range. |
| Otherwise, returns <code>-1</code>.</div> |
| <dl> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>value</code> - the value to search.</dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>the index of the range which contains this value, or -1 if there is no such range.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a id="getMinLong(int)"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getMinLong</h4> |
| <pre class="methodSignature">public long getMinLong​(int index) |
| throws <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/IndexOutOfBoundsException.html?is-external=true" title="class or interface in java.lang" class="externalLink">IndexOutOfBoundsException</a>, |
| <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/ClassCastException.html?is-external=true" title="class or interface in java.lang" class="externalLink">ClassCastException</a></pre> |
| <div class="block">Returns a <a href="../../measure/Range.html#getMinValue()">range minimum value</a> as a <code>long</code>. |
| The <code>index</code> can be any value from 0 inclusive to the set <a href="#size()"><code>size</code></a> |
| exclusive. The returned values always increase with <code>index</code>. |
| Widening conversions are performed as needed.</div> |
| <dl> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>index</code> - the range index, from 0 inclusive to <a href="#size()"><code>size</code></a> exclusive.</dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>the minimum value for the range at the specified index, inclusive.</dd> |
| <dt><span class="throwsLabel">Throws:</span></dt> |
| <dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/IndexOutOfBoundsException.html?is-external=true" title="class or interface in java.lang" class="externalLink">IndexOutOfBoundsException</a></code> - if <code>index</code> is out of bounds.</dd> |
| <dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/ClassCastException.html?is-external=true" title="class or interface in java.lang" class="externalLink">ClassCastException</a></code> - if range elements are not convertible to <code>long</code>.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a id="getMinDouble(int)"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getMinDouble</h4> |
| <pre class="methodSignature">public double getMinDouble​(int index) |
| throws <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/IndexOutOfBoundsException.html?is-external=true" title="class or interface in java.lang" class="externalLink">IndexOutOfBoundsException</a>, |
| <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/ClassCastException.html?is-external=true" title="class or interface in java.lang" class="externalLink">ClassCastException</a></pre> |
| <div class="block">Returns a <a href="../../measure/Range.html#getMinValue()">range minimum value</a> as a <code>double</code>. |
| The <code>index</code> can be any value from 0 inclusive to the set <a href="#size()"><code>size</code></a> |
| exclusive. The returned values always increase with <code>index</code>. |
| Widening conversions are performed as needed.</div> |
| <dl> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>index</code> - the range index, from 0 inclusive to <a href="#size()"><code>size</code></a> exclusive.</dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>the minimum value for the range at the specified index, inclusive.</dd> |
| <dt><span class="throwsLabel">Throws:</span></dt> |
| <dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/IndexOutOfBoundsException.html?is-external=true" title="class or interface in java.lang" class="externalLink">IndexOutOfBoundsException</a></code> - if <code>index</code> is out of bounds.</dd> |
| <dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/ClassCastException.html?is-external=true" title="class or interface in java.lang" class="externalLink">ClassCastException</a></code> - if range elements are not convertible to numbers.</dd> |
| <dt><span class="seeLabel">See Also:</span></dt> |
| <dd><a href="../../measure/NumberRange.html#getMinDouble()"><code>NumberRange.getMinDouble()</code></a></dd> |
| </dl> |
| </li> |
| </ul> |
| <a id="getMaxLong(int)"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getMaxLong</h4> |
| <pre class="methodSignature">public long getMaxLong​(int index) |
| throws <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/IndexOutOfBoundsException.html?is-external=true" title="class or interface in java.lang" class="externalLink">IndexOutOfBoundsException</a>, |
| <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/ClassCastException.html?is-external=true" title="class or interface in java.lang" class="externalLink">ClassCastException</a></pre> |
| <div class="block">Returns a <a href="../../measure/Range.html#getMaxValue()">range maximum value</a> as a <code>long</code>. |
| The <code>index</code> can be any value from 0 inclusive to the set <a href="#size()"><code>size</code></a> |
| exclusive. The returned values always increase with <code>index</code>. |
| Widening conversions are performed as needed.</div> |
| <dl> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>index</code> - the range index, from 0 inclusive to <a href="#size()"><code>size</code></a> exclusive.</dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>the maximum value for the range at the specified index, inclusive.</dd> |
| <dt><span class="throwsLabel">Throws:</span></dt> |
| <dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/IndexOutOfBoundsException.html?is-external=true" title="class or interface in java.lang" class="externalLink">IndexOutOfBoundsException</a></code> - if <code>index</code> is out of bounds.</dd> |
| <dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/ClassCastException.html?is-external=true" title="class or interface in java.lang" class="externalLink">ClassCastException</a></code> - if range elements are not convertible to <code>long</code>.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a id="getMaxDouble(int)"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getMaxDouble</h4> |
| <pre class="methodSignature">public double getMaxDouble​(int index) |
| throws <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/IndexOutOfBoundsException.html?is-external=true" title="class or interface in java.lang" class="externalLink">IndexOutOfBoundsException</a>, |
| <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/ClassCastException.html?is-external=true" title="class or interface in java.lang" class="externalLink">ClassCastException</a></pre> |
| <div class="block">Returns a <a href="../../measure/Range.html#getMaxValue()">range maximum value</a> as a <code>double</code>. |
| The <code>index</code> can be any value from 0 inclusive to the set's <a href="#size()"><code>size</code></a> |
| exclusive. The returned values always increase with <code>index</code>. |
| Widening conversions are performed as needed.</div> |
| <dl> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>index</code> - the range index, from 0 inclusive to <a href="#size()"><code>size</code></a> exclusive.</dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>the maximum value for the range at the specified index, exclusive.</dd> |
| <dt><span class="throwsLabel">Throws:</span></dt> |
| <dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/IndexOutOfBoundsException.html?is-external=true" title="class or interface in java.lang" class="externalLink">IndexOutOfBoundsException</a></code> - if <code>index</code> is out of bounds.</dd> |
| <dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/ClassCastException.html?is-external=true" title="class or interface in java.lang" class="externalLink">ClassCastException</a></code> - if range elements are not convertible to numbers.</dd> |
| <dt><span class="seeLabel">See Also:</span></dt> |
| <dd><a href="../../measure/NumberRange.html#getMaxDouble()"><code>NumberRange.getMaxDouble()</code></a></dd> |
| </dl> |
| </li> |
| </ul> |
| <a id="newRange(java.lang.Comparable,java.lang.Comparable)"> |
| <!-- --> |
| </a><a id="newRange(E,E)"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>newRange</h4> |
| <pre class="methodSignature">protected <a href="../../measure/Range.html" title="class in org.apache.sis.measure">Range</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a>> newRange​(<a href="RangeSet.html" title="type parameter in RangeSet">E</a> lower, |
| <a href="RangeSet.html" title="type parameter in RangeSet">E</a> upper)</pre> |
| <div class="block">Returns a new <a href="../../measure/Range.html" title="class in org.apache.sis.measure"><code>Range</code></a> object initialized with the given values.</div> |
| <dl> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>lower</code> - the lower value, inclusive.</dd> |
| <dd><code>upper</code> - the upper value, exclusive.</dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>the new range for the given values.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a id="equals(java.lang.Object)"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>equals</h4> |
| <pre class="methodSignature">public boolean equals​(<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang" class="externalLink">Object</a> object)</pre> |
| <div class="block">Compares the specified object with this set of ranges for equality.</div> |
| <dl> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/Collection.html?is-external=true#equals(java.lang.Object)" title="class or interface in java.util" class="externalLink">equals</a></code> in interface <code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/Collection.html?is-external=true" title="class or interface in java.util" class="externalLink">Collection</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a> extends <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Comparable.html?is-external=true" title="class or interface in java.lang" class="externalLink">Comparable</a><? super <a href="RangeSet.html" title="type parameter in RangeSet">E</a>>></code></dd> |
| <dt><span class="overrideSpecifyLabel">Specified by:</span></dt> |
| <dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/Set.html?is-external=true#equals(java.lang.Object)" title="class or interface in java.util" class="externalLink">equals</a></code> in interface <code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/Set.html?is-external=true" title="class or interface in java.util" class="externalLink">Set</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a> extends <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Comparable.html?is-external=true" title="class or interface in java.lang" class="externalLink">Comparable</a><? super <a href="RangeSet.html" title="type parameter in RangeSet">E</a>>></code></dd> |
| <dt><span class="overrideSpecifyLabel">Overrides:</span></dt> |
| <dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/AbstractSet.html?is-external=true#equals(java.lang.Object)" title="class or interface in java.util" class="externalLink">equals</a></code> in class <code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/AbstractSet.html?is-external=true" title="class or interface in java.util" class="externalLink">AbstractSet</a><<a href="../../measure/Range.html" title="class in org.apache.sis.measure">Range</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a> extends <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Comparable.html?is-external=true" title="class or interface in java.lang" class="externalLink">Comparable</a><? super <a href="RangeSet.html" title="type parameter in RangeSet">E</a>>>></code></dd> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>object</code> - the object to compare with this range.</dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd><code>true</code> if the given object is equal to this range.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a id="clone()"> |
| <!-- --> |
| </a> |
| <ul class="blockListLast"> |
| <li class="blockList"> |
| <h4>clone</h4> |
| <pre class="methodSignature">public <a href="RangeSet.html" title="class in org.apache.sis.util.collection">RangeSet</a><<a href="RangeSet.html" title="type parameter in RangeSet">E</a>> clone()</pre> |
| <div class="block">Returns a clone of this range set.</div> |
| <dl> |
| <dt><span class="overrideSpecifyLabel">Overrides:</span></dt> |
| <dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true#clone()" title="class or interface in java.lang" class="externalLink">clone</a></code> in class <code><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang" class="externalLink">Object</a></code></dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>a clone of this range set.</dd> |
| </dl> |
| </li> |
| </ul> |
| </li> |
| </ul> |
| </section> |
| </li> |
| </ul> |
| </div> |
| </div> |
| </main> |
| <!-- ========= END OF CLASS DATA ========= --> |
| <footer role="contentinfo"> |
| <nav role="navigation"> |
| <!-- ======= START OF BOTTOM NAVBAR ====== --> |
| <div class="bottomNav"><a id="navbar.bottom"> |
| <!-- --> |
| </a> |
| <div class="skipNav"><a href="#skip.navbar.bottom" title="Skip navigation links">Skip navigation links</a></div> |
| <a id="navbar.bottom.firstrow"> |
| <!-- --> |
| </a> |
| <ul class="navList" title="Navigation"> |
| <li><a href="../../../../../index.html">Overview</a></li> |
| <li><a href="package-summary.html">Package</a></li> |
| <li class="navBarCell1Rev">Class</li> |
| <li><a href="class-use/RangeSet.html">Use</a></li> |
| <li><a href="package-tree.html">Tree</a></li> |
| <li><a href="../../../../../deprecated-list.html">Deprecated</a></li> |
| <li><a href="../../../../../index-all.html">Index</a></li> |
| <li><a href="../../../../../help-doc.html">Help</a></li> |
| </ul> |
| </div> |
| <div class="subNav"> |
| <ul class="navList" id="allclasses_navbar_bottom"> |
| <li><a href="../../../../../allclasses.html">All Classes</a></li> |
| </ul> |
| <div> |
| <script type="text/javascript"><!-- |
| allClassesLink = document.getElementById("allclasses_navbar_bottom"); |
| if(window==top) { |
| allClassesLink.style.display = "block"; |
| } |
| else { |
| allClassesLink.style.display = "none"; |
| } |
| //--> |
| </script> |
| <noscript> |
| <div>JavaScript is disabled on your browser.</div> |
| </noscript> |
| </div> |
| <div> |
| <ul class="subNavList"> |
| <li>Summary: </li> |
| <li>Nested | </li> |
| <li><a href="#field.summary">Field</a> | </li> |
| <li><a href="#constructor.summary">Constr</a> | </li> |
| <li><a href="#method.summary">Method</a></li> |
| </ul> |
| <ul class="subNavList"> |
| <li>Detail: </li> |
| <li><a href="#field.detail">Field</a> | </li> |
| <li><a href="#constructor.detail">Constr</a> | </li> |
| <li><a href="#method.detail">Method</a></li> |
| </ul> |
| </div> |
| <a id="skip.navbar.bottom"> |
| <!-- --> |
| </a></div> |
| <!-- ======== END OF BOTTOM NAVBAR ======= --> |
| </nav> |
| <p class="legalCopy"><small>Copyright © 2010–2019 <a href="https://www.apache.org/">The Apache Software Foundation</a>. All rights reserved.</small></p> |
| </footer> |
| </body> |
| </html> |