Android Guides | Samples

Android.OS.BaseBundle.GetInt Method

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

Syntax

[Android.Runtime.Register("getInt", "(Ljava/lang/String;I)I", "GetGetInt_Ljava_lang_String_IHandler")]
public virtual Int32 GetInt (String key, Int32 defaultValue)

Parameters

key
a String
defaultValue
Value to return if key does not exist

Remarks

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

[Android Documentation]

Requirements

Namespace: Android.OS
Assembly: Mono.Android (in Mono.Android.dll)
Assembly Versions: 0.0.0.0