Total Complexity | 6 |
Total Lines | 63 |
Duplicated Lines | 0 % |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
5 | enum PaymentMethods: int |
||
6 | { |
||
7 | case CreditCard = 0; |
||
8 | case Cash = 3; |
||
9 | case eBanking = 4; |
||
10 | case VivaWallet = 8; |
||
11 | case iDEAL = 10; |
||
12 | case P24 = 11; |
||
13 | case BLIK = 12; |
||
14 | case PayU = 13; |
||
15 | case giropay = 15; |
||
16 | case Sofort = 16; |
||
17 | case EPS = 17; |
||
18 | case WeChatPay = 18; |
||
19 | case BitPay = 19; |
||
20 | case PayPal = 23; |
||
21 | case Trustly = 24; |
||
22 | case Klarna = 26; |
||
23 | case BancontactQR = 27; |
||
24 | case Payconiq = 28; |
||
25 | case IRIS = 29; |
||
26 | case PayByBank = 30; |
||
27 | case MBWAY = 31; |
||
28 | case MULTIBANCO = 32; |
||
29 | case TbiBank = 34; |
||
30 | case PayOnDelivery = 35; |
||
31 | case MobilePayOnline = 36; |
||
32 | case BANCOMATPay = 37; |
||
33 | case Bluecode = 41; |
||
34 | case Satispay = 43; |
||
35 | case Swish = 221; |
||
36 | |||
37 | /** |
||
38 | * Return value as string |
||
39 | * Enums\PaymentMethods::fromName('Dias'); |
||
40 | */ |
||
41 | |||
42 | |||
43 | public static function fromName(string $name): int |
||
51 | } |
||
52 | |||
53 | |||
54 | |||
55 | /** |
||
56 | * Return value as string |
||
57 | * Enums\PaymentMethods::fromValue(15); |
||
58 | */ |
||
59 | |||
60 | public static function fromValue(int $value): string |
||
72 | } |