Hi,

I have a question about the usage of import.
In the test-import module I would like to make sure interface name not in the 
interface list of pim-base.
So I import ietf-pim-base module and design the must statement.

My question is, if the device doesn't support PIM, will it raise error when 
"import ietf-pim-base"?

Thanks a lot!

module test-import {
namespace "http://example.com/ns/test";;
prefix tf;
 import ietf-routing {
  prefix "rt";
}

import ietf-interfaces {
  prefix "if";
}

import ietf-pim-base {
  prefix "pim-base";
}
 container interfaces {
  list interface {
   key "name";
   leaf name {
    type if:interface-ref;

    must "current() != 
/rt:routing/rt:control-plane-protocols/pim-base:pim/pim-base:interfaces/pim-base:interface/pim-base:name";

   }
  }
}
}

module: ietf-pim-base
  augment /rt:routing/rt:control-plane-protocols:
    +--rw pim!
                   +--rw graceful-restart
       |  +--rw enabled?    boolean
       |  +--rw duration?   uint16
       +--rw address-family* [address-family]
       |  +--rw address-family        identityref
       |  +--rw graceful-restart
                   ...
                   +--rw interfaces
          +--rw interface* [name]
             +--rw name              if:interface-ref
             +--rw address-family* [address-family]





BR/Hongji
赵宏吉

_______________________________________________
netmod mailing list
netmod@ietf.org
https://www.ietf.org/mailman/listinfo/netmod

Reply via email to