1 | <?php namespace Propaganistas\LaravelPhone\Traits; |
||
7 | trait ParsesTypes |
||
8 | { |
||
9 | /** |
||
10 | * Array of available phone formats. |
||
11 | * |
||
12 | * @var array |
||
13 | */ |
||
14 | protected static $types; |
||
15 | |||
16 | /** |
||
17 | * Determine whether the given type is valid. |
||
18 | * |
||
19 | * @param string $type |
||
20 | * @return bool |
||
21 | */ |
||
22 | public static function isType($type) |
||
26 | |||
27 | /** |
||
28 | * Parse a phone type. |
||
29 | * |
||
30 | * @param string|array $types |
||
31 | * @return array |
||
32 | */ |
||
33 | protected static function parseTypes($types) |
||
49 | |||
50 | /** |
||
51 | * Parse a phone type into its string representation. |
||
52 | * |
||
53 | * @param string|array $types |
||
54 | * @return array |
||
55 | */ |
||
56 | protected static function parseTypesAsStrings($types) |
||
74 | |||
75 | |||
76 | /** |
||
77 | * Load all available formats once. |
||
78 | */ |
||
79 | private static function loadTypes() |
||
85 | } |