diff options
| author | Luiz Strobelt <[email protected]> | 2020-10-01 00:28:36 -0300 |
|---|---|---|
| committer | GitHub <[email protected]> | 2020-10-01 00:28:36 -0300 |
| commit | 5df3678f842383855c53a4c14d39a20deb64f7cc (patch) | |
| tree | 3b9fb614af27c68cfae7cdf76929069f8935ec0c /doc/faker.random.html | |
| parent | 27f4878ab3d989cdddec9df99802fe2150730ba2 (diff) | |
| parent | 91dc8a3372426bc691be56153b33e81a16459f49 (diff) | |
| download | faker-5df3678f842383855c53a4c14d39a20deb64f7cc.tar.xz faker-5df3678f842383855c53a4c14d39a20deb64f7cc.zip | |
Merge pull request #1 from Marak/master
Update to latest base branch
Diffstat (limited to 'doc/faker.random.html')
| -rw-r--r-- | doc/faker.random.html | 5632 |
1 files changed, 5597 insertions, 35 deletions
diff --git a/doc/faker.random.html b/doc/faker.random.html index c3e01762..ecda2a77 100644 --- a/doc/faker.random.html +++ b/doc/faker.random.html @@ -33,21 +33,30 @@ <li class="dropdown"> <a href="namespaces.list.html" class="dropdown-toggle" data-toggle="dropdown">Namespaces<b class="caret"></b></a> <ul class="dropdown-menu "> - <li><a href="faker.html">faker</a></li><li><a href="faker.address.html">faker.address</a></li><li><a href="faker.commerce.html">faker.commerce</a></li><li><a href="faker.company.html">faker.company</a></li><li><a href="faker.database.html">faker.database</a></li><li><a href="faker.date.html">faker.date</a></li><li><a href="faker.finance.html">faker.finance</a></li><li><a href="faker.hacker.html">faker.hacker</a></li><li><a href="faker.helpers.html">faker.helpers</a></li><li><a href="faker.image.html">faker.image</a></li><li><a href="faker.internet.html">faker.internet</a></li><li><a href="faker.lorem.html">faker.lorem</a></li><li><a href="faker.name.html">faker.name</a></li><li><a href="faker.phone.html">faker.phone</a></li><li><a href="faker.random.html">faker.random</a></li><li><a href="faker.system.html">faker.system</a></li> + <li><a href="faker.html">faker</a></li><li><a href="faker.address.html">faker.address</a></li><li><a href="faker.commerce.html">faker.commerce</a></li><li><a href="faker.company.html">faker.company</a></li><li><a href="faker.database.html">faker.database</a></li><li><a href="faker.date.html">faker.date</a></li><li><a href="faker.finance.html">faker.finance</a></li><li><a href="faker.git.html">faker.git</a></li><li><a href="faker.hacker.html">faker.hacker</a></li><li><a href="faker.helpers.html">faker.helpers</a></li><li><a href="faker.image.html">faker.image</a></li><li><a href="faker.image.lorempicsum.html">faker.image.lorempicsum</a></li><li><a href="faker.image.lorempixel.html">faker.image.lorempixel</a></li><li><a href="faker.image.unsplash.html">faker.image.unsplash</a></li><li><a href="faker.internet.html">faker.internet</a></li><li><a href="faker.lorem.html">faker.lorem</a></li><li><a href="faker.name.html">faker.name</a></li><li><a href="faker.phone.html">faker.phone</a></li><li><a href="faker.random.html">faker.random</a></li><li><a href="faker.system.html">faker.system</a></li><li><a href="faker.time.html">faker.time</a></li><li><a href="faker.unique.html">faker.unique</a></li><li><a href="faker.vehicle.html">faker.vehicle</a></li> + </ul> + </li> + + <li class="dropdown"> + <a href="global.html" class="dropdown-toggle" data-toggle="dropdown">Global<b class="caret"></b></a> + <ul class="dropdown-menu "> + <li><a href="global.html#unique">unique</a></li> </ul> </li> </ul> - <div class="col-sm-3 col-md-3"> - <form class="navbar-form" role="search"> - <div class="input-group"> - <input type="text" class="form-control" placeholder="Search" name="q" id="search-input"> - <div class="input-group-btn"> - <button class="btn btn-default" id="search-submit"><i class="glyphicon glyphicon-search"></i></button> + + <div class="col-sm-3 col-md-3"> + <form class="navbar-form" role="search"> + <div class="input-group"> + <input type="text" class="form-control" placeholder="Search" name="q" id="search-input"> + <div class="input-group-btn"> + <button class="btn btn-default" id="search-submit"><i class="glyphicon glyphicon-search"></i></button> + </div> </div> - </div> - </form> - </div> + </form> + </div> + </div> </div> @@ -146,6 +155,3634 @@ <hr> <dt> + <h4 class="name" id=".alpha"><span class="type-signature"><static> </span>alpha(options)</h4> + + +</dt> +<dd> + + + <div class="description"> + <p>alpha. returns lower/upper alpha characters based count and upcase options</p> + </div> + + + + + + + + + <h5>Parameters:</h5> + + +<table class="params table table-striped"> + <thead> + <tr> + + <th>Name</th> + + + <th>Type</th> + + + + + + <th class="last">Description</th> + </tr> + </thead> + + <tbody> + + + <tr> + + <td class="name"><code>options</code></td> + + + <td class="type"> + + +<span class="param-type">mixed</span> + + + + + </td> + + + + + + <td class="description last"><p>// defaults to { count: 1, upcase: false }</p></td> + </tr> + + + </tbody> +</table> + + + + +<dl class="details"> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +</dl> + + + + + + + + + + + + + + + +</dd> + + + +<hr> +<dt> + <h4 class="name" id=".alpha"><span class="type-signature"><static> </span>alpha(options)</h4> + + +</dt> +<dd> + + + <div class="description"> + <p>alpha. returns lower/upper alpha characters based count and upcase options</p> + </div> + + + + + + + + + <h5>Parameters:</h5> + + +<table class="params table table-striped"> + <thead> + <tr> + + <th>Name</th> + + + <th>Type</th> + + + + + + <th class="last">Description</th> + </tr> + </thead> + + <tbody> + + + <tr> + + <td class="name"><code>options</code></td> + + + <td class="type"> + + +<span class="param-type">mixed</span> + + + + + </td> + + + + + + <td class="description last"><p>// defaults to { count: 1, upcase: false }</p></td> + </tr> + + + </tbody> +</table> + + + + +<dl class="details"> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +</dl> + + + + + + + + + + + + + + + +</dd> + + + +<hr> +<dt> + <h4 class="name" id=".alphaNumeric"><span class="type-signature"><static> </span>alphaNumeric(count)</h4> + + +</dt> +<dd> + + + <div class="description"> + <p>alphaNumeric</p> + </div> + + + + + + + + + <h5>Parameters:</h5> + + +<table class="params table table-striped"> + <thead> + <tr> + + <th>Name</th> + + + <th>Type</th> + + + + + + <th class="last">Description</th> + </tr> + </thead> + + <tbody> + + + <tr> + + <td class="name"><code>count</code></td> + + + <td class="type"> + + +<span class="param-type">number</span> + + + + + </td> + + + + + + <td class="description last"><p>defaults to 1</p></td> + </tr> + + + </tbody> +</table> + + + + +<dl class="details"> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +</dl> + + + + + + + + + + + + + + + +</dd> + + + +<hr> +<dt> + <h4 class="name" id=".alphaNumeric"><span class="type-signature"><static> </span>alphaNumeric(count)</h4> + + +</dt> +<dd> + + + <div class="description"> + <p>alphaNumeric</p> + </div> + + + + + + + + + <h5>Parameters:</h5> + + +<table class="params table table-striped"> + <thead> + <tr> + + <th>Name</th> + + + <th>Type</th> + + + + + + <th class="last">Description</th> + </tr> + </thead> + + <tbody> + + + <tr> + + <td class="name"><code>count</code></td> + + + <td class="type"> + + +<span class="param-type">number</span> + + + + + </td> + + + + + + <td class="description last"><p>defaults to 1</p></td> + </tr> + + + </tbody> +</table> + + + + +<dl class="details"> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +</dl> + + + + + + + + + + + + + + + +</dd> + + + +<hr> +<dt> + <h4 class="name" id=".arrayElement"><span class="type-signature"><static> </span>arrayElement(array)</h4> + + +</dt> +<dd> + + + <div class="description"> + <p>takes an array and returns a random element of the array</p> + </div> + + + + + + + + + <h5>Parameters:</h5> + + +<table class="params table table-striped"> + <thead> + <tr> + + <th>Name</th> + + + <th>Type</th> + + + + + + <th class="last">Description</th> + </tr> + </thead> + + <tbody> + + + <tr> + + <td class="name"><code>array</code></td> + + + <td class="type"> + + +<span class="param-type">array</span> + + + + + </td> + + + + + + <td class="description last"></td> + </tr> + + + </tbody> +</table> + + + + +<dl class="details"> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +</dl> + + + + + + + + + + + + + + + +</dd> + + + +<hr> +<dt> + <h4 class="name" id=".arrayElement"><span class="type-signature"><static> </span>arrayElement(array)</h4> + + +</dt> +<dd> + + + <div class="description"> + <p>takes an array and returns a random element of the array</p> + </div> + + + + + + + + + <h5>Parameters:</h5> + + +<table class="params table table-striped"> + <thead> + <tr> + + <th>Name</th> + + + <th>Type</th> + + + + + + <th class="last">Description</th> + </tr> + </thead> + + <tbody> + + + <tr> + + <td class="name"><code>array</code></td> + + + <td class="type"> + + +<span class="param-type">array</span> + + + + + </td> + + + + + + <td class="description last"></td> + </tr> + + + </tbody> +</table> + + + + +<dl class="details"> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +</dl> + + + + + + + + + + + + + + + +</dd> + + + +<hr> +<dt> + <h4 class="name" id=".arrayElements"><span class="type-signature"><static> </span>arrayElements(array, count)</h4> + + +</dt> +<dd> + + + <div class="description"> + <p>takes an array and returns a subset with random elements of the array</p> + </div> + + + + + + + + + <h5>Parameters:</h5> + + +<table class="params table table-striped"> + <thead> + <tr> + + <th>Name</th> + + + <th>Type</th> + + + + + + <th class="last">Description</th> + </tr> + </thead> + + <tbody> + + + <tr> + + <td class="name"><code>array</code></td> + + + <td class="type"> + + +<span class="param-type">array</span> + + + + + </td> + + + + + + <td class="description last"></td> + </tr> + + + + <tr> + + <td class="name"><code>count</code></td> + + + <td class="type"> + + +<span class="param-type">number</span> + + + + + </td> + + + + + + <td class="description last"><p>number of elements to pick</p></td> + </tr> + + + </tbody> +</table> + + + + +<dl class="details"> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +</dl> + + + + + + + + + + + + + + + +</dd> + + + +<hr> +<dt> + <h4 class="name" id=".arrayElements"><span class="type-signature"><static> </span>arrayElements(array, count)</h4> + + +</dt> +<dd> + + + <div class="description"> + <p>takes an array and returns a subset with random elements of the array</p> + </div> + + + + + + + + + <h5>Parameters:</h5> + + +<table class="params table table-striped"> + <thead> + <tr> + + <th>Name</th> + + + <th>Type</th> + + + + + + <th class="last">Description</th> + </tr> + </thead> + + <tbody> + + + <tr> + + <td class="name"><code>array</code></td> + + + <td class="type"> + + +<span class="param-type">array</span> + + + + + </td> + + + + + + <td class="description last"></td> + </tr> + + + + <tr> + + <td class="name"><code>count</code></td> + + + <td class="type"> + + +<span class="param-type">number</span> + + + + + </td> + + + + + + <td class="description last"><p>number of elements to pick</p></td> + </tr> + + + </tbody> +</table> + + + + +<dl class="details"> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +</dl> + + + + + + + + + + + + + + + +</dd> + + + +<hr> +<dt> + <h4 class="name" id=".boolean"><span class="type-signature"><static> </span>boolean()</h4> + + +</dt> +<dd> + + + <div class="description"> + <p>boolean</p> + </div> + + + + + + + + + + +<dl class="details"> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +</dl> + + + + + + + + + + + + + + + +</dd> + + + +<hr> +<dt> + <h4 class="name" id=".boolean"><span class="type-signature"><static> </span>boolean()</h4> + + +</dt> +<dd> + + + <div class="description"> + <p>boolean</p> + </div> + + + + + + + + + + +<dl class="details"> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +</dl> + + + + + + + + + + + + + + + +</dd> + + + +<hr> +<dt> + <h4 class="name" id=".float"><span class="type-signature"><static> </span>float(options)</h4> + + +</dt> +<dd> + + + <div class="description"> + <p>returns a single random floating-point number based on a max number or range</p> + </div> + + + + + + + + + <h5>Parameters:</h5> + + +<table class="params table table-striped"> + <thead> + <tr> + + <th>Name</th> + + + <th>Type</th> + + + + + + <th class="last">Description</th> + </tr> + </thead> + + <tbody> + + + <tr> + + <td class="name"><code>options</code></td> + + + <td class="type"> + + +<span class="param-type">mixed</span> + + + + + </td> + + + + + + <td class="description last"></td> + </tr> + + + </tbody> +</table> + + + + +<dl class="details"> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +</dl> + + + + + + + + + + + + + + + +</dd> + + + +<hr> +<dt> + <h4 class="name" id=".float"><span class="type-signature"><static> </span>float(options)</h4> + + +</dt> +<dd> + + + <div class="description"> + <p>returns a single random floating-point number based on a max number or range</p> + </div> + + + + + + + + + <h5>Parameters:</h5> + + +<table class="params table table-striped"> + <thead> + <tr> + + <th>Name</th> + + + <th>Type</th> + + + + + + <th class="last">Description</th> + </tr> + </thead> + + <tbody> + + + <tr> + + <td class="name"><code>options</code></td> + + + <td class="type"> + + +<span class="param-type">mixed</span> + + + + + </td> + + + + + + <td class="description last"></td> + </tr> + + + </tbody> +</table> + + + + +<dl class="details"> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +</dl> + + + + + + + + + + + + + + + +</dd> + + + +<hr> +<dt> + <h4 class="name" id=".hexaDecimal"><span class="type-signature"><static> </span>hexaDecimal(count)</h4> + + +</dt> +<dd> + + + <div class="description"> + <p>hexaDecimal</p> + </div> + + + + + + + + + <h5>Parameters:</h5> + + +<table class="params table table-striped"> + <thead> + <tr> + + <th>Name</th> + + + <th>Type</th> + + + + + + <th class="last">Description</th> + </tr> + </thead> + + <tbody> + + + <tr> + + <td class="name"><code>count</code></td> + + + <td class="type"> + + +<span class="param-type">number</span> + + + + + </td> + + + + + + <td class="description last"><p>defaults to 1</p></td> + </tr> + + + </tbody> +</table> + + + + +<dl class="details"> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +</dl> + + + + + + + + + + + + + + + +</dd> + + + +<hr> +<dt> + <h4 class="name" id=".hexaDecimal"><span class="type-signature"><static> </span>hexaDecimal(count)</h4> + + +</dt> +<dd> + + + <div class="description"> + <p>hexaDecimal</p> + </div> + + + + + + + + + <h5>Parameters:</h5> + + +<table class="params table table-striped"> + <thead> + <tr> + + <th>Name</th> + + + <th>Type</th> + + + + + + <th class="last">Description</th> + </tr> + </thead> + + <tbody> + + + <tr> + + <td class="name"><code>count</code></td> + + + <td class="type"> + + +<span class="param-type">number</span> + + + + + </td> + + + + + + <td class="description last"><p>defaults to 1</p></td> + </tr> + + + </tbody> +</table> + + + + +<dl class="details"> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +</dl> + + + + + + + + + + + + + + + +</dd> + + + +<hr> +<dt> + <h4 class="name" id=".image"><span class="type-signature"><static> </span>image()</h4> + + +</dt> +<dd> + + + <div class="description"> + <p>locale</p> + </div> + + + + + + + + + + +<dl class="details"> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +</dl> + + + + + + + + + + + + + + + +</dd> + + + +<hr> +<dt> + <h4 class="name" id=".image"><span class="type-signature"><static> </span>image()</h4> + + +</dt> +<dd> + + + <div class="description"> + <p>locale</p> + </div> + + + + + + + + + + +<dl class="details"> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +</dl> + + + + + + + + + + + + + + + +</dd> + + + +<hr> +<dt> + <h4 class="name" id=".locale"><span class="type-signature"><static> </span>locale()</h4> + + +</dt> +<dd> + + + <div class="description"> + <p>locale</p> + </div> + + + + + + + + + + +<dl class="details"> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +</dl> + + + + + + + + + + + + + + + +</dd> + + + +<hr> +<dt> + <h4 class="name" id=".locale"><span class="type-signature"><static> </span>locale()</h4> + + +</dt> +<dd> + + + <div class="description"> + <p>locale</p> + </div> + + + + + + + + + + +<dl class="details"> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +</dl> + + + + + + + + + + + + + + + +</dd> + + + +<hr> +<dt> + <h4 class="name" id=".number"><span class="type-signature"><static> </span>number(options)</h4> + + +</dt> +<dd> + + + <div class="description"> + <p>returns a single random number based on a max number or range</p> + </div> + + + + + + + + + <h5>Parameters:</h5> + + +<table class="params table table-striped"> + <thead> + <tr> + + <th>Name</th> + + + <th>Type</th> + + + + + + <th class="last">Description</th> + </tr> + </thead> + + <tbody> + + + <tr> + + <td class="name"><code>options</code></td> + + + <td class="type"> + + +<span class="param-type">mixed</span> + + + + + </td> + + + + + + <td class="description last"><p>{min, max, precision}</p></td> + </tr> + + + </tbody> +</table> + + + + +<dl class="details"> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +</dl> + + + + + + + + + + + + + + + +</dd> + + + +<hr> +<dt> + <h4 class="name" id=".number"><span class="type-signature"><static> </span>number(options)</h4> + + +</dt> +<dd> + + + <div class="description"> + <p>returns a single random number based on a max number or range</p> + </div> + + + + + + + + + <h5>Parameters:</h5> + + +<table class="params table table-striped"> + <thead> + <tr> + + <th>Name</th> + + + <th>Type</th> + + + + + + <th class="last">Description</th> + </tr> + </thead> + + <tbody> + + + <tr> + + <td class="name"><code>options</code></td> + + + <td class="type"> + + +<span class="param-type">mixed</span> + + + + + </td> + + + + + + <td class="description last"><p>{min, max, precision}</p></td> + </tr> + + + </tbody> +</table> + + + + +<dl class="details"> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +</dl> + + + + + + + + + + + + + + + +</dd> + + + +<hr> +<dt> + <h4 class="name" id=".objectElement"><span class="type-signature"><static> </span>objectElement(object, field)</h4> + + +</dt> +<dd> + + + <div class="description"> + <p>takes an object and returns the randomly key or value</p> + </div> + + + + + + + + + <h5>Parameters:</h5> + + +<table class="params table table-striped"> + <thead> + <tr> + + <th>Name</th> + + + <th>Type</th> + + + + + + <th class="last">Description</th> + </tr> + </thead> + + <tbody> + + + <tr> + + <td class="name"><code>object</code></td> + + + <td class="type"> + + +<span class="param-type">object</span> + + + + + </td> + + + + + + <td class="description last"></td> + </tr> + + + + <tr> + + <td class="name"><code>field</code></td> + + + <td class="type"> + + +<span class="param-type">mixed</span> + + + + + </td> + + + + + + <td class="description last"></td> + </tr> + + + </tbody> +</table> + + + + +<dl class="details"> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +</dl> + + + + + + + + + + + + + + + +</dd> + + + +<hr> +<dt> + <h4 class="name" id=".objectElement"><span class="type-signature"><static> </span>objectElement(object, field)</h4> + + +</dt> +<dd> + + + <div class="description"> + <p>takes an object and returns the randomly key or value</p> + </div> + + + + + + + + + <h5>Parameters:</h5> + + +<table class="params table table-striped"> + <thead> + <tr> + + <th>Name</th> + + + <th>Type</th> + + + + + + <th class="last">Description</th> + </tr> + </thead> + + <tbody> + + + <tr> + + <td class="name"><code>object</code></td> + + + <td class="type"> + + +<span class="param-type">object</span> + + + + + </td> + + + + + + <td class="description last"></td> + </tr> + + + + <tr> + + <td class="name"><code>field</code></td> + + + <td class="type"> + + +<span class="param-type">mixed</span> + + + + + </td> + + + + + + <td class="description last"></td> + </tr> + + + </tbody> +</table> + + + + +<dl class="details"> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +</dl> + + + + + + + + + + + + + + + +</dd> + + + +<hr> +<dt> + <h4 class="name" id=".uuid"><span class="type-signature"><static> </span>uuid()</h4> + + +</dt> +<dd> + + + <div class="description"> + <p>uuid</p> + </div> + + + + + + + + + + +<dl class="details"> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +</dl> + + + + + + + + + + + + + + + +</dd> + + + +<hr> +<dt> + <h4 class="name" id=".uuid"><span class="type-signature"><static> </span>uuid()</h4> + + +</dt> +<dd> + + + <div class="description"> + <p>uuid</p> + </div> + + + + + + + + + + +<dl class="details"> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +</dl> + + + + + + + + + + + + + + + +</dd> + + + +<hr> +<dt> + <h4 class="name" id=".word"><span class="type-signature"><static> </span>word(type)</h4> + + +</dt> +<dd> + + + <div class="description"> + <p>word</p> + </div> + + + + + + + + + <h5>Parameters:</h5> + + +<table class="params table table-striped"> + <thead> + <tr> + + <th>Name</th> + + + <th>Type</th> + + + + + + <th class="last">Description</th> + </tr> + </thead> + + <tbody> + + + <tr> + + <td class="name"><code>type</code></td> + + + <td class="type"> + + +<span class="param-type">string</span> + + + + + </td> + + + + + + <td class="description last"></td> + </tr> + + + </tbody> +</table> + + + + +<dl class="details"> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +</dl> + + + + + + + + + + + + + + + +</dd> + + + +<hr> +<dt> + <h4 class="name" id=".word"><span class="type-signature"><static> </span>word(type)</h4> + + +</dt> +<dd> + + + <div class="description"> + <p>word</p> + </div> + + + + + + + + + <h5>Parameters:</h5> + + +<table class="params table table-striped"> + <thead> + <tr> + + <th>Name</th> + + + <th>Type</th> + + + + + + <th class="last">Description</th> + </tr> + </thead> + + <tbody> + + + <tr> + + <td class="name"><code>type</code></td> + + + <td class="type"> + + +<span class="param-type">string</span> + + + + + </td> + + + + + + <td class="description last"></td> + </tr> + + + </tbody> +</table> + + + + +<dl class="details"> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +</dl> + + + + + + + + + + + + + + + +</dd> + + + +<hr> +<dt> + <h4 class="name" id=".words"><span class="type-signature"><static> </span>words(count)</h4> + + +</dt> +<dd> + + + <div class="description"> + <p>randomWords</p> + </div> + + + + + + + + + <h5>Parameters:</h5> + + +<table class="params table table-striped"> + <thead> + <tr> + + <th>Name</th> + + + <th>Type</th> + + + + + + <th class="last">Description</th> + </tr> + </thead> + + <tbody> + + + <tr> + + <td class="name"><code>count</code></td> + + + <td class="type"> + + +<span class="param-type">number</span> + + + + + </td> + + + + + + <td class="description last"><p>defaults to a random value between 1 and 3</p></td> + </tr> + + + </tbody> +</table> + + + + +<dl class="details"> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +</dl> + + + + + + + + + + + + + + + +</dd> + + + +<hr> +<dt> + <h4 class="name" id=".words"><span class="type-signature"><static> </span>words(count)</h4> + + +</dt> +<dd> + + + <div class="description"> + <p>randomWords</p> + </div> + + + + + + + + + <h5>Parameters:</h5> + + +<table class="params table table-striped"> + <thead> + <tr> + + <th>Name</th> + + + <th>Type</th> + + + + + + <th class="last">Description</th> + </tr> + </thead> + + <tbody> + + + <tr> + + <td class="name"><code>count</code></td> + + + <td class="type"> + + +<span class="param-type">number</span> + + + + + </td> + + + + + + <td class="description last"><p>defaults to a random value between 1 and 3</p></td> + </tr> + + + </tbody> +</table> + + + + +<dl class="details"> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +</dl> + + + + + + + + + + + + + + + +</dd> + + </dl> + + + + + +</article> + +</section> + + + + + <h1 class="page-title">Namespace: random</h1> +<section> + +<header> + + <h2> + <span class="ancestors"><a href="faker.html">faker</a>.</span> + + random + </h2> + + +</header> + + +<article> + <div class="container-overview"> + + + + +<dl class="details"> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +</dl> + + + + + </div> + + + + + + + + + + + + + + + <h3 class="subsection-title">Methods</h3> + + <dl> + +<hr> +<dt> + <h4 class="name" id=".alpha"><span class="type-signature"><static> </span>alpha(options)</h4> + + +</dt> +<dd> + + + <div class="description"> + <p>alpha. returns lower/upper alpha characters based count and upcase options</p> + </div> + + + + + + + + + <h5>Parameters:</h5> + + +<table class="params table table-striped"> + <thead> + <tr> + + <th>Name</th> + + + <th>Type</th> + + + + + + <th class="last">Description</th> + </tr> + </thead> + + <tbody> + + + <tr> + + <td class="name"><code>options</code></td> + + + <td class="type"> + + +<span class="param-type">mixed</span> + + + + + </td> + + + + + + <td class="description last"><p>// defaults to { count: 1, upcase: false }</p></td> + </tr> + + + </tbody> +</table> + + + + +<dl class="details"> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +</dl> + + + + + + + + + + + + + + + +</dd> + + + +<hr> +<dt> + <h4 class="name" id=".alpha"><span class="type-signature"><static> </span>alpha(options)</h4> + + +</dt> +<dd> + + + <div class="description"> + <p>alpha. returns lower/upper alpha characters based count and upcase options</p> + </div> + + + + + + + + + <h5>Parameters:</h5> + + +<table class="params table table-striped"> + <thead> + <tr> + + <th>Name</th> + + + <th>Type</th> + + + + + + <th class="last">Description</th> + </tr> + </thead> + + <tbody> + + + <tr> + + <td class="name"><code>options</code></td> + + + <td class="type"> + + +<span class="param-type">mixed</span> + + + + + </td> + + + + + + <td class="description last"><p>// defaults to { count: 1, upcase: false }</p></td> + </tr> + + + </tbody> +</table> + + + + +<dl class="details"> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +</dl> + + + + + + + + + + + + + + + +</dd> + + + +<hr> +<dt> <h4 class="name" id=".alphaNumeric"><span class="type-signature"><static> </span>alphaNumeric(count)</h4> @@ -274,6 +3911,262 @@ <hr> <dt> + <h4 class="name" id=".alphaNumeric"><span class="type-signature"><static> </span>alphaNumeric(count)</h4> + + +</dt> +<dd> + + + <div class="description"> + <p>alphaNumeric</p> + </div> + + + + + + + + + <h5>Parameters:</h5> + + +<table class="params table table-striped"> + <thead> + <tr> + + <th>Name</th> + + + <th>Type</th> + + + + + + <th class="last">Description</th> + </tr> + </thead> + + <tbody> + + + <tr> + + <td class="name"><code>count</code></td> + + + <td class="type"> + + +<span class="param-type">number</span> + + + + + </td> + + + + + + <td class="description last"><p>defaults to 1</p></td> + </tr> + + + </tbody> +</table> + + + + +<dl class="details"> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +</dl> + + + + + + + + + + + + + + + +</dd> + + + +<hr> +<dt> + <h4 class="name" id=".arrayElement"><span class="type-signature"><static> </span>arrayElement(array)</h4> + + +</dt> +<dd> + + + <div class="description"> + <p>takes an array and returns a random element of the array</p> + </div> + + + + + + + + + <h5>Parameters:</h5> + + +<table class="params table table-striped"> + <thead> + <tr> + + <th>Name</th> + + + <th>Type</th> + + + + + + <th class="last">Description</th> + </tr> + </thead> + + <tbody> + + + <tr> + + <td class="name"><code>array</code></td> + + + <td class="type"> + + +<span class="param-type">array</span> + + + + + </td> + + + + + + <td class="description last"></td> + </tr> + + + </tbody> +</table> + + + + +<dl class="details"> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +</dl> + + + + + + + + + + + + + + + +</dd> + + + +<hr> +<dt> <h4 class="name" id=".arrayElement"><span class="type-signature"><static> </span>arrayElement(array)</h4> @@ -402,6 +4295,310 @@ <hr> <dt> + <h4 class="name" id=".arrayElements"><span class="type-signature"><static> </span>arrayElements(array, count)</h4> + + +</dt> +<dd> + + + <div class="description"> + <p>takes an array and returns a subset with random elements of the array</p> + </div> + + + + + + + + + <h5>Parameters:</h5> + + +<table class="params table table-striped"> + <thead> + <tr> + + <th>Name</th> + + + <th>Type</th> + + + + + + <th class="last">Description</th> + </tr> + </thead> + + <tbody> + + + <tr> + + <td class="name"><code>array</code></td> + + + <td class="type"> + + +<span class="param-type">array</span> + + + + + </td> + + + + + + <td class="description last"></td> + </tr> + + + + <tr> + + <td class="name"><code>count</code></td> + + + <td class="type"> + + +<span class="param-type">number</span> + + + + + </td> + + + + + + <td class="description last"><p>number of elements to pick</p></td> + </tr> + + + </tbody> +</table> + + + + +<dl class="details"> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +</dl> + + + + + + + + + + + + + + + +</dd> + + + +<hr> +<dt> + <h4 class="name" id=".arrayElements"><span class="type-signature"><static> </span>arrayElements(array, count)</h4> + + +</dt> +<dd> + + + <div class="description"> + <p>takes an array and returns a subset with random elements of the array</p> + </div> + + + + + + + + + <h5>Parameters:</h5> + + +<table class="params table table-striped"> + <thead> + <tr> + + <th>Name</th> + + + <th>Type</th> + + + + + + <th class="last">Description</th> + </tr> + </thead> + + <tbody> + + + <tr> + + <td class="name"><code>array</code></td> + + + <td class="type"> + + +<span class="param-type">array</span> + + + + + </td> + + + + + + <td class="description last"></td> + </tr> + + + + <tr> + + <td class="name"><code>count</code></td> + + + <td class="type"> + + +<span class="param-type">number</span> + + + + + </td> + + + + + + <td class="description last"><p>number of elements to pick</p></td> + </tr> + + + </tbody> +</table> + + + + +<dl class="details"> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +</dl> + + + + + + + + + + + + + + + +</dd> + + + +<hr> +<dt> <h4 class="name" id=".boolean"><span class="type-signature"><static> </span>boolean()</h4> @@ -480,6 +4677,674 @@ <hr> <dt> + <h4 class="name" id=".boolean"><span class="type-signature"><static> </span>boolean()</h4> + + +</dt> +<dd> + + + <div class="description"> + <p>boolean</p> + </div> + + + + + + + + + + +<dl class="details"> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +</dl> + + + + + + + + + + + + + + + +</dd> + + + +<hr> +<dt> + <h4 class="name" id=".float"><span class="type-signature"><static> </span>float(options)</h4> + + +</dt> +<dd> + + + <div class="description"> + <p>returns a single random floating-point number based on a max number or range</p> + </div> + + + + + + + + + <h5>Parameters:</h5> + + +<table class="params table table-striped"> + <thead> + <tr> + + <th>Name</th> + + + <th>Type</th> + + + + + + <th class="last">Description</th> + </tr> + </thead> + + <tbody> + + + <tr> + + <td class="name"><code>options</code></td> + + + <td class="type"> + + +<span class="param-type">mixed</span> + + + + + </td> + + + + + + <td class="description last"></td> + </tr> + + + </tbody> +</table> + + + + +<dl class="details"> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +</dl> + + + + + + + + + + + + + + + +</dd> + + + +<hr> +<dt> + <h4 class="name" id=".float"><span class="type-signature"><static> </span>float(options)</h4> + + +</dt> +<dd> + + + <div class="description"> + <p>returns a single random floating-point number based on a max number or range</p> + </div> + + + + + + + + + <h5>Parameters:</h5> + + +<table class="params table table-striped"> + <thead> + <tr> + + <th>Name</th> + + + <th>Type</th> + + + + + + <th class="last">Description</th> + </tr> + </thead> + + <tbody> + + + <tr> + + <td class="name"><code>options</code></td> + + + <td class="type"> + + +<span class="param-type">mixed</span> + + + + + </td> + + + + + + <td class="description last"></td> + </tr> + + + </tbody> +</table> + + + + +<dl class="details"> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +</dl> + + + + + + + + + + + + + + + +</dd> + + + +<hr> +<dt> + <h4 class="name" id=".hexaDecimal"><span class="type-signature"><static> </span>hexaDecimal(count)</h4> + + +</dt> +<dd> + + + <div class="description"> + <p>hexaDecimal</p> + </div> + + + + + + + + + <h5>Parameters:</h5> + + +<table class="params table table-striped"> + <thead> + <tr> + + <th>Name</th> + + + <th>Type</th> + + + + + + <th class="last">Description</th> + </tr> + </thead> + + <tbody> + + + <tr> + + <td class="name"><code>count</code></td> + + + <td class="type"> + + +<span class="param-type">number</span> + + + + + </td> + + + + + + <td class="description last"><p>defaults to 1</p></td> + </tr> + + + </tbody> +</table> + + + + +<dl class="details"> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +</dl> + + + + + + + + + + + + + + + +</dd> + + + +<hr> +<dt> + <h4 class="name" id=".hexaDecimal"><span class="type-signature"><static> </span>hexaDecimal(count)</h4> + + +</dt> +<dd> + + + <div class="description"> + <p>hexaDecimal</p> + </div> + + + + + + + + + <h5>Parameters:</h5> + + +<table class="params table table-striped"> + <thead> + <tr> + + <th>Name</th> + + + <th>Type</th> + + + + + + <th class="last">Description</th> + </tr> + </thead> + + <tbody> + + + <tr> + + <td class="name"><code>count</code></td> + + + <td class="type"> + + +<span class="param-type">number</span> + + + + + </td> + + + + + + <td class="description last"><p>defaults to 1</p></td> + </tr> + + + </tbody> +</table> + + + + +<dl class="details"> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +</dl> + + + + + + + + + + + + + + + +</dd> + + + +<hr> +<dt> + <h4 class="name" id=".image"><span class="type-signature"><static> </span>image()</h4> + + +</dt> +<dd> + + + <div class="description"> + <p>locale</p> + </div> + + + + + + + + + + +<dl class="details"> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +</dl> + + + + + + + + + + + + + + + +</dd> + + + +<hr> +<dt> <h4 class="name" id=".image"><span class="type-signature"><static> </span>image()</h4> @@ -636,6 +5501,84 @@ <hr> <dt> + <h4 class="name" id=".locale"><span class="type-signature"><static> </span>locale()</h4> + + +</dt> +<dd> + + + <div class="description"> + <p>locale</p> + </div> + + + + + + + + + + +<dl class="details"> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +</dl> + + + + + + + + + + + + + + + +</dd> + + + +<hr> +<dt> <h4 class="name" id=".number"><span class="type-signature"><static> </span>number(options)</h4> @@ -696,6 +5639,286 @@ + <td class="description last"><p>{min, max, precision}</p></td> + </tr> + + + </tbody> +</table> + + + + +<dl class="details"> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +</dl> + + + + + + + + + + + + + + + +</dd> + + + +<hr> +<dt> + <h4 class="name" id=".number"><span class="type-signature"><static> </span>number(options)</h4> + + +</dt> +<dd> + + + <div class="description"> + <p>returns a single random number based on a max number or range</p> + </div> + + + + + + + + + <h5>Parameters:</h5> + + +<table class="params table table-striped"> + <thead> + <tr> + + <th>Name</th> + + + <th>Type</th> + + + + + + <th class="last">Description</th> + </tr> + </thead> + + <tbody> + + + <tr> + + <td class="name"><code>options</code></td> + + + <td class="type"> + + +<span class="param-type">mixed</span> + + + + + </td> + + + + + + <td class="description last"><p>{min, max, precision}</p></td> + </tr> + + + </tbody> +</table> + + + + +<dl class="details"> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +</dl> + + + + + + + + + + + + + + + +</dd> + + + +<hr> +<dt> + <h4 class="name" id=".objectElement"><span class="type-signature"><static> </span>objectElement(object, field)</h4> + + +</dt> +<dd> + + + <div class="description"> + <p>takes an object and returns the randomly key or value</p> + </div> + + + + + + + + + <h5>Parameters:</h5> + + +<table class="params table table-striped"> + <thead> + <tr> + + <th>Name</th> + + + <th>Type</th> + + + + + + <th class="last">Description</th> + </tr> + </thead> + + <tbody> + + + <tr> + + <td class="name"><code>object</code></td> + + + <td class="type"> + + +<span class="param-type">object</span> + + + + + </td> + + + + + + <td class="description last"></td> + </tr> + + + + <tr> + + <td class="name"><code>field</code></td> + + + <td class="type"> + + +<span class="param-type">mixed</span> + + + + + </td> + + + + + <td class="description last"></td> </tr> @@ -994,6 +6217,84 @@ <hr> <dt> + <h4 class="name" id=".uuid"><span class="type-signature"><static> </span>uuid()</h4> + + +</dt> +<dd> + + + <div class="description"> + <p>uuid</p> + </div> + + + + + + + + + + +<dl class="details"> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +</dl> + + + + + + + + + + + + + + + +</dd> + + + +<hr> +<dt> <h4 class="name" id=".word"><span class="type-signature"><static> </span>word(type)</h4> @@ -1122,6 +6423,262 @@ <hr> <dt> + <h4 class="name" id=".word"><span class="type-signature"><static> </span>word(type)</h4> + + +</dt> +<dd> + + + <div class="description"> + <p>word</p> + </div> + + + + + + + + + <h5>Parameters:</h5> + + +<table class="params table table-striped"> + <thead> + <tr> + + <th>Name</th> + + + <th>Type</th> + + + + + + <th class="last">Description</th> + </tr> + </thead> + + <tbody> + + + <tr> + + <td class="name"><code>type</code></td> + + + <td class="type"> + + +<span class="param-type">string</span> + + + + + </td> + + + + + + <td class="description last"></td> + </tr> + + + </tbody> +</table> + + + + +<dl class="details"> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +</dl> + + + + + + + + + + + + + + + +</dd> + + + +<hr> +<dt> + <h4 class="name" id=".words"><span class="type-signature"><static> </span>words(count)</h4> + + +</dt> +<dd> + + + <div class="description"> + <p>randomWords</p> + </div> + + + + + + + + + <h5>Parameters:</h5> + + +<table class="params table table-striped"> + <thead> + <tr> + + <th>Name</th> + + + <th>Type</th> + + + + + + <th class="last">Description</th> + </tr> + </thead> + + <tbody> + + + <tr> + + <td class="name"><code>count</code></td> + + + <td class="type"> + + +<span class="param-type">number</span> + + + + + </td> + + + + + + <td class="description last"><p>defaults to a random value between 1 and 3</p></td> + </tr> + + + </tbody> +</table> + + + + +<dl class="details"> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +</dl> + + + + + + + + + + + + + + + +</dd> + + + +<hr> +<dt> <h4 class="name" id=".words"><span class="type-signature"><static> </span>words(count)</h4> @@ -1273,28 +6830,30 @@ </div> </div> -<div class="modal fade" id="searchResults"> - <div class="modal-dialog"> - <div class="modal-content"> - <div class="modal-header"> - <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">×</span></button> - <h4 class="modal-title">Search results</h4> - </div> - <div class="modal-body"></div> - <div class="modal-footer"> - <button type="button" class="btn btn-default" data-dismiss="modal">Close</button> - </div> - </div><!-- /.modal-content --> - </div><!-- /.modal-dialog --> -</div> + + <div class="modal fade" id="searchResults"> + <div class="modal-dialog"> + <div class="modal-content"> + <div class="modal-header"> + <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">×</span></button> + <h4 class="modal-title">Search results</h4> + </div> + <div class="modal-body"></div> + <div class="modal-footer"> + <button type="button" class="btn btn-default" data-dismiss="modal">Close</button> + </div> + </div><!-- /.modal-content --> + </div><!-- /.modal-dialog --> + </div> + <footer> <span class="jsdoc-message"> - Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.4.3</a> + Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.6.5</a> - on 2017-02-21T13:01:35-05:00 + on 2020-08-26T18:35:43-04:00 using the <a href="https://github.com/docstrap/docstrap">DocStrap template</a>. </span> @@ -1302,7 +6861,9 @@ <script src="scripts/docstrap.lib.js"></script> <script src="scripts/toc.js"></script> -<script type="text/javascript" src="scripts/fulltext-search-ui.js"></script> + + <script type="text/javascript" src="scripts/fulltext-search-ui.js"></script> + <script> $( function () { @@ -1312,7 +6873,7 @@ $( function () { $this.attr( "id", $this.attr( "id" ).replace( "$", "__" ) ); } ); - $( ".tutorial-section pre, .readme-section pre" ).each( function () { + $( ".tutorial-section pre, .readme-section pre, pre.prettyprint.source" ).each( function () { var $this = $( this ); var example = $this.find( "code" ); @@ -1348,8 +6909,7 @@ $( function () { } ); $( "#toc" ).toc( { anchorName : function ( i, heading, prefix ) { - var id = $( heading ).attr( "id" ); - return id && id.replace(/\~/g, '-inner-').replace(/\./g, '-static-') || ( prefix + i ); + return $( heading ).attr( "id" ) || ( prefix + i ); }, selectors : "#toc-content h1,#toc-content h2,#toc-content h3,#toc-content h4", showAndHide : false, @@ -1375,11 +6935,13 @@ $( function () { <!--Google Analytics--> -<script type="text/javascript"> - $(document).ready(function() { - SearcherDisplay.init(); - }); -</script> + + <script type="text/javascript"> + $(document).ready(function() { + SearcherDisplay.init(); + }); + </script> + </body> </html>
\ No newline at end of file |
