mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2025-01-22 04:25:18 +00:00
util: Introduce virJSONValueObjectStealObject
Signed-off-by: Jiri Denemark <jdenemar@redhat.com> Reviewed-by: Ján Tomko <jtomko@redhat.com>
This commit is contained in:
parent
dacf2a6bbc
commit
bf856b6054
@ -2098,6 +2098,7 @@ virJSONValueObjectIsNull;
|
||||
virJSONValueObjectKeysNumber;
|
||||
virJSONValueObjectRemoveKey;
|
||||
virJSONValueObjectStealArray;
|
||||
virJSONValueObjectStealObject;
|
||||
virJSONValueToString;
|
||||
|
||||
|
||||
|
@ -1400,6 +1400,14 @@ virJSONValueObjectStealArray(virJSONValuePtr object, const char *key)
|
||||
}
|
||||
|
||||
|
||||
virJSONValuePtr
|
||||
virJSONValueObjectStealObject(virJSONValuePtr object,
|
||||
const char *key)
|
||||
{
|
||||
return virJSONValueObjectStealByType(object, key, VIR_JSON_TYPE_OBJECT);
|
||||
}
|
||||
|
||||
|
||||
int
|
||||
virJSONValueObjectIsNull(virJSONValuePtr object,
|
||||
const char *key)
|
||||
|
@ -112,6 +112,8 @@ virJSONValuePtr virJSONValueObjectGetArray(virJSONValuePtr object,
|
||||
const char *key);
|
||||
virJSONValuePtr virJSONValueObjectStealArray(virJSONValuePtr object,
|
||||
const char *key);
|
||||
virJSONValuePtr virJSONValueObjectStealObject(virJSONValuePtr object,
|
||||
const char *key);
|
||||
|
||||
const char *virJSONValueObjectGetString(virJSONValuePtr object, const char *key);
|
||||
const char *virJSONValueObjectGetStringOrNumber(virJSONValuePtr object, const char *key);
|
||||
|
Loading…
x
Reference in New Issue
Block a user