Punic\Territory::getGrossDomesticProduct PHP Метод

getGrossDomesticProduct() публичный статический Метод

Return the GDP (Gross Domestic Product) for a specific territory, in US$.
public static getGrossDomesticProduct ( string $territoryCode ) : number | null
$territoryCode string The territory code
Результат number | null Return the GDP of the specified territory (or null if $territoryCode is not valid or no data is available)
    public static function getGrossDomesticProduct($territoryCode)
    {
        $result = null;
        $info = self::getTerritoryInfo($territoryCode);
        if (is_array($info)) {
            $result = $info['gdp'];
        }
        return $result;
    }