Code Coverage |
||||||||||
Lines |
Functions and Methods |
Classes and Traits |
||||||||
| Total | |
100.00% |
1 / 1 |
|
100.00% |
1 / 1 |
CRAP | |
100.00% |
1 / 1 |
| Password | |
100.00% |
1 / 1 |
|
100.00% |
1 / 1 |
1 | |
100.00% |
1 / 1 |
| __construct | |
100.00% |
1 / 1 |
|
100.00% |
1 / 1 |
1 | |||
| 1 | <?php |
| 2 | |
| 3 | declare(strict_types=1); |
| 4 | |
| 5 | namespace Cosray\Config; |
| 6 | |
| 7 | final class Password |
| 8 | { |
| 9 | public function __construct( |
| 10 | private readonly \Cosray\Config $config, |
| 11 | ) {} |
| 12 | |
| 13 | /** @var positive-float */ |
| 14 | public float $entropy { |
| 15 | get => $this->config->get('password.entropy'); |
| 16 | } |
| 17 | |
| 18 | public int|string|null $algorithm { |
| 19 | get => $this->config->get('password.algorithm'); |
| 20 | } |
| 21 | } |