Share via


AconfigPackage.GetBooleanFlagValue(String, Boolean) Method

Definition

Retrieves the value of a boolean flag.

[Android.Runtime.Register("getBooleanFlagValue", "(Ljava/lang/String;Z)Z", "GetGetBooleanFlagValue_Ljava_lang_String_ZHandler", ApiSince=36)]
public virtual bool GetBooleanFlagValue(string flagName, bool defaultValue);
[<Android.Runtime.Register("getBooleanFlagValue", "(Ljava/lang/String;Z)Z", "GetGetBooleanFlagValue_Ljava_lang_String_ZHandler", ApiSince=36)>]
abstract member GetBooleanFlagValue : string * bool -> bool
override this.GetBooleanFlagValue : string * bool -> bool

Parameters

flagName
String

The name of the flag (excluding any package name prefix).

defaultValue
Boolean

The value to return if the flag is not found.

Returns

The boolean value of the flag, or defaultValue if the flag is not found.

Attributes

Remarks

Retrieves the value of a boolean flag.

This method retrieves the value of the specified flag. If the flag exists within the loaded Aconfig Package, its value is returned. Otherwise, the provided `defaultValue` is returned.

Java documentation for android.os.flagging.AconfigPackage.getBooleanFlagValue(java.lang.String, boolean).

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