Passed
Push — 6.0 ( e6360e...a5ddb0 )
by Olivier
01:38
created

LocalizedLocale   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 12
Duplicated Lines 0 %

Importance

Changes 0
Metric Value
eloc 4
dl 0
loc 12
rs 10
c 0
b 0
f 0
wmc 1

1 Method

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 5 1
1
<?php
2
3
namespace ICanBoogie\CLDR;
4
5
/**
6
 * A localized locale.
7
 *
8
 * @extends LocalizedObject<Locale>
9
 */
10
class LocalizedLocale extends LocalizedObject
11
{
12
    /**
13
     * @var string The localized name of the locale.
14
     */
15
    public readonly string $name;
16
17
    public function __construct(Locale $target, Locale $locale)
18
    {
19
        $this->name = $locale['languages'][$target->id->value];
0 ignored issues
show
Bug introduced by
The property name is declared read-only in ICanBoogie\CLDR\LocalizedLocale.
Loading history...
20
21
        parent::__construct($target, $locale);
22
    }
23
}
24