Scrutinizer GitHub App not installed

We could not synchronize checks via GitHub's checks API since Scrutinizer's GitHub App is not installed for this repository.

Install GitHub App

Completed
Pull Request — master (#1034)
by Henrique
02:29
created

RoSubdivisionCode   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 50
Duplicated Lines 0 %

Importance

Changes 0
Metric Value
wmc 1
dl 0
loc 50
c 0
b 0
f 0
rs 10

1 Method

Rating   Name   Duplication   Size   Complexity  
A getDataSource() 0 45 1
1
<?php
2
3
/*
4
 * This file is part of Respect/Validation.
5
 *
6
 * (c) Alexandre Gomes Gaigalas <[email protected]>
7
 *
8
 * For the full copyright and license information, please view the "LICENSE.md"
9
 * file that was distributed with this source code.
10
 */
11
12
declare(strict_types=1);
13
14
namespace Respect\Validation\Rules\Locale;
15
16
use Respect\Validation\Rules\AbstractSearcher;
17
18
/**
19
 * Validates whether an input is subdivision code of Romania or not.
20
 *
21
 * ISO 3166-1 alpha-2: RO
22
 *
23
 * @see http://www.geonames.org/RO/administrative-division-romania.html
24
 *
25
 * @author Henrique Moody <[email protected]>
26
 */
27
final class RoSubdivisionCode extends AbstractSearcher
28
{
29
    /**
30
     * {@inheritdoc}
31
     */
32
    protected function getDataSource(): array
33
    {
34
        return [
35
           'AB', // Alba
36
           'AG', // Arges
37
           'AR', // Arad
38
           'B', // Bucuresti
39
           'BC', // Bacau
40
           'BH', // Bihor
41
           'BN', // Bistrita-Nasaud
42
           'BR', // Braila
43
           'BT', // Botosani
44
           'BV', // Brasov
45
           'BZ', // Buzau
46
           'CJ', // Cluj
47
           'CL', // Calarasi
48
           'CS', // Caras-Severin
49
           'CT', // Constanta
50
           'CV', // Covasna
51
           'DB', // Dimbovita
52
           'DJ', // Dolj
53
           'GJ', // Gorj
54
           'GL', // Galati
55
           'GR', // Giurgiu
56
           'HD', // Hunedoara
57
           'HR', // Harghita
58
           'IF', // Ilfov
59
           'IL', // Ialomita
60
           'IS', // Iasi
61
           'MH', // Mehedinti
62
           'MM', // Maramures
63
           'MS', // Mures
64
           'NT', // Neamt
65
           'OT', // Olt
66
           'PH', // Prahova
67
           'SB', // Sibiu
68
           'SJ', // Salaj
69
           'SM', // Satu Mare
70
           'SV', // Suceava
71
           'TL', // Tulcea
72
           'TM', // Timis
73
           'TR', // Teleorman
74
           'VL', // Vilcea
75
           'VN', // Vrancea
76
           'VS', // Vaslui
77
       ];
78
    }
79
}
80