gobj_shoot_snap()

gobj_shoot_snap()#

The gobj_shoot_snap() function creates a snapshot of the current state of a GObj, identified by a given tag.

Prototype

int gobj_shoot_snap(
    hgobj gobj,
    const char *tag,
    json_t *kw,
    hgobj src
);

Parameters

Key

Type

Description

gobj

hgobj

The GObj whose state will be captured in the snapshot.

tag

const char *

A string identifier for the snapshot.

kw

json_t *

A JSON object containing additional options for the snapshot. The ownership is transferred.

src

hgobj

The source GObj initiating the snapshot.


Return Value

Returns 0 on success, or -1 if an error occurs.

Notes

If the GObj does not support snapshots, an error is logged and the function returns -1.

Prototype

// Not applicable in JS

Prototype

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