Sdílet prostřednictvím


BaseBundle.GetBoolean Method

Definition

Overloads

GetBoolean(String)

Returns the value associated with the given key, or false if no mapping of the desired type exists for the given key.

GetBoolean(String, Boolean)

Returns the value associated with the given key, or defaultValue if no mapping of the desired type exists for the given key.

GetBoolean(String)

Returns the value associated with the given key, or false if no mapping of the desired type exists for the given key.

[Android.Runtime.Register("getBoolean", "(Ljava/lang/String;)Z", "GetGetBoolean_Ljava_lang_String_Handler", ApiSince=22)]
public virtual bool GetBoolean (string? key);
[<Android.Runtime.Register("getBoolean", "(Ljava/lang/String;)Z", "GetGetBoolean_Ljava_lang_String_Handler", ApiSince=22)>]
abstract member GetBoolean : string -> bool
override this.GetBoolean : string -> bool

Parameters

key
String

a String

Returns

a boolean value

Attributes

Remarks

Returns the value associated with the given key, or false if no mapping of the desired type exists for the given key.

Java documentation for android.os.BaseBundle.getBoolean(java.lang.String).

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

GetBoolean(String, Boolean)

Returns the value associated with the given key, or defaultValue if no mapping of the desired type exists for the given key.

[Android.Runtime.Register("getBoolean", "(Ljava/lang/String;Z)Z", "GetGetBoolean_Ljava_lang_String_ZHandler", ApiSince=22)]
public virtual bool GetBoolean (string? key, bool defaultValue);
[<Android.Runtime.Register("getBoolean", "(Ljava/lang/String;Z)Z", "GetGetBoolean_Ljava_lang_String_ZHandler", ApiSince=22)>]
abstract member GetBoolean : string * bool -> bool
override this.GetBoolean : string * bool -> bool

Parameters

key
String

a String

defaultValue
Boolean

Value to return if key does not exist

Returns

a boolean value

Attributes

Remarks

Returns the value associated with the given key, or defaultValue if no mapping of the desired type exists for the given key.

Java documentation for android.os.BaseBundle.getBoolean(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