YANG Data modeling language – IETF standard
- module that is a self-contained top-level hierarchy of nodes
- users containers to group related nodes
- lists to identify nodes that are stored in sequence
- each individual attributes of a node is represented by a leaf
- every leaf must have an associated type
Source: “Useful Python Libraries for Network Engineers.mp4” by Hank Preston.
bchoi@nuc86:~/PyLearn$ cat yang_example.yang
module ietf-interface {
import ietf-yang-types {
prefix yang;
}
container interfaces {
list interface {
key “name”;
leaf name {
type string;
}
leaf enabled {
type boolean;
default “true”;
}
}
Leave a comment