| <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> |
| <!-- NewPage --> |
| <html lang="en"> |
| <head> |
| <!-- Generated by javadoc (9) on Fri Oct 01 19:18:48 PDT 2021 --> |
| <title>AnotB (datasketches-java 3.1.0-SNAPSHOT API)</title> |
| <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> |
| <meta name="date" content="2021-10-01"> |
| <link rel="stylesheet" type="text/css" href="../../../../stylesheet.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-1.10.2.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="AnotB (datasketches-java 3.1.0-SNAPSHOT API)"; |
| } |
| } |
| catch(err) { |
| } |
| //--> |
| var methods = {"i0":9,"i1":9,"i2":10,"i3":10,"i4":10,"i5":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 = "../../../../";loadScripts(document, 'script');</script> |
| <noscript> |
| <div>JavaScript is disabled on your browser.</div> |
| </noscript> |
| <div class="fixedNav"> |
| <!-- ========= START OF TOP NAVBAR ======= --> |
| <div class="topNav"><a name="navbar.top"> |
| <!-- --> |
| </a> |
| <div class="skipNav"><a href="#skip.navbar.top" title="Skip navigation links">Skip navigation links</a></div> |
| <a name="navbar.top.firstrow"> |
| <!-- --> |
| </a> |
| <ul class="navList" title="Navigation"> |
| <li><a href="../../../../overview-summary.html">Overview</a></li> |
| <li><a href="package-summary.html">Package</a></li> |
| <li class="navBarCell1Rev">Class</li> |
| <li><a href="class-use/AnotB.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"> |
| <li>Prev Class</li> |
| <li><a href="../../../../org/apache/datasketches/tuple/CompactSketch.html" title="class in org.apache.datasketches.tuple"><span class="typeNameLink">Next Class</span></a></li> |
| </ul> |
| <ul class="navList"> |
| <li><a href="../../../../index.html?org/apache/datasketches/tuple/AnotB.html" target="_top">Frames</a></li> |
| <li><a href="AnotB.html" target="_top">No Frames</a></li> |
| </ul> |
| <ul class="navList" id="allclasses_navbar_top"> |
| <li><a href="../../../../allclasses-noframe.html">All Classes</a></li> |
| </ul> |
| <ul class="navListSearch"> |
| <li><span>SEARCH: </span> |
| <input type="text" id="search" value=" " disabled="disabled"> |
| <input type="reset" id="reset" value=" " 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>Field | </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>Field | </li> |
| <li><a href="#constructor.detail">Constr</a> | </li> |
| <li><a href="#method.detail">Method</a></li> |
| </ul> |
| </div> |
| <a name="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> |
| <!-- ======== START OF CLASS DATA ======== --> |
| <div class="header"> |
| <div class="subTitle"><span class="packageLabelInType">Package</span> <a href="../../../../org/apache/datasketches/tuple/package-summary.html">org.apache.datasketches.tuple</a></div> |
| <h2 title="Class AnotB" class="title">Class AnotB<S extends <a href="../../../../org/apache/datasketches/tuple/Summary.html" title="interface in org.apache.datasketches.tuple">Summary</a>></h2> |
| </div> |
| <div class="contentContainer"> |
| <ul class="inheritance"> |
| <li><a href="https://docs.oracle.com/javase/9/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">java.lang.Object</a></li> |
| <li> |
| <ul class="inheritance"> |
| <li>org.apache.datasketches.tuple.AnotB<S></li> |
| </ul> |
| </li> |
| </ul> |
| <div class="description"> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <dl> |
| <dt><span class="paramLabel">Type Parameters:</span></dt> |
| <dd><code>S</code> - Type of Summary</dd> |
| </dl> |
| <hr> |
| <br> |
| <pre>public final class <span class="typeNameLabel">AnotB<S extends <a href="../../../../org/apache/datasketches/tuple/Summary.html" title="interface in org.apache.datasketches.tuple">Summary</a>></span> |
| extends <a href="https://docs.oracle.com/javase/9/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a></pre> |
| <div class="block">Computes a set difference, A-AND-NOT-B, of two generic tuple sketches. |
| This class includes both stateful and stateless operations. |
| |
| <p>The stateful operation is as follows:</p> |
| <pre><code> |
| AnotB anotb = SetOperationBuilder.buildAnotB(); |
| |
| anotb.setA(Sketch skA); //The first argument. |
| anotb.notB(Sketch skB); //The second (subtraction) argument. |
| anotb.notB(Sketch skC); // ...any number of additional subtractions... |
| anotb.getResult(false); //Get an interim result. |
| anotb.notB(Sketch skD); //Additional subtractions. |
| anotb.getResult(true); //Final result and resets the AnotB operator. |
| </code></pre> |
| |
| <p>The stateless operation is as follows:</p> |
| <pre><code> |
| AnotB anotb = SetOperationBuilder.buildAnotB(); |
| |
| CompactSketch csk = anotb.aNotB(Sketch skA, Sketch skB); |
| </code></pre> |
| |
| <p>Calling the <i>setA</i> operation a second time essentially clears the internal state and loads |
| the new sketch.</p> |
| |
| <p>The stateless and stateful operations are independent of each other with the exception of |
| sharing the same update hash seed loaded as the default seed or specified by the user as an |
| argument to the builder.</p></div> |
| </li> |
| </ul> |
| </div> |
| <div class="summary"> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <!-- ======== CONSTRUCTOR SUMMARY ======== --> |
| <ul class="blockList"> |
| <li class="blockList"><a name="constructor.summary"> |
| <!-- --> |
| </a> |
| <h3>Constructor Summary</h3> |
| <table class="memberSummary" summary="Constructor Summary table, listing constructors, and an explanation"> |
| <caption><span>Constructors</span><span class="tabEnd"> </span></caption> |
| <tr> |
| <th class="colFirst" scope="col">Constructor</th> |
| <th class="colLast" scope="col">Description</th> |
| </tr> |
| <tr class="altColor"> |
| <th class="colConstructorName" scope="row"><code><span class="memberNameLink"><a href="../../../../org/apache/datasketches/tuple/AnotB.html#AnotB--">AnotB</a></span>​()</code></th> |
| <td class="colLast"> </td> |
| </tr> |
| </table> |
| </li> |
| </ul> |
| <!-- ========== METHOD SUMMARY =========== --> |
| <ul class="blockList"> |
| <li class="blockList"><a name="method.summary"> |
| <!-- --> |
| </a> |
| <h3>Method Summary</h3> |
| <table class="memberSummary" summary="Method Summary table, listing methods, and an explanation"> |
| <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>static <S extends <a href="../../../../org/apache/datasketches/tuple/Summary.html" title="interface in org.apache.datasketches.tuple">Summary</a>><br><a href="../../../../org/apache/datasketches/tuple/CompactSketch.html" title="class in org.apache.datasketches.tuple">CompactSketch</a><S></code></td> |
| <th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="../../../../org/apache/datasketches/tuple/AnotB.html#aNotB-org.apache.datasketches.tuple.Sketch-org.apache.datasketches.theta.Sketch-">aNotB</a></span>​(<a href="../../../../org/apache/datasketches/tuple/Sketch.html" title="class in org.apache.datasketches.tuple">Sketch</a><S> skA, |
| <a href="../../../../org/apache/datasketches/theta/Sketch.html" title="class in org.apache.datasketches.theta">Sketch</a> skB)</code></th> |
| <td class="colLast"> |
| <div class="block">Returns the A-and-not-B set operation on a Tuple sketch and a Theta sketch.</div> |
| </td> |
| </tr> |
| <tr id="i1" class="rowColor"> |
| <td class="colFirst"><code>static <S extends <a href="../../../../org/apache/datasketches/tuple/Summary.html" title="interface in org.apache.datasketches.tuple">Summary</a>><br><a href="../../../../org/apache/datasketches/tuple/CompactSketch.html" title="class in org.apache.datasketches.tuple">CompactSketch</a><S></code></td> |
| <th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="../../../../org/apache/datasketches/tuple/AnotB.html#aNotB-org.apache.datasketches.tuple.Sketch-org.apache.datasketches.tuple.Sketch-">aNotB</a></span>​(<a href="../../../../org/apache/datasketches/tuple/Sketch.html" title="class in org.apache.datasketches.tuple">Sketch</a><S> skA, |
| <a href="../../../../org/apache/datasketches/tuple/Sketch.html" title="class in org.apache.datasketches.tuple">Sketch</a><S> skB)</code></th> |
| <td class="colLast"> |
| <div class="block">Returns the A-and-not-B set operation on the two given Tuple sketches.</div> |
| </td> |
| </tr> |
| <tr id="i2" class="altColor"> |
| <td class="colFirst"><code><a href="../../../../org/apache/datasketches/tuple/CompactSketch.html" title="class in org.apache.datasketches.tuple">CompactSketch</a><<a href="../../../../org/apache/datasketches/tuple/AnotB.html" title="type parameter in AnotB">S</a>></code></td> |
| <th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="../../../../org/apache/datasketches/tuple/AnotB.html#getResult-boolean-">getResult</a></span>​(boolean reset)</code></th> |
| <td class="colLast"> |
| <div class="block">Gets the result of the mutistep, stateful operation AnotB that have been executed with calls |
| to <a href="../../../../org/apache/datasketches/tuple/AnotB.html#setA-org.apache.datasketches.tuple.Sketch-"><code>setA(Sketch)</code></a> and (<a href="../../../../org/apache/datasketches/tuple/AnotB.html#notB-org.apache.datasketches.tuple.Sketch-"><code>notB(Sketch)</code></a> or |
| <a href="../../../../org/apache/datasketches/tuple/AnotB.html#notB-org.apache.datasketches.theta.Sketch-"><code>notB(org.apache.datasketches.theta.Sketch)</code></a>).</div> |
| </td> |
| </tr> |
| <tr id="i3" class="rowColor"> |
| <td class="colFirst"><code>void</code></td> |
| <th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="../../../../org/apache/datasketches/tuple/AnotB.html#notB-org.apache.datasketches.theta.Sketch-">notB</a></span>​(<a href="../../../../org/apache/datasketches/theta/Sketch.html" title="class in org.apache.datasketches.theta">Sketch</a> skB)</code></th> |
| <td class="colLast"> |
| <div class="block">This is part of a multistep, stateful AnotB operation and sets the given Theta sketch as the |
| second (or <i>n+1</i>th) argument <i>B</i> of <i>A-AND-NOT-B</i>.</div> |
| </td> |
| </tr> |
| <tr id="i4" class="altColor"> |
| <td class="colFirst"><code>void</code></td> |
| <th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="../../../../org/apache/datasketches/tuple/AnotB.html#notB-org.apache.datasketches.tuple.Sketch-">notB</a></span>​(<a href="../../../../org/apache/datasketches/tuple/Sketch.html" title="class in org.apache.datasketches.tuple">Sketch</a><<a href="../../../../org/apache/datasketches/tuple/AnotB.html" title="type parameter in AnotB">S</a>> skB)</code></th> |
| <td class="colLast"> |
| <div class="block">This is part of a multistep, stateful AnotB operation and sets the given Tuple sketch as the |
| second (or <i>n+1</i>th) argument <i>B</i> of <i>A-AND-NOT-B</i>.</div> |
| </td> |
| </tr> |
| <tr id="i5" class="rowColor"> |
| <td class="colFirst"><code>void</code></td> |
| <th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="../../../../org/apache/datasketches/tuple/AnotB.html#setA-org.apache.datasketches.tuple.Sketch-">setA</a></span>​(<a href="../../../../org/apache/datasketches/tuple/Sketch.html" title="class in org.apache.datasketches.tuple">Sketch</a><<a href="../../../../org/apache/datasketches/tuple/AnotB.html" title="type parameter in AnotB">S</a>> skA)</code></th> |
| <td class="colLast"> |
| <div class="block">This is part of a multistep, stateful AnotB operation and sets the given Tuple sketch as the |
| first argument <i>A</i> of <i>A-AND-NOT-B</i>.</div> |
| </td> |
| </tr> |
| </table> |
| <ul class="blockList"> |
| <li class="blockList"><a name="methods.inherited.from.class.java.lang.Object"> |
| <!-- --> |
| </a> |
| <h3>Methods inherited from class java.lang.<a href="https://docs.oracle.com/javase/9/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a></h3> |
| <code><a href="https://docs.oracle.com/javase/9/docs/api/java/lang/Object.html?is-external=true#clone--" title="class or interface in java.lang">clone</a>, <a href="https://docs.oracle.com/javase/9/docs/api/java/lang/Object.html?is-external=true#equals-java.lang.Object-" title="class or interface in java.lang">equals</a>, <a href="https://docs.oracle.com/javase/9/docs/api/java/lang/Object.html?is-external=true#finalize--" title="class or interface in java.lang">finalize</a>, <a href="https://docs.oracle.com/javase/9/docs/api/java/lang/Object.html?is-external=true#getClass--" title="class or interface in java.lang">getClass</a>, <a href="https://docs.oracle.com/javase/9/docs/api/java/lang/Object.html?is-external=true#hashCode--" title="class or interface in java.lang">hashCode</a>, <a href="https://docs.oracle.com/javase/9/docs/api/java/lang/Object.html?is-external=true#notify--" title="class or interface in java.lang">notify</a>, <a href="https://docs.oracle.com/javase/9/docs/api/java/lang/Object.html?is-external=true#notifyAll--" title="class or interface in java.lang">notifyAll</a>, <a href="https://docs.oracle.com/javase/9/docs/api/java/lang/Object.html?is-external=true#toString--" title="class or interface in java.lang">toString</a>, <a href="https://docs.oracle.com/javase/9/docs/api/java/lang/Object.html?is-external=true#wait--" title="class or interface in java.lang">wait</a>, <a href="https://docs.oracle.com/javase/9/docs/api/java/lang/Object.html?is-external=true#wait-long-" title="class or interface in java.lang">wait</a>, <a href="https://docs.oracle.com/javase/9/docs/api/java/lang/Object.html?is-external=true#wait-long-int-" title="class or interface in java.lang">wait</a></code></li> |
| </ul> |
| </li> |
| </ul> |
| </li> |
| </ul> |
| </div> |
| <div class="details"> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <!-- ========= CONSTRUCTOR DETAIL ======== --> |
| <ul class="blockList"> |
| <li class="blockList"><a name="constructor.detail"> |
| <!-- --> |
| </a> |
| <h3>Constructor Detail</h3> |
| <a name="AnotB--"> |
| <!-- --> |
| </a> |
| <ul class="blockListLast"> |
| <li class="blockList"> |
| <h4>AnotB</h4> |
| <pre>public AnotB​()</pre> |
| </li> |
| </ul> |
| </li> |
| </ul> |
| <!-- ============ METHOD DETAIL ========== --> |
| <ul class="blockList"> |
| <li class="blockList"><a name="method.detail"> |
| <!-- --> |
| </a> |
| <h3>Method Detail</h3> |
| <a name="setA-org.apache.datasketches.tuple.Sketch-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>setA</h4> |
| <pre>public void setA​(<a href="../../../../org/apache/datasketches/tuple/Sketch.html" title="class in org.apache.datasketches.tuple">Sketch</a><<a href="../../../../org/apache/datasketches/tuple/AnotB.html" title="type parameter in AnotB">S</a>> skA)</pre> |
| <div class="block">This is part of a multistep, stateful AnotB operation and sets the given Tuple sketch as the |
| first argument <i>A</i> of <i>A-AND-NOT-B</i>. This overwrites the internal state of this |
| AnotB operator with the contents of the given sketch. |
| This sets the stage for multiple following <i>notB</i> steps. |
| |
| <p>An input argument of null will throw an exception.</p> |
| |
| <p>Rationale: In mathematics a "null set" is a set with no members, which we call an empty set. |
| That is distinctly different from the java <i>null</i>, which represents a nonexistent object. |
| In most cases it is a programming error due to some object that was not properly initialized. |
| With a null as the first argument, we cannot know what the user's intent is. |
| Since it is very likely that a <i>null</i> is a programming error, we throw a an exception.</p> |
| |
| <p>An enpty input argument will set the internal state to empty.</p> |
| |
| <p>Rationale: An empty set is a mathematically legal concept. Although it makes any subsequent, |
| valid argument for B irrelvant, we must allow this and assume the user knows what they are |
| doing.</p> |
| |
| <p>Performing <a href="../../../../org/apache/datasketches/tuple/AnotB.html#getResult-boolean-"><code>getResult(boolean)</code></a> just after this step will return a compact form of |
| the given argument.</p></div> |
| <dl> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>skA</code> - The incoming sketch for the first argument, <i>A</i>.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="notB-org.apache.datasketches.tuple.Sketch-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>notB</h4> |
| <pre>public void notB​(<a href="../../../../org/apache/datasketches/tuple/Sketch.html" title="class in org.apache.datasketches.tuple">Sketch</a><<a href="../../../../org/apache/datasketches/tuple/AnotB.html" title="type parameter in AnotB">S</a>> skB)</pre> |
| <div class="block">This is part of a multistep, stateful AnotB operation and sets the given Tuple sketch as the |
| second (or <i>n+1</i>th) argument <i>B</i> of <i>A-AND-NOT-B</i>. |
| Performs an <i>AND NOT</i> operation with the existing internal state of this AnotB operator. |
| |
| <p>An input argument of null or empty is ignored.</p> |
| |
| <p>Rationale: A <i>null</i> for the second or following arguments is more tollerable because |
| <i>A NOT null</i> is still <i>A</i> even if we don't know exactly what the null represents. It |
| clearly does not have any content that overlaps with <i>A</i>. Also, because this can be part of |
| a multistep operation with multiple <i>notB</i> steps. Other following steps can still produce |
| a valid result.</p> |
| |
| <p>Use <a href="../../../../org/apache/datasketches/tuple/AnotB.html#getResult-boolean-"><code>getResult(boolean)</code></a> to obtain the result.</p></div> |
| <dl> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>skB</code> - The incoming Tuple sketch for the second (or following) argument <i>B</i>.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="notB-org.apache.datasketches.theta.Sketch-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>notB</h4> |
| <pre>public void notB​(<a href="../../../../org/apache/datasketches/theta/Sketch.html" title="class in org.apache.datasketches.theta">Sketch</a> skB)</pre> |
| <div class="block">This is part of a multistep, stateful AnotB operation and sets the given Theta sketch as the |
| second (or <i>n+1</i>th) argument <i>B</i> of <i>A-AND-NOT-B</i>. |
| Performs an <i>AND NOT</i> operation with the existing internal state of this AnotB operator. |
| Calls to this method can be intermingled with calls to |
| <a href="../../../../org/apache/datasketches/tuple/AnotB.html#notB-org.apache.datasketches.theta.Sketch-"><code>notB(org.apache.datasketches.theta.Sketch)</code></a>. |
| |
| <p>An input argument of null or empty is ignored.</p> |
| |
| <p>Rationale: A <i>null</i> for the second or following arguments is more tollerable because |
| <i>A NOT null</i> is still <i>A</i> even if we don't know exactly what the null represents. It |
| clearly does not have any content that overlaps with <i>A</i>. Also, because this can be part of |
| a multistep operation with multiple <i>notB</i> steps. Other following steps can still produce |
| a valid result.</p> |
| |
| <p>Use <a href="../../../../org/apache/datasketches/tuple/AnotB.html#getResult-boolean-"><code>getResult(boolean)</code></a> to obtain the result.</p></div> |
| <dl> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>skB</code> - The incoming Theta sketch for the second (or following) argument <i>B</i>.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="getResult-boolean-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getResult</h4> |
| <pre>public <a href="../../../../org/apache/datasketches/tuple/CompactSketch.html" title="class in org.apache.datasketches.tuple">CompactSketch</a><<a href="../../../../org/apache/datasketches/tuple/AnotB.html" title="type parameter in AnotB">S</a>> getResult​(boolean reset)</pre> |
| <div class="block">Gets the result of the mutistep, stateful operation AnotB that have been executed with calls |
| to <a href="../../../../org/apache/datasketches/tuple/AnotB.html#setA-org.apache.datasketches.tuple.Sketch-"><code>setA(Sketch)</code></a> and (<a href="../../../../org/apache/datasketches/tuple/AnotB.html#notB-org.apache.datasketches.tuple.Sketch-"><code>notB(Sketch)</code></a> or |
| <a href="../../../../org/apache/datasketches/tuple/AnotB.html#notB-org.apache.datasketches.theta.Sketch-"><code>notB(org.apache.datasketches.theta.Sketch)</code></a>).</div> |
| <dl> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>reset</code> - If <i>true</i>, clears this operator to the empty state after this result is |
| returned. Set this to <i>false</i> if you wish to obtain an intermediate result.</dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>the result of this operation as an unordered <a href="../../../../org/apache/datasketches/tuple/CompactSketch.html" title="class in org.apache.datasketches.tuple"><code>CompactSketch</code></a>.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="aNotB-org.apache.datasketches.tuple.Sketch-org.apache.datasketches.tuple.Sketch-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>aNotB</h4> |
| <pre>public static <S extends <a href="../../../../org/apache/datasketches/tuple/Summary.html" title="interface in org.apache.datasketches.tuple">Summary</a>> <a href="../../../../org/apache/datasketches/tuple/CompactSketch.html" title="class in org.apache.datasketches.tuple">CompactSketch</a><S> aNotB​(<a href="../../../../org/apache/datasketches/tuple/Sketch.html" title="class in org.apache.datasketches.tuple">Sketch</a><S> skA, |
| <a href="../../../../org/apache/datasketches/tuple/Sketch.html" title="class in org.apache.datasketches.tuple">Sketch</a><S> skB)</pre> |
| <div class="block">Returns the A-and-not-B set operation on the two given Tuple sketches. |
| |
| <p>This a stateless operation and has no impact on the internal state of this operator. |
| Thus, this is not an accumulating update and is independent of the <a href="../../../../org/apache/datasketches/tuple/AnotB.html#setA-org.apache.datasketches.tuple.Sketch-"><code>setA(Sketch)</code></a>, |
| <a href="../../../../org/apache/datasketches/tuple/AnotB.html#notB-org.apache.datasketches.tuple.Sketch-"><code>notB(Sketch)</code></a>, <a href="../../../../org/apache/datasketches/tuple/AnotB.html#notB-org.apache.datasketches.theta.Sketch-"><code>notB(org.apache.datasketches.theta.Sketch)</code></a>, and |
| <a href="../../../../org/apache/datasketches/tuple/AnotB.html#getResult-boolean-"><code>getResult(boolean)</code></a> methods.</p> |
| |
| <p>If either argument is null an exception is thrown.</p> |
| |
| <p>Rationale: In mathematics a "null set" is a set with no members, which we call an empty set. |
| That is distinctly different from the java <i>null</i>, which represents a nonexistent object. |
| In most cases it is a programming error due to some object that was not properly initialized. |
| With a null as the first argument, we cannot know what the user's intent is. |
| With a null as the second argument, we can't ignore it as we must return a result and there is |
| no following possible viable arguments for the second argument. |
| Since it is very likely that a <i>null</i> is a programming error, we throw an exception.</p></div> |
| <dl> |
| <dt><span class="paramLabel">Type Parameters:</span></dt> |
| <dd><code>S</code> - Type of Summary</dd> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>skA</code> - The incoming Tuple sketch for the first argument</dd> |
| <dd><code>skB</code> - The incoming Tuple sketch for the second argument</dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>the result as an unordered <a href="../../../../org/apache/datasketches/tuple/CompactSketch.html" title="class in org.apache.datasketches.tuple"><code>CompactSketch</code></a></dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="aNotB-org.apache.datasketches.tuple.Sketch-org.apache.datasketches.theta.Sketch-"> |
| <!-- --> |
| </a> |
| <ul class="blockListLast"> |
| <li class="blockList"> |
| <h4>aNotB</h4> |
| <pre>public static <S extends <a href="../../../../org/apache/datasketches/tuple/Summary.html" title="interface in org.apache.datasketches.tuple">Summary</a>> <a href="../../../../org/apache/datasketches/tuple/CompactSketch.html" title="class in org.apache.datasketches.tuple">CompactSketch</a><S> aNotB​(<a href="../../../../org/apache/datasketches/tuple/Sketch.html" title="class in org.apache.datasketches.tuple">Sketch</a><S> skA, |
| <a href="../../../../org/apache/datasketches/theta/Sketch.html" title="class in org.apache.datasketches.theta">Sketch</a> skB)</pre> |
| <div class="block">Returns the A-and-not-B set operation on a Tuple sketch and a Theta sketch. |
| |
| <p>This a stateless operation and has no impact on the internal state of this operator. |
| Thus, this is not an accumulating update and is independent of the <a href="../../../../org/apache/datasketches/tuple/AnotB.html#setA-org.apache.datasketches.tuple.Sketch-"><code>setA(Sketch)</code></a>, |
| <a href="../../../../org/apache/datasketches/tuple/AnotB.html#notB-org.apache.datasketches.tuple.Sketch-"><code>notB(Sketch)</code></a>, <a href="../../../../org/apache/datasketches/tuple/AnotB.html#notB-org.apache.datasketches.theta.Sketch-"><code>notB(org.apache.datasketches.theta.Sketch)</code></a>, and |
| <a href="../../../../org/apache/datasketches/tuple/AnotB.html#getResult-boolean-"><code>getResult(boolean)</code></a> methods.</p> |
| |
| <p>If either argument is null an exception is thrown.</p> |
| |
| <p>Rationale: In mathematics a "null set" is a set with no members, which we call an empty set. |
| That is distinctly different from the java <i>null</i>, which represents a nonexistent object. |
| In most cases it is a programming error due to some object that was not properly initialized. |
| With a null as the first argument, we cannot know what the user's intent is. |
| With a null as the second argument, we can't ignore it as we must return a result and there is |
| no following possible viable arguments for the second argument. |
| Since it is very likely that a <i>null</i> is a programming error for either argument |
| we throw a an exception.</p></div> |
| <dl> |
| <dt><span class="paramLabel">Type Parameters:</span></dt> |
| <dd><code>S</code> - Type of Summary</dd> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>skA</code> - The incoming Tuple sketch for the first argument</dd> |
| <dd><code>skB</code> - The incoming Theta sketch for the second argument</dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>the result as an unordered <a href="../../../../org/apache/datasketches/tuple/CompactSketch.html" title="class in org.apache.datasketches.tuple"><code>CompactSketch</code></a></dd> |
| </dl> |
| </li> |
| </ul> |
| </li> |
| </ul> |
| </li> |
| </ul> |
| </div> |
| </div> |
| <!-- ========= END OF CLASS DATA ========= --> |
| <!-- ======= START OF BOTTOM NAVBAR ====== --> |
| <div class="bottomNav"><a name="navbar.bottom"> |
| <!-- --> |
| </a> |
| <div class="skipNav"><a href="#skip.navbar.bottom" title="Skip navigation links">Skip navigation links</a></div> |
| <a name="navbar.bottom.firstrow"> |
| <!-- --> |
| </a> |
| <ul class="navList" title="Navigation"> |
| <li><a href="../../../../overview-summary.html">Overview</a></li> |
| <li><a href="package-summary.html">Package</a></li> |
| <li class="navBarCell1Rev">Class</li> |
| <li><a href="class-use/AnotB.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"> |
| <li>Prev Class</li> |
| <li><a href="../../../../org/apache/datasketches/tuple/CompactSketch.html" title="class in org.apache.datasketches.tuple"><span class="typeNameLink">Next Class</span></a></li> |
| </ul> |
| <ul class="navList"> |
| <li><a href="../../../../index.html?org/apache/datasketches/tuple/AnotB.html" target="_top">Frames</a></li> |
| <li><a href="AnotB.html" target="_top">No Frames</a></li> |
| </ul> |
| <ul class="navList" id="allclasses_navbar_bottom"> |
| <li><a href="../../../../allclasses-noframe.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>Field | </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>Field | </li> |
| <li><a href="#constructor.detail">Constr</a> | </li> |
| <li><a href="#method.detail">Method</a></li> |
| </ul> |
| </div> |
| <a name="skip.navbar.bottom"> |
| <!-- --> |
| </a></div> |
| <!-- ======== END OF BOTTOM NAVBAR ======= --> |
| <p class="legalCopy"><small>Copyright © 2015–2021 <a href="https://www.apache.org/">The Apache Software Foundation</a>. All rights reserved.</small></p> |
| </body> |
| </html> |