somenamedtuple._asdict()
Return a new OrderedDict
which maps field names to their corresponding values:
>>> p = Point(x=11, y=22) >>> p._asdict() OrderedDict([('x', 11), ('y', 22)])
Changed in version 3.1: Returns an OrderedDict
instead of a regular dict
.
Please login to continue.