Compartilhar via


ArraySet.ValueAt(Int32) Method

Definition

Return the value at the given index in the array.

[Android.Runtime.Register("valueAt", "(I)Ljava/lang/Object;", "", ApiSince=23)]
public Java.Lang.Object? ValueAt (int index);
[<Android.Runtime.Register("valueAt", "(I)Ljava/lang/Object;", "", ApiSince=23)>]
member this.ValueAt : int -> Java.Lang.Object

Parameters

index
Int32

The desired index, must be between 0 and #size()-1.

Returns

Returns the value stored at the given index.

Attributes

Remarks

Return the value at the given index in the array.

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.ArraySet.valueAt(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