Mac Guides | Samples

MonoMac.Foundation.NSLocale Class

Encapsulates parameters about user language, cultural and technical conventions.

See Also: NSLocale

Syntax

[MonoMac.Foundation.Register("NSLocale", true)]
public class NSLocale : NSObject

Remarks

You can access the current local information for the device using NSLocale.CurrentLocale or construct a specific locale passing a locale code, for example 'new NSLocale ("es_ES_PREEURO"). You can get a list of the available device locale identifiers using the static NSLocale.AvailableLocaleIdentifiers property.

Your application can be notified of changes in the system local by using the NSLocale.CurrentLocaleDidChangeNotification as the notification to monitor with NSNotificationCenter.

Requirements

Namespace: MonoMac.Foundation
Assembly: XamMac (in XamMac.dll)
Assembly Versions: 0.0.0.0

The members of MonoMac.Foundation.NSLocale are listed below.

See Also: NSObject

Public Constructors

A constructor that initializes the object from the data stored in the unarchiver object.
Constructor to call on derived classes when the derived class has an [Export] constructor.
A constructor used when creating managed representations of unmanaged objects; Called by the runtime.

Public Properties

[read-only]
static
AutoUpdatingCurrentLocaleNSLocale.
[read-only]
static
AvailableLocaleIdentifiersString[]. Returns an array of available locale identifiers.
[read-only]
override
ClassHandleIntPtr. The handle for this class.
[read-only]
static
CommonISOCurrencyCodesString[].
[read-only]
static
CurrentLocaleNSLocale.
[read-only]
static
CurrentLocaleDidChangeNotificationNSString. Notification constant for CurrentLocaleDidChange
[read-only]
static
ISOCountryCodesString[].
[read-only]
static
ISOCurrencyCodesString[].
[read-only]
static
ISOLanguageCodesString[].
[read-only]
LocaleIdentifierString.
[read-only]
static
PreferredLanguagesString[].
[read-only]
static
SystemLocaleNSLocale. The system locale.

Public Methods