ly.img.android.pesdk.backend.exif / IOUtils / write

write

static fun write(data: kotlin.Array<byte>, output: java.io.OutputStream): void

Writes bytes from a byte[] to an OutputStream.

Parameters

data - kotlin.Array<byte>: the byte array to write, do not modify during output, null ignored

output - java.io.OutputStream: the OutputStream to write to

Exceptions

NullPointerException - if output is null

IOException - if an I/O error occurs

Since
Commons IO 1.1

static fun write(data: kotlin.Array<byte>, output: java.io.Writer): void

Writes bytes from a byte[] to chars on a Writer using the default character encoding of the platform.

This method uses String#String(byte[]).

Parameters

data - kotlin.Array<byte>: the byte array to write, do not modify during output, null ignored

output - java.io.Writer: the Writer to write to

Exceptions

NullPointerException - if output is null

IOException - if an I/O error occurs

Since
Commons IO 1.1

static fun write(data: kotlin.Array<byte>, output: java.io.Writer, encoding: java.lang.String): void

Writes bytes from a byte[] to chars on a Writer using the specified character encoding.

Character encoding names can be found at IANA.

This method uses String#String(byte[], String).

Parameters

data - kotlin.Array<byte>: the byte array to write, do not modify during output, null ignored

output - java.io.Writer: the Writer to write to

encoding - java.lang.String: the encoding to use, null means platform default

Exceptions

NullPointerException - if output is null

IOException - if an I/O error occurs

Since
Commons IO 1.1

static fun write(data: kotlin.Array<char>, output: java.io.Writer): void

Writes chars from a char[] to a Writer using the default character encoding of the platform.

Parameters

data - kotlin.Array<char>: the char array to write, do not modify during output, null ignored

output - java.io.Writer: the Writer to write to

Exceptions

NullPointerException - if output is null

IOException - if an I/O error occurs

Since
Commons IO 1.1

static fun write(data: kotlin.Array<char>, output: java.io.OutputStream): void

Writes chars from a char[] to bytes on an OutputStream.

This method uses String#String(char[]) and String#getBytes().

Parameters

data - kotlin.Array<char>: the char array to write, do not modify during output, null ignored

output - java.io.OutputStream: the OutputStream to write to

Exceptions

NullPointerException - if output is null

IOException - if an I/O error occurs

Since
Commons IO 1.1

static fun write(data: kotlin.Array<char>, output: java.io.OutputStream, encoding: java.lang.String): void

Writes chars from a char[] to bytes on an OutputStream using the specified character encoding.

Character encoding names can be found at IANA.

This method uses String#String(char[]) and String#getBytes(String).

Parameters

data - kotlin.Array<char>: the char array to write, do not modify during output, null ignored

output - java.io.OutputStream: the OutputStream to write to

encoding - java.lang.String: the encoding to use, null means platform default

Exceptions

NullPointerException - if output is null

IOException - if an I/O error occurs

Since
Commons IO 1.1

static fun write(data: java.lang.String, output: java.io.Writer): void

Writes chars from a String to a Writer.

Parameters

data - java.lang.String: the String to write, null ignored

output - java.io.Writer: the Writer to write to

Exceptions

NullPointerException - if output is null

IOException - if an I/O error occurs

Since
Commons IO 1.1

static fun write(data: java.lang.String, output: java.io.OutputStream): void

Writes chars from a String to bytes on an OutputStream using the default character encoding of the platform.

This method uses String#getBytes().

Parameters

data - java.lang.String: the String to write, null ignored

output - java.io.OutputStream: the OutputStream to write to

Exceptions

NullPointerException - if output is null

IOException - if an I/O error occurs

Since
Commons IO 1.1

static fun write(data: java.lang.String, output: java.io.OutputStream, encoding: java.lang.String): void

Writes chars from a String to bytes on an OutputStream using the specified character encoding.

Character encoding names can be found at IANA.

This method uses String#getBytes(String).

Parameters

data - java.lang.String: the String to write, null ignored

output - java.io.OutputStream: the OutputStream to write to

encoding - java.lang.String: the encoding to use, null means platform default

Exceptions

NullPointerException - if output is null

IOException - if an I/O error occurs

Since
Commons IO 1.1

static fun write(data: java.lang.StringBuffer, output: java.io.Writer): void

Writes chars from a StringBuffer to a Writer.

Parameters

data - java.lang.StringBuffer: the StringBuffer to write, null ignored

output - java.io.Writer: the Writer to write to

Exceptions

NullPointerException - if output is null

IOException - if an I/O error occurs

Since
Commons IO 1.1

static fun write(data: java.lang.StringBuffer, output: java.io.OutputStream): void

Writes chars from a StringBuffer to bytes on an OutputStream using the default character encoding of the platform.

This method uses String#getBytes().

Parameters

data - java.lang.StringBuffer: the StringBuffer to write, null ignored

output - java.io.OutputStream: the OutputStream to write to

Exceptions

NullPointerException - if output is null

IOException - if an I/O error occurs

Since
Commons IO 1.1

static fun write(data: java.lang.StringBuffer, output: java.io.OutputStream, encoding: java.lang.String): void

Writes chars from a StringBuffer to bytes on an OutputStream using the specified character encoding.

Character encoding names can be found at IANA.

This method uses String#getBytes(String).

Parameters

data - java.lang.StringBuffer: the StringBuffer to write, null ignored

output - java.io.OutputStream: the OutputStream to write to

encoding - java.lang.String: the encoding to use, null means platform default

Exceptions

NullPointerException - if output is null

IOException - if an I/O error occurs

Since
Commons IO 1.1