On Mon, May 23, 2016 at 05:29:42PM +0200, Ladislav Lhotka wrote:
[...]
> This mixes up paths in the data tree with those in the schema tree. The XPath
> expression in the "path" statement is evaluated in the context of a data
> tree, but if the result is an empty node set, then "this leaf node" makes no
> sense.
>
> A specific example:
>
> leaf fooref {
> type leafref {
> path "../foo";
> require-instance false;
> }
> }
>
> leaf foo {
> type uint8;
> when "../bar < 42";
> }
>
> leaf bar {
> type uint8;
> default 100;
> }
>
> If there is neither "foo" nor "bar" in the data tree, what is the value space
> of "fooref"?
>
Hm. Is it not both? The path refers to a schema node in order to
determine the base type (which is the base value set if
require-instance is false). If require-instance is true, then there is
an additional constraint that refers to a set of data nodes that
essentially determine a (possibly empty) subset of the value space.
If you agree with this, then we essentially have to phrase this
clearly.
/js
--
Juergen Schoenwaelder Jacobs University Bremen gGmbH
Phone: +49 421 200 3587 Campus Ring 1 | 28759 Bremen | Germany
Fax: +49 421 200 3103 <http://www.jacobs-university.de/>
_______________________________________________
netmod mailing list
[email protected]
https://www.ietf.org/mailman/listinfo/netmod