RandomAccessFile.SkipBytes(Int32) Method

Definition

Attempts to skip over n bytes of input discarding the skipped bytes.

[Android.Runtime.Register("skipBytes", "(I)I", "GetSkipBytes_IHandler")]
public virtual int SkipBytes (int n);
[<Android.Runtime.Register("skipBytes", "(I)I", "GetSkipBytes_IHandler")>]
abstract member SkipBytes : int -> int
override this.SkipBytes : int -> int

Parameters

n
Int32

the number of bytes to be skipped.

Returns

the actual number of bytes skipped.

Implements

Attributes

Exceptions

if this file is closed or another I/O error occurs.

Remarks

Attempts to skip over n bytes of input discarding the skipped bytes.

This method may skip over some smaller number of bytes, possibly zero. This may result from any of a number of conditions; reaching end of file before n bytes have been skipped is only one possibility. This method never throws an EOFException. The actual number of bytes skipped is returned. If n is negative, no bytes are skipped.

Java documentation for java.io.RandomAccessFile.skipBytes(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