readDoubleLe

Removes eight bytes from this source and returns a floating point number with type Double composed of it according to the little-endian order.

The Double.Companion.fromBits function is used for decoding bytes into Double.

Throws

when there are not enough data to read an unsigned int value.

when the source is closed.

when some I/O error occurs.

Samples

import kotlinx.io.*
import kotlin.test.*

fun main() { 
   //sampleStart 
   val buffer = Buffer()
buffer.write(byteArrayOf(35, -13, -56, -97, 12, 36, -2, 64))
assertEquals(123456.78901, buffer.readDoubleLe()) 
   //sampleEnd
}