groovy node-tree integration
[controller.git] / opendaylight / sal / yang-prototype / yang / yang-data-impl / src / test / resources / org / opendaylight / controller / yang / data / impl / config02.groovy
1 /*\r
2  * Copyright (c) 2013 Cisco Systems, Inc. and others.  All rights reserved.\r
3  *\r
4  * This program and the accompanying materials are made available under the\r
5  * terms of the Eclipse Public License v1.0 which accompanies this distribution,\r
6  * and is available at http://www.eclipse.org/legal/epl-v10.html\r
7  */\r
8 def data = {\r
9  network(xmlns: 'urn:opendaylight:controller:network') {\r
10     topologies {\r
11       topology {\r
12         'topology-id'('topId_01')\r
13         \r
14         //types()\r
15         nodes {\r
16           node {\r
17             'node-id'('nodeId_02')\r
18             'supporting-ne'('networkId_03')\r
19             'termination-points' {\r
20               'termination-point' {\r
21                 'tp-id'('tpId_04')\r
22               }\r
23             }\r
24           }\r
25           node {\r
26             'node-id'('nodeId_05')\r
27             'supporting-ne'('networkId_06')\r
28             'termination-points' {\r
29               'termination-point' {\r
30                 'tp-id'('tpId_07')\r
31               }\r
32             }\r
33           }\r
34           node {\r
35             'node-id'('nodeId_08')\r
36             'supporting-ne'('networkId_09')\r
37             'termination-points' {\r
38               'termination-point' {\r
39                 'tp-id'('tpId_10')\r
40               }\r
41               'termination-point' {\r
42                 'tp-id'('tpId_11')\r
43               }\r
44             }\r
45           }\r
46         }\r
47         links {\r
48           link {\r
49             'link-id'('linkId_12')\r
50             source {\r
51               'source-node'('nodeId_13')\r
52               'source-tp'('tpId_13')\r
53             }\r
54             destination {\r
55               'dest-node'('nodeId_14')\r
56               'dest-tp'('tpId_14')\r
57             }\r
58           }\r
59           link {\r
60             'link-id'('linkId_15')\r
61             source {\r
62               'source-node'('nodeId_16')\r
63               'source-tp'('tpId_16')\r
64             }\r
65             destination {\r
66               'dest-node'('nodeId_17')\r
67               'dest-tp'('tpId_17')\r
68             }\r
69           }\r
70         }\r
71       }\r
72     }\r
73     'network-elements' {\r
74       'network-element' {\r
75         'element-id'('ntElementId_18')\r
76       }\r
77       'network-element' {\r
78         'element-id'('ntElementId_19')\r
79       }\r
80     }\r
81   }\r
82 }\r
83 \r
84 System.err.println('data inited')\r
85 \r
86 import MyXmlGenerator\r
87 \r
88 xmlGen = new MyXmlGenerator()\r
89 xmlGen.buildTree(data)\r