]>
cvs.zerfleddert.de Git - proxmark3-svn/blob - client/jansson/strbuffer.h
2 * Copyright (c) 2009-2016 Petri Lehtinen <petri@digip.org>
4 * Jansson is free software; you can redistribute it and/or modify
5 * it under the terms of the MIT license. See LICENSE for details.
15 size_t length
; /* bytes used */
16 size_t size
; /* bytes allocated */
19 int strbuffer_init(strbuffer_t
*strbuff
) JANSSON_ATTRS(warn_unused_result
);
20 void strbuffer_close(strbuffer_t
*strbuff
);
22 void strbuffer_clear(strbuffer_t
*strbuff
);
24 const char *strbuffer_value(const strbuffer_t
*strbuff
);
26 /* Steal the value and close the strbuffer */
27 char *strbuffer_steal_value(strbuffer_t
*strbuff
);
29 int strbuffer_append_byte(strbuffer_t
*strbuff
, char byte
);
30 int strbuffer_append_bytes(strbuffer_t
*strbuff
, const char *data
, size_t size
);
32 char strbuffer_pop(strbuffer_t
*strbuff
);