#include <inttypes.h>
#include <parserutils/errors.h>
#include <parserutils/functypes.h>
Go to the source code of this file.
◆ parserutils_filter
◆ parserutils_filter_optparams
Input filter option parameters
◆ parserutils_filter_opttype
Input filter option types
◆ parserutils_filter_opttype
Input filter option types
| Enumerator |
|---|
| PARSERUTILS_FILTER_SET_ENCODING | |
◆ parserutils__filter_create()
Create an input filter
- Parameters
-
| int_enc | Desired encoding of document |
| filter | Pointer to location to receive filter instance |
- Returns
- PARSERUTILS_OK on success, PARSERUTILS_BADPARM on bad parameters, PARSERUTILS_NOMEM on memory exhausion, PARSERUTILS_BADENCODING if the encoding is unsupported
◆ parserutils__filter_destroy()
Destroy an input filter
- Parameters
-
| input | Pointer to filter instance |
- Returns
- PARSERUTILS_OK on success, appropriate error otherwise
◆ parserutils__filter_process_chunk()
Process a chunk of data
- Parameters
-
| input | Pointer to filter instance |
| data | Pointer to pointer to input buffer |
| len | Pointer to length of input buffer |
| output | Pointer to pointer to output buffer |
| outlen | Pointer to length of output buffer |
- Returns
- PARSERUTILS_OK on success, appropriate error otherwise
Call this with an input buffer length of 0 to flush any buffers.
◆ parserutils__filter_reset()
Reset an input filter's state
- Parameters
-
| input | The input filter to reset |
- Returns
- PARSERUTILS_OK on success, appropriate error otherwise
◆ parserutils__filter_setopt()
Configure an input filter
- Parameters
-
| input | Pointer to filter instance |
| type | Input option type to configure |
| params | Option-specific parameters |
- Returns
- PARSERUTILS_OK on success, appropriate error otherwise