1 | <?php |
||
8 | class TypeUtils |
||
9 | { |
||
10 | /** |
||
11 | * Asserts that the input is an integerish, otherwise null will be returned. |
||
12 | * |
||
13 | * @param mixed $value The input value. |
||
14 | * |
||
15 | * @return integer|null |
||
16 | */ |
||
17 | public static function integerOrNull($value): ?int |
||
30 | |||
31 | /** |
||
32 | * @param int|float $num1 |
||
33 | * @param int|float $num2 |
||
34 | * |
||
35 | * @return int |
||
36 | */ |
||
37 | public static function compareNumbers($num1, $num2): ?int |
||
45 | } |
||
46 |