1 | <?php |
||
24 | abstract class AbstractOperatingSystem implements OperatingSystem |
||
25 | { |
||
26 | /** |
||
27 | * @param string $userAgent |
||
28 | * |
||
29 | * @return boolean |
||
30 | */ |
||
31 | 19 | public function match(string $userAgent): bool |
|
41 | |||
42 | /** |
||
43 | * @return array |
||
44 | */ |
||
45 | abstract protected function getPatterns(): array; |
||
46 | |||
47 | /** |
||
48 | * @param string|OperatingSystem $operatingSystem |
||
49 | * |
||
50 | * @return boolean |
||
51 | * |
||
52 | * @throws \InvalidArgumentException |
||
53 | */ |
||
54 | 4 | public function equals($operatingSystem): bool |
|
68 | } |
||
69 |