Share via


SparseArray.RemoveAt(Int32) Method

Definition

Removes the mapping at the specified index.

[Android.Runtime.Register("removeAt", "(I)V", "GetRemoveAt_IHandler")]
public virtual void RemoveAt (int index);
[<Android.Runtime.Register("removeAt", "(I)V", "GetRemoveAt_IHandler")>]
abstract member RemoveAt : int -> unit
override this.RemoveAt : int -> unit

Parameters

index
Int32
Attributes

Remarks

Removes the mapping at the specified index.

For indices outside of the range 0...size()-1, the behavior is undefined for apps targeting android.os.Build.VERSION_CODES#P and earlier, and an ArrayIndexOutOfBoundsException is thrown for apps targeting android.os.Build.VERSION_CODES#Q and later.

Java documentation for android.util.SparseArray.removeAt(int).

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