| Total Complexity | 2 |
| Total Lines | 21 |
| Duplicated Lines | 0 % |
| Changes | 0 | ||
| 1 | <?php declare( strict_types=1 ); |
||
| 8 | abstract class Element { |
||
| 9 | /** |
||
| 10 | * Return a regex for matching the name of the element |
||
| 11 | * |
||
| 12 | * @return string |
||
| 13 | */ |
||
| 14 | abstract public function getRegex() : string; |
||
| 15 | |||
| 16 | /** |
||
| 17 | * Get a regex matching any element in the given array |
||
| 18 | * |
||
| 19 | * @param self[] $elements |
||
| 20 | * @return string |
||
| 21 | * @fixme Is this the right place? |
||
| 22 | */ |
||
| 23 | public static function regexFromArray( array $elements ) : string { |
||
| 31 |