ByteBuffer.GetShort(Int32) Method

Definition

Absolute get method for reading a short value.

[Android.Runtime.Register("getShort", "(I)S", "GetGetShort_IHandler")]
public abstract short GetShort (int index);
[<Android.Runtime.Register("getShort", "(I)S", "GetGetShort_IHandler")>]
abstract member GetShort : int -> int16

Parameters

index
Int32

The index from which the bytes will be read

Returns

The short value at the given index

Attributes

Exceptions

if index is invalid.

Remarks

Absolute get method for reading a short value.

Reads two bytes at the given index, composing them into a short value according to the current byte order.

Java documentation for java.nio.ByteBuffer.getShort(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