Create a buffered parser input for the progressive parsing of a file
If filename is "-' then we use stdin as the input.
Automatic support for ZLIB/Compress compressed document is provided
by default if found at compile-time.
Grow up the content of the input buffer, the old data are preserved
This routine handle the I18N transcoding to internal UTF-8
This routine is used when operating the parser in normal (pull) mode
TODO: one should be able to remove one extra copy
in :
a buffered parser input
len :
indicative value of the amount of chars to read
Returns :
the number of chars read and stored in the buffer, or -1
in case of error.
Push the content of the arry in the input buffer
This routine handle the I18N transcoding to internal UTF-8
This is used when operating the parser in progressive (push) mode.
in :
a buffered parser input
len :
the size in bytes of the array.
buf :
an char array
Returns :
the number of chars read and stored in the buffer, or -1
in case of error.