python-openflow icon indicating copy to clipboard operation
python-openflow copied to clipboard

provide GenericAlignedStruct that auto Pads itself to keep alignment.

Open erickvermot opened this issue 7 years ago • 0 comments

While implementing Match and ActionSetField classes (https://github.com/kytos/python-openflow/issues/348), padding to keep alignment of variable size structs was implemented. I suggest we place the custom get_size and pack methods in a new base class called GenericAlignedStruct to be used whenever needed, avoiding reimplementation and bugs. (the methods implementation can be found in the PR https://github.com/kytos/python-openflow/pull/392.)

erickvermot avatar Jul 20 '17 13:07 erickvermot