Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

...

...

...

...

...

...

...

...

...

...

...

...

...

...

...

...

...

...

...

...

...

...

...

...

...

...

...

...

...

...

...

...

...

...

...

...

...

Table of Contents

Overview

The following study describes extending YANG language statements to allow customization of models.

References:

YANG Language

  • The YANG language provides us the ability to define and model configurations and state data by defining YANG modules
    • Modules contain a sequence of statements
      • Statement syntax is either of the following :
        • statement = keyword [argument] ;
        • statement = keyword [argument] { <substatement(s)..> } ;

...

Figure 1.1 Schema tree of module 'stores'


Code Block
languagexml
titleSchema tree of module stores

stores module schema tree


YANG extension Statement

** the YIN version and Schema trees above are generated by YANG validator 'pyang'

...

  • Contains interface which has methods to access data of a YANG extension statement
    • package org.opendaylight.yangtools.yang.model.api;
      import org.opendaylight.yangtools.yang.model.api.stmt.ExtensionEffectiveStatement;
      public interface ExtensionDefinition extends SchemaNode, EffectiveStatementEquivalent<ExtensionEffectiveStatement> {
      String getArgument();
      boolean isYinElement();
      }
      • Implementing Class
        • Class

References:

https://datatracker.ietf.org/doc/rfc8526/

https://www.rfc-editor.org/rfc/rfc6095.html

https://www.hjp.at/doc/rfc/rfc6020.html#sec_6.3.1

https://docs.opendaylight.org/en/latest/release-notes/upgrade-process.html?highlight=extension%20annotation#unrecognized-yang-statement-handling

https://datatracker.ietf.org/doc/html/rfc6110#section-9.4

...