IBinaryReader

Description

interface Tinman.Core.IO.IBinaryReader

Base interface for classes that sequentially read data from a binary stream.

The methods of this interface read multibyte values which are affected by byte order..

Public / Methods

Read​Char


public method ReadChar → ()

returns → char

The read value.

Reads an unsigned 16-bit UTF-16 code unit from the stream.

IOException

If an I/O error has occurred.

Read​Chars


public method ReadChars → (3)

array in : char [ ]

[not-null]
The output array.

offset in : int32

[>=0]
Index of first array element to write.

count in : int32

[>=0]
Number of values to read.

Reads unsigned 16-bit UTF-16 code units from the stream.

Calling this method is equivalent to calling ReadChar sequentially for each element in the given array in segment but may be implemented in a more efficient way.

IOException

If an I/O error has occurred.

Read​Float32


public method ReadFloat32 → ()

returns → float32

The read value.

Reads a 32-bit floating point value from the stream.

IOException

If an I/O error has occurred.

Read​Float32s


public method ReadFloat32s → (3)

array in : float32 [ ]

[not-null]
The output array.

offset in : int32

[>=0]
Index of first array element to write.

count in : int32

[>=0]
Number of values to read.

Reads 32-bit floating point values from the stream.

Calling this method is equivalent to calling ReadFloat32 sequentially for each element in the given array in segment but may be implemented in a more efficient way.

IOException

If an I/O error has occurred.

Read​Float64


public method ReadFloat64 → ()

returns → float64

The read value.

Reads a 64-bit floating point value from the stream.

IOException

If an I/O error has occurred.

Read​Float64s


public method ReadFloat64s → (3)

array in : float64 [ ]

[not-null]
The output array.

offset in : int32

[>=0]
Index of first array element to write.

count in : int32

[>=0]
Number of values to read.

Reads 64-bit floating point values from the stream.

Calling this method is equivalent to calling ReadFloat64 sequentially for each element in the given array in segment but may be implemented in a more efficient way.

IOException

If an I/O error has occurred.

Read​Int16


public method ReadInt16 → ()

returns → int16

The read value.

Reads a signed 16-bit integer value from the stream.

IOException

If an I/O error has occurred.

Read​Int16s


public method ReadInt16s → (3)

array in : int16 [ ]

[not-null]
The output array.

offset in : int32

[>=0]
Index of first array element to write.

count in : int32

[>=0]
Number of values to read.

Reads signed 16-bit integer values from the stream.

Calling this method is equivalent to calling ReadInt16 sequentially for each element in the given array in segment but may be implemented in a more efficient way.

IOException

If an I/O error has occurred.

Read​Int32


public method ReadInt32 → ()

returns → int32

The read value.

Reads a signed 32-bit integer value from the stream.

IOException

If an I/O error has occurred.

Read​Int32s


public method ReadInt32s → (3)

array in : int32 [ ]

[not-null]
The output array.

offset in : int32

[>=0]
Index of first array element to write.

count in : int32

[>=0]
Number of values to read.

Reads signed 32-bit integer values from the stream.

Calling this method is equivalent to calling ReadInt32 sequentially for each element in the given array in segment but may be implemented in a more efficient way.

IOException

If an I/O error has occurred.

Read​Int64


public method ReadInt64 → ()

returns → int64

The read value.

Reads a signed 64-bit integer value from the stream.

IOException

If an I/O error has occurred.

Read​Int64s


public method ReadInt64s → (3)

array in : int64 [ ]

[not-null]
The output array.

offset in : int32

[>=0]
Index of first array element to write.

count in : int32

[>=0]
Number of values to read.

Reads signed 64-bit integer values from the stream.

Calling this method is equivalent to calling ReadInt64 sequentially for each element in the given array in segment but may be implemented in a more efficient way.

IOException

If an I/O error has occurred.

Read​UInt16


public method ReadUInt16 → ()

returns → int32

The read value.

Reads an unsigned 16-bit integer value from the stream.

This method is equivalent to ReadInt16, except that it applies the bitmask 0xFFFF to the read value, before returning it. It does not choose a different binary encoding in the first place.

IOException

If an I/O error has occurred.

Read​UInt32


public method ReadUInt32 → ()

returns → int64

The read value.

Reads an unsigned 32-bit integer value from the stream.

This method is equivalent to ReadInt32, except that it applies the bitmask 0xFFFFFFFF to the read value, before returning it. It does not choose a different binary encoding in the first place.

IOException

If an I/O error has occurred.