[augeas-devel] [PATCH] Add API function aug_node_count to compute the subtree size
David Lutterkort
lutter at redhat.com
Wed Jan 26 00:25:57 UTC 2011
On Sun, 2011-01-23 at 21:07 -0500, Francis Giraldeau wrote:
> The new function aug_node_count computes the subtree size corresponding to a
> given path expression. The count includes all descendants.
There's no need for a new function. The statement
r = aug_node_count(aug, path)
is the same as
r = aug_match(aug, path + "//*", NULL)
We _could_ add aug_node_count to the API as a convenience wrapper, but I
don't think it's really necessary.
David
More information about the augeas-devel
mailing list