Add special type for representing special values
Before this, pseudo-values like lists and containers were represented by
a string leaf value. Now, I can tell these values apart. This can be
helpful for filtering (for example, when printing the values). It will
also be used for implementing key value completion.
Change-Id: I48f6fa2facaf3e8e52aa3b3b4d92130e63acdb6f
diff --git a/src/netconf_access.cpp b/src/netconf_access.cpp
index d1619cb..78d80b1 100644
--- a/src/netconf_access.cpp
+++ b/src/netconf_access.cpp
@@ -58,7 +58,7 @@
if (!it)
continue;
if (it->schema()->nodetype() == LYS_LIST) {
- res.emplace(it->path(), std::string{"(list)"});
+ res.emplace(it->path(), special_{SpecialValue::List});
}
if (it->schema()->nodetype() == LYS_LEAF) {
libyang::Data_Node_Leaf_List leaf(it);