blob: 55fb6a4bf7332744d2f05457f5ca1cd8b1dbe702 [file] [log] [blame]
<!DOCTYPE HTML>
<!-- NewPage -->
<html lang="en">
<head>
<!-- Generated by javadoc (11.0.11) on Mon Jun 14 16:40:44 EDT 2021 -->
<title>AtomicBiInteger (Eclipse Jetty API Doc - v10.0.5)</title>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<meta name="dc.created" content="2021-06-14">
<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-3.5.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="AtomicBiInteger (Eclipse Jetty API Doc - v10.0.5)";
}
}
catch(err) {
}
//-->
var data = {"i0":10,"i1":10,"i2":10,"i3":10,"i4":10,"i5":10,"i6":10,"i7":9,"i8":9,"i9":9,"i10":10,"i11":10,"i12":10,"i13":9,"i14":10,"i15":9,"i16":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 = true;
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/AtomicBiInteger.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&nbsp;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:&nbsp;</li>
<li>Nested&nbsp;|&nbsp;</li>
<li>Field&nbsp;|&nbsp;</li>
<li><a href="#constructor.summary">Constr</a>&nbsp;|&nbsp;</li>
<li><a href="#method.summary">Method</a></li>
</ul>
<ul class="subNavList">
<li>Detail:&nbsp;</li>
<li>Field&nbsp;|&nbsp;</li>
<li><a href="#constructor.detail">Constr</a>&nbsp;|&nbsp;</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">&nbsp;</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>&nbsp;<a href="package-summary.html">org.eclipse.jetty.util</a></div>
<h2 title="Class AtomicBiInteger" class="title">Class AtomicBiInteger</h2>
</div>
<div class="contentContainer">
<ul class="inheritance">
<li>java.lang.Object</li>
<li>
<ul class="inheritance">
<li>java.lang.Number</li>
<li>
<ul class="inheritance">
<li>java.util.concurrent.atomic.AtomicLong</li>
<li>
<ul class="inheritance">
<li>org.eclipse.jetty.util.AtomicBiInteger</li>
</ul>
</li>
</ul>
</li>
</ul>
</li>
</ul>
<div class="description">
<ul class="blockList">
<li class="blockList">
<dl>
<dt>All Implemented Interfaces:</dt>
<dd><code>java.io.Serializable</code></dd>
</dl>
<hr>
<pre>public class <span class="typeNameLabel">AtomicBiInteger</span>
extends java.util.concurrent.atomic.AtomicLong</pre>
<div class="block">An AtomicLong with additional methods to treat it as two hi/lo integers.</div>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../../serialized-form.html#org.eclipse.jetty.util.AtomicBiInteger">Serialized Form</a></dd>
</dl>
</li>
</ul>
</div>
<div class="summary">
<ul class="blockList">
<li class="blockList">
<!-- ======== 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">&nbsp;</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="#%3Cinit%3E()">AtomicBiInteger</a></span>()</code></th>
<td class="colLast">&nbsp;</td>
</tr>
<tr class="rowColor">
<th class="colConstructorName" scope="row"><code><span class="memberNameLink"><a href="#%3Cinit%3E(int,int)">AtomicBiInteger</a></span>&#8203;(int&nbsp;hi,
int&nbsp;lo)</code></th>
<td class="colLast">&nbsp;</td>
</tr>
<tr class="altColor">
<th class="colConstructorName" scope="row"><code><span class="memberNameLink"><a href="#%3Cinit%3E(long)">AtomicBiInteger</a></span>&#8203;(long&nbsp;encoded)</code></th>
<td class="colLast">&nbsp;</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">&nbsp;</span></span><span id="t1" class="tableTab"><span><a href="javascript:show(1);">Static Methods</a></span><span class="tabEnd">&nbsp;</span></span><span id="t2" class="tableTab"><span><a href="javascript:show(2);">Instance Methods</a></span><span class="tabEnd">&nbsp;</span></span><span id="t4" class="tableTab"><span><a href="javascript:show(8);">Concrete Methods</a></span><span class="tabEnd">&nbsp;</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>void</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#add(int,int)">add</a></span>&#8203;(int&nbsp;deltaHi,
int&nbsp;deltaLo)</code></th>
<td class="colLast">
<div class="block">Atomically adds the given deltas to the current hi and lo values.</div>
</td>
</tr>
<tr id="i1" class="rowColor">
<td class="colFirst"><code>int</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#addAndGetHi(int)">addAndGetHi</a></span>&#8203;(int&nbsp;delta)</code></th>
<td class="colLast">
<div class="block">Atomically adds the given delta to the current hi value, returning the updated hi value.</div>
</td>
</tr>
<tr id="i2" class="altColor">
<td class="colFirst"><code>int</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#addAndGetLo(int)">addAndGetLo</a></span>&#8203;(int&nbsp;delta)</code></th>
<td class="colLast">
<div class="block">Atomically adds the given delta to the current lo value, returning the updated lo value.</div>
</td>
</tr>
<tr id="i3" class="rowColor">
<td class="colFirst"><code>boolean</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#compareAndSet(int,int,int,int)">compareAndSet</a></span>&#8203;(int&nbsp;expectHi,
int&nbsp;hi,
int&nbsp;expectLo,
int&nbsp;lo)</code></th>
<td class="colLast">
<div class="block">Atomically sets the hi and lo values to the given updated values only if
the current hi and lo values <code>==</code> the expected hi and lo values.</div>
</td>
</tr>
<tr id="i4" class="altColor">
<td class="colFirst"><code>boolean</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#compareAndSet(long,int,int)">compareAndSet</a></span>&#8203;(long&nbsp;encoded,
int&nbsp;hi,
int&nbsp;lo)</code></th>
<td class="colLast">
<div class="block">Atomically sets the values to the given updated values only if
the current encoded value <code>==</code> the expected encoded value.</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="#compareAndSetHi(int,int)">compareAndSetHi</a></span>&#8203;(int&nbsp;expectHi,
int&nbsp;hi)</code></th>
<td class="colLast">
<div class="block">Atomically sets the hi value to the given updated value
only if the current value <code>==</code> the expected value.</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="#compareAndSetLo(int,int)">compareAndSetLo</a></span>&#8203;(int&nbsp;expectLo,
int&nbsp;lo)</code></th>
<td class="colLast">
<div class="block">Atomically sets the lo value to the given updated value
only if the current value <code>==</code> the expected value.</div>
</td>
</tr>
<tr id="i7" class="rowColor">
<td class="colFirst"><code>static long</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#encode(int,int)">encode</a></span>&#8203;(int&nbsp;hi,
int&nbsp;lo)</code></th>
<td class="colLast">
<div class="block">Encodes hi and lo values into a long.</div>
</td>
</tr>
<tr id="i8" class="altColor">
<td class="colFirst"><code>static long</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#encodeHi(long,int)">encodeHi</a></span>&#8203;(long&nbsp;encoded,
int&nbsp;hi)</code></th>
<td class="colLast">
<div class="block">Sets the hi value into the given encoded value.</div>
</td>
</tr>
<tr id="i9" class="rowColor">
<td class="colFirst"><code>static long</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#encodeLo(long,int)">encodeLo</a></span>&#8203;(long&nbsp;encoded,
int&nbsp;lo)</code></th>
<td class="colLast">
<div class="block">Sets the lo value into the given encoded value.</div>
</td>
</tr>
<tr id="i10" class="altColor">
<td class="colFirst"><code>int</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#getAndSetHi(int)">getAndSetHi</a></span>&#8203;(int&nbsp;hi)</code></th>
<td class="colLast">
<div class="block">Atomically sets the hi value without changing the lo value.</div>
</td>
</tr>
<tr id="i11" class="rowColor">
<td class="colFirst"><code>int</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#getAndSetLo(int)">getAndSetLo</a></span>&#8203;(int&nbsp;lo)</code></th>
<td class="colLast">
<div class="block">Atomically sets the lo value without changing the hi value.</div>
</td>
</tr>
<tr id="i12" class="altColor">
<td class="colFirst"><code>int</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#getHi()">getHi</a></span>()</code></th>
<td class="colLast">&nbsp;</td>
</tr>
<tr id="i13" class="rowColor">
<td class="colFirst"><code>static int</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#getHi(long)">getHi</a></span>&#8203;(long&nbsp;encoded)</code></th>
<td class="colLast">
<div class="block">Gets a hi value from the given encoded value.</div>
</td>
</tr>
<tr id="i14" class="altColor">
<td class="colFirst"><code>int</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#getLo()">getLo</a></span>()</code></th>
<td class="colLast">&nbsp;</td>
</tr>
<tr id="i15" class="rowColor">
<td class="colFirst"><code>static int</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#getLo(long)">getLo</a></span>&#8203;(long&nbsp;encoded)</code></th>
<td class="colLast">
<div class="block">Gets a lo value from the given encoded value.</div>
</td>
</tr>
<tr id="i16" class="altColor">
<td class="colFirst"><code>void</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#set(int,int)">set</a></span>&#8203;(int&nbsp;hi,
int&nbsp;lo)</code></th>
<td class="colLast">
<div class="block">Sets the hi and lo values.</div>
</td>
</tr>
</table>
<ul class="blockList">
<li class="blockList"><a id="methods.inherited.from.class.java.util.concurrent.atomic.AtomicLong">
<!-- -->
</a>
<h3>Methods inherited from class&nbsp;java.util.concurrent.atomic.AtomicLong</h3>
<code>accumulateAndGet, addAndGet, compareAndExchange, compareAndExchangeAcquire, compareAndExchangeRelease, compareAndSet, decrementAndGet, doubleValue, floatValue, get, getAcquire, getAndAccumulate, getAndAdd, getAndDecrement, getAndIncrement, getAndSet, getAndUpdate, getOpaque, getPlain, incrementAndGet, intValue, lazySet, longValue, set, setOpaque, setPlain, setRelease, toString, updateAndGet, weakCompareAndSet, weakCompareAndSetAcquire, weakCompareAndSetPlain, weakCompareAndSetRelease, weakCompareAndSetVolatile</code></li>
</ul>
<ul class="blockList">
<li class="blockList"><a id="methods.inherited.from.class.java.lang.Number">
<!-- -->
</a>
<h3>Methods inherited from class&nbsp;java.lang.Number</h3>
<code>byteValue, shortValue</code></li>
</ul>
<ul class="blockList">
<li class="blockList"><a id="methods.inherited.from.class.java.lang.Object">
<!-- -->
</a>
<h3>Methods inherited from class&nbsp;java.lang.Object</h3>
<code>clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait</code></li>
</ul>
</li>
</ul>
</section>
</li>
</ul>
</div>
<div class="details">
<ul class="blockList">
<li class="blockList">
<!-- ========= CONSTRUCTOR DETAIL ======== -->
<section role="region">
<ul class="blockList">
<li class="blockList"><a id="constructor.detail">
<!-- -->
</a>
<h3>Constructor Detail</h3>
<a id="&lt;init&gt;()">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>AtomicBiInteger</h4>
<pre>public&nbsp;AtomicBiInteger()</pre>
</li>
</ul>
<a id="&lt;init&gt;(long)">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>AtomicBiInteger</h4>
<pre>public&nbsp;AtomicBiInteger&#8203;(long&nbsp;encoded)</pre>
</li>
</ul>
<a id="&lt;init&gt;(int,int)">
<!-- -->
</a>
<ul class="blockListLast">
<li class="blockList">
<h4>AtomicBiInteger</h4>
<pre>public&nbsp;AtomicBiInteger&#8203;(int&nbsp;hi,
int&nbsp;lo)</pre>
</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="getHi()">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getHi</h4>
<pre class="methodSignature">public&nbsp;int&nbsp;getHi()</pre>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>the hi value</dd>
</dl>
</li>
</ul>
<a id="getHi(long)">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getHi</h4>
<pre class="methodSignature">public static&nbsp;int&nbsp;getHi&#8203;(long&nbsp;encoded)</pre>
<div class="block">Gets a hi value from the given encoded value.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>encoded</code> - the encoded value</dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>the hi value</dd>
</dl>
</li>
</ul>
<a id="getLo()">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getLo</h4>
<pre class="methodSignature">public&nbsp;int&nbsp;getLo()</pre>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>the lo value</dd>
</dl>
</li>
</ul>
<a id="getLo(long)">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getLo</h4>
<pre class="methodSignature">public static&nbsp;int&nbsp;getLo&#8203;(long&nbsp;encoded)</pre>
<div class="block">Gets a lo value from the given encoded value.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>encoded</code> - the encoded value</dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>the lo value</dd>
</dl>
</li>
</ul>
<a id="getAndSetHi(int)">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getAndSetHi</h4>
<pre class="methodSignature">public&nbsp;int&nbsp;getAndSetHi&#8203;(int&nbsp;hi)</pre>
<div class="block">Atomically sets the hi value without changing the lo value.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>hi</code> - the new hi value</dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>the previous hi value</dd>
</dl>
</li>
</ul>
<a id="getAndSetLo(int)">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getAndSetLo</h4>
<pre class="methodSignature">public&nbsp;int&nbsp;getAndSetLo&#8203;(int&nbsp;lo)</pre>
<div class="block">Atomically sets the lo value without changing the hi value.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>lo</code> - the new lo value</dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>the previous lo value</dd>
</dl>
</li>
</ul>
<a id="set(int,int)">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>set</h4>
<pre class="methodSignature">public&nbsp;void&nbsp;set&#8203;(int&nbsp;hi,
int&nbsp;lo)</pre>
<div class="block">Sets the hi and lo values.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>hi</code> - the new hi value</dd>
<dd><code>lo</code> - the new lo value</dd>
</dl>
</li>
</ul>
<a id="compareAndSetHi(int,int)">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>compareAndSetHi</h4>
<pre class="methodSignature">public&nbsp;boolean&nbsp;compareAndSetHi&#8203;(int&nbsp;expectHi,
int&nbsp;hi)</pre>
<div class="block"><p>Atomically sets the hi value to the given updated value
only if the current value <code>==</code> the expected value.</p>
<p>Concurrent changes to the lo value result in a retry.</p></div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>expectHi</code> - the expected hi value</dd>
<dd><code>hi</code> - the new hi value</dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd><code>true</code> if successful. False return indicates that
the actual hi value was not equal to the expected hi value.</dd>
</dl>
</li>
</ul>
<a id="compareAndSetLo(int,int)">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>compareAndSetLo</h4>
<pre class="methodSignature">public&nbsp;boolean&nbsp;compareAndSetLo&#8203;(int&nbsp;expectLo,
int&nbsp;lo)</pre>
<div class="block"><p>Atomically sets the lo value to the given updated value
only if the current value <code>==</code> the expected value.</p>
<p>Concurrent changes to the hi value result in a retry.</p></div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>expectLo</code> - the expected lo value</dd>
<dd><code>lo</code> - the new lo value</dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd><code>true</code> if successful. False return indicates that
the actual lo value was not equal to the expected lo value.</dd>
</dl>
</li>
</ul>
<a id="compareAndSet(long,int,int)">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>compareAndSet</h4>
<pre class="methodSignature">public&nbsp;boolean&nbsp;compareAndSet&#8203;(long&nbsp;encoded,
int&nbsp;hi,
int&nbsp;lo)</pre>
<div class="block">Atomically sets the values to the given updated values only if
the current encoded value <code>==</code> the expected encoded value.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>encoded</code> - the expected encoded value</dd>
<dd><code>hi</code> - the new hi value</dd>
<dd><code>lo</code> - the new lo value</dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd><code>true</code> if successful. False return indicates that
the actual encoded value was not equal to the expected encoded value.</dd>
</dl>
</li>
</ul>
<a id="compareAndSet(int,int,int,int)">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>compareAndSet</h4>
<pre class="methodSignature">public&nbsp;boolean&nbsp;compareAndSet&#8203;(int&nbsp;expectHi,
int&nbsp;hi,
int&nbsp;expectLo,
int&nbsp;lo)</pre>
<div class="block">Atomically sets the hi and lo values to the given updated values only if
the current hi and lo values <code>==</code> the expected hi and lo values.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>expectHi</code> - the expected hi value</dd>
<dd><code>hi</code> - the new hi value</dd>
<dd><code>expectLo</code> - the expected lo value</dd>
<dd><code>lo</code> - the new lo value</dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd><code>true</code> if successful. False return indicates that
the actual hi and lo values were not equal to the expected hi and lo value.</dd>
</dl>
</li>
</ul>
<a id="addAndGetHi(int)">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>addAndGetHi</h4>
<pre class="methodSignature">public&nbsp;int&nbsp;addAndGetHi&#8203;(int&nbsp;delta)</pre>
<div class="block">Atomically adds the given delta to the current hi value, returning the updated hi value.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>delta</code> - the delta to apply</dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>the updated hi value</dd>
</dl>
</li>
</ul>
<a id="addAndGetLo(int)">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>addAndGetLo</h4>
<pre class="methodSignature">public&nbsp;int&nbsp;addAndGetLo&#8203;(int&nbsp;delta)</pre>
<div class="block">Atomically adds the given delta to the current lo value, returning the updated lo value.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>delta</code> - the delta to apply</dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>the updated lo value</dd>
</dl>
</li>
</ul>
<a id="add(int,int)">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>add</h4>
<pre class="methodSignature">public&nbsp;void&nbsp;add&#8203;(int&nbsp;deltaHi,
int&nbsp;deltaLo)</pre>
<div class="block">Atomically adds the given deltas to the current hi and lo values.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>deltaHi</code> - the delta to apply to the hi value</dd>
<dd><code>deltaLo</code> - the delta to apply to the lo value</dd>
</dl>
</li>
</ul>
<a id="encode(int,int)">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>encode</h4>
<pre class="methodSignature">public static&nbsp;long&nbsp;encode&#8203;(int&nbsp;hi,
int&nbsp;lo)</pre>
<div class="block">Encodes hi and lo values into a long.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>hi</code> - the hi value</dd>
<dd><code>lo</code> - the lo value</dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>the encoded value</dd>
</dl>
</li>
</ul>
<a id="encodeHi(long,int)">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>encodeHi</h4>
<pre class="methodSignature">public static&nbsp;long&nbsp;encodeHi&#8203;(long&nbsp;encoded,
int&nbsp;hi)</pre>
<div class="block">Sets the hi value into the given encoded value.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>encoded</code> - the encoded value</dd>
<dd><code>hi</code> - the hi value</dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>the new encoded value</dd>
</dl>
</li>
</ul>
<a id="encodeLo(long,int)">
<!-- -->
</a>
<ul class="blockListLast">
<li class="blockList">
<h4>encodeLo</h4>
<pre class="methodSignature">public static&nbsp;long&nbsp;encodeLo&#8203;(long&nbsp;encoded,
int&nbsp;lo)</pre>
<div class="block">Sets the lo value into the given encoded value.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>encoded</code> - the encoded value</dd>
<dd><code>lo</code> - the lo value</dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>the new encoded value</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/AtomicBiInteger.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&nbsp;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:&nbsp;</li>
<li>Nested&nbsp;|&nbsp;</li>
<li>Field&nbsp;|&nbsp;</li>
<li><a href="#constructor.summary">Constr</a>&nbsp;|&nbsp;</li>
<li><a href="#method.summary">Method</a></li>
</ul>
<ul class="subNavList">
<li>Detail:&nbsp;</li>
<li>Field&nbsp;|&nbsp;</li>
<li><a href="#constructor.detail">Constr</a>&nbsp;|&nbsp;</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 &#169; 1995&#x2013;2021 <a href="https://webtide.com">Webtide</a>. All rights reserved.</small></p>
</footer>
</body>
</html>