Refactor folder structure.
[sim/o1-interface.git] / ntsimulator / yang / o-ran-sc / o-ran-ru / o-ran-sc-hardware-v1.yang
1 module o-ran-sc-hardware-v1 {
2   yang-version 1.1;
3   namespace "urn:o-ran:sc:hardware:1.0";
4   prefix ohw;
5
6   import o-ran-sc-root-v1 {
7     prefix root;
8   }
9   import ietf-hardware {
10     prefix hw;
11     reference
12       "RFC 8348: A YANG Data Model for Hardware Management";
13   }
14
15   organization
16     "O-RAN Software Community";
17   contact
18     "www.o-ran-sc.org";
19   description
20     "This module augements the  o-ran-sc-controlled-element and  
21      o-ran-sc-controlled-function object by adding ietf-hardware.
22
23      Copyright 2020 the O-RAN Alliance.
24
25      Licensed under the Apache License, Version 2.0 (the 'License');
26      you may not use this file except in compliance with the License.
27      You may obtain a copy of the License at
28
29      http://www.apache.org/licenses/LICENSE-2.0
30
31      Unless required by applicable law or agreed to in writing, software
32      distributed under the License is distributed on an 'AS IS' BASIS,
33      WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
34      See the License for the specific language governing permissions and
35      limitations under the License.";
36
37   revision 2020-03-09 {
38     description
39       "initial revision";
40     reference
41       "O-RAN-OAM-Interface-Specification (O1)";
42   }
43
44   /*
45    * Typedefs
46    */
47
48   typedef hardware-ref {
49     type leafref {
50       path "/hw:hardware/hw:component/hw:name";
51     }
52     description
53       "This type is used by data models that need to reference
54        hardware.";
55   }
56
57   /*
58    * Groupings
59    */
60
61   grouping hardware-grp {
62     leaf-list hardware-reference  {
63       type hardware-ref;
64       config false;
65       description 
66         "A list of ietf-hardware references using the hardware name as key.";
67     }
68     description 
69       "A group adding ietf-hardware references.";
70   }
71
72   /*
73    * Data nodes
74    */
75
76   augment "/root:controlled-element" {
77     uses hardware-grp;
78     description
79       "An augmentation, which adds ietf-hardware 
80        to root:controlled-element.";
81   }
82
83   augment "/root:controlled-element/root:controlled-function" {
84     uses hardware-grp;
85     description
86       "An augmentation, which adds ietf-hardware 
87        to root:controlled-function.";
88   }
89 }