1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51
|
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8">
<title>Passenger: Passenger::RandomGenerator Class Reference</title>
<link href="tabs.css" rel="stylesheet" type="text/css">
<link href="doxygen.css" rel="stylesheet" type="text/css">
</head><body>
<!-- Generated by Doxygen 1.5.8 -->
<div class="navigation" id="top">
<div class="tabs">
<ul>
<li><a href="main.html"><span>Main Page</span></a></li>
<li><a href="modules.html"><span>Modules</span></a></li>
<li><a href="namespaces.html"><span>Namespaces</span></a></li>
<li class="current"><a href="annotated.html"><span>Classes</span></a></li>
<li><a href="files.html"><span>Files</span></a></li>
</ul>
</div>
<div class="tabs">
<ul>
<li><a href="annotated.html"><span>Class List</span></a></li>
<li><a href="hierarchy.html"><span>Class Hierarchy</span></a></li>
<li><a href="functions.html"><span>Class Members</span></a></li>
</ul>
</div>
<div class="navpath"><a class="el" href="namespacePassenger.html">Passenger</a>::<a class="el" href="classPassenger_1_1RandomGenerator.html">RandomGenerator</a>
</div>
</div>
<div class="contents">
<h1>Passenger::RandomGenerator Class Reference</h1><!-- doxytag: class="Passenger::RandomGenerator" -->A random data generator.
<a href="#_details">More...</a>
<p>
<code>#include <<a class="el" href="RandomGenerator_8h-source.html">RandomGenerator.h</a>></code>
<p>
<p>
<a href="classPassenger_1_1RandomGenerator-members.html">List of all members.</a><table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
</table>
<hr><a name="_details"></a><h2>Detailed Description</h2>
A random data generator.
<p>
Data is generated using /dev/urandom, and is cryptographically secure. Unlike rand() and friends, <a class="el" href="classPassenger_1_1RandomGenerator.html" title="A random data generator.">RandomGenerator</a> does not require seeding.<p>
The reason why <a class="el" href="classPassenger_1_1RandomGenerator.html" title="A random data generator.">RandomGenerator</a> isn't a singleton is because opening /dev/urandom is *very* slow on Mac OS X and OpenBSD. Each object of this class caches the /dev/urandom file handle.<p>
This class is thread-safe as long as there are no concurrent calls to reopen() or close(). <hr>The documentation for this class was generated from the following file:<ul>
<li><a class="el" href="RandomGenerator_8h-source.html">RandomGenerator.h</a></ul>
</div>
<hr size="1"><address style="text-align: right;"><small>Generated on Sun Feb 21 12:22:48 2010 for Passenger by
<a href="http://www.doxygen.org/index.html">
<img src="doxygen.png" alt="doxygen" align="middle" border="0"></a> 1.5.8 </small></address>
</body>
</html>
|