Language

LocaleConfig Constructors

Definition

Overloads

Name Description
LocaleConfig(Context)

Returns an override LocaleConfig if it has been set via LocaleManager#setOverrideLocaleConfig(LocaleConfig).

LocaleConfig(LocaleList)

Return the LocaleConfig with any sequence of locales combined into a LocaleList.

LocaleConfig(IntPtr, JniHandleOwnership)

Initializes a managed representation of an existing Java Native Interface object.

LocaleConfig(Context)

Returns an override LocaleConfig if it has been set via LocaleManager#setOverrideLocaleConfig(LocaleConfig).

[Android.Runtime.Register(".ctor", "(Landroid/content/Context;)V", "", ApiSince=33)]
public LocaleConfig(Android.Content.Context context);
[<Android.Runtime.Register(".ctor", "(Landroid/content/Context;)V", "", ApiSince=33)>]
new Android.App.LocaleConfig : Android.Content.Context -> Android.App.LocaleConfig

Parameters

context
Context

the context of the application.

Attributes

Remarks

Returns an override LocaleConfig if it has been set via LocaleManager.setOverrideLocaleConfig(LocaleConfig). Otherwise, returns the LocaleConfig from the application resources.

Android reference for android.app.LocaleConfig.LocaleConfig.

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to

LocaleConfig(LocaleList)

Return the LocaleConfig with any sequence of locales combined into a LocaleList.

[Android.Runtime.Register(".ctor", "(Landroid/os/LocaleList;)V", "", ApiSince=34)]
public LocaleConfig(Android.OS.LocaleList locales);
[<Android.Runtime.Register(".ctor", "(Landroid/os/LocaleList;)V", "", ApiSince=34)>]
new Android.App.LocaleConfig : Android.OS.LocaleList -> Android.App.LocaleConfig

Parameters

locales
LocaleList

the desired locales for a specified application

Attributes

Remarks

Return the LocaleConfig with any sequence of locales combined into a LocaleList. Applications seeking to create an override LocaleConfig should use this constructor to first create the LocaleConfig they intend the system to see as the override. Creating it does not automatically make it the override config for an application. To persist it and affect the system's understanding of app-supported resources, set OverrideLocaleConfig to the new LocaleConfig.

Android reference for android.app.LocaleConfig.LocaleConfig.

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to

LocaleConfig(IntPtr, JniHandleOwnership)

Initializes a managed representation of an existing Java Native Interface object.

protected LocaleConfig(IntPtr javaReference, Android.Runtime.JniHandleOwnership transfer);
new Android.App.LocaleConfig : nativeint * Android.Runtime.JniHandleOwnership -> Android.App.LocaleConfig

Parameters

javaReference
IntPtr

nativeint

The Java Native Interface object reference.

transfer
JniHandleOwnership

Specifies how the runtime handles the JNI reference, including its release and peer registration.

Remarks

This constructor is called by the .NET for Android binding runtime when it creates a managed peer for an existing Java object.

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to