- public bool boxed_can_deserialize (Type gboxed_type, NodeType node_type)
Checks whether it is possible to deserialize a `GBoxed` of type
`gboxed_type` from a [struct@Json.
- public bool boxed_can_serialize (Type gboxed_type, out NodeType node_type)
Checks whether it is possible to serialize a `GBoxed` of type
`gboxed_type` into a [struct@Json.
- public void* boxed_deserialize (Type gboxed_type, Node node)
Deserializes the given [struct@Json.
- public void boxed_register_deserialize_func (Type gboxed_type, NodeType node_type, BoxedDeserializeFunc deserialize_func)
Registers a deserialization function for a `GBoxed` of type
`gboxed_type` from a [struct@Json.
- public void boxed_register_serialize_func (Type gboxed_type, NodeType node_type, BoxedSerializeFunc serialize_func)
Registers a serialization function for a `GBoxed` of type
`gboxed_type` to a [struct@Json.
- public Node? boxed_serialize (Type gboxed_type, void* boxed)
Serializes a pointer to a `GBoxed` of the given type into a [
struct@Json.
- public Object? construct_gobject (Type gtype, string data, size_t length) throws Error
Deserializes a JSON data stream and creates an instance of the given
type
- public Node? from_string (string str) throws Error
Parses the given string and returns the corresponding JSON tree.
- public Object gobject_deserialize (Type gtype, Node node)
Creates a new `GObject` instance of the given type, and constructs it
using the members of the object in the given node.
- public Object? gobject_from_data (Type gtype, string data, ssize_t length = -1) throws Error
Deserializes a JSON data stream and creates an instance of the given
type.
- public Node gobject_serialize (Object gobject)
Creates a JSON tree representing the passed object instance.
- public string gobject_to_data (Object gobject, out size_t length)
Serializes a `GObject` instance into a JSON data stream, iterating
recursively over each property.
- public Variant? gvariant_deserialize (Node json_node, string? signature) throws Error
Converts a JSON data structure to a `GVariant`.
- public Variant? gvariant_deserialize_data (string json, ssize_t length, string? signature) throws Error
Converts a JSON string to a `GVariant` value.
- public Node gvariant_serialize (Variant variant)
Converts `variant` to a JSON tree.
- public string gvariant_serialize_data (Variant variant, out size_t length)
Converts variant
to its JSON encoded string
representation.
- public Quark parser_error_quark ()
- public Quark path_error_quark ()
- public Quark reader_error_quark ()
- public string serialize_gobject (Object gobject, out size_t length)
Serializes a `GObject` instance into a JSON data stream.
- public int string_compare (string a, string b)
Check whether a
and b
are equal UTF-8 JSON
strings and return an ordering over them in `strcmp()` style.
- public bool string_equal (string a, string b)
Check whether a
and b
are equal UTF-8 JSON
strings.
- public uint string_hash (string key)
Calculate a hash value for the given key
(a UTF-8 JSON
string).
- public string to_string (Node node, bool pretty)
Generates a stringified JSON representation of the contents of the
given `node`.