fmt_parser [function]
fmt_parser( callable[, buffersize ] )
creates a fmt_parser object, connected to the callable
- the callable is a function that returns at most the number of bytes requested from the stream
- if previous request reached end, subsequent requests must return 'null'
f = io_file( "test.txt", FILE_READ );
// usually it is easier to use @fmt_file_parser instead of the next line of code
p = fmt_parser( function( num ) use( file ){ if( file.eof() ) return null; return file.read( num ); } );