Match and actions (de)serialization + fix
[openflowjava.git] / openflow-protocol-api / src / main / yang / openflow-protocol.yang
index cca7011f2b0d79466c31c3530f2b4971e15bffb3..7f65a22b444aca36113425f860750d289359dd7d 100644 (file)
@@ -80,6 +80,26 @@ module openflow-protocol {
             uses oxm:oxm-fields;\r
         }\r
 \r
+        grouping buckets {\r
+                list buckets-list {\r
+                    uses bucket;\r
+                }\r
+            }\r
+            \r
+            grouping bucket {\r
+                leaf weight {\r
+                    type uint16;\r
+                }\r
+                leaf watch-port {\r
+                    type oft:port-number;\r
+                }\r
+                leaf watch-group {\r
+                    type uint32;\r
+                }\r
+                \r
+                uses ofaction:actions;\r
+            }\r
+            \r
         container table-features-properties-container {\r
             uses table-features-properties;\r
         }\r
@@ -339,14 +359,11 @@ module openflow-protocol {
                 \r
                 uses ofHeader;\r
                 \r
-                list actions-list {\r
-                    uses ofaction:action-header;\r
-                    \r
-                    leaf data {\r
-                        type binary;\r
-                    }\r
-                }\r
+                uses ofaction:actions;\r
                 \r
+                leaf data {\r
+                    type binary;\r
+                }\r
                 leaf buffer-id {\r
                     type uint32;\r
                 }\r
@@ -396,6 +413,8 @@ module openflow-protocol {
                 container match {\r
                     uses match;\r
                 }\r
+                \r
+                uses ofinstruction:instructions;\r
             } \r
             grouping group-mod {\r
                 // reference "OFPT_GROUP_MOD message in Openflow Switch 1.3 Spec"\r
@@ -413,24 +432,9 @@ module openflow-protocol {
                     type uint32;\r
                 }\r
                 \r
-                list buckets-list {\r
-                    uses bucket;\r
-                }\r
-            }\r
-            grouping bucket {\r
-                leaf weight {\r
-                    type uint16;\r
-                }\r
-                leaf watch-port {\r
-                    type oft:port-number;\r
-                }\r
-                leaf watch-group {\r
-                    type uint32;\r
-                }\r
-                list actions-list {\r
-                    uses ofaction:action-header;\r
-                }\r
+                uses buckets;\r
             }\r
+            \r
             grouping port-mod {\r
                 // reference "OFPT_PORT_MOD message in Openflow Switch 1.3 Spec"\r
                 /* Controller/switch message */\r
@@ -647,6 +651,8 @@ module openflow-protocol {
                             container match {\r
                                 uses match;\r
                             }\r
+                            \r
+                            uses ofinstruction:instructions;\r
                         }\r
                     }\r
                     case multipart-reply-aggregate {\r
@@ -789,9 +795,7 @@ module openflow-protocol {
                             leaf group-id {\r
                                 type uint32;\r
                             }\r
-                            list buckets-list {\r
-                                uses bucket;\r
-                            }\r
+                            uses buckets;\r
                         }\r
                     }\r
                     case multipart-reply-group-features {\r
@@ -804,12 +808,8 @@ module openflow-protocol {
                         leaf-list max_groups {\r
                             type uint32;\r
                         }\r
-                        //leaf-list actions {\r
-                        //    type ofaction:action-type;\r
-                        //}\r
-                        list actions-list {\r
-                            uses ofaction:action-header;\r
-                        }\r
+                        \r
+                        uses ofaction:actions;\r
                     }\r
                     case multipart-reply-meter {\r
                         list meter-stats {\r
@@ -891,6 +891,7 @@ module openflow-protocol {
                             leaf max-entries {\r
                                 type uint32;\r
                             }\r
+                            uses table-features-properties;\r
                         }\r
                     }\r
                     case multipart-reply-port-desc {\r