String buffer

String buffer — Append-only strings.

Functions

Types and Values

Description

A utility class that allows easy construction of strings that grow at the end by appending new strings. Primarily used for constructing/serializing syntaxes into strings by the raptor_iostream and raptor_serializer classes.

Functions

raptor_new_stringbuffer ()

raptor_stringbuffer *
raptor_new_stringbuffer (void);

Returns


raptor_free_stringbuffer ()

void
raptor_free_stringbuffer (raptor_stringbuffer *stringbuffer);


raptor_stringbuffer_append_counted_string ()

int
raptor_stringbuffer_append_counted_string
                               (raptor_stringbuffer *stringbuffer,
                                const unsigned char *string,
                                size_t length,
                                int do_copy);

Returns


raptor_stringbuffer_append_decimal ()

int
raptor_stringbuffer_append_decimal (raptor_stringbuffer *stringbuffer,
                                    int integer);

Returns


raptor_stringbuffer_append_hexadecimal ()

int
raptor_stringbuffer_append_hexadecimal
                               (raptor_stringbuffer *stringbuffer,
                                int hex);

Returns


raptor_stringbuffer_append_string ()

int
raptor_stringbuffer_append_string (raptor_stringbuffer *stringbuffer,
                                   const unsigned char *string,
                                   int do_copy);

Returns


raptor_stringbuffer_append_stringbuffer ()

int
raptor_stringbuffer_append_stringbuffer
                               (raptor_stringbuffer *stringbuffer,
                                raptor_stringbuffer *append);

Returns


raptor_stringbuffer_append_uri_escaped_counted_string ()

int
raptor_stringbuffer_append_uri_escaped_counted_string
                               (raptor_stringbuffer *sb,
                                const char *string,
                                size_t length,
                                int space_is_plus);

Returns


raptor_stringbuffer_prepend_counted_string ()

int
raptor_stringbuffer_prepend_counted_string
                               (raptor_stringbuffer *stringbuffer,
                                const unsigned char *string,
                                size_t length,
                                int do_copy);

Returns


raptor_stringbuffer_prepend_string ()

int
raptor_stringbuffer_prepend_string (raptor_stringbuffer *stringbuffer,
                                    const unsigned char *string,
                                    int do_copy);

Returns


raptor_stringbuffer_as_string ()

unsigned char *
raptor_stringbuffer_as_string (raptor_stringbuffer *stringbuffer);

Returns


raptor_stringbuffer_length ()

size_t
raptor_stringbuffer_length (raptor_stringbuffer *stringbuffer);

Returns


raptor_stringbuffer_copy_to_string ()

int
raptor_stringbuffer_copy_to_string (raptor_stringbuffer *stringbuffer,
                                    unsigned char *string,
                                    size_t length);

Returns


raptor_stringbuffer_write ()

int
raptor_stringbuffer_write (raptor_stringbuffer *sb,
                           raptor_iostream *iostr);

Returns

Types and Values

raptor_stringbuffer

raptor_stringbuffer* raptor_stringbuffer;

Raptor string buffer class