|
libannodex 0.7.3
|
Manipulation of name=value parameters, with parsing of URI query strings and HTTP-style headers, and printing to these formats and XML meta and param tags. More...
Go to the source code of this file.
Typedefs | |
| typedef void | AnxParams |
| A set of parameters. | |
Enumerations | |
| enum | AnxParamStyle { ANX_PARAMS_QUERY = 0 , ANX_PARAMS_HEADERS = 1 , ANX_PARAMS_METATAGS = 1000 , ANX_PARAMS_PARAMTAGS = 1001 } |
| Formatting styles for parsing and printing AnxParams objects. More... | |
Functions | |
| AnxParams * | anx_params_new_parse (char *input, AnxParamStyle style) |
| Create a new AnxParms object by parsing text input of a given format. | |
| int | anx_params_snprint (char *buf, size_t n, AnxParams *params, AnxParamStyle style) |
| Print an AnxParms object with a given formatting style. | |
| char * | anx_params_get (AnxParams *params, char *name) |
| Retrieve a parameter from an AnxParams object. | |
| AnxParams * | anx_params_replace (AnxParams *params, char *name, char *value) |
| Add a parameter to an AnxParams object. | |
| AnxParams * | anx_params_append (AnxParams *params, char *name, char *value) |
| Add a parameter to an AnxParams object. | |
| AnxParams * | anx_params_remove (AnxParams *params, char *name) |
| Remove a parameter from an AnxParams object. | |
| AnxParams * | anx_params_merge (AnxParams *dest, AnxParams *src) |
| Merge two AnxParams objects. | |
| AnxParams * | anx_params_clone (AnxParams *params) |
| Create a new AnxParams object by cloning an existing one. | |
| AnxParams * | anx_params_free (AnxParams *params) |
| Free an AnxParams object. | |
Manipulation of name=value parameters, with parsing of URI query strings and HTTP-style headers, and printing to these formats and XML meta and param tags.
| typedef void AnxParams |
A set of parameters.
| enum AnxParamStyle |
Formatting styles for parsing and printing AnxParams objects.
Add a parameter to an AnxParams object.
If a parameter with the given name already exists in params, the new value is appended to the old one, separated by a comma.
| params | An AnxParams object |
| name | The parameter name |
| value | The new parameter value |
Create a new AnxParams object by cloning an existing one.
| params | An existing AnxParams object. |
Free an AnxParams object.
| params | An AnxParams object |
| char * anx_params_get | ( | AnxParams * | params, |
| char * | name | ||
| ) |
Retrieve a parameter from an AnxParams object.
| params | An AnxParams object |
| name | The parameter name |
| NULL | No such parameter |
Merge two AnxParams objects.
Copies of all parameters in src are appended (as for anx_params_append()) to dest.
| dest | The AnxParams object into which new values are appended |
| src | An AnxParams object with the new values. |
| AnxParams * anx_params_new_parse | ( | char * | input, |
| AnxParamStyle | style | ||
| ) |
Create a new AnxParms object by parsing text input of a given format.
| input | The text to parse |
| style | The formatting style of the text. Only ANX_PARAMS_QUERY and ANX_PARAMS_HEADERS are supported. |
| NULL | no parameters found in input, or unsupported style |
Remove a parameter from an AnxParams object.
| params | An AnxParams object |
| name | The parameter name |
Add a parameter to an AnxParams object.
If a parameter with the given name already exists in params, the new value replaces the old one.
| params | An AnxParams object |
| name | The parameter name |
| value | The new parameter value |
| int anx_params_snprint | ( | char * | buf, |
| size_t | n, | ||
| AnxParams * | params, | ||
| AnxParamStyle | style | ||
| ) |
Print an AnxParms object with a given formatting style.
| buf | The output buffer |
| n | The maximum number of bytes to write |
| params | The AnxParams object |
| style | The formatting style of the generated text. |
Truncation: