From: Rafael Zalamena Date: Thu, 1 Aug 2019 22:56:46 +0000 (-0300) Subject: yang: simplify filter choice by removing cases X-Git-Tag: base_7.2~83^2 X-Git-Url: https://git.puffer.fish/?a=commitdiff_plain;h=bec0aa85b1f404ac9800c7524070fcf8582e82bc;p=matthieu%2Ffrr.git yang: simplify filter choice by removing cases Based on @rwestphal feedback, lets remove `case`s where we don't expect to add more items or items with more than one `leaf`. Signed-off-by: Rafael Zalamena --- diff --git a/yang/frr-filter.yang b/yang/frr-filter.yang index 92af6aebfd..e79ede87b7 100644 --- a/yang/frr-filter.yang +++ b/yang/frr-filter.yang @@ -107,23 +107,17 @@ module frr-filter { Extended access list: source value to match."; mandatory true; - case host { - leaf host { - description "Host to match"; - type inet:ipv4-address; - } + leaf host { + description "Host to match"; + type inet:ipv4-address; } - case network { - leaf network { - description "Network to match"; - type inet:ipv4-prefix; - } + leaf network { + description "Network to match"; + type inet:ipv4-prefix; } - case any { - leaf any { - description "Match any"; - type empty; - } + leaf any { + description "Match any"; + type empty; } } @@ -132,23 +126,17 @@ module frr-filter { ./sequence >= 2000 and ./sequence <= 2699"; description "Destination value to match"; - case destination-host { - leaf destination-host { - description "Host to match"; - type inet:ipv4-address; - } + leaf destination-host { + description "Host to match"; + type inet:ipv4-address; } - case destination-network { - leaf destination-network { - description "Network to match"; - type inet:ipv4-prefix; - } + leaf destination-network { + description "Network to match"; + type inet:ipv4-prefix; } - case destination-any { - leaf destination-any { - description "Match any"; - type empty; - } + leaf destination-any { + description "Match any"; + type empty; } } }