MCPcopy Create free account
hub / github.com/dabeaz-course/python-mastery / from_row

Method from_row

Solutions/7_3/structure.py:20–22  ·  view source on GitHub ↗
(cls, row)

Source from the content-addressed store, hash-verified

18
19 @classmethod
20 def from_row(cls, row):
21 rowdata = [ func(val) for func, val in zip(cls._types, row) ]
22 return cls(*rowdata)
23
24 @classmethod
25 def create_init(cls):

Callers 2

csv_as_instancesFunction · 0.45
test_from_rowMethod · 0.45

Calls

no outgoing calls

Tested by 1

test_from_rowMethod · 0.36