3 iR�Vd" � @ s� d Z ddlmZ dZdZddlmZ dd lmZm Z m Z mZmZm Z mZmZmZmZmZmZ dd lmZ ddlmZ ddlmZ er�dd lmZ G dd� de�ZG dd� de�ZG dd� de�ZG dd� de�ZdS )z9Implementation for dbus.Bus. Not to be imported directly.� )� generators�Bus� SystemBus� SessionBus� StarterBusZreStructuredText)� DBusException)�BUS_DAEMON_IFACE�BUS_DAEMON_NAME�BUS_DAEMON_PATH�BUS_SESSION�BUS_STARTER� BUS_SYSTEM� DBUS_START_REPLY_ALREADY_RUNNING�DBUS_START_REPLY_SUCCESS�validate_bus_name�validate_interface_name�validate_member_name�validate_object_path)� BusConnection)� SignalMessage)�is_py2)� UTF8Stringc s� e Zd ZdZi Zejddfdd�Z� fdd�Zdd � Z e e ddd �Zddd�Ze e�Zdd d�Ze e�Zddd�Ze e�Zdd� ZeZ� ZS )r a A connection to one of three possible standard buses, the SESSION, SYSTEM, or STARTER bus. This class manages shared connections to those buses. If you're trying to subclass `Bus`, you may be better off subclassing `BusConnection`, which doesn't have all this magic. FNc C sx | r|| j kr| j | S |tkr(t}n(|tkr6t}n|tkrDt}ntd| ��tj |||d�}||_ |st|| j |<