diff options
-rw-r--r-- | ryu/lib/packet/packet_base.py | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/ryu/lib/packet/packet_base.py b/ryu/lib/packet/packet_base.py index 847e5ce7..c3f76e31 100644 --- a/ryu/lib/packet/packet_base.py +++ b/ryu/lib/packet/packet_base.py @@ -13,9 +13,12 @@ # See the License for the specific language governing permissions and # limitations under the License. +import abc + class PacketBase(object): """A base class for a protocol (ethernet, ipv4, ...) header.""" + __metaclass__ = abc.ABCMeta _TYPES = {} @classmethod @@ -43,6 +46,7 @@ class PacketBase(object): return self.__class__.__name__ @classmethod + @abc.abstractmethod def parser(cls, buf): """Decode a protocol header. |