| module openconfig-transport-line-common { |
| |
| yang-version "1"; |
| |
| // namespace |
| namespace "http://openconfig.net/yang/transport-line-common"; |
| |
| prefix "oc-line-com"; |
| |
| // import some basic types |
| import openconfig-platform { |
| prefix oc-platform; |
| revision-date "2016-06-06"; |
| } |
| import openconfig-platform-types { |
| prefix oc-platform-types; |
| revision-date "2016-06-06"; |
| } |
| import openconfig-interfaces { |
| prefix oc-if; |
| revision-date "2016-05-26"; |
| } |
| import iana-if-type { |
| prefix ift; |
| revision-date "2016-11-23"; |
| } |
| import openconfig-extensions { |
| prefix oc-ext; |
| revision-date "2015-10-09"; |
| } |
| |
| // import tailf-common {prefix "tailf";} |
| // tailf:export netconf; |
| // tailf:export rest; |
| |
| // meta |
| organization "OpenConfig working group"; |
| |
| contact |
| "OpenConfig working group |
| www.openconfig.net"; |
| |
| description |
| "This module defines common data elements for OpenConfig data |
| models for optical transport line system elements, such as |
| amplifiers and ROADMs (wavelength routers)."; |
| |
| oc-ext:openconfig-version "0.1.0"; |
| |
| revision "2016-03-31" { |
| description |
| "Initial public release"; |
| reference "0.1.0"; |
| } |
| |
| |
| // extension statements |
| |
| // feature statements |
| |
| // identity statements |
| |
| identity OPTICAL_LINE_PORT_TYPE { |
| description |
| "Type definition for optical node port types"; |
| } |
| |
| identity INGRESS { |
| base OPTICAL_LINE_PORT_TYPE; |
| description |
| "Ingress port, corresponding to a signal entering |
| a line device such as an amplifier or wavelength |
| router."; |
| } |
| |
| identity EGRESS { |
| base OPTICAL_LINE_PORT_TYPE; |
| description |
| "Egress port, corresponding to a signal exiting |
| a line device wavelength router."; |
| } |
| |
| identity ADD { |
| base OPTICAL_LINE_PORT_TYPE; |
| description |
| "Add port, corresponding to a signal injected |
| at a wavelength router."; |
| } |
| |
| identity DROP { |
| base OPTICAL_LINE_PORT_TYPE; |
| description |
| "Drop port, corresponding to a signal dropped |
| at a wavelength router."; |
| } |
| |
| // typedef statements |
| |
| // grouping statements |
| |
| grouping optical-osc-config { |
| description |
| "Configuration data for OSC interfaces"; |
| |
| leaf-list interface { |
| type oc-if:base-interface-ref; |
| description |
| "List of references to OSC interfaces"; |
| } |
| } |
| |
| grouping optical-osc-state { |
| description |
| "Operational state data for OSC interfaces"; |
| } |
| |
| |
| |
| grouping optical-osc-top { |
| description |
| "Top-level grouping for configuration and operational state |
| data for optical supervisory channels (OSC) for amplifiers, |
| WSS/ROADM, nodes, etc."; |
| |
| container supervisory-channels { |
| description |
| "Top-level container for OSC data"; |
| |
| container config { |
| description |
| "Configuration data for OSCs"; |
| |
| uses optical-osc-config; |
| } |
| |
| container state { |
| |
| config false; |
| |
| description |
| "Operational state data for OSCs"; |
| |
| uses optical-osc-config; |
| uses optical-osc-state; |
| } |
| } |
| } |
| |
| |
| grouping transport-line-common-port-config { |
| description |
| "Configuration data for optical line ports"; |
| } |
| |
| grouping transport-line-common-port-state { |
| description |
| "Operational state data describing optical line ports"; |
| |
| leaf optical-port-type { |
| type identityref { |
| base OPTICAL_LINE_PORT_TYPE; |
| } |
| description |
| "Indicates the type of transport line port. This is an |
| informational field that should be made available by the |
| device (e.g., in the openconfig-platform model)."; |
| } |
| } |
| |
| grouping transport-line-common-port-top { |
| description |
| "Top-level grouping "; |
| |
| container optical-port { |
| description |
| "Top-level container "; |
| |
| container state { |
| |
| config false; |
| |
| description |
| "Operational state data for optical line ports"; |
| |
| uses transport-line-common-port-config; |
| uses transport-line-common-port-state; |
| } |
| } |
| } |
| |
| |
| |
| // data definition statements |
| |
| // uses optical-osc-top; |
| |
| // augment statements |
| /* |
| augment "/oc-platform:components/oc-platform:component" { |
| description |
| "Adding optical line port data to platform model"; |
| |
| uses transport-line-common-port-top { |
| when "/oc-platform:components/oc-platform:component/" + |
| "oc-platform:state/oc-platform:type = 'oc-platform-types:PORT'" { |
| description |
| "Augment is active when component is of type |
| PORT"; |
| } |
| } |
| } |
| */ |
| //TODO:this is placeholder until SONET model is added |
| //to interfaces model |
| /* augment "/oc-if:interfaces/oc-if:interface" { |
| when "oc-if:type = 'ift:sonet'" { |
| description "Additional interface configuration parameters when |
| the interface type is SONET/SDH"; |
| } |
| description "Adds additional SONET/SDH-specific data to |
| osc model"; |
| |
| container sonet { |
| description |
| "Data related to SONET/SDH interfaces"; |
| } |
| } |
| */ |
| // rpc statements |
| |
| // notification statements |
| |
| } |