"Sterne, Jason (Nokia - CA)" <[email protected]> writes:
> I saw the addition of empty types in list keys in YANG 1.1 but had
> troubles finding more details in the NETMOD list.  Is it discussed in
> the YANG 1.1 issues page (and if so, where is that now ?  I tried an
> old link and it didn't work) ?

> Doesn't the empty type have two states and the absence/presence of the
> leaf/tag indicates those states ?

The empty type has two states in the fullest sense, but remember that
missing values are not treated as first-class values.  In particular, if
a leaf is a key for a list, the leaf element must be present in all list
elements:

   7.8.2.  The list's key Statement

   The combined values of all the leafs specified in the key are used to
   uniquely identify a list entry.  All key leafs MUST be given values
   when a list entry is created.  Thus, any default values in the key
   leafs or their types are ignored.  It also implies that any mandatory
   statement in the key leafs are ignored.

So a leaf with empty type can be included in the key, but since it
always has the same value, it has no effect.

Dale

_______________________________________________
netmod mailing list
[email protected]
https://www.ietf.org/mailman/listinfo/netmod

Reply via email to