src/File.php
public function read($handle, int $chunkSize) : string
    {
        $data = fread($handle, $chunkSize);

        if (false === $data) {
            throw new FileException('Cannot read file.');
        }

        return (string) $data;
    }
public function read($handle, int $chunkSize) : string
    {
        $data = fread($handle, $chunkSize);

        if (false === $data) {
            throw new FileException('Cannot read file.');
        }

        return (string) $data;
    }
public function read ( $ handle , int $ chunkSize ) : string { $ data = fread ( $ handle , $ chunkSize ) ; if ( false === $ data ) { throw new FileException ( 'Cannot read file.' ) ; } return ( string ) $ data ; }
Read data from file.

@param Resource $handle
@param int      $chunkSize

@throws FileException

@return string
Read data from file .