Writer.Write Method

Definition

Overloads

Write(Char[])

Writes an array of characters.

Write(Int32)

Writes a single character.

Write(String)

Writes a string.

Write(Char[], Int32, Int32)

Writes a portion of an array of characters.

Write(String, Int32, Int32)

Writes a portion of a string.

Write(Char[])

Writes an array of characters.

[Android.Runtime.Register("write", "([C)V", "GetWrite_arrayCHandler")]
public virtual void Write (char[]? cbuf);
[<Android.Runtime.Register("write", "([C)V", "GetWrite_arrayCHandler")>]
abstract member Write : char[] -> unit
override this.Write : char[] -> unit

Parameters

cbuf
Char[]

Array of characters to be written

Attributes

Exceptions

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

Remarks

Writes an array of characters.

Java documentation for java.io.Writer.write(char[]).

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

Write(Int32)

Writes a single character.

[Android.Runtime.Register("write", "(I)V", "GetWrite_IHandler")]
public virtual void Write (int c);
[<Android.Runtime.Register("write", "(I)V", "GetWrite_IHandler")>]
abstract member Write : int -> unit
override this.Write : int -> unit

Parameters

c
Int32

int specifying a character to be written

Attributes

Exceptions

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

Remarks

Writes a single character. The character to be written is contained in the 16 low-order bits of the given integer value; the 16 high-order bits are ignored.

Subclasses that intend to support efficient single-character output should override this method.

Java documentation for java.io.Writer.write(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

Write(String)

Writes a string.

[Android.Runtime.Register("write", "(Ljava/lang/String;)V", "GetWrite_Ljava_lang_String_Handler")]
public virtual void Write (string? str);
[<Android.Runtime.Register("write", "(Ljava/lang/String;)V", "GetWrite_Ljava_lang_String_Handler")>]
abstract member Write : string -> unit
override this.Write : string -> unit

Parameters

str
String

String to be written

Attributes

Exceptions

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

Remarks

Writes a string.

Java documentation for java.io.Writer.write(java.lang.String).

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

Write(Char[], Int32, Int32)

Writes a portion of an array of characters.

[Android.Runtime.Register("write", "([CII)V", "GetWrite_arrayCIIHandler")]
public abstract void Write (char[]? cbuf, int off, int len);
[<Android.Runtime.Register("write", "([CII)V", "GetWrite_arrayCIIHandler")>]
abstract member Write : char[] * int * int -> unit

Parameters

cbuf
Char[]

Array of characters

off
Int32

Offset from which to start writing characters

len
Int32

Number of characters to write

Attributes

Exceptions

if offset or count , or if offset + count is greater than the size of buf.

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

Remarks

Writes a portion of an array of characters.

Java documentation for java.io.Writer.write(char[], int, 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

Write(String, Int32, Int32)

Writes a portion of a string.

[Android.Runtime.Register("write", "(Ljava/lang/String;II)V", "GetWrite_Ljava_lang_String_IIHandler")]
public virtual void Write (string? str, int off, int len);
[<Android.Runtime.Register("write", "(Ljava/lang/String;II)V", "GetWrite_Ljava_lang_String_IIHandler")>]
abstract member Write : string * int * int -> unit
override this.Write : string * int * int -> unit

Parameters

str
String

A String

off
Int32

Offset from which to start writing characters

len
Int32

Number of characters to write

Attributes

Exceptions

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

if offset or count , or if offset + count is greater than the length of str.

Remarks

Writes a portion of a string.

Java documentation for java.io.Writer.write(java.lang.String, int, 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