abinslib.io =========== .. py:module:: abinslib.io .. autoapi-nested-parse:: I/O and serialization utilities for abinslib data structures. Classes ------- .. autoapisummary:: abinslib.io.JSONMixin Module Contents --------------- .. py:class:: JSONMixin Bases: :py:obj:`abc.ABC` Mixin providing JSON serialization and deserialization methods. .. py:method:: to_dict() -> collections.abc.Mapping[str, Any] :abstractmethod: Convert object to a dictionary. .. py:method:: from_dict(data_dict: Any) -> Self :classmethod: :abstractmethod: Instantiate object from a dictionary. .. py:method:: to_json() -> str Convert object representation to a JSON string. .. py:method:: from_json(json_str: str) -> Self :classmethod: Instantiate object from a JSON string. .. py:method:: to_json_file(filename: pathlib.Path | str) -> None Write object representation to a JSON file. .. py:method:: from_json_file(filename: pathlib.Path | str) -> Self :classmethod: Read object representation from a JSON file.