backing up
[vsorcdistro/.git] / ryu / build / lib.linux-armv7l-2.7 / ryu / ofproto / __init__.py
1 # Copyright (C) 2013,2014 Nippon Telegraph and Telephone Corporation.
2 # Copyright (C) 2013 Isaku Yamahata <yamahata at private email ne jp>
3 #
4 # Licensed under the Apache License, Version 2.0 (the "License");
5 # you may not use this file except in compliance with the License.
6 # You may obtain a copy of the License at
7 #
8 #    http://www.apache.org/licenses/LICENSE-2.0
9 #
10 # Unless required by applicable law or agreed to in writing, software
11 # distributed under the License is distributed on an "AS IS" BASIS,
12 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
13 # implied.
14 # See the License for the specific language governing permissions and
15 # limitations under the License.
16
17 import glob
18 import inspect
19 import os.path
20
21 from ryu.ofproto import ofproto_protocol
22
23
24 def get_ofp_modules():
25     """get modules pair for the constants and parser of OF-wire of
26     a given OF version.
27     """
28     return ofproto_protocol._versions
29
30
31 def get_ofp_module(ofp_version):
32     """get modules pair for the constants and parser of OF-wire of
33     a given OF version.
34     """
35     return get_ofp_modules()[ofp_version]