Spamworldpro Mini Shell
Spamworldpro


Server : Apache/2.4.52 (Ubuntu)
System : Linux webserver 6.8.0-49-generic #49~22.04.1-Ubuntu SMP PREEMPT_DYNAMIC Wed Nov 6 17:42:15 UTC 2 x86_64
User : www-data ( 33)
PHP Version : 8.1.2-1ubuntu2.21
Disable Function : NONE
Directory :  /lib/python3/dist-packages/zope/interface/common/__pycache__/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Current File : //lib/python3/dist-packages/zope/interface/common/__pycache__/mapping.cpython-310.pyc
o

$
x`R�@s�dZddlmZddlmZddlmZGdd�de�ZGdd�dej	e�Z
Gd	d
�d
e�ZGdd�deje
�Z
Gd
d�dee
�ZGdd�de
�ZGdd�de�ZGdd�de�ZGdd�de�ZGdd�dejeeee�ZdS)ah
Mapping Interfaces.

Importing this module does *not* mark any standard classes as
implementing any of these interfaces.

While this module is not deprecated, new code should generally use
:mod:`zope.interface.common.collections`, specifically
:class:`~zope.interface.common.collections.IMapping` and
:class:`~zope.interface.common.collections.IMutableMapping`. This
module is occasionally useful for its extremely fine grained breakdown
of interfaces.

The standard library :class:`dict` and :class:`collections.UserDict`
implement ``IMutableMapping``, but *do not* implement any of the
interfaces in this module.
�)�	Interface)�PYTHON2)�collectionsc@�eZdZdZdd�ZdS)�IItemMappingz%Simplest readable mapping object
    cC�dS)z`Get a value for a key

        A `KeyError` is raised if there is no value for the key.
        N���keyrr�?/usr/lib/python3/dist-packages/zope/interface/common/mapping.py�__getitem__'�zIItemMapping.__getitem__N)�__name__�
__module__�__qualname__�__doc__rrrrrr#src@s"eZdZdZddd�Zdd�ZdS)�IReadMappingz^
    Basic mapping interface.

    .. versionchanged:: 5.0.0
       Extend ``IContainer``
    NcCr)zaGet a value for a key

        The default is returned if there is no value for the key.
        Nr�r
�defaultrrr�get6r
zIReadMapping.getcCr)z$Tell if a key exists in the mapping.Nrr	rrr�__contains__<r
zIReadMapping.__contains__�N)rrrrrrrrrrr.s
rc@s eZdZdZdd�Zdd�ZdS)�
IWriteMappingz!Mapping methods for changing datacCr)z.Delete a value from the mapping using the key.Nrr	rrr�__delitem__Dr
zIWriteMapping.__delitem__cCr)zSet a new item in the mapping.Nr)r
�valuerrr�__setitem__Gr
zIWriteMapping.__setitem__N)rrrrrrrrrrrAsrc@s0eZdZdZdd�Zdd�Zdd�Zdd	�Zd
S)�IEnumerableMappingzp
    Mapping objects whose items can be enumerated.

    .. versionchanged:: 5.0.0
       Extend ``ISized``
    cCr)z/Return the keys of the mapping object.
        Nrrrrr�keysSr
zIEnumerableMapping.keyscCr)z?Return an iterator for the keys of the mapping object.
        Nrrrrr�__iter__Wr
zIEnumerableMapping.__iter__cCr)z1Return the values of the mapping object.
        Nrrrrr�values[r
zIEnumerableMapping.valuescCr)z0Return the items of the mapping object.
        Nrrrrr�items_r
zIEnumerableMapping.itemsN)rrrrrrrr rrrrrKsrc@�eZdZdZdS)�IMappingz Simple mapping interface N�rrrrrrrrr"csr"c@s0eZdZdZerdd�Zdd�Zdd�ZdSdS)	�IIterableMappingz�A mapping that has distinct methods for iterating
    without copying.

    On Python 2, a `dict` has these methods, but on Python 3
    the methods defined in `IEnumerableMapping` already iterate
    without copying.
    cCr)z-iterate over keys; equivalent to ``__iter__``Nrrrrr�iterkeyspr
zIIterableMapping.iterkeyscCr)ziterate over valuesNrrrrr�
itervaluessr
zIIterableMapping.itervaluescCr)ziterate over itemsNrrrrr�	iteritemsvr
zIIterableMapping.iteritemsN)rrrr�PY2r%r&r'rrrrr$fs�r$c@r)�IClonableMappingzSSomething that can produce a copy of itself.

    This is available in `dict`.
    cCr)zreturn copy of dictNrrrrr�copyr
zIClonableMapping.copyN)rrrrr*rrrrr)ysr)c@s eZdZdZerdd�ZdSdS)�IExtendedReadMappingz�
    Something with a particular method equivalent to ``__contains__``.

    On Python 2, `dict` provides this method, but it was removed
    in Python 3.
    cCr)zCTell if a key exists in the mapping; equivalent to ``__contains__``Nrr	rrr�has_key�r
zIExtendedReadMapping.has_keyN)rrrrr(r,rrrrr+�s
�r+c@s<eZdZdZdd�Zdd�Zd
dd�Zd
d	d
�Zdd�ZdS)�IExtendedWriteMappingzHAdditional mutation methods.

    These are all provided by `dict`.
    cCr)zdelete all itemsNrrrrr�clear�r
zIExtendedWriteMapping.clearcCr)z0 Update D from E: for k in E.keys(): D[k] = E[k]Nr)�drrr�update�r
zIExtendedWriteMapping.updateNcCr)z@D.setdefault(k[,d]) -> D.get(k,d), also set D[k]=d if k not in DNrrrrr�
setdefault�r
z IExtendedWriteMapping.setdefaultcCr)a
        pop(k[,default]) -> value

        Remove specified key and return the corresponding value.

        If key is not found, *default* is returned if given, otherwise
        `KeyError` is raised. Note that *default* must not be passed by
        name.
        Nr)�krrrr�pop�r
zIExtendedWriteMapping.popcCr)zeremove and return some (key, value) pair as a
        2-tuple; but raise KeyError if mapping is emptyNrrrrr�popitem�r
zIExtendedWriteMapping.popitemr)	rrrrr.r0r1r3r4rrrrr-�s

r-c@r!)�IFullMappinga$
    Full mapping interface.

    Most uses of this interface should instead use
    :class:`~zope.interface.commons.collections.IMutableMapping` (one of the
    bases of this interface). The required methods are the same.

    .. versionchanged:: 5.0.0
       Extend ``IMutableMapping``
    Nr#rrrrr5�sr5N)r�zope.interfacer�zope.interface._compatrr(�zope.interface.commonrr�
IContainerrr�ISizedrr"r$r)r+r-�IMutableMappingr5rrrr�<module>s"

	
�

Spamworldpro Mini