| 1 | <?php |
||
| 10 | abstract class Gtin extends Luhn |
||
| 11 | { |
||
| 12 | const HYPHENS = ['‐', '-', ' ']; // regular dash, authentic hyphen (rare!) and space |
||
| 13 | |||
| 14 | /** |
||
| 15 | * {@inheritdoc} |
||
| 16 | */ |
||
| 17 | public static function check($gtin, $length, $unDecorate = true, $hyphens = self::HYPHENS) |
||
| 21 | |||
| 22 | /** |
||
| 23 | * {@inheritdoc} |
||
| 24 | */ |
||
| 25 | public static function unDecorate($gtin, $hyphens = self::HYPHENS) |
||
| 29 | } |
||
| 30 |