final class ByteChoices
Restricted visibility: declared "@visibility root". Code outside that scope must not name this declaration.

Consumes input choices while constructing an immutable generation plan.

Methods§

public function __construct(private string $bytes)
public function index(int $count): ?int

Returns a choice, or null when a complete choice is unavailable.

Parameters

$countint

Returns

?int

Throws

InvalidArgumentException When the candidate count is not positive
Test cases 3
Called from 2
Calls 3
public static function width(int $count): int

Counts the little-endian bytes used by both encoder and decoder.

Parameters

$countint

Returns

int

Throws

InvalidArgumentException When the candidate count is not positive
Test cases 4
Called from 1
Calls 2

Private surface 2§

Implementation details, listed for orientation only.

private int $position = 0
private string $bytes

Test cases 12§

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

Dedicated tests 4
Other tests reaching this symbol 8

Relations§

Instantiated in 2
Method calls 2