MtpDevice.GetPartialObject(Int32, Int64, Int64, Byte[]) Method

Definition

Obtains object bytes in the specified range and writes it to an array.

[Android.Runtime.Register("getPartialObject", "(IJJ[B)J", "", ApiSince=24)]
public long GetPartialObject (int objectHandle, long offset, long size, byte[] buffer);
[<Android.Runtime.Register("getPartialObject", "(IJJ[B)J", "", ApiSince=24)>]
member this.GetPartialObject : int * int64 * int64 * byte[] -> int64

Parameters

objectHandle
Int32

handle of the object to read

offset
Int64

Start index of reading range. It must be a non-negative value at most 0xffffffff.

size
Int64

Size of reading range. It must be a non-negative value at most Integer.MAX_VALUE or 0xffffffff. If 0xffffffff is specified, the method obtains the full bytes of object.

buffer
Byte[]

Array to write data.

Returns

Size of bytes that are actually read.

Attributes

Remarks

Obtains object bytes in the specified range and writes it to an array. This call may block for an arbitrary amount of time depending on the size of the data and speed of the devices.

Java documentation for android.mtp.MtpDevice.getPartialObject(int, long, long, byte[]).

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