Commit 40c457d1 by Owo Sugiana

Tambah FixLength.to_dict()

1 parent 3932282b
0.1.3 2019-07-05
----------------
- Penambahan FixLength.to_dict()
0.1.2 2019-06-13
----------------
- Penambahan thousand()
......
......@@ -117,6 +117,12 @@ class FixLength:
value = d[name]
self.set(name, value)
def to_dict(self):
r = dict()
for name, size, typ in self.struct:
r[name] = self.fields[name]['value']
return r
class DateVar(FixLength):
def __init__(self):
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!