summaryrefslogtreecommitdiff
path: root/schema/interface_definition.rnc
diff options
context:
space:
mode:
authorJohn Estabrook <jestabro@vyos.io>2021-05-22 12:51:18 -0500
committerJohn Estabrook <jestabro@vyos.io>2021-06-23 20:05:47 -0500
commit591b8bcadd8b6bbd46c61484193d2bf7e16bd1ae (patch)
tree2e9a5ce8daef4fe52eae490fe6d344cf629e2753 /schema/interface_definition.rnc
parentd48dddab0509e562209adfb115b0e691b8e47f54 (diff)
downloadvyos-1x-591b8bcadd8b6bbd46c61484193d2bf7e16bd1ae.tar.gz
vyos-1x-591b8bcadd8b6bbd46c61484193d2bf7e16bd1ae.zip
T3574: add constraintGroup to schema
Diffstat (limited to 'schema/interface_definition.rnc')
-rw-r--r--schema/interface_definition.rnc11
1 files changed, 11 insertions, 0 deletions
diff --git a/schema/interface_definition.rnc b/schema/interface_definition.rnc
index 6647f5e11..d7fc4966c 100644
--- a/schema/interface_definition.rnc
+++ b/schema/interface_definition.rnc
@@ -93,6 +93,7 @@ properties = element properties
{
help? &
constraint? &
+ constraintGroup* &
valueHelp* &
(element constraintErrorMessage { text })? &
completionHelp* &
@@ -140,6 +141,16 @@ constraint = element constraint
validator )+
}
+# Tag and leaf nodes may have constraintGroups on their names and
+# values (respectively).
+# When multiple constraints are listed within a group, they work as
+# logical AND
+constraintGroup = element constraintGroup
+{
+ ( (element regex { text }) |
+ validator )+
+}
+
# A constraint may also use an external validator rather than regex
validator = element validator
{