gobj_find_child()

gobj_find_child()#

Finds the first child of gobj that matches the given filter criteria.

Prototype

hgobj gobj_find_child(
    hgobj gobj,
    json_t *jn_filter // owned
);

Parameters

Key

Type

Description

gobj

hgobj

The parent gobj whose children will be searched.

jn_filter

json_t *

A JSON object containing filter criteria. The first child that matches these criteria is returned.


Return Value

Returns the first child gobj that matches the filter criteria, or NULL if no match is found.

Notes

The function iterates over the direct children of gobj and applies the filter criteria to find a match.

Prototype

// Not applicable in JS

Prototype

# Not applicable in Python
Examples
// TODO C examples
// TODO JS examples
# TODO Python examples