7fab2226cd013b2465771d555399f4f0e76d3aa0
[GitHub/Stricted/speedport-hybrid-php-api.git] / CryptLib / Random / Mixer.php
1 <?php
2 /**
3 * The Mixer strategy interface.
4 *
5 * All mixing strategies must implement this interface
6 *
7 * PHP version 5.3
8 *
9 * @category PHPCryptLib
10 * @package Random
11 * @author Anthony Ferrara <ircmaxell@ircmaxell.com>
12 * @copyright 2011 The Authors
13 * @license http://www.opensource.org/licenses/mit-license.html MIT License
14 * @version Build @@version@@
15 */
16
17 namespace CryptLib\Random;
18
19 /**
20 * The Mixer strategy interface.
21 *
22 * All mixing strategies must implement this interface
23 *
24 * @category PHPCryptLib
25 * @package Random
26 * @author Anthony Ferrara <ircmaxell@ircmaxell.com>
27 * @codeCoverageIgnore
28 */
29 interface Mixer {
30
31 /**
32 * Return an instance of Strength indicating the strength of the mixer
33 *
34 * @return Strength An instance of one of the strength classes
35 */
36 public static function getStrength();
37
38 /**
39 * Test to see if the mixer is available
40 *
41 * @return boolean If the mixer is available on the system
42 */
43 public static function test();
44
45 /**
46 * Mix the provided array of strings into a single output of the same size
47 *
48 * All elements of the array should be the same size.
49 *
50 * @param array $parts The parts to be mixed
51 *
52 * @return string The mixed result
53 */
54 public function mix(array $parts);
55
56 }