Page MenuHomeWickedGov Phorge

RandSource.php
No OneTemporary

Size
512 B
Referenced Files
None
Subscribers
None

RandSource.php

<?php
namespace Eris\Random;
class RandSource implements Source
{
/**
* Returns a random number between 0 and @see max().
* @return integer
*/
public function extractNumber()
{
return rand(0, $this->max());
}
/**
* @return integer
*/
public function max()
{
return getrandmax();
}
/**
* @param integer $seed
* @return self
*/
public function seed($seed)
{
srand($seed);
return $this;
}
}

File Metadata

Mime Type
text/x-php
Expires
Sat, Oct 3, 09:26 (1 w, 3 d ago)
Storage Engine
local-disk
Storage Format
Raw Data
Storage Handle
9f/86/08e814636f83a7152c4d8736e2bd
Default Alt Text
RandSource.php (512 B)

Event Timeline