blob: b2655cdb0e6d5f90e04d93ca2d7c090e512a07cd (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
|
<?php
class LanguageDTO {
public $Label;
public $Name;
public function __construct(string $name) {
$this->Name = $name;
$this->Label = sprintf(
'[%s] %s',
$this->Name,
Locale::getDisplayLanguage($this->Name)
);
}
public static function __compare(LanguageDTO $l1, LanguageDTO $l2) {
return strcmp($l1->Name, $l2->Name);
}
}
?>
|