blob: 4f31cde3de6bdb77a39aa79af1f662a91797e30d [file] [log] [blame]
<!DOCTYPE HTML>
<!-- NewPage -->
<html lang="en">
<head>
<!-- Generated by javadoc -->
<title>FluentLongAssertion (Apache Juneau 9.0.0)</title>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<meta name="description" content="declaration: package: org.apache.juneau.assertions, class: FluentLongAssertion">
<meta name="generator" content="javadoc/ClassWriterImpl">
<link rel="stylesheet" type="text/css" href="../../../../javadoc.css" title="Style">
<link rel="stylesheet" type="text/css" href="../../../../script-dir/jquery-ui.css" title="Style">
<script type="text/javascript" src="../../../../script.js"></script>
<script type="text/javascript" src="../../../../script-dir/jszip/dist/jszip.min.js"></script>
<script type="text/javascript" src="../../../../script-dir/jszip-utils/dist/jszip-utils.min.js"></script>
<!--[if IE]>
<script type="text/javascript" src="../../../../script-dir/jszip-utils/dist/jszip-utils-ie.min.js"></script>
<![endif]-->
<script type="text/javascript" src="../../../../script-dir/jquery-3.4.1.js"></script>
<script type="text/javascript" src="../../../../script-dir/jquery-ui.js"></script>
</head>
<body class="class-declaration">
<script type="text/javascript">var data = {"i0":10,"i1":10,"i2":10,"i3":10,"i4":10,"i5":10};
var tabs = {65535:["t0","All 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="flexBox">
<header role="banner" class="flexHeader">
<nav role="navigation">
<!-- ========= 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="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">
<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>
<div class="navListSearch"><label for="search">SEARCH:</label>
<input type="text" id="search" value="search" disabled="disabled">
<input type="reset" id="reset" value="reset" disabled="disabled">
</div>
</div>
<!-- ========= END OF TOP NAVBAR ========= -->
<div class="skipNav"><a id="skip.navbar.top">
<!-- -->
</a></div>
</nav>
</header>
<div class="flexContent">
<main role="main">
<!-- ======== START OF CLASS DATA ======== -->
<div class="header">
<div class="subTitle"><span class="packageLabelInType">Package</span>&nbsp;<a href="package-summary.html">org.apache.juneau.assertions</a></div>
<h1 title="Class FluentLongAssertion" class="title">Class FluentLongAssertion&lt;R&gt;</h1>
</div>
<div class="contentContainer">
<div class="inheritance" title="Inheritance Tree">java.lang.Object
<div class="inheritance"><a href="Assertion.html" title="class in org.apache.juneau.assertions">org.apache.juneau.assertions.Assertion</a>
<div class="inheritance"><a href="FluentAssertion.html" title="class in org.apache.juneau.assertions">org.apache.juneau.assertions.FluentAssertion</a>&lt;R&gt;
<div class="inheritance"><a href="FluentObjectAssertion.html" title="class in org.apache.juneau.assertions">org.apache.juneau.assertions.FluentObjectAssertion</a>&lt;T,&#8203;R&gt;
<div class="inheritance"><a href="FluentComparableAssertion.html" title="class in org.apache.juneau.assertions">org.apache.juneau.assertions.FluentComparableAssertion</a>&lt;java.lang.Long,&#8203;R&gt;
<div class="inheritance">org.apache.juneau.assertions.FluentLongAssertion&lt;R&gt;</div>
</div>
</div>
</div>
</div>
</div>
<section class="description">
<dl>
<dt><span class="paramLabel">Type Parameters:</span></dt>
<dd><code>R</code> - The return type.</dd>
</dl>
<dl>
<dt>Direct Known Subclasses:</dt>
<dd><code><a href="LongAssertion.html" title="class in org.apache.juneau.assertions">LongAssertion</a></code></dd>
</dl>
<hr>
<pre>public class <a href="../../../../src-html/org/apache/juneau/assertions/FluentLongAssertion.html#line.105">FluentLongAssertion</a>&lt;R&gt;
extends <a href="FluentComparableAssertion.html" title="class in org.apache.juneau.assertions">FluentComparableAssertion</a>&lt;java.lang.Long,&#8203;R&gt;</pre>
<div class="block">Used for fluent assertion calls against longs.
<h5 class='section'>Example:</h5>
<p class='bjava'>
<jc>// Validates the response length isn't too long.</jc>
<jv>client</jv>
.get(<jsf>URL</jsf>)
.run()
.assertLongHeader(<js>"Length"</js>).isLessThan(100000);
</p>
<h5 class='topic'>Test Methods</h5>
<p>
<ul class='javatree'>
<li class='jc'><a href="FluentComparableAssertion.html" title="class in org.apache.juneau.assertions"><code>FluentComparableAssertion</code></a>
<ul class='javatreec'>
<li class='jm'><a href="FluentComparableAssertion.html#isGt(java.lang.Comparable)"><code>isGt(Comparable)</code></a>
<li class='jm'><a href="FluentComparableAssertion.html#isGte(java.lang.Comparable)"><code>isGte(Comparable)</code></a>
<li class='jm'><a href="FluentComparableAssertion.html#isLt(java.lang.Comparable)"><code>isLt(Comparable)</code></a>
<li class='jm'><a href="FluentComparableAssertion.html#isLte(java.lang.Comparable)"><code>isLte(Comparable)</code></a>
<li class='jm'><a href="FluentComparableAssertion.html#isBetween(java.lang.Comparable,java.lang.Comparable)"><code>isBetween(Comparable,Comparable)</code></a>
</ul>
<li class='jc'><a href="FluentObjectAssertion.html" title="class in org.apache.juneau.assertions"><code>FluentObjectAssertion</code></a>
<ul class='javatreec'>
<li class='jm'><a href="FluentObjectAssertion.html#isExists()"><code>isExists()</code></a>
<li class='jm'><a href="FluentObjectAssertion.html#is(T)"><code>is(Object)</code></a>
<li class='jm'><a href="FluentObjectAssertion.html#is(java.util.function.Predicate)"><code>is(Predicate)</code></a>
<li class='jm'><a href="FluentObjectAssertion.html#isNot(T)"><code>isNot(Object)</code></a>
<li class='jm'><a href="FluentObjectAssertion.html#isAny(T...)"><code>isAny(Object...)</code></a>
<li class='jm'><a href="FluentObjectAssertion.html#isNotAny(T...)"><code>isNotAny(Object...)</code></a>
<li class='jm'><a href="FluentObjectAssertion.html#isNull()"><code>isNull()</code></a>
<li class='jm'><a href="FluentObjectAssertion.html#isNotNull()"><code>isNotNull()</code></a>
<li class='jm'><a href="FluentObjectAssertion.html#isString(java.lang.String)"><code>isString(String)</code></a>
<li class='jm'><a href="FluentObjectAssertion.html#isJson(java.lang.String)"><code>isJson(String)</code></a>
<li class='jm'><a href="FluentObjectAssertion.html#isSame(T)"><code>isSame(Object)</code></a>
<li class='jm'><a href="FluentObjectAssertion.html#isSameJsonAs(java.lang.Object)"><code>isSameJsonAs(Object)</code></a>
<li class='jm'><a href="FluentObjectAssertion.html#isSameSortedJsonAs(java.lang.Object)"><code>isSameSortedJsonAs(Object)</code></a>
<li class='jm'><a href="FluentObjectAssertion.html#isSameSerializedAs(java.lang.Object,org.apache.juneau.serializer.WriterSerializer)"><code>isSameSerializedAs(Object, WriterSerializer)</code></a>
<li class='jm'><a href="FluentObjectAssertion.html#isType(java.lang.Class)"><code>isType(Class)</code></a>
<li class='jm'><a href="FluentObjectAssertion.html#isExactType(java.lang.Class)"><code>isExactType(Class)</code></a>
</ul>
</ul>
<h5 class='topic'>Transform Methods</h5>
<p>
<ul class='javatree'>
<li class='jc'><a href="FluentLongAssertion.html" title="class in org.apache.juneau.assertions"><code>FluentLongAssertion</code></a>
<ul class='javatreec'>
<li class='jm'><a href="#asInteger()"><code>asInteger()</code></a>
</ul>
<li class='jc'><a href="FluentObjectAssertion.html" title="class in org.apache.juneau.assertions"><code>FluentObjectAssertion</code></a>
<ul class='javatreec'>
<li class='jm'><a href="FluentObjectAssertion.html#asString()"><code>asString()</code></a>
<li class='jm'><a href="FluentObjectAssertion.html#asString(org.apache.juneau.serializer.WriterSerializer)"><code>asString(WriterSerializer)</code></a>
<li class='jm'><a href="FluentObjectAssertion.html#asString(java.util.function.Function)"><code>asString(Function)</code></a>
<li class='jm'><a href="FluentObjectAssertion.html#asJson()"><code>asJson()</code></a>
<li class='jm'><a href="FluentObjectAssertion.html#asJsonSorted()"><code>asJsonSorted()</code></a>
<li class='jm'><a href="FluentObjectAssertion.html#asTransformed(java.util.function.Function)"><code>asApplied(Function)</code></a>
<li class='jm'><a href="FluentObjectAssertion.html#asAny()"><code>asAny()</code></a>
</ul>
</ul>
<h5 class='topic'>Configuration Methods</h5>
<p>
<ul class='javatree'>
<li class='jc'><a href="Assertion.html" title="class in org.apache.juneau.assertions"><code>Assertion</code></a>
<ul class='javatreec'>
<li class='jm'><a href="Assertion.html#setMsg(java.lang.String,java.lang.Object...)"><code>setMsg(String, Object...)</code></a>
<li class='jm'><a href="Assertion.html#setOut(java.io.PrintStream)"><code>setOut(PrintStream)</code></a>
<li class='jm'><a href="Assertion.html#setSilent()"><code>setSilent()</code></a>
<li class='jm'><a href="Assertion.html#setStdOut()"><code>setStdOut()</code></a>
<li class='jm'><a href="Assertion.html#setThrowable(java.lang.Class)"><code>setThrowable(Class)</code></a>
</ul>
</ul>
<ul class='seealso'>
<li class='link'><a class="doclink" href="../../../../overview-summary.html#juneau-assertions.ja.Overview">Overview &gt; juneau-assertions &gt; Overview</a>
</ul></div>
</section>
<section class="summary">
<ul class="blockList">
<!-- ======== CONSTRUCTOR SUMMARY ======== -->
<li class="blockList">
<section class="constructorSummary"><a id="constructor.summary">
<!-- -->
</a>
<h2>Constructor Summary</h2>
<div class="memberSummary">
<table>
<caption><span>Constructors</span><span class="tabEnd">&nbsp;</span></caption>
<thead>
<tr>
<th class="colFirst" scope="col">Constructor</th>
<th class="colLast" scope="col">Description</th>
</tr>
</thead>
<tbody>
<tr class="altColor">
<th class="colConstructorName" scope="row"><code><span class="memberNameLink"><a href="#%3Cinit%3E(java.lang.Long,R)">FluentLongAssertion</a></span>&#8203;(java.lang.Long&nbsp;value,
<a href="FluentLongAssertion.html" title="type parameter in FluentLongAssertion">R</a>&nbsp;returns)</code></th>
<td class="colLast">
<div class="block">Constructor.</div>
</td>
</tr>
<tr class="rowColor">
<th class="colConstructorName" scope="row"><code><span class="memberNameLink"><a href="#%3Cinit%3E(org.apache.juneau.assertions.Assertion,java.lang.Long,R)">FluentLongAssertion</a></span>&#8203;(<a href="Assertion.html" title="class in org.apache.juneau.assertions">Assertion</a>&nbsp;creator,
java.lang.Long&nbsp;value,
<a href="FluentLongAssertion.html" title="type parameter in FluentLongAssertion">R</a>&nbsp;returns)</code></th>
<td class="colLast">
<div class="block">Chained constructor.</div>
</td>
</tr>
</tbody>
</table>
</div>
</section>
</li>
<!-- ========== METHOD SUMMARY =========== -->
<li class="blockList">
<section class="methodSummary"><a id="method.summary">
<!-- -->
</a>
<h2>Method Summary</h2>
<div class="memberSummary">
<div role="tablist" aria-orientation="horizontal"><button role="tab" aria-selected="true" aria-controls="memberSummary_tabpanel" tabindex="0" onkeydown="switchTab(event)" id="t0" class="activeTableTab">All Methods</button><button role="tab" aria-selected="false" aria-controls="memberSummary_tabpanel" tabindex="-1" onkeydown="switchTab(event)" id="t2" class="tableTab" onclick="show(2);">Instance Methods</button><button role="tab" aria-selected="false" aria-controls="memberSummary_tabpanel" tabindex="-1" onkeydown="switchTab(event)" id="t4" class="tableTab" onclick="show(8);">Concrete Methods</button></div>
<div id="memberSummary_tabpanel" role="tabpanel">
<table aria-labelledby="t0">
<thead>
<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>
</thead>
<tbody>
<tr class="altColor" id="i0">
<td class="colFirst"><code><a href="FluentIntegerAssertion.html" title="class in org.apache.juneau.assertions">FluentIntegerAssertion</a>&lt;<a href="FluentLongAssertion.html" title="type parameter in FluentLongAssertion">R</a>&gt;</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#asInteger()">asInteger</a></span>()</code></th>
<td class="colLast">
<div class="block">Converts this long into an integer and then returns it as an integer assertion.</div>
</td>
</tr>
<tr class="rowColor" id="i1">
<td class="colFirst"><code><a href="FluentLongAssertion.html" title="class in org.apache.juneau.assertions">FluentLongAssertion</a>&lt;<a href="FluentLongAssertion.html" title="type parameter in FluentLongAssertion">R</a>&gt;</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#setMsg(java.lang.String,java.lang.Object...)">setMsg</a></span>&#8203;(java.lang.String&nbsp;msg,
java.lang.Object...&nbsp;args)</code></th>
<td class="colLast">
<div class="block">Allows you to override the assertion failure message.</div>
</td>
</tr>
<tr class="altColor" id="i2">
<td class="colFirst"><code><a href="FluentLongAssertion.html" title="class in org.apache.juneau.assertions">FluentLongAssertion</a>&lt;<a href="FluentLongAssertion.html" title="type parameter in FluentLongAssertion">R</a>&gt;</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#setOut(java.io.PrintStream)">setOut</a></span>&#8203;(java.io.PrintStream&nbsp;value)</code></th>
<td class="colLast">
<div class="block">If an error occurs, send the error message to the specified stream instead of STDERR.</div>
</td>
</tr>
<tr class="rowColor" id="i3">
<td class="colFirst"><code><a href="FluentLongAssertion.html" title="class in org.apache.juneau.assertions">FluentLongAssertion</a>&lt;<a href="FluentLongAssertion.html" title="type parameter in FluentLongAssertion">R</a>&gt;</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#setSilent()">setSilent</a></span>()</code></th>
<td class="colLast">
<div class="block">Suppresses output to STDERR.</div>
</td>
</tr>
<tr class="altColor" id="i4">
<td class="colFirst"><code><a href="FluentLongAssertion.html" title="class in org.apache.juneau.assertions">FluentLongAssertion</a>&lt;<a href="FluentLongAssertion.html" title="type parameter in FluentLongAssertion">R</a>&gt;</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#setStdOut()">setStdOut</a></span>()</code></th>
<td class="colLast">
<div class="block">If an error occurs, send the error message to STDOUT instead of STDERR.</div>
</td>
</tr>
<tr class="rowColor" id="i5">
<td class="colFirst"><code><a href="FluentLongAssertion.html" title="class in org.apache.juneau.assertions">FluentLongAssertion</a>&lt;<a href="FluentLongAssertion.html" title="type parameter in FluentLongAssertion">R</a>&gt;</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#setThrowable(java.lang.Class)">setThrowable</a></span>&#8203;(java.lang.Class&lt;? extends java.lang.RuntimeException&gt;&nbsp;value)</code></th>
<td class="colLast">
<div class="block">If an error occurs, throw this exception instead of the standard <code>AssertionError</code>.</div>
</td>
</tr>
</tbody>
</table>
</div>
</div>
<div class="inheritedList">
<h3>Methods inherited from class&nbsp;org.apache.juneau.assertions.<a href="FluentComparableAssertion.html" title="class in org.apache.juneau.assertions">FluentComparableAssertion</a></h3>
<a id="methods.inherited.from.class.org.apache.juneau.assertions.FluentComparableAssertion">
<!-- -->
</a><code><a href="FluentComparableAssertion.html#asTransformed(java.util.function.Function)">asTransformed</a>, <a href="FluentComparableAssertion.html#isBetween(java.lang.Comparable,java.lang.Comparable)">isBetween</a>, <a href="FluentComparableAssertion.html#isGt(java.lang.Comparable)">isGt</a>, <a href="FluentComparableAssertion.html#isGte(java.lang.Comparable)">isGte</a>, <a href="FluentComparableAssertion.html#isLt(java.lang.Comparable)">isLt</a>, <a href="FluentComparableAssertion.html#isLte(java.lang.Comparable)">isLte</a></code></div>
<div class="inheritedList">
<h3>Methods inherited from class&nbsp;org.apache.juneau.assertions.<a href="FluentObjectAssertion.html" title="class in org.apache.juneau.assertions">FluentObjectAssertion</a></h3>
<a id="methods.inherited.from.class.org.apache.juneau.assertions.FluentObjectAssertion">
<!-- -->
</a><code><a href="FluentObjectAssertion.html#asAny()">asAny</a>, <a href="FluentObjectAssertion.html#asJson()">asJson</a>, <a href="FluentObjectAssertion.html#asJsonSorted()">asJsonSorted</a>, <a href="FluentObjectAssertion.html#asString()">asString</a>, <a href="FluentObjectAssertion.html#asString(java.util.function.Function)">asString</a>, <a href="FluentObjectAssertion.html#asString(org.apache.juneau.serializer.WriterSerializer)">asString</a>, <a href="FluentObjectAssertion.html#asTransformedTo(java.util.function.Function)">asTransformedTo</a>, <a href="FluentObjectAssertion.html#equals(java.lang.Object,java.lang.Object)">equals</a>, <a href="FluentObjectAssertion.html#getFailureMessage(java.util.function.Predicate,java.lang.Object)">getFailureMessage</a>, <a href="FluentObjectAssertion.html#is(java.util.function.Predicate)">is</a>, <a href="FluentObjectAssertion.html#is(T)">is</a>, <a href="FluentObjectAssertion.html#isAny(T...)">isAny</a>, <a href="FluentObjectAssertion.html#isExactType(java.lang.Class)">isExactType</a>, <a href="FluentObjectAssertion.html#isExists()">isExists</a>, <a href="FluentObjectAssertion.html#isJson(java.lang.String)">isJson</a>, <a href="FluentObjectAssertion.html#isNot(T)">isNot</a>, <a href="FluentObjectAssertion.html#isNotAny(T...)">isNotAny</a>, <a href="FluentObjectAssertion.html#isNotNull()">isNotNull</a>, <a href="FluentObjectAssertion.html#isNull()">isNull</a>, <a href="FluentObjectAssertion.html#isSame(T)">isSame</a>, <a href="FluentObjectAssertion.html#isSameJsonAs(java.lang.Object)">isSameJsonAs</a>, <a href="FluentObjectAssertion.html#isSameSerializedAs(java.lang.Object,org.apache.juneau.serializer.WriterSerializer)">isSameSerializedAs</a>, <a href="FluentObjectAssertion.html#isSameSortedJsonAs(java.lang.Object)">isSameSortedJsonAs</a>, <a href="FluentObjectAssertion.html#isString(java.lang.String)">isString</a>, <a href="FluentObjectAssertion.html#isType(java.lang.Class)">isType</a>, <a href="FluentObjectAssertion.html#map(java.util.function.Function)">map</a>, <a href="FluentObjectAssertion.html#opt()">opt</a>, <a href="FluentObjectAssertion.html#orElse(T)">orElse</a>, <a href="FluentObjectAssertion.html#toString()">toString</a>, <a href="FluentObjectAssertion.html#value()">value</a>, <a href="FluentObjectAssertion.html#valueAsString()">valueAsString</a>, <a href="FluentObjectAssertion.html#valueIsNotNull()">valueIsNotNull</a>, <a href="FluentObjectAssertion.html#valueIsNull()">valueIsNull</a></code></div>
<div class="inheritedList">
<h3>Methods inherited from class&nbsp;org.apache.juneau.assertions.<a href="FluentAssertion.html" title="class in org.apache.juneau.assertions">FluentAssertion</a></h3>
<a id="methods.inherited.from.class.org.apache.juneau.assertions.FluentAssertion">
<!-- -->
</a><code><a href="FluentAssertion.html#returns()">returns</a></code></div>
<div class="inheritedList">
<h3>Methods inherited from class&nbsp;org.apache.juneau.assertions.<a href="Assertion.html" title="class in org.apache.juneau.assertions">Assertion</a></h3>
<a id="methods.inherited.from.class.org.apache.juneau.assertions.Assertion">
<!-- -->
</a><code><a href="Assertion.html#arrayClass(java.lang.Class)">arrayClass</a>, <a href="Assertion.html#className(java.lang.Object)">className</a>, <a href="Assertion.html#error(java.lang.String,java.lang.Object...)">error</a>, <a href="Assertion.html#error(java.lang.Throwable,java.lang.String,java.lang.Object...)">error</a></code></div>
<div class="inheritedList">
<h3>Methods inherited from class&nbsp;java.lang.Object</h3>
<a id="methods.inherited.from.class.java.lang.Object">
<!-- -->
</a><code>clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait</code></div>
</section>
</li>
</ul>
</section>
<section class="details">
<ul class="blockList">
<!-- ========= CONSTRUCTOR DETAIL ======== -->
<li class="blockList">
<section class="constructorDetails"><a id="constructor.detail">
<!-- -->
</a>
<h2>Constructor Details</h2>
<ul class="blockList">
<li class="blockList">
<section class="detail">
<h3><a id="&lt;init&gt;(java.lang.Long,java.lang.Object)">
<!-- -->
</a><a id="&lt;init&gt;(java.lang.Long,R)">FluentLongAssertion</a></h3>
<div class="memberSignature"><span class="modifiers">public</span>&nbsp;<span class="memberName"><a href="../../../../src-html/org/apache/juneau/assertions/FluentLongAssertion.html#line.123">FluentLongAssertion</a></span>&#8203;(<span class="arguments">java.lang.Long&nbsp;value,
<a href="FluentLongAssertion.html" title="type parameter in FluentLongAssertion">R</a>&nbsp;returns)</span></div>
<div class="block">Constructor.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>value</code> - The object being tested.
<br>Can be <jk>null</jk>.</dd>
<dd><code>returns</code> - The object to return after a test method is called.
<br>If <jk>null</jk>, the test method returns this object allowing multiple test method calls to be
used on the same assertion.</dd>
</dl>
</section>
</li>
<li class="blockList">
<section class="detail">
<h3><a id="&lt;init&gt;(org.apache.juneau.assertions.Assertion,java.lang.Long,java.lang.Object)">
<!-- -->
</a><a id="&lt;init&gt;(org.apache.juneau.assertions.Assertion,java.lang.Long,R)">FluentLongAssertion</a></h3>
<div class="memberSignature"><span class="modifiers">public</span>&nbsp;<span class="memberName"><a href="../../../../src-html/org/apache/juneau/assertions/FluentLongAssertion.html#line.144">FluentLongAssertion</a></span>&#8203;(<span class="arguments"><a href="Assertion.html" title="class in org.apache.juneau.assertions">Assertion</a>&nbsp;creator,
java.lang.Long&nbsp;value,
<a href="FluentLongAssertion.html" title="type parameter in FluentLongAssertion">R</a>&nbsp;returns)</span></div>
<div class="block">Chained constructor.
<p>
Used when transforming one assertion into another so that the assertion config can be used by the new assertion.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>creator</code> - The assertion that created this assertion.
<br>Should be <jk>null</jk> if this is the top-level assertion.</dd>
<dd><code>value</code> - The object being tested.
<br>Can be <jk>null</jk>.</dd>
<dd><code>returns</code> - The object to return after a test method is called.
<br>If <jk>null</jk>, the test method returns this object allowing multiple test method calls to be
used on the same assertion.</dd>
</dl>
</section>
</li>
</ul>
</section>
</li>
<!-- ============ METHOD DETAIL ========== -->
<li class="blockList">
<section class="methodDetails"><a id="method.detail">
<!-- -->
</a>
<h2>Method Details</h2>
<ul class="blockList">
<li class="blockList">
<section class="detail">
<h3><a id="asInteger()">asInteger</a></h3>
<div class="memberSignature"><span class="modifiers">public</span>&nbsp;<span class="returnType"><a href="FluentIntegerAssertion.html" title="class in org.apache.juneau.assertions">FluentIntegerAssertion</a>&lt;<a href="FluentLongAssertion.html" title="type parameter in FluentLongAssertion">R</a>&gt;</span>&nbsp;<span class="memberName"><a href="../../../../src-html/org/apache/juneau/assertions/FluentLongAssertion.html#line.157">asInteger</a></span>()</div>
<div class="block">Converts this long into an integer and then returns it as an integer assertion.</div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>A new assertion.</dd>
</dl>
</section>
</li>
<li class="blockList">
<section class="detail">
<h3><a id="setMsg(java.lang.String,java.lang.Object...)">setMsg</a></h3>
<div class="memberSignature"><span class="modifiers">public</span>&nbsp;<span class="returnType"><a href="FluentLongAssertion.html" title="class in org.apache.juneau.assertions">FluentLongAssertion</a>&lt;<a href="FluentLongAssertion.html" title="type parameter in FluentLongAssertion">R</a>&gt;</span>&nbsp;<span class="memberName"><a href="../../../../src-html/org/apache/juneau/assertions/FluentLongAssertion.html#line.167">setMsg</a></span>&#8203;(<span class="arguments">java.lang.String&nbsp;msg,
java.lang.Object...&nbsp;args)</span></div>
<div class="block"><span class="descfrmTypeLabel">Description copied from class:&nbsp;<code><a href="Assertion.html#setMsg(java.lang.String,java.lang.Object...)">Assertion</a></code></span></div>
<div class="block">Allows you to override the assertion failure message.
<p>
String can contain <js>"{msg}"</js> to represent the original message.
<h5 class='section'>Example:</h5>
<p class='bjava'>
<jk>import static</jk> org.apache.juneau.assertions.Assertions.*;
<jc>// Throws an assertion with a custom message instead of the default "Value was null."</jc>
<jsm>assertString</jsm>(<jv>myString</jv>)
.setMsg(<js>"My string was bad: {msg}"</js>)
.isNotNull();
</p></div>
<dl>
<dt><span class="overrideSpecifyLabel">Overrides:</span></dt>
<dd><code><a href="FluentComparableAssertion.html#setMsg(java.lang.String,java.lang.Object...)">setMsg</a></code>&nbsp;in class&nbsp;<code><a href="FluentComparableAssertion.html" title="class in org.apache.juneau.assertions">FluentComparableAssertion</a>&lt;java.lang.Long,&#8203;<a href="FluentLongAssertion.html" title="type parameter in FluentLongAssertion">R</a>&gt;</code></dd>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>msg</code> - The assertion failure message.</dd>
<dd><code>args</code> - Optional message arguments.</dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>This object.</dd>
</dl>
</section>
</li>
<li class="blockList">
<section class="detail">
<h3><a id="setOut(java.io.PrintStream)">setOut</a></h3>
<div class="memberSignature"><span class="modifiers">public</span>&nbsp;<span class="returnType"><a href="FluentLongAssertion.html" title="class in org.apache.juneau.assertions">FluentLongAssertion</a>&lt;<a href="FluentLongAssertion.html" title="type parameter in FluentLongAssertion">R</a>&gt;</span>&nbsp;<span class="memberName"><a href="../../../../src-html/org/apache/juneau/assertions/FluentLongAssertion.html#line.173">setOut</a></span>&#8203;(<span class="arguments">java.io.PrintStream&nbsp;value)</span></div>
<div class="block"><span class="descfrmTypeLabel">Description copied from class:&nbsp;<code><a href="Assertion.html#setOut(java.io.PrintStream)">Assertion</a></code></span></div>
<div class="block">If an error occurs, send the error message to the specified stream instead of STDERR.</div>
<dl>
<dt><span class="overrideSpecifyLabel">Overrides:</span></dt>
<dd><code><a href="FluentComparableAssertion.html#setOut(java.io.PrintStream)">setOut</a></code>&nbsp;in class&nbsp;<code><a href="FluentComparableAssertion.html" title="class in org.apache.juneau.assertions">FluentComparableAssertion</a>&lt;java.lang.Long,&#8203;<a href="FluentLongAssertion.html" title="type parameter in FluentLongAssertion">R</a>&gt;</code></dd>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>value</code> - The output stream.
Can be <jk>null</jk> to suppress output.</dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>This object.</dd>
</dl>
</section>
</li>
<li class="blockList">
<section class="detail">
<h3><a id="setSilent()">setSilent</a></h3>
<div class="memberSignature"><span class="modifiers">public</span>&nbsp;<span class="returnType"><a href="FluentLongAssertion.html" title="class in org.apache.juneau.assertions">FluentLongAssertion</a>&lt;<a href="FluentLongAssertion.html" title="type parameter in FluentLongAssertion">R</a>&gt;</span>&nbsp;<span class="memberName"><a href="../../../../src-html/org/apache/juneau/assertions/FluentLongAssertion.html#line.179">setSilent</a></span>()</div>
<div class="block"><span class="descfrmTypeLabel">Description copied from class:&nbsp;<code><a href="Assertion.html#setSilent()">Assertion</a></code></span></div>
<div class="block">Suppresses output to STDERR.
<p>
This is the equivalent to calling <c>out(<jk>null</jk>)</c>.</div>
<dl>
<dt><span class="overrideSpecifyLabel">Overrides:</span></dt>
<dd><code><a href="FluentComparableAssertion.html#setSilent()">setSilent</a></code>&nbsp;in class&nbsp;<code><a href="FluentComparableAssertion.html" title="class in org.apache.juneau.assertions">FluentComparableAssertion</a>&lt;java.lang.Long,&#8203;<a href="FluentLongAssertion.html" title="type parameter in FluentLongAssertion">R</a>&gt;</code></dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>This object.</dd>
</dl>
</section>
</li>
<li class="blockList">
<section class="detail">
<h3><a id="setStdOut()">setStdOut</a></h3>
<div class="memberSignature"><span class="modifiers">public</span>&nbsp;<span class="returnType"><a href="FluentLongAssertion.html" title="class in org.apache.juneau.assertions">FluentLongAssertion</a>&lt;<a href="FluentLongAssertion.html" title="type parameter in FluentLongAssertion">R</a>&gt;</span>&nbsp;<span class="memberName"><a href="../../../../src-html/org/apache/juneau/assertions/FluentLongAssertion.html#line.185">setStdOut</a></span>()</div>
<div class="block"><span class="descfrmTypeLabel">Description copied from class:&nbsp;<code><a href="Assertion.html#setStdOut()">Assertion</a></code></span></div>
<div class="block">If an error occurs, send the error message to STDOUT instead of STDERR.</div>
<dl>
<dt><span class="overrideSpecifyLabel">Overrides:</span></dt>
<dd><code><a href="FluentComparableAssertion.html#setStdOut()">setStdOut</a></code>&nbsp;in class&nbsp;<code><a href="FluentComparableAssertion.html" title="class in org.apache.juneau.assertions">FluentComparableAssertion</a>&lt;java.lang.Long,&#8203;<a href="FluentLongAssertion.html" title="type parameter in FluentLongAssertion">R</a>&gt;</code></dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>This object.</dd>
</dl>
</section>
</li>
<li class="blockList">
<section class="detail">
<h3><a id="setThrowable(java.lang.Class)">setThrowable</a></h3>
<div class="memberSignature"><span class="modifiers">public</span>&nbsp;<span class="returnType"><a href="FluentLongAssertion.html" title="class in org.apache.juneau.assertions">FluentLongAssertion</a>&lt;<a href="FluentLongAssertion.html" title="type parameter in FluentLongAssertion">R</a>&gt;</span>&nbsp;<span class="memberName"><a href="../../../../src-html/org/apache/juneau/assertions/FluentLongAssertion.html#line.191">setThrowable</a></span>&#8203;(<span class="arguments">java.lang.Class&lt;? extends java.lang.RuntimeException&gt;&nbsp;value)</span></div>
<div class="block"><span class="descfrmTypeLabel">Description copied from class:&nbsp;<code><a href="Assertion.html#setThrowable(java.lang.Class)">Assertion</a></code></span></div>
<div class="block">If an error occurs, throw this exception instead of the standard <code>AssertionError</code>.
<p>
The throwable class must have a public constructor that takes in any of the following parameters:
<ul>
<li><code>Throwable</code> - The caused-by exception (if there is one).
<li><code>String</code> - The assertion failure message.
</ul>
<p>
If the throwable cannot be instantiated, a <code>RuntimeException</code> is thrown instead.
<h5 class='section'>Example:</h5>
<p class='bjava'>
<jk>import static</jk> org.apache.juneau.assertions.Assertions.*;
<jc>// Throws a BadRequest instead of an AssertionError if the string is null.</jc>
<jsm>assertString</jsm>(<jv>myString</jv>)
.setThrowable(BadRequest.<jk>class</jk>)
.isNotNull();
</p></div>
<dl>
<dt><span class="overrideSpecifyLabel">Overrides:</span></dt>
<dd><code><a href="FluentComparableAssertion.html#setThrowable(java.lang.Class)">setThrowable</a></code>&nbsp;in class&nbsp;<code><a href="FluentComparableAssertion.html" title="class in org.apache.juneau.assertions">FluentComparableAssertion</a>&lt;java.lang.Long,&#8203;<a href="FluentLongAssertion.html" title="type parameter in FluentLongAssertion">R</a>&gt;</code></dd>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>value</code> - The new value for this setting.</dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>This object.</dd>
</dl>
</section>
</li>
</ul>
</section>
</li>
</ul>
</section>
</div>
<!-- ========= END OF CLASS DATA ========= -->
</main>
<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="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">
<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>
</div>
<a id="skip.navbar.bottom">
<!-- -->
</a>
<!-- ======== END OF BOTTOM NAVBAR ======= -->
</nav>
<p class="legalCopy"><small>Copyright &#169; 2016&#x2013;2022 <a href="https://www.apache.org/">The Apache Software Foundation</a>. All rights reserved.</small></p>
</footer>
</div>
</div>
</body>
</html>