-
-
Notifications
You must be signed in to change notification settings - Fork 38
/
Copy pathPhoneNumberFormat.php
50 lines (44 loc) · 1.14 KB
/
PhoneNumberFormat.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
<?php
declare(strict_types=1);
namespace Brick\PhoneNumber;
/**
* Enum values for the phone number formats.
*/
enum PhoneNumberFormat: int
{
/**
* The E164 format.
*
* This consists of a + sign followed by a series of digits,
* comprising the country code and national number.
*
* Example: `+41446681800`.
*/
case E164 = 0;
/**
* The international format.
*
* This is similar to the E164 format, with extra formatting.
* This format is consistent with the definition in ITU-T Recommendation E123.
*
* Example: `+41 44 668 1800`.
*/
case INTERNATIONAL = 1;
/**
* The national format.
*
* This is the number as it would be composed from within the country, with formatting.
* This format is consistent with the definition in ITU-T Recommendation E123.
*
* Example: `044 668 1800`.
*/
case NATIONAL = 2;
/**
* The RFC 3966 format.
*
* This format outputs a `tel:` URI that can be used as an anchor link to start a VOIP call from a web page.
*
* Example: `tel:+41-44-668-1800`.
*/
case RFC3966 = 3;
}