William,

The when clause determines whether the node will be instantiated or not.
Only when it is instantiated (when condition evaluates to true), the default
property comes into the picture.  At least, that is how I interpret it.

Best regards - Vriendelijke groeten,
Bart Bogaert

-----Original Message-----
From: netmod [mailto:[email protected]] On Behalf Of William Ivory
Sent: 22 March 2017 18:56
To: Martin Bjorklund <[email protected]>
Cc: Nick Brown <[email protected]>; [email protected]
Subject: Re: [netmod] Interaction of 'when' and 'default' statements

Hi Martin,

Thanks.  Can you point me at the part of RFC 6020 that explicitly states
that 'when' wins over 'default'?

William

-----Original Message-----
From: Martin Bjorklund [mailto:[email protected]]
Sent: 22 March 2017 17:53
To: William Ivory <[email protected]>
Cc: [email protected]; Nick Brown <[email protected]>
Subject: Re: [netmod] Interaction of 'when' and 'default' statements

William Ivory <[email protected]> wrote:
> Hi,
> 
> I'm looking for clarification of the 'when' and 'default' statements 
> on a leaf.  For example, if a leaf has a 'default', can it also have a 
> 'when' statement that could cause it to disappear if the 'when'
> condition evaluates to false?

Yes, and in that case the default doesn't apply.

> Section 8.3 or RFC 6020 isn't clear on how evaluation of constraints 
> should be done here, and neither the section on the 'when' statement 
> nor the 'default' section have any cross-references.

If the "when" expression evaluates to false, it's like if the whole node
doesn't exist.  A client can't set it etc.


/martin

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

Attachment: smime.p7s
Description: S/MIME cryptographic signature

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

Reply via email to