-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Wrap lyd_meta_is_internal to check if meta is internal
There are some internal meta attributes that libyang uses for internal stuff and they are ignored when printing the meta collections. One (and now also the only) example of such node is yang:lyds_tree attribute. It can be useful to check if the meta attribute is internal. For instance, when we want to be sure that our parsed data did not contain any meta attributes from user. However, sometimes, libyang silently inserts these internal attributes while parsing. We asked upstream if there could be a function that checks for us if the attribute is internal and therefore we should ignore it. They kindly provided us with such function (`lyd_meta_is_internal`) [1]. This commit wraps the function. Unfortunately, our Meta class does not wrap lyd_meta, only copies data from the structure so we can't just call this function when requested but we call it in Meta object construction which creates a little overhead in both time and memory. [1] CESNET/libyang@f77ca9c Change-Id: Id772ded765569089525cf4fd5dba8a64efe87d02
- Loading branch information
Showing
5 changed files
with
37 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters