<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="utf-8">
<!-- numbers.cpp -->
  <meta name="description" content="The Numbers class provides functions for manipulating numbers.">
  <title>QDocTests::Numbers Class | Qt</title>
</head>
<body>
<li><a href="qdoctest-module.html" translate="no">QDocTest</a></li>
<li>Numbers</li>
<div class="sidebar">
<div class="toc">
<h3 id="toc">Contents</h3>
<ul>
<li class="level1"><a href="#public-functions">Public Functions</a></li>
<li class="level1"><a href="#details">Detailed Description</a></li>
</ul>
</div>
<div class="sidebar-content" id="sidebar-content"></div></div>
<h1 class="title" translate="no">QDocTests::Numbers Class</h1>
<span class="small-subtitle" translate="no">class <a href="qdoctests.html" translate="no">QDocTests</a>::Numbers</span>
<!-- $$$Numbers-brief -->
<p>The Numbers class provides functions for manipulating numbers. <a href="#details">More...</a></p>
<!-- @@@Numbers -->
<div class="table"><table class="alignedsummary requisites" translate="no">
<tr><td class="memItemLeft rightAlign topAlign"> Header:</td><td class="memItemRight bottomAlign"> <code translate="no">#include &lt;Numbers&gt;</code></td></tr>
</table></div>
<ul>
<li><a href="qdoctests-numbers-members.html">List of all members, including inherited members</a></li>
</ul>
<h2 id="public-functions">Public Functions</h2>
<div class="table"><table class="alignedsummary" translate="no">
<tr><td class="memItemLeft rightAlign topAlign"> T </td><td class="memItemRight bottomAlign"><b><a href="qdoctests-numbers.html#add" translate="no">add</a></b>(T <i>a</i>, T <i>b</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> auto </td><td class="memItemRight bottomAlign"><b><a href="qdoctests-numbers.html#add-1" translate="no">add</a></b>(int <i>a</i>, int <i>b</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> auto </td><td class="memItemRight bottomAlign"><b><a href="qdoctests-numbers.html#adder" translate="no">adder</a></b>(ThisIsMyReallyLongAndComplicatedTemplateName <i>a</i>, int <i>b</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> auto </td><td class="memItemRight bottomAlign"><b><a href="qdoctests-numbers.html#number" translate="no">number</a></b>() const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qdoctests-numbers.html#setNumber" translate="no">setNumber</a></b>(int <i>number</i>)</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> auto </td><td class="memItemRight bottomAlign"><b><a href="qdoctests-numbers.html#subtract" translate="no">subtract</a></b>(int <i>a</i>, int <i>b</i>)</td></tr>
</table></div>
<!-- $$$Numbers-description -->
<div class="descr">
<h2 id="details">Detailed Description</h2>
</div>
<!-- @@@Numbers -->
<div class="func">
<h2>Member Function Documentation</h2>
<!-- $$$add[overload1]$$$addTT -->
<h3 class="fn" translate="no" id="add">template &lt;typename T&gt; <span class="type">T</span> Numbers::<span class="name">add</span>(<span class="type">T</span> <i>a</i>, <span class="type">T</span> <i>b</i>)</h3>
<p>Adds two numbers of the same underlying type.</p>
<p>Returns a value containing the sum of <i translate="no">a</i> and <i translate="no">b</i>.</p>
<!-- @@@add -->
<!-- $$$add$$$addintint -->
<h3 class="fn" translate="no" id="add-1"><span class="type">auto</span> Numbers::<span class="name">add</span>(<span class="type">int</span> <i>a</i>, <span class="type">int</span> <i>b</i>)</h3>
<p>Adds two numbers.</p>
<p>Returns an integer containing the sum of <i translate="no">a</i> and <i translate="no">b</i>.</p>
<!-- @@@add -->
<!-- $$$adder[overload1]$$$adderThisIsMyReallyLongAndComplicatedTemplateNameint -->
<h3 class="fn" translate="no" id="adder">template &lt;typename ThisIsMyReallyLongAndComplicatedTemplateName&gt; <span class="type">auto</span> Numbers::<span class="name">adder</span>(<span class="type">ThisIsMyReallyLongAndComplicatedTemplateName</span> <i>a</i>, <span class="type">int</span> <i>b</i>)</h3>
<p>Adds two numbers of the same underlying type.</p>
<p>Returns a value containing the sum of <i translate="no">a</i> and <i translate="no">b</i>.</p>
<!-- @@@adder -->
<!-- $$$number[overload1]$$$number -->
<h3 class="fn" translate="no" id="number"><span class="type">auto</span> Numbers::<span class="name">number</span>() const</h3>
<p>Returns the number.</p>
<p>Returns the number, whatever it may be.</p>
<p><b>See also </b><a href="qdoctests-numbers.html#setNumber" translate="no">setNumber</a>().</p>
<!-- @@@number -->
<!-- $$$setNumber[overload1]$$$setNumberint -->
<h3 class="fn" translate="no" id="setNumber"><span class="type">void</span> Numbers::<span class="name">setNumber</span>(<span class="type">int</span> <i>number</i>)</h3>
<p>Sets the number.</p>
<p>Sets the number to <i translate="no">number</i>, and expects nothing more.</p>
<p><b>See also </b><a href="qdoctests-numbers.html#number" translate="no">number</a>().</p>
<!-- @@@setNumber -->
<!-- $$$subtract[overload1]$$$subtractintint -->
<h3 class="fn" translate="no" id="subtract"><span class="type">auto</span> Numbers::<span class="name">subtract</span>(<span class="type">int</span> <i>a</i>, <span class="type">int</span> <i>b</i>)</h3>
<p>Subtracts two numbers.</p>
<p>Returns an integer containing the difference of <i translate="no">a</i> and <i translate="no">b</i>.</p>
<!-- @@@subtract -->
</div>
</body>
</html>
