forEachBlock
Reads file by byte blocks and calls action for each block read. Block has default size which is implementation-dependent. This functions passes the byte array and amount of bytes in the array to the action function.
You can use this function for huge files.
Since Kotlin
1.0Parameters
action
function to process file blocks.
Reads file by byte blocks and calls action for each block read. This functions passes the byte array and amount of bytes in the array to the action function.
You can use this function for huge files.
Since Kotlin
1.0Parameters
action
function to process file blocks.
blockSize
size of a block, replaced by 512 if it's less, 4096 by default.