| 1 | <?php |
||
| 10 | final class SequenceSet |
||
| 11 | { |
||
| 12 | |||
| 13 | /** |
||
| 14 | * @var int |
||
| 15 | */ |
||
| 16 | private $first; |
||
| 17 | /** |
||
| 18 | * @var int |
||
| 19 | */ |
||
| 20 | private $last; |
||
| 21 | |||
| 22 | /** |
||
| 23 | * SequenceSet constructor. |
||
| 24 | * @param int $first |
||
| 25 | */ |
||
| 26 | public function __construct(int $first) |
||
| 30 | |||
| 31 | /** |
||
| 32 | * @return string |
||
| 33 | */ |
||
| 34 | public function __toString(): string |
||
| 42 | |||
| 43 | /** |
||
| 44 | * @param int $number |
||
| 45 | * @return SequenceSet |
||
| 46 | */ |
||
| 47 | public static function single(int $number): self |
||
| 53 | |||
| 54 | /** |
||
| 55 | * @param int $first |
||
| 56 | * @param int $last |
||
| 57 | * @return SequenceSet |
||
| 58 | */ |
||
| 59 | public static function sequence(int $first, int $last): self |
||
| 65 | } |