final class RandomCharacters

Draws a fixed number of bytes from a caller-supplied alphabet using Faker. Contains no identifier, literal, quoting or database rules.

Methods§

public function string(string $alphabet, int $length): string

Draws a string of a given length from an alphabet.

Parameters

$alphabetstringCharacters that may appear
$lengthintHow many characters to draw

Returns

string String of that length, empty when no characters were asked for
Test cases 4
Called from 12
Calls 1

Private surface 1§

Implementation details, listed for orientation only.

private Generator $faker

Test cases 19§

Test cases that cover or call this symbol, from the coverage report and from the analyzed test sources.

Dedicated tests 5
Other tests reaching this symbol 14

Relations§

Instantiated in 3
Method calls 15
Type declarations 3