--- a/libpurple/circularbuffer.h Tue Oct 24 01:23:22 2023 -0500 +++ b/libpurple/circularbuffer.h Tue Oct 24 02:02:49 2023 -0500 @@ -27,6 +27,8 @@ #include <glib.h> #include <glib-object.h> +#include "purpleversion.h" + G_BEGIN_DECLS #define PURPLE_TYPE_CIRCULAR_BUFFER (purple_circular_buffer_get_type()) @@ -58,7 +60,10 @@ * actual buffer until data is appended to it. * * Returns: The new PurpleCircularBuffer. + * + * Since: 3.0.0 */ +PURPLE_AVAILABLE_IN_3_0 PurpleCircularBuffer *purple_circular_buffer_new(gsize growsize); /** @@ -69,7 +74,10 @@ * * Append data to the PurpleCircularBuffer. This will grow the internal * buffer to fit the added data, if needed. + * + * Since: 3.0.0 */ +PURPLE_AVAILABLE_IN_3_0 void purple_circular_buffer_append(PurpleCircularBuffer *buffer, gconstpointer src, gsize len); /** @@ -84,7 +92,10 @@ * more data is available to read. * * Returns: the number of bytes that can be read from the PurpleCircularBuffer + * + * Since: 3.0.0 */ +PURPLE_AVAILABLE_IN_3_0 gsize purple_circular_buffer_get_max_read(PurpleCircularBuffer *buffer); /** @@ -96,7 +107,10 @@ * * Returns: TRUE if we successfully marked the bytes as having been read, FALSE * otherwise. + * + * Since: 3.0.0 */ +PURPLE_AVAILABLE_IN_3_0 gboolean purple_circular_buffer_mark_read(PurpleCircularBuffer *buffer, gsize len); /** @@ -106,7 +120,10 @@ * * Increases the buffer size by a multiple of grow size, so that it can hold at * least 'len' bytes. + * + * Since: 3.0.0 */ +PURPLE_AVAILABLE_IN_3_0 void purple_circular_buffer_grow(PurpleCircularBuffer *buffer, gsize len); /** @@ -117,7 +134,10 @@ * needed. * * Returns: The grow size of the buffer. + * + * Since: 3.0.0 */ +PURPLE_AVAILABLE_IN_3_0 gsize purple_circular_buffer_get_grow_size(PurpleCircularBuffer *buffer); /** @@ -127,7 +147,10 @@ * Returns the number of bytes of this buffer that contain unread data. * * Returns: The number of bytes that contain unread data. + * + * Since: 3.0.0 */ +PURPLE_AVAILABLE_IN_3_0 gsize purple_circular_buffer_get_used(PurpleCircularBuffer *buffer); /** @@ -140,7 +163,10 @@ * call purple_circular_buffer_mark_read() to mark the retrieved data as read. * * Returns: The output pointer for the buffer. + * + * Since: 3.0.0 */ +PURPLE_AVAILABLE_IN_3_0 const gchar *purple_circular_buffer_get_output(PurpleCircularBuffer *buffer); /** @@ -148,7 +174,10 @@ * @buffer: The PurpleCircularBuffer to reset. * * Resets the buffer input and output pointers to the start of the buffer. + * + * Since: 3.0.0 */ +PURPLE_AVAILABLE_IN_3_0 void purple_circular_buffer_reset(PurpleCircularBuffer *buffer); G_END_DECLS