Table of Contents

GetCountry Method

Definition

Namespace
Cuemon.Globalization
Assemblies
Cuemon.Core.dll
Source
src/Cuemon.Core/Globalization/World.cs

GetCountry(string)

Gets a country by its UN M.49 code.

public static StatisticalRegionInfo GetCountry(string m49Code)

Parameters

m49Code string

The three-digit UN M.49 country code (e.g., "840" for United States).

Returns

StatisticalRegionInfo

A StatisticalRegionInfo instance with CountryOrTerritory, or null if the code is not found.

GetCountry(RegionInfo)

Gets the UN M.49 country information for the specified RegionInfo.

public static StatisticalRegionInfo GetCountry(RegionInfo region)

Parameters

region RegionInfo

The .NET region information.

Returns

StatisticalRegionInfo

A StatisticalRegionInfo instance, or null if no mapping exists.

Exceptions

ArgumentNullException

region is null.