src.dackar.contrib.lazy.lazy_loader =================================== .. py:module:: src.dackar.contrib.lazy.lazy_loader .. autoapi-nested-parse:: A LazyLoader class. Classes ------- .. autoapisummary:: src.dackar.contrib.lazy.lazy_loader.LazyLoader Module Contents --------------- .. py:class:: LazyLoader(local_name, parent_module_globals, name) Bases: :py:obj:`types.ModuleType` Lazily import a module, mainly to avoid pulling in large dependencies. `contrib`, and `ffmpeg` are examples of modules that are large and not always needed, and this allows them to only be loaded when they are used. .. py:attribute:: _local_name .. py:attribute:: _parent_module_globals .. py:method:: _load() Load the module and insert it into the parent's globals. .. py:method:: __getattr__(item) .. py:method:: __dir__()