IDataOutput.WriteInt(Int32) Method

Definition

Writes an int value, which is comprised of four bytes, to the output stream.

[Android.Runtime.Register("writeInt", "(I)V", "GetWriteInt_IHandler:Java.IO.IDataOutputInvoker, Mono.Android, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null")]
public void WriteInt (int v);
[<Android.Runtime.Register("writeInt", "(I)V", "GetWriteInt_IHandler:Java.IO.IDataOutputInvoker, Mono.Android, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null")>]
abstract member WriteInt : int -> unit

Parameters

v
Int32

the int value to be written.

Attributes

Exceptions

if an I/O error occurs while writing.

Remarks

Writes an int value, which is comprised of four bytes, to the output stream. The byte values to be written, in the order shown, are:

{@code
            (byte)(0xff & (v >> 24))
            (byte)(0xff & (v >> 16))
            (byte)(0xff & (v >>  8))
            (byte)(0xff & v)
            }

The bytes written by this method may be read by the readInt method of interface DataInput , which will then return an int equal to v.

Java documentation for java.io.DataOutput.writeInt(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

See also