mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2025-01-22 12:35:17 +00:00
util: json: Export virJSONValueToBuffer
Signed-off-by: Peter Krempa <pkrempa@redhat.com> Reviewed-by: Laine Stump <laine@laine.org>
This commit is contained in:
parent
cfe6cecdca
commit
a2a04524be
@ -2204,6 +2204,7 @@ virJSONValueObjectKeysNumber;
|
||||
virJSONValueObjectRemoveKey;
|
||||
virJSONValueObjectStealArray;
|
||||
virJSONValueObjectStealObject;
|
||||
virJSONValueToBuffer;
|
||||
virJSONValueToString;
|
||||
|
||||
|
||||
|
@ -1970,7 +1970,7 @@ virJSONValueToStringOne(virJSONValuePtr object,
|
||||
}
|
||||
|
||||
|
||||
static int
|
||||
int
|
||||
virJSONValueToBuffer(virJSONValuePtr object,
|
||||
virBufferPtr buf,
|
||||
bool pretty)
|
||||
@ -2031,7 +2031,7 @@ virJSONValueFromString(const char *jsonstring ATTRIBUTE_UNUSED)
|
||||
}
|
||||
|
||||
|
||||
static int
|
||||
int
|
||||
virJSONValueToBuffer(virJSONValuePtr object ATTRIBUTE_UNUSED,
|
||||
virBufferPtr buf ATTRIBUTE_UNUSED,
|
||||
bool pretty ATTRIBUTE_UNUSED)
|
||||
|
@ -26,6 +26,7 @@
|
||||
# include "internal.h"
|
||||
# include "virbitmap.h"
|
||||
# include "viralloc.h"
|
||||
# include "virbuffer.h"
|
||||
|
||||
# include <stdarg.h>
|
||||
|
||||
@ -143,6 +144,10 @@ int virJSONValueArrayAppendString(virJSONValuePtr object, const char *value);
|
||||
virJSONValuePtr virJSONValueFromString(const char *jsonstring);
|
||||
char *virJSONValueToString(virJSONValuePtr object,
|
||||
bool pretty);
|
||||
int virJSONValueToBuffer(virJSONValuePtr object,
|
||||
virBufferPtr buf,
|
||||
bool pretty)
|
||||
ATTRIBUTE_NONNULL(1) ATTRIBUTE_NONNULL(2) ATTRIBUTE_RETURN_CHECK;
|
||||
|
||||
typedef int (*virJSONValueObjectIteratorFunc)(const char *key,
|
||||
virJSONValuePtr value,
|
||||
|
Loading…
x
Reference in New Issue
Block a user