。我想知道爲什麼不放錯誤?它確實如果我使用了錯誤的前綴。爲什麼在這種情況下,當條件指的是一個不存在的節點時,爲什麼在這種情況下不會出現錯誤
請問您可以查看何時條件(嵌入模塊中)。
是否允許(在表達式中)引用架構中的擴展本身?
module mod-w-1 {
namespace "http://example.org/tests/mod-w-1";
prefix m1;
container m1 {
leaf b1 {
type string;
}
}
}
module when-tests {
namespace "http://example.org/tests/when-tests";
prefix wt;
import mod-w-1 {
prefix m1;
}
augment "/m1:m1" {
// when "/m1:m1/b3 = 'abc'";
// there is no b3, so, should be invalid.
// when "/m1:m1/b1 = 'abc'";
// a payload or data situation that has m1/b1 != 'abc' will cause the
// data that fits this augment content will be invalid/rejected.
/* for ex;
<m1>
<b1>fff</b1>
<x>sfsf</x>
<conditional>
<foo>dddd</foo>
</conditional>
</m1>
is invalid, hence, the <x> and <conditional> parts will be
rejected.
*/
leaf x {
type string;
}
container conditional {
leaf foo {
type string;
}
}
}
}
嗨,謝謝。有什麼方法可以直接與您聯繫。我可能需要諮詢(我將支付)的幾個小時,你似乎是積極幫助楊相關問題的唯一一個。 – user19937
是否有其他的陽工具超出了剛剛提供的陽工具。我知道libyang,但是,我需要一個被認可的,被稱爲陽1.1兼容和可靠的。有沒有(不是說libyang不是那些,我只想聽到一個知道第一手的人)? – user19937
@ user19937,哦,我不是唯一一個 - 我只是恰好是第一個回答,我只回答我知道我可以回答的問題。 NETMOD WG最近已經開始[編譯](http://www.claise.be/IETFYANGPageCompilation.html)他們幾個編譯器(檢查列表)模塊,雖然我不知道他們是否是1.1兼容。有NETCONF /楊與實現的列表[這裏](https://trac.ietf.org/trac/netconf)。我知道MG-SOFT有楊工具鏈(包括IDE),已經開始推出支持1.1和驗證XPath表達式(免責聲明:我的員工)。 – predi