1 | <?php |
||
44 | class RandomBytes extends \RandomLib\AbstractSource |
||
45 | { |
||
46 | |||
47 | /** |
||
48 | * If the source is currently available. |
||
49 | * Reasons might be because the library is not installed |
||
50 | * |
||
51 | * @return bool |
||
52 | */ |
||
53 | public static function isSupported() |
||
57 | |||
58 | /** |
||
59 | * Return an instance of Strength indicating the strength of the source |
||
60 | * |
||
61 | * @return Strength An instance of one of the strength classes |
||
62 | */ |
||
63 | public static function getStrength() |
||
67 | |||
68 | /** |
||
69 | * Generate a random string of the specified size |
||
70 | * |
||
71 | * @param int $size The size of the requested random string |
||
72 | * |
||
73 | * @return string A string of the requested size |
||
74 | */ |
||
75 | public function generate($size) |
||
83 | } |
||
84 |