Transaction: add fromObj() method, for importing textual JSON representation