(cls: type[T], src_dict: dict[str, Any])
| 63 | |
| 64 | @classmethod |
| 65 | def from_dict(cls: type[T], src_dict: dict[str, Any]) -> T: |
| 66 | from ..models.item_data import ItemData |
| 67 | |
| 68 | d = src_dict.copy() |
| 69 | id = d.pop("id") |
| 70 | |
| 71 | state = PlaidItemSyncState(d.pop("state")) |
| 72 | |
| 73 | item = ItemData.from_dict(d.pop("item")) |
| 74 | |
| 75 | def _parse_error_message(data: object) -> Union[None, Unset, str]: |
| 76 | if data is None: |
| 77 | return data |
| 78 | if isinstance(data, Unset): |
| 79 | return data |
| 80 | return cast(Union[None, Unset, str], data) |
| 81 | |
| 82 | error_message = _parse_error_message(d.pop("error_message", UNSET)) |
| 83 | |
| 84 | sync_data = cls( |
| 85 | id=id, |
| 86 | state=state, |
| 87 | item=item, |
| 88 | error_message=error_message, |
| 89 | ) |
| 90 | |
| 91 | sync_data.additional_properties = d |
| 92 | return sync_data |
| 93 | |
| 94 | @property |
| 95 | def additional_keys(self) -> list[str]: |
nothing calls this directly
no test coverage detected