:py:mod:`expliot.core.protocols.internet.mdns` ============================================== .. py:module:: expliot.core.protocols.internet.mdns .. autoapi-nested-parse:: Support for discovery on the local network with mDNS. Submodules ---------- .. toctree:: :titlesonly: :maxdepth: 1 constants/index.rst Package Contents ---------------- Classes ~~~~~~~ .. autoapisummary:: expliot.core.protocols.internet.mdns.Discovery expliot.core.protocols.internet.mdns.MdnsListener expliot.core.protocols.internet.mdns.MdnsDiscovery Attributes ~~~~~~~~~~ .. autoapisummary:: expliot.core.protocols.internet.mdns.MDNS_SERVICE_TYPES expliot.core.protocols.internet.mdns.DEFAULT_MDNS_TIMEOUT expliot.core.protocols.internet.mdns.DeviceDetails .. py:class:: Discovery Representation of a discovery entity. .. py:method:: devices() :abstractmethod: Return the found devices. This should be called after scan() Args: Nothing Returns: list: List of all devices discovered in scan() .. py:method:: services() :abstractmethod: Return the found services. This should be called after scan() Args: Nothing Returns: list: List of all devices discovered in scan() .. py:method:: scan() :abstractmethod: Scan for devices or services depending on the Discovery type Args: Nothing Returns: Nothing .. py:data:: MDNS_SERVICE_TYPES .. py:data:: DEFAULT_MDNS_TIMEOUT :annotation: = 1.0 .. py:data:: DeviceDetails .. py:class:: MdnsListener Listener for the detection of zero-configuration devices. .. py:method:: remove_service(zeroconf, service_type, name) Callback to remove a service from the Listener. No action if a device is disappearing. Args: zeroconf(Zeroconf): The Zeroconf Object that has the scanning data. service_type(str): The device service type to be removed. name(str): The device name to be removed. Returns: Nothing .. py:method:: add_service(zeroconf, service_type, name) Callback to add the service found, in the listener. Args: zeroconf(Zeroconf): The Zeroconf Object that has the scanning data. service_type(str): The device service type. name(str): The device name. Returns: Nothing .. py:method:: get_data() Return all collected announcements. Returns (list): List of the found devices. .. py:class:: MdnsDiscovery(service_type, scan_timeout=1) Bases: :py:obj:`expliot.core.discovery.Discovery` Discover local mDNS devices. .. py:method:: devices() Returns the found devices. Returns: list: List of devices found .. py:method:: scan() Scan the network for devices.