<?xml version="1.0" encoding="iso-8859-1"?>
<module name="Ft.Lib.Random" file="/work/a/ports/textproc/py-4suite-xml/work/4Suite-1.0b3/build/lib.freebsd-6.1-PRERELEASE-i386-2.4/Ft/Lib/Random.py">
  <modification-date>2005-10-17 02:30:05</modification-date>
  <abstract>Thread-safe random number generation</abstract>
  <description>We consider a physical source of entropy to be better than a simulated
one, so we will try to use one (/dev/urandom on posix, for example).
If a pseudo-random number generator is to be used, it should be seeded
from the physical source, if possible, rather than the usual custom of
seeding it from the system clock. Random number sources that are not
known to be thread-safe should be polled serially.

Copyright 2005 Fourthought, Inc. (USA).
Detailed license and copyright information: http://4suite.org/COPYRIGHT
Project home, documentation, distributions: http://4suite.org/</description>
  <functions>
    <function public="yes" name="GetRandomBytes" id="GetRandomBytes">
      <abstract>Returns numBytes random bytes from the best RNG available</abstract>
      <description/>
      <arguments>
        <arg name="numBytes"/>
      </arguments>
    </function>
    <function public="yes" name="Random" id="Random">
      <abstract>Returns a random float, n, where 0 &lt;= n &lt; 1</abstract>
      <description/>
      <arguments>
      </arguments>
    </function>
  </functions>
  <globals>
    <global public="no" name="__all__" id="__all__">
      <value>['dev_rand_fd', 'pseudo_rng', 'GetRandomBytes', 'Random']</value>
    </global>
    <global public="yes" name="dev_rand_fd" id="dev_rand_fd">
      <value>9</value>
    </global>
    <global public="no" name="lock" id="lock">
      <abstract>A lock object is a synchronization primitive.  To create a lock,
call the PyThread_allocate_lock() function.  Methods are:</abstract>
      <description>acquire() -- lock the lock, possibly blocking until it can be obtained
release() -- unlock of the lock
locked() -- test whether the lock is currently locked

A lock is not owned by the thread that locked it; another thread may
unlock it.  A thread attempting to lock a lock that it has already locked
will block until another thread unlocks it.  Deadlocks may ensue.</description>
      <value>&lt;thread.lock object&gt;</value>
    </global>
    <global public="yes" name="pseudo_rng" id="pseudo_rng">
      <abstract>Random number generator base class used by bound module functions.</abstract>
      <description>Used to instantiate instances of Random to get generators that don't
share state.  Especially useful for multi-threaded programs, creating
a different instance of Random for each thread, and using the jumpahead()
method to ensure that the generated sequences seen by each thread don't
overlap.

Class Random can also be subclassed if you want to use a different basic
generator of your own devising: in that case, override the following
methods:  random(), seed(), getstate(), setstate() and jumpahead().
Optionally, implement a getrandombits() method so that randrange()
can cover arbitrarily large ranges.</description>
      <value>&lt;random.Random object&gt;</value>
    </global>
    <global public="no" name="py22" id="py22">
      <value>False</value>
    </global>
  </globals>
</module>
