Go to the source code of this file.
#define BSTR_BUILDER_DEFAULT_SIZE 16 |
Adds one new piece, in the form of a NUL-terminated string, to the builder. This function will make a copy of the provided string.
- Parameters
-
- Returns
- HTP_OK on success, HTP_ERROR on failure.
Adds one new piece, defined with the supplied pointer and length, to the builder. This function will make a copy of the provided data region.
- Parameters
-
- Returns
-
HTP_OK on success, HTP_ERROR on failure.
Adds one new string to the builder. This function will adopt the string and destroy it when the builder itself is destroyed.
- Parameters
-
- Returns
- HTP_OK on success, HTP_ERROR on failure.
Clears this string builder, destroying all existing pieces. You may want to clear a builder once you've either read all the pieces and done something with them, or after you've converted the builder into a single string.
- Parameters
-
Creates a new string builder.
- Returns
- New string builder, or NULL on error.
Destroys an existing string builder, also destroying all the pieces stored within.
- Parameters
-
Returns the size (the number of pieces) currently in a string builder.
- Parameters
-
- Returns
- size
Creates a single string out of all the pieces held in a string builder. This method will not destroy any of the pieces.
- Parameters
-
- Returns
- New string, or NULL on error.