Skip to main content

lyd_insert_sibling

Function lyd_insert_sibling 

Source
pub unsafe extern "C" fn lyd_insert_sibling(
    sibling: *mut lyd_node,
    node: *mut lyd_node,
    first: *mut *mut lyd_node,
) -> Type
Expand description

@brief Insert a node into siblings.

  • if the node is part of some other tree, it is automatically unlinked.
  • if the node is the first node of a node list (with no parent), all the subsequent nodes are also inserted.

@param[in] sibling Siblings to insert into, can even be NULL. @param[in] node Node to insert. @param[out] first Optionally return the first sibling after insertion. Can be the address of @p sibling. @return LY_SUCCESS on success. @return LY_ERR error on error.