MCPcopy Create free account
hub / github.com/chronoxor/FastBinaryEncoding / __from_json__

Method __from_json__

projects/Python/proto/proto.py:1771–1781  ·  view source on GitHub ↗
(fields)

Source from the content-addressed store, hash-verified

1769
1770 @staticmethod
1771 def __from_json__(fields):
1772 if fields is None:
1773 return None
1774 return Account(
1775 None if "id" not in fields else fields["id"],
1776 None if "name" not in fields else fields["name"],
1777 None if "state" not in fields else State.__from_json__(fields["state"]),
1778 None if "wallet" not in fields else Balance.__from_json__(fields["wallet"]),
1779 None if "asset" not in fields else Balance.__from_json__(fields["asset"]),
1780 None if "orders" not in fields else [Order.__from_json__(value) for value in fields["orders"]],
1781 )
1782
1783 # Get the FBE type
1784 @property

Callers

nothing calls this directly

Calls 2

AccountClass · 0.70
__from_json__Method · 0.45

Tested by

no test coverage detected