mirror of
https://github.com/wassname/catalyst.git
synced 2026-07-02 07:36:49 +08:00
ENH: Add serialization to account
This commit is contained in:
@@ -165,6 +165,12 @@ class Account(object):
|
||||
def __repr__(self):
|
||||
return "Account({0})".format(self.__dict__)
|
||||
|
||||
def serialize(self):
|
||||
return 'Account', self.__dict__
|
||||
|
||||
def reconstruct(self, saved_state):
|
||||
self.__dict__.update(saved_state)
|
||||
|
||||
|
||||
class Position(object):
|
||||
|
||||
|
||||
Reference in New Issue
Block a user