:py:mod:`dissect.cstruct.types.instance` ======================================== .. py:module:: dissect.cstruct.types.instance Module Contents --------------- Classes ~~~~~~~ .. autoapisummary:: dissect.cstruct.types.instance.Instance .. py:class:: Instance(type_: dissect.cstruct.types.BaseType, values: Dict[str, Any], sizes: Dict[str, int] = None) Holds parsed structure data. .. py:attribute:: __slots__ :value: ('_type', '_values', '_sizes') .. py:method:: __getattr__(attr: str) -> Any .. py:method:: __setattr__(attr: str, value: Any) -> None Implement setattr(self, name, value). .. py:method:: __getitem__(item: str) -> Any .. py:method:: __contains__(attr: str) -> bool .. py:method:: __repr__() -> str Return repr(self). .. py:method:: __len__() -> int .. py:method:: __bytes__() -> bytes .. py:method:: write(stream: BinaryIO) -> int Write this structure to a writable file-like object. :param fh: File-like objects that supports writing. :returns: The amount of bytes written. .. py:method:: dumps() -> bytes Dump this structure to a byte string. :returns: The raw bytes of this structure.