The YANG syntax is similar to C and C++ and uses a C-like syntax that was chosen for its readability. This section introduces the YANG syntax. While SMIv1, SMIv2, and SPPI are bound to specific protocols like SNMP and COPS-PR, the purpose of SMIng is to define a common data definition language that can specify data models independently of protocols.
Convert to study materialsBETA
Transform any presentation into ready-made study material¡ªselect from outputs like summaries, definitions, and practice questions.
5. 6. YANG Syntax
The YANG syntax is similar to that of SMIng [RFC3780] and programming
languages like C and C++. This C-like syntax was chosen specifically
for its readability, since YANG values the time and effort of the
readers of models above those of modules writers and YANG tool-chain
developers. This section introduces the YANG syntax.
The SMIv1 and the SMIv2 are bound to the Simple Network Management
Protocol (SNMP) [RFC3411], while the SPPI is bound to the Common Open
Policy Service Provisioning (COPS-PR) Protocol [RFC3084]. Even
though the languages have common rules, it is hard to use common data
definitions with both protocols. It is the purpose of this document
to define a common data definition language, named SMIng, that can
formally specify data models independent of specific protocols and
applications. The appendix of this document defines a core module
that supplies common SMIng definitions.