mirror of
https://github.com/faucetsdn/ryu.git
synced 2026-05-08 13:56:09 +02:00
of13: OFPMatch from_json/to_json for new api
this breaks from_json/to_json for old api Signed-off-by: YAMAMOTO Takashi <yamamoto@valinux.co.jp> Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
This commit is contained in:
parent
6b6fd7e67a
commit
358017785a
@ -397,6 +397,15 @@ class OFPMatch(StringifyMixin):
|
||||
def get(self, key, default=None):
|
||||
return self._fields2.get(key, default)
|
||||
|
||||
stringify_attrs = iteritems
|
||||
|
||||
def to_jsondict(self):
|
||||
return super(OFPMatch, self).to_jsondict(lambda x: x)
|
||||
|
||||
@classmethod
|
||||
def from_jsondict(cls, dict_):
|
||||
return super(OFPMatch, cls).from_jsondict(dict_, lambda x: x)
|
||||
|
||||
def append_field(self, header, value, mask=None):
|
||||
self.fields.append(OFPMatchField.make(header, value, mask))
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user