janani b | f9819ff | 2016-08-03 16:40:01 +0530 | [diff] [blame^] | 1 | module typedef { |
| 2 | yang-version "1"; |
| 3 | namespace "http://rob.sh/yang/test/list"; |
| 4 | prefix "foo"; |
| 5 | organization "BugReports Inc"; |
| 6 | contact "Bug reporter"; |
| 7 | |
| 8 | description |
| 9 | "A test module"; |
| 10 | revision 2014-01-01 { |
| 11 | description "april-fools"; |
| 12 | reference "fooled-you"; |
| 13 | } |
| 14 | |
| 15 | typedef referenced-leaf { |
| 16 | type leafref { |
| 17 | path "/container/target"; |
| 18 | require-instance false; |
| 19 | } |
| 20 | } |
| 21 | |
| 22 | container container { |
| 23 | description |
| 24 | "A container"; |
| 25 | leaf-list target { |
| 26 | type uint8; |
| 27 | description |
| 28 | "A target leaf for leafref checks"; |
| 29 | } |
| 30 | leaf reference { |
| 31 | type referenced-leaf; |
| 32 | } |
| 33 | } |
| 34 | } |