Signed-off-by: IWASE Yusuke <[email protected]>
---
 doc/source/developing.rst     |  1 +
 doc/source/nicira_ext_ref.rst | 31 +++++++++++++++++++++++++++++++
 ryu/ofproto/nx_match.py       | 28 ++++++++++++++++++++++++++++
 3 files changed, 60 insertions(+)
 create mode 100644 doc/source/nicira_ext_ref.rst

diff --git a/doc/source/developing.rst b/doc/source/developing.rst
index 2e41674..8f124b0 100644
--- a/doc/source/developing.rst
+++ b/doc/source/developing.rst
@@ -10,4 +10,5 @@ Writing Your Ryu Application
    ryu_app_api.rst
    library.rst
    ofproto_ref.rst
+   nicira_ext_ref.rst
    api_ref.rst
diff --git a/doc/source/nicira_ext_ref.rst b/doc/source/nicira_ext_ref.rst
new file mode 100644
index 0000000..dc7d542
--- /dev/null
+++ b/doc/source/nicira_ext_ref.rst
@@ -0,0 +1,31 @@
+***************************
+Nicira Extension Structures
+***************************
+
+.. _nx_actions_structures:
+
+Nicira Extension Actions Structures
+===================================
+
+The followings shows the supported NXAction classes in OF1.3,
+but also available in OF1.2+.
+
+.. py:currentmodule:: ryu.ofproto.ofproto_v1_3_parser
+
+
+.. autoclass:: NXActionRegMove
+.. autoclass:: NXActionLearn
+.. autoclass:: NXActionConjunction
+.. autoclass:: NXActionResubmitTable
+.. autoclass:: NXActionCT
+.. autoclass:: NXFlowSpecMatch
+.. autoclass:: NXFlowSpecLoad
+.. autoclass:: NXFlowSpecOutput
+
+.. _nx_match_structures:
+
+Nicira Extended Match Structures
+================================
+
+.. automodule:: ryu.ofproto.nx_match
+
diff --git a/ryu/ofproto/nx_match.py b/ryu/ofproto/nx_match.py
index ca4b270..281fdc2 100644
--- a/ryu/ofproto/nx_match.py
+++ b/ryu/ofproto/nx_match.py
@@ -16,6 +16,7 @@
 # limitations under the License.
 
 import struct
+import sys
 
 from ryu import exception
 from ryu.lib import mac
@@ -1194,6 +1195,33 @@ class NXMatch(object):
 # The followings are implementations for OpenFlow 1.2+
 #
 
+sys.modules[__name__].__doc__ = """
+The API of this class is the same as ``OFPMatch``.
+
+You can define the flow match by the keyword arguments.
+The following arguments are available.
+
+================ =============== ==================================
+Argument         Value           Description
+================ =============== ==================================
+eth_dst_nxm      MAC address     Ethernet destination address.
+eth_src_nxm      MAC address     Ethernet source address.
+tunnel_id_nxm    Integer 64bit   Tunnel identifier.
+tun_ipv4_src     IPv4 address    Tunnel IPv4 source address.
+tun_ipv4_dst     IPv4 address    Tunnel IPv4 destination address.
+pkt_mark         Integer 32bit   Packet metadata mark.
+conj_id          Integer 32bit   Conjunction ID used only with
+                                 the conjunction action
+ct_state         Integer 32bit   Conntrack state.
+ct_zone          Integer 16bit   Conntrack zone.
+ct_mark          Integer 32bit   Conntrack mark.
+ct_label         Integer 128bit  Conntrack label.
+_dp_hash         Integer 32bit   Flow hash computed in Datapath.
+reg<idx>         Integer 32bit   Packet register.
+                                 <idx> is register number 0-7.
+================ =============== ==================================
+"""
+
 oxm_types = [
     oxm_fields.NiciraExtended0('eth_dst_nxm', 1, type_desc.MacAddr),
     oxm_fields.NiciraExtended0('eth_src_nxm', 2, type_desc.MacAddr),
-- 
1.9.1


------------------------------------------------------------------------------
Site24x7 APM Insight: Get Deep Visibility into Application Performance
APM + Mobile APM + RUM: Monitor 3 App instances at just $35/Month
Monitor end-to-end web transactions and take corrective actions now
Troubleshoot faster and improve end-user experience. Signup Now!
http://pubads.g.doubleclick.net/gampad/clk?id=267308311&iu=/4140
_______________________________________________
Ryu-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/ryu-devel

Reply via email to