deserialize
Deserialize a stream or a string. Return an iterator that yields (obj, m2m_relation_dict), where obj is an instantiated -- but unsaved -- object, and m2m_relation_dict is a dictionary of {m2m_field_name : list_of_related_objects}.
def deserialize(
format: string,
stream_or_string: string|file-like object,
**options: dict
) - > iterator
Deserialize a stream or a string. Return an iterator that yields (obj, m2m_relation_dict), where obj is an instantiated -- but unsaved -- object, and m2m_relation_dict is a dictionary of {m2m_field_name : list_of_related_objects}.
Parameters
| Name | Type | Description |
|---|---|---|
| format | string | The serialization format identifier (e.g., 'json', 'xml') used to select the appropriate deserializer engine |
| stream_or_string | `string | file-like object` |
| **options | dict | Additional format-specific keyword arguments passed to the underlying deserializer engine |
Returns
| Type | Description |
|---|---|
iterator | An iterator yielding tuples of (unsaved_object, m2m_relation_dictionary) for each record in the source |