%PDF- %PDF-
Mini Shell

Mini Shell

Direktori : /lib/python3/dist-packages/dbus/__pycache__/
Upload File :
Create Path :
Current File : //lib/python3/dist-packages/dbus/__pycache__/_dbus.cpython-312.pyc

�

@iaO"����dZddlmZdZdZddlmZddlmZm	Z	m
Z
mZmZm
Z
mZmZmZmZmZmZddlmZddlmZdd	lmZGd
�de�ZGd�d
e�ZGd�de�ZGd�de�Zy)z9Implementation for dbus.Bus. Not to be imported directly.�)�
generators)�Bus�	SystemBus�
SessionBus�
StarterBus�reStructuredText)�
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_py2c���eZdZdZiZejddfd�Z�fd�Zd�Z	e
e	ddd�Zdd�Ze
e�Zdd	�Ze
e�Zdd
�Ze
e�Zd�ZeZ�xZS)
ra 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� �|s||jvr|j|S|tk(rt}n.|tk(rt}n|t
k(rt}ntd|z��tj|||��}||_
|s||j|<|S)a�Constructor, returning an existing instance where appropriate.

        The returned instance is actually always an instance of `SessionBus`,
        `SystemBus` or `StarterBus`.

        :Parameters:
            `bus_type` : cls.TYPE_SESSION, cls.TYPE_SYSTEM or cls.TYPE_STARTER
                Connect to the appropriate bus
            `private` : bool
                If true, never return an existing shared instance, but instead
                return a private connection.

                :Deprecated: since 0.82.3. Use dbus.bus.BusConnection for
                    private connections.

            `mainloop` : dbus.mainloop.NativeMainLoop
                The main loop to use. The default is to use the default
                main loop if one has been set up, or raise an exception
                if none has been.
        :Changed: in dbus-python 0.80:
            converted from a wrapper around a Connection to a Connection
            subclass.
        zinvalid bus_type %s)�mainloop)�_shared_instancesr
rrrrr�
ValueErrorr�__new__�	_bus_type)�cls�bus_type�privater�subclass�buss      �,/usr/lib/python3/dist-packages/dbus/_dbus.pyrzBus.__new__9s���2�H��(=�(=�=��(�(��2�2��{�"�!�H�
��
#� �H�
��
$�!�H��2�X�=�>�>��#�#�H�h��J�� ��
��.1�C�!�!�(�+��
�c���|j}|jjj|�|ur|jj|=tt
|��y)N)r�	__class__r�get�superr�close)�self�tr(s  �r%r+z	Bus.closelsH����N�N���>�>�+�+�/�/��2�d�:����0�0��3�
�c�4�� r&c��|S)z�Return self, for backwards compatibility with earlier dbus-python
        versions where Bus was not a subclass of Connection.

        :Deprecated: since 0.80.0
        �)r,s r%�get_connectionzBus.get_connectionrs	���r&z�self._connection == self, for backwards
                           compatibility with earlier dbus-python versions
                           where Bus was not a subclass of Connection.c��t|��S)z�Static method that returns a connection to the session bus.

        :Parameters:
            `private` : bool
                If true, do not return a shared connection.
        �r")rr2s r%�get_sessionzBus.get_session~����'�*�*r&c��t|��S)z�Static method that returns a connection to the system bus.

        :Parameters:
            `private` : bool
                If true, do not return a shared connection.
        r2)rr2s r%�
get_systemzBus.get_system�s����)�)r&c��t|��S)z�Static method that returns a connection to the starter bus.

        :Parameters:
            `private` : bool
                If true, do not return a shared connection.
        r2)rr2s r%�get_starterzBus.get_starter�r4r&c��|jtk(rd}n.|jtk(rd}n|jtk(rd}nd}d|jj
|jj|t|�fzS)N�session�system�starterzunknown bus typez<%s.%s (%s) at %#x>)rr
rrr(�
__module__�__name__�id)r,�names  r%�__repr__zBus.__repr__�sn���>�>�[�(��D�
�^�^�z�
)��D�
�^�^�{�
*��D�%�D�$����(A�(A�(,���(?�(?�(,�b��h�(8�8�	8r&)F)r>r=�__qualname__�__doc__rr�TYPE_SESSIONrr+r0�property�_connectionr3�staticmethodr6r8rA�__str__�
__classcell__)r(s@r%rr.s�������+�8�8�%��1�f!���>�4��J�K�K�
+��{�+�K�*��j�)�J�+��{�+�K�8��Gr&rc��eZdZdZdd�Zy)rzThe system-wide message bus.Nc�P�tj|tj||��S)a�Return a connection to the system bus.

        :Parameters:
            `private` : bool
                If true, never return an existing shared instance, but instead
                return a private connection.
            `mainloop` : dbus.mainloop.NativeMainLoop
                The main loop to use. The default is to use the default
                main loop if one has been set up, or raise an exception
                if none has been.
        )rr")rr�TYPE_SYSTEM�r r"rs   r%rzSystemBus.__new__�s'���{�{�3����(�#*��,�	,r&�FN�r>r=rBrCrr/r&r%rr�s
��&�
,r&rc��eZdZdZdd�Zy)rz(The session (current login) message bus.Nc�P�tj|tj||��S)a�Return a connection to the session bus.

        :Parameters:
            `private` : bool
                If true, never return an existing shared instance, but instead
                return a private connection.
            `mainloop` : dbus.mainloop.NativeMainLoop
                The main loop to use. The default is to use the default
                main loop if one has been set up, or raise an exception
                if none has been.
        �r"r)rrrDrMs   r%rzSessionBus.__new__��)���{�{�3�� 0� 0�'�$,��.�	.r&rNrOr/r&r%rr�s
��2�
.r&rc��eZdZdZdd�Zy)rzjThe bus that activated this process (only valid if
    this process was launched by DBus activation).
    Nc�P�tj|tj||��S)a�Return a connection to the bus that activated this process.

        :Parameters:
            `private` : bool
                If true, never return an existing shared instance, but instead
                return a private connection.
            `mainloop` : dbus.mainloop.NativeMainLoop
                The main loop to use. The default is to use the default
                main loop if one has been set up, or raise an exception
                if none has been.
        rR)rr�TYPE_STARTERrMs   r%rzStarterBus.__new__�rSr&rNrOr/r&r%rr�s���
.r&rN)rC�
__future__r�__all__�
__docformat__�dbus.exceptionsr	�_dbus_bindingsr
rrr
rrrrrrrr�dbus.busr�
dbus.lowlevelr�dbus._compatrrrrrr/r&r%�<module>r_sp��?�:"�
:��"�
�)�I�I�I�I�
#�'���-��H,��,�".��.�".��.r&

Zerion Mini Shell 1.0