]> git.proxmox.com Git - mirror_qemu.git/blobdiff - qapi/qobject-input-visitor.c
qobject-input-visitor: Document full_name_nth()
[mirror_qemu.git] / qapi / qobject-input-visitor.c
index 865e948ac065aa09923b9d11134f436c4f4e191d..253095978154e22b1c2d33c2eaf3f65acdbfaf48 100644 (file)
@@ -55,6 +55,17 @@ static QObjectInputVisitor *to_qiv(Visitor *v)
     return container_of(v, QObjectInputVisitor, visitor);
 }
 
+/*
+ * Find the full name of something @qiv is currently visiting.
+ * @qiv is visiting something named @name in the stack of containers
+ * @qiv->stack.
+ * If @n is zero, return its full name.
+ * If @n is positive, return the full name of the @n-th container
+ * counting from the top.  The stack of containers must have at least
+ * @n elements.
+ * The returned string is valid until the next full_name_nth(@v) or
+ * destruction of @v.
+ */
 static const char *full_name_nth(QObjectInputVisitor *qiv, const char *name,
                                  int n)
 {