Json.Node.init_object

### Method

# Json Nodeinit_object

since: 0.16

#### Declaration [src]

    JsonNode*
    json_node_init_object (
      JsonNode* node,
      JsonObject* object
    )

#### Description [src]

Initializes `node` to `JSON_NODE_OBJECT` and sets `object` into it.

This function will take a reference on `object`.

If the node has already been initialized once, it will be reset to the given type, and any data contained will be cleared.

Available since: 0.16

#### Parameters

`object`

  Type: `JsonObject`

  The JSON object to initialize `node` with, or `NULL`.

  The argument can be `NULL`.
  The data is owned by the caller of the method.

#### Return value

Type: `JsonNode`

The initialized node.

The returned data is owned by the instance.