프로퍼티 | 타입 | 설명 | |
---|---|---|---|
$dataCache | array | Cached data. | |
$dataDir | string | Path to the directory containing countries data. | |
$dataSources | array | Available data sources. |
메소드 | 설명 | |
---|---|---|
__construct ( string | null $dataDir = null ) | Constructor. | |
getDataDir ( ) : string | ||
getList ( string $locale = 'en', string $format = 'php', string $source = 'cldr' ) : array | Returns a list of countries. | |
getOne ( string $countryCode, string $locale = 'en', string $source = 'cldr' ) : string | Returns one country. | |
has ( string $countryCode, string $locale = 'en', string $source = 'cldr' ) : boolean | Indicates whether or not a given $countryCode matches a country. | |
setList ( string $locale, string $source, array $data ) : |
메소드 | 설명 | |
---|---|---|
loadData ( string $locale, string $source, string $format ) : array | A lazy-loader that loads data from a PHP file if it is not stored in memory yet. | |
sortData ( string $locale, array $data ) : array | Sorts the data array for a given locale, using the locale translations. |
public __construct ( string | null $dataDir = null ) | ||
$dataDir | string | null | Path to the directory containing countries data |
protected string $dataDir | ||
리턴 | string |