
Â�Â­Â�Â­Â�Â­Â�Â­Â�Â­Â�Â­Â�Â­Â�Â­Â�Â­Â�Â­Â�Â­Â�Â­Â�Â­Â�Â­Â�Â­Â�Â­Â�Â­Â�Â­
<!DOCTYPE html>
<html>
3

  \g  ã               @   sr  d Z ddlmZmZ ddlZdddddd	d
ddddddddddddddddddgZdZeedƒƒZ	eee
ƒ ƒƒZeei jƒ ƒƒZeei jƒ ƒƒZeei jƒ ƒƒZeeg ƒƒZeeeg ƒƒƒZeeedƒƒƒZeeedd > ƒƒƒZeeeƒ ƒƒZeed!ƒƒZeef ƒƒZeeeƒ ƒƒZei jƒ ƒZei jƒ ƒZei jƒ ƒZ eej!ƒZ"ed"d#„ ƒ ƒZ#d$d%„ Z$e$ƒ Z$ee$ƒZ%e$j&ƒ  [$d&d'„ Z'e'ƒ Z'ee'ƒZ(['d(d)„ Z)G d*d	„ d	ed+�Z*G d,d„ ded+�Z+G d-d„ de+ƒZ,e,j-e%ƒ G d.d„ ded+�Z.G d/d„ de.ƒZ/G d0d„ de/ƒZ0e0j-e(ƒ G d1d
„ d
ed+�Z1G d2d„ de1ƒZ2e2j-e	ƒ e2j-eƒ e2j-eƒ e2j-eƒ e2j-eƒ e2j-eƒ e2j-eƒ e2j-eƒ e2j-eƒ e2j-eƒ e2j-eƒ e2j-eƒ e2j-eƒ G d3d„ de1ƒZ3G d4d„ de2ƒZ4e4j-e#ƒ G d5d„ ded+�Z5G d6d„ ded+�Z6G d7d„ de5e1e6ƒZ7G d8d„ ded+�Z8G d9d„ de7ƒZ9e9j-e:ƒ G d:d„ de9ƒZ;e;j-eƒ G d;d„ de7ƒZ<e<j-e"ƒ G d<d„ de5ƒZ=G d=d„ de=e9ƒZ>e>j-eƒ G d>d„ de=e9ƒZ?e?j-e ƒ G d?d„ de=ƒZ@e@j-eƒ G d@d„ de<ƒZAeAj-eBƒ G dAd„ de3e7ƒZCeCj-eDƒ eCj-eEƒ eCj-eƒ eCj-eFƒ G dBd„ deCƒZGeGj-eHƒ eGj-e
ƒ G dCd„ deCƒZIeIj-eJƒ eIj-e
ƒ dS )DzjAbstract Base Classes (ABCs) for collections, according to PEP 3119.

Unit tests are in test_collections.
é    )ÚABCMetaÚabstractmethodNÚ	AwaitableÚ	CoroutineÚAsyncIterableÚAsyncIteratorÚAsyncGeneratorÚHashableÚIterableÚIteratorÚ	GeneratorÚ
ReversibleÚSizedÚ	ContainerÚCallableÚ
CollectionÚSetÚ
MutableSetÚMappingÚMutableMappingÚMappingViewÚKeysViewÚ	ItemsViewÚ
ValuesViewÚSequenceÚMutableSequenceÚ
ByteStringzcollections.abcó    é   iè  Ú c               c   s   d V S )N© r    r    r    ú(/usr/lib64/python3.6/_collections_abc.pyÚ<lambda>8   s    r"   c               Ã   s   d S )Nr    r    r    r    r!   Ú_coro:   s    r#   c               C  s
   d V  d S )Nr    r    r    r    r!   Ú_ag@   s    r$   c             G   sH   | j }x<|D ]4}x.|D ]"}||jkr|j| d kr6tS P qW tS qW dS )NT)Ú__mro__Ú__dict__ÚNotImplemented)ÚCÚmethodsÚmroÚmethodÚBr    r    r!   Ú_check_methodsH   s    


r-   c               @   s(   e Zd Zf Zedd„ ƒZedd„ ƒZdS )r	   c             C   s   dS )Nr   r    )Úselfr    r    r!   Ú__hash__X   s    zHashable.__hash__c             C   s   | t krt|dƒS tS )Nr/   )r	   r-   r'   )Úclsr(   r    r    r!   Ú__subclasshook__\   s    
zHashable.__subclasshook__N)Ú__name__Ú
__module__Ú__qualname__Ú	__slots__r   r/   Úclassmethodr1   r    r    r    r!   r	   T   s   )Ú	metaclassc               @   s(   e Zd Zf Zedd„ ƒZedd„ ƒZdS )r   c             c   s
   d V  d S )Nr    )r.   r    r    r!   Ú	__await__g   s    zAwaitable.__await__c             C   s   | t krt|dƒS tS )Nr8   )r   r-   r'   )r0   r(   r    r    r!   r1   k   s    
zAwaitable.__subclasshook__N)r2   r3   r4   r5   r   r8   r6   r1   r    r    r    r!   r   c   s   c               @   s>   e Zd Zf Zedd„ ƒZed
dd„ƒZdd„ Zedd	„ ƒZ	dS )r   c             C   s   t ‚dS )zcSend a value into the coroutine.
        Return next yielded value or raise StopIteration.
        N)ÚStopIteration)r.   Úvaluer    r    r!   Úsendv   s    zCoroutine.sendNc             C   s4   |dkr|dkr|‚|ƒ }|dk	r,|j |ƒ}|‚dS )zgRaise an exception in the coroutine.
        Return next yielded value or raise StopIteration.
        N)Úwith_traceback)r.   ÚtypÚvalÚtbr    r    r!   Úthrow}   s    
zCoroutine.throwc             C   s4   y| j tƒ W n ttfk
r&   Y n
X tdƒ‚dS )z.Raise GeneratorExit inside coroutine.
        zcoroutine ignored GeneratorExitN)r@   ÚGeneratorExitr9   ÚRuntimeError)r.   r    r    r!   ÚcloseŠ   s
    zCoroutine.closec             C   s   | t krt|ddddƒS tS )Nr8   r;   r@   rC   )r   r-   r'   )r0   r(   r    r    r!   r1   ”   s    zCoroutine.__subclasshook__)NN)
r2   r3   r4   r5   r   r;   r@   rC   r6   r1   r    r    r    r!   r   r   s   
c               @   s(   e Zd Zf Zedd„ ƒZedd„ ƒZdS )r   c             C   s   t ƒ S )N)r   )r.   r    r    r!   Ú	__aiter__¢   s    zAsyncIterable.__aiter__c             C   s   | t krt|dƒS tS )NrD   )r   r-   r'   )r0   r(   r    r    r!   r1   ¦   s    
zAsyncIterable.__subclasshook__N)r2   r3   r4   r5   r   rD   r6   r1   r    r    r    r!   r   ž   s   c               @   s0   e Zd Zf Zedd„ ƒZdd„ Zedd„ ƒZdS )r   c             Ã   s   t ‚dS )z@Return the next item or raise StopAsyncIteration when exhausted.N)ÚStopAsyncIteration)r.   r    r    r!   Ú	__anext__±   s    zAsyncIterator.__anext__c             C   s   | S )Nr    )r.   r    r    r!   rD   ¶   s    zAsyncIterator.__aiter__c             C   s   | t krt|ddƒS tS )NrF   rD   )r   r-   r'   )r0   r(   r    r    r!   r1   ¹   s    zAsyncIterator.__subclasshook__N)	r2   r3   r4   r5   r   rF   rD   r6   r1   r    r    r    r!   r   ­   s   c               @   sF   e Zd Zf Zdd„ Zedd„ ƒZeddd„ƒZdd	„ Ze	d
d„ ƒZ
dS )r   c             Ã   s   | j dƒI dH S )zpReturn the next item from the asynchronous generator.
        When exhausted, raise StopAsyncIteration.
        N)Úasend)r.   r    r    r!   rF   Ä   s    zAsyncGenerator.__anext__c             Ã   s   t ‚dS )zuSend a value into the asynchronous generator.
        Return next yielded value or raise StopAsyncIteration.
        N)rE   )r.   r:   r    r    r!   rG   Ê   s    zAsyncGenerator.asendNc             Ã   s4   |dkr|dkr|‚|ƒ }|dk	r,|j |ƒ}|‚dS )zyRaise an exception in the asynchronous generator.
        Return next yielded value or raise StopAsyncIteration.
        N)r<   )r.   r=   r>   r?   r    r    r!   ÚathrowÑ   s    
zAsyncGenerator.athrowc             Ã   s:   y| j tƒI dH  W n ttfk
r,   Y n
X tdƒ‚dS )z.Raise GeneratorExit inside coroutine.
        Nz,asynchronous generator ignored GeneratorExit)rH   rA   rE   rB   )r.   r    r    r!   ÚacloseÞ   s
    zAsyncGenerator.aclosec             C   s   | t krt|dddddƒS tS )NrD   rF   rG   rH   rI   )r   r-   r'   )r0   r(   r    r    r!   r1   è   s    
zAsyncGenerator.__subclasshook__)NN)r2   r3   r4   r5   rF   r   rG   rH   rI   r6   r1   r    r    r    r!   r   À   s   
c               @   s(   e Zd Zf Zedd„ ƒZedd„ ƒZdS )r
   c             c   s   d S )Nr    )r.   r    r    r!   Ú__iter__÷   s    zIterable.__iter__c             C   s   | t krt|dƒS tS )NrJ   )r
   r-   r'   )r0   r(   r    r    r!   r1   ü   s    
zIterable.__subclasshook__N)r2   r3   r4   r5   r   rJ   r6   r1   r    r    r    r!   r
   ó   s   c               @   s0   e Zd Zf Zedd„ ƒZdd„ Zedd„ ƒZdS )r   c             C   s   t ‚dS )zKReturn the next item from the iterator. When exhausted, raise StopIterationN)r9   )r.   r    r    r!   Ú__next__  s    zIterator.__next__c             C   s   | S )Nr    )r.   r    r    r!   rJ     s    zIterator.__iter__c             C   s   | t krt|ddƒS tS )NrJ   rK   )r   r-   r'   )r0   r(   r    r    r!   r1     s    zIterator.__subclasshook__N)	r2   r3   r4   r5   r   rK   rJ   r6   r1   r    r    r    r!   r     s   c               @   s(   e Zd Zf Zedd„ ƒZedd„ ƒZdS )r   c             c   s   d S )Nr    )r.   r    r    r!   Ú__reversed__)  s    zReversible.__reversed__c             C   s   | t krt|ddƒS tS )NrL   rJ   )r   r-   r'   )r0   r(   r    r    r!   r1   .  s    zReversible.__subclasshook__N)r2   r3   r4   r5   r   rL   r6   r1   r    r    r    r!   r   %  s   c               @   sF   e Zd Zf Zdd„ Zedd„ ƒZeddd„ƒZdd	„ Ze	d
d„ ƒZ
dS )r   c             C   s
   | j dƒS )z^Return the next item from the generator.
        When exhausted, raise StopIteration.
        N)r;   )r.   r    r    r!   rK   9  s    zGenerator.__next__c             C   s   t ‚dS )zcSend a value into the generator.
        Return next yielded value or raise StopIteration.
        N)r9   )r.   r:   r    r    r!   r;   ?  s    zGenerator.sendNc             C   s4   |dkr|dkr|‚|ƒ }|dk	r,|j |ƒ}|‚dS )zgRaise an exception in the generator.
        Return next yielded value or raise StopIteration.
        N)r<   )r.   r=   r>   r?   r    r    r!   r@   F  s    
zGenerator.throwc             C   s4   y| j tƒ W n ttfk
r&   Y n
X tdƒ‚dS )z.Raise GeneratorExit inside generator.
        zgenerator ignored GeneratorExitN)r@   rA   r9   rB   )r.   r    r    r!   rC   S  s
    zGenerator.closec             C   s   | t krt|dddddƒS tS )NrJ   rK   r;   r@   rC   )r   r-   r'   )r0   r(   r    r    r!   r1   ]  s    
zGenerator.__subclasshook__)NN)r2   r3   r4   r5   rK   r   r;   r@   rC   r6   r1   r    r    r    r!   r   5  s   
c               @   s(   e Zd Zf Zedd„ ƒZedd„ ƒZdS )r   c             C   s   dS )Nr   r    )r.   r    r    r!   Ú__len__k  s    zSized.__len__c             C   s   | t krt|dƒS tS )NrM   )r   r-   r'   )r0   r(   r    r    r!   r1   o  s    
zSized.__subclasshook__N)r2   r3   r4   r5   r   rM   r6   r1   r    r    r    r!   r   g  s   c               @   s(   e Zd Zf Zedd„ ƒZedd„ ƒZdS )r   c             C   s   dS )NFr    )r.   Úxr    r    r!   Ú__contains__z  s    zContainer.__contains__c             C   s   | t krt|dƒS tS )NrO   )r   r-   r'   )r0   r(   r    r    r!   r1   ~  s    
zContainer.__subclasshook__N)r2   r3   r4   r5   r   rO   r6   r1   r    r    r    r!   r   v  s   c               @   s   e Zd Zf Zedd„ ƒZdS )r   c             C   s   | t krt|dddƒS tS )NrM   rJ   rO   )r   r-   r'   )r0   r(   r    r    r!   r1   ˆ  s    zCollection.__subclasshook__N)r2   r3   r4   r5   r6   r1   r    r    r    r!   r   „  s   c               @   s(   e Zd Zf Zedd„ ƒZedd„ ƒZdS )r   c             O   s   dS )NFr    )r.   ÚargsÚkwdsr    r    r!   Ú__call__’  s    zCallable.__call__c             C   s   | t krt|dƒS tS )NrR   )r   r-   r'   )r0   r(   r    r    r!   r1   –  s    
zCallable.__subclasshook__N)r2   r3   r4   r5   r   rR   r6   r1   r    r    r    r!   r   Ž  s   c               @   sŒ   e Zd ZdZf Zdd„ Zdd„ Zdd„ Zdd	„ Zd
d„ Z	e
dd„ ƒZdd„ ZeZdd„ Zdd„ ZeZdd„ Zdd„ Zdd„ ZeZdd„ ZdS )r   aZ  A set is a finite, iterable container.

    This class provides concrete generic implementations of all
    methods except for __contains__, __iter__ and __len__.

    To override the comparisons (presumably for speed, as the
    semantics are fixed), redefine __le__ and __ge__,
    then the other operations will automatically follow suit.
    c             C   s@   t |tƒstS t| ƒt|ƒkr"dS x| D ]}||kr(dS q(W dS )NFT)Ú
isinstancer   r'   Úlen)r.   ÚotherÚelemr    r    r!   Ú__le__®  s    

z
Set.__le__c             C   s(   t |tƒstS t| ƒt|ƒk o&| j|ƒS )N)rS   r   r'   rT   rW   )r.   rU   r    r    r!   Ú__lt__¸  s    
z
Set.__lt__c             C   s(   t |tƒstS t| ƒt|ƒko&| j|ƒS )N)rS   r   r'   rT   Ú__ge__)r.   rU   r    r    r!   Ú__gt__½  s    
z
Set.__gt__c             C   s@   t |tƒstS t| ƒt|ƒk r"dS x|D ]}|| kr(dS q(W dS )NFT)rS   r   r'   rT   )r.   rU   rV   r    r    r!   rY   Â  s    

z
Set.__ge__c             C   s(   t |tƒstS t| ƒt|ƒko&| j|ƒS )N)rS   r   r'   rT   rW   )r.   rU   r    r    r!   Ú__eq__Ì  s    
z
Set.__eq__c             C   s   | |ƒS )z¼Construct an instance of the class from any iterable input.

        Must override this method if the class constructor signature
        does not accept an iterable for an input.
        r    )r0   Úitr    r    r!   Ú_from_iterableÑ  s    zSet._from_iterablec                s&   t |tƒstS ˆ j‡ fdd„|D ƒƒS )Nc             3   s   | ]}|ˆ kr|V  qd S )Nr    )Ú.0r:   )r.   r    r!   ú	<genexpr>Ý  s    zSet.__and__.<locals>.<genexpr>)rS   r
   r'   r]   )r.   rU   r    )r.   r!   Ú__and__Ú  s    
zSet.__and__c             C   s   x|D ]}|| krdS qW dS )z1Return True if two sets have a null intersection.FTr    )r.   rU   r:   r    r    r!   Ú
isdisjointá  s    
zSet.isdisjointc             C   s*   t |tƒstS dd„ | |fD ƒ}| j|ƒS )Nc             s   s   | ]}|D ]
}|V  q
qd S )Nr    )r^   ÚsÚer    r    r!   r_   ë  s    zSet.__or__.<locals>.<genexpr>)rS   r
   r'   r]   )r.   rU   Úchainr    r    r!   Ú__or__è  s    
z
Set.__or__c                s:   t ˆ tƒs"t ˆ tƒstS | jˆ ƒ‰ | j‡ fdd„| D ƒƒS )Nc             3   s   | ]}|ˆ kr|V  qd S )Nr    )r^   r:   )rU   r    r!   r_   õ  s    zSet.__sub__.<locals>.<genexpr>)rS   r   r
   r'   r]   )r.   rU   r    )rU   r!   Ú__sub__ð  s
    


zSet.__sub__c                s:   t |tƒs"t |tƒstS ˆ j|ƒ}ˆ j‡ fdd„|D ƒƒS )Nc             3   s   | ]}|ˆ kr|V  qd S )Nr    )r^   r:   )r.   r    r!   r_   ý  s    zSet.__rsub__.<locals>.<genexpr>)rS   r   r
   r'   r]   )r.   rU   r    )r.   r!   Ú__rsub__ø  s
    


zSet.__rsub__c             C   s2   t |tƒs"t |tƒstS | j|ƒ}| | ||  B S )N)rS   r   r
   r'   r]   )r.   rU   r    r    r!   Ú__xor__   s
    


zSet.__xor__c             C   sœ   t j}d| d }t| ƒ}d|d  }||M }x4| D ],}t|ƒ}|||d> A dA d N }||M }q4W |d d }||M }||krŒ||d 8 }|d
kr˜d	}|S )a+  Compute the hash value of a set.

        Note that we don't define __hash__: not all sets are hashable.
        But if you define a hashable set type, its __hash__ should
        call this function.

        This must be compatible __eq__.

        All sets ought to compare equal if they contain the same
        elements, regardless of how they are implemented, and
        regardless of the order of the elements; so there's not much
        freedom for __eq__ or __hash__.  We match the algorithm used
        by the built-in frozenset type.
        é   r   iMïèré   i³M[l   ×4~2 iÍ iãÃ6iÁÇ8#éÿÿÿÿ)ÚsysÚmaxsizerT   Úhash)r.   ÚMAXÚMASKÚnÚhrN   Úhxr    r    r!   Ú_hash	  s     
z	Set._hashN)r2   r3   r4   Ú__doc__r5   rW   rX   rZ   rY   r[   r6   r]   r`   Ú__rand__ra   re   Ú__ror__rf   rg   rh   Ú__rxor__rt   r    r    r    r!   r      s$   


	c               @   sd   e Zd ZdZf Zedd„ ƒZedd„ ƒZdd„ Zdd	„ Z	d
d„ Z
dd„ Zdd„ Zdd„ Zdd„ ZdS )r   a‡  A mutable set is a finite, iterable container.

    This class provides concrete generic implementations of all
    methods except for __contains__, __iter__, __len__,
    add(), and discard().

    To override the comparisons (presumably for speed, as the
    semantics are fixed), all you have to do is redefine __le__ and
    then the other operations will automatically follow suit.
    c             C   s   t ‚dS )zAdd an element.N)ÚNotImplementedError)r.   r:   r    r    r!   Úadd:  s    zMutableSet.addc             C   s   t ‚dS )z8Remove an element.  Do not raise an exception if absent.N)ry   )r.   r:   r    r    r!   Údiscard?  s    zMutableSet.discardc             C   s   || krt |ƒ‚| j|ƒ dS )z5Remove an element. If not a member, raise a KeyError.N)ÚKeyErrorr{   )r.   r:   r    r    r!   ÚremoveD  s    zMutableSet.removec             C   s<   t | ƒ}yt|ƒ}W n tk
r,   t‚Y nX | j|ƒ |S )z2Return the popped value.  Raise KeyError if empty.)ÚiterÚnextr9   r|   r{   )r.   r\   r:   r    r    r!   ÚpopJ  s    

zMutableSet.popc             C   s,   yx| j ƒ  qW W n tk
r&   Y nX dS )z6This is slow (creates N new iterators!) but effective.N)r€   r|   )r.   r    r    r!   ÚclearT  s
    zMutableSet.clearc             C   s   x|D ]}| j |ƒ qW | S )N)rz   )r.   r\   r:   r    r    r!   Ú__ior__\  s    
zMutableSet.__ior__c             C   s    x| | D ]}| j |ƒ q
W | S )N)r{   )r.   r\   r:   r    r    r!   Ú__iand__a  s    zMutableSet.__iand__c             C   sV   || kr| j ƒ  n@t|tƒs&| j|ƒ}x*|D ]"}|| krD| j|ƒ q,| j|ƒ q,W | S )N)r�   rS   r   r]   r{   rz   )r.   r\   r:   r    r    r!   Ú__ixor__f  s    



zMutableSet.__ixor__c             C   s.   || kr| j ƒ  nx|D ]}| j|ƒ qW | S )N)r�   r{   )r.   r\   r:   r    r    r!   Ú__isub__s  s
    

zMutableSet.__isub__N)r2   r3   r4   ru   r5   r   rz   r{   r}   r€   r�   r‚   rƒ   r„   r…   r    r    r    r!   r   ,  s   

c               @   sR   e Zd Zf Zedd„ ƒZddd„Zdd„ Zdd	„ Zd
d„ Z	dd„ Z
dd„ ZdZdS )r   c             C   s   t ‚d S )N)r|   )r.   Úkeyr    r    r!   Ú__getitem__�  s    zMapping.__getitem__Nc             C   s"   y| | S  t k
r   |S X dS )z<D.get(k[,d]) -> D[k] if k in D, else d.  d defaults to None.N)r|   )r.   r†   Údefaultr    r    r!   Úget‘  s    zMapping.getc             C   s*   y| |  W n t k
r    dS X dS d S )NFT)r|   )r.   r†   r    r    r!   rO   ˜  s
    zMapping.__contains__c             C   s   t | ƒS )z:D.keys() -> a set-like object providing a view on D's keys)r   )r.   r    r    r!   Úkeys   s    zMapping.keysc             C   s   t | ƒS )z<D.items() -> a set-like object providing a view on D's items)r   )r.   r    r    r!   Úitems¤  s    zMapping.itemsc             C   s   t | ƒS )z6D.values() -> an object providing a view on D's values)r   )r.   r    r    r!   Úvalues¨  s    zMapping.valuesc             C   s&   t |tƒstS t| jƒ ƒt|jƒ ƒkS )N)rS   r   r'   Údictr‹   )r.   rU   r    r    r!   r[   ¬  s    
zMapping.__eq__)N)r2   r3   r4   r5   r   r‡   r‰   rO   rŠ   r‹   rŒ   r[   rL   r    r    r    r!   r   �  s   

c               @   s(   e Zd Zd	Zdd„ Zdd„ Zdd„ ZdS )
r   Ú_mappingc             C   s
   || _ d S )N)rŽ   )r.   Úmappingr    r    r!   Ú__init__º  s    zMappingView.__init__c             C   s
   t | jƒS )N)rT   rŽ   )r.   r    r    r!   rM   ½  s    zMappingView.__len__c             C   s
   dj | ƒS )Nz&{0.__class__.__name__}({0._mapping!r}))Úformat)r.   r    r    r!   Ú__repr__À  s    zMappingView.__repr__N)rŽ   )r2   r3   r4   r5   r�   rM   r’   r    r    r    r!   r   ¶  s   c               @   s,   e Zd Zf Zedd„ ƒZdd„ Zdd„ ZdS )r   c             C   s   t |ƒS )N)Úset)r.   r\   r    r    r!   r]   È  s    zKeysView._from_iterablec             C   s
   || j kS )N)rŽ   )r.   r†   r    r    r!   rO   Ì  s    zKeysView.__contains__c             c   s   | j E d H  d S )N)rŽ   )r.   r    r    r!   rJ   Ï  s    zKeysView.__iter__N)r2   r3   r4   r5   r6   r]   rO   rJ   r    r    r    r!   r   Ä  s   c               @   s,   e Zd Zf Zedd„ ƒZdd„ Zdd„ ZdS )r   c             C   s   t |ƒS )N)r“   )r.   r\   r    r    r!   r]   Ù  s    zItemsView._from_iterablec             C   s@   |\}}y| j | }W n tk
r*   dS X ||kp:||kS d S )NF)rŽ   r|   )r.   Úitemr†   r:   Úvr    r    r!   rO   Ý  s    zItemsView.__contains__c             c   s$   x| j D ]}|| j | fV  qW d S )N)rŽ   )r.   r†   r    r    r!   rJ   æ  s    zItemsView.__iter__N)r2   r3   r4   r5   r6   r]   rO   rJ   r    r    r    r!   r   Õ  s   	c               @   s    e Zd Zf Zdd„ Zdd„ ZdS )r   c             C   s2   x,| j D ]"}| j | }||ks&||krdS qW dS )NTF)rŽ   )r.   r:   r†   r•   r    r    r!   rO   ñ  s
    
zValuesView.__contains__c             c   s    x| j D ]}| j | V  qW d S )N)rŽ   )r.   r†   r    r    r!   rJ   ø  s    zValuesView.__iter__N)r2   r3   r4   r5   rO   rJ   r    r    r    r!   r   í  s   c               @   s\   e Zd Zf Zedd„ ƒZedd„ ƒZeƒ Zefdd„Z	dd„ Z
d	d
„ Zdd„ Zddd„ZdS )r   c             C   s   t ‚d S )N)r|   )r.   r†   r:   r    r    r!   Ú__setitem__  s    zMutableMapping.__setitem__c             C   s   t ‚d S )N)r|   )r.   r†   r    r    r!   Ú__delitem__  s    zMutableMapping.__delitem__c             C   s<   y| | }W n  t k
r,   || jkr(‚ |S X | |= |S dS )z©D.pop(k[,d]) -> v, remove specified key and return the corresponding value.
          If key is not found, d is returned if given, otherwise KeyError is raised.
        N)r|   Ú_MutableMapping__marker)r.   r†   rˆ   r:   r    r    r!   r€     s    
zMutableMapping.popc             C   s@   yt t| ƒƒ}W n tk
r(   t‚Y nX | | }| |= ||fS )zƒD.popitem() -> (k, v), remove and return some (key, value) pair
           as a 2-tuple; but raise KeyError if D is empty.
        )r   r~   r9   r|   )r.   r†   r:   r    r    r!   Úpopitem$  s    
zMutableMapping.popitemc             C   s,   yx| j ƒ  qW W n tk
r&   Y nX dS )z,D.clear() -> None.  Remove all items from D.N)r™   r|   )r.   r    r    r!   r�   0  s
    zMutableMapping.clearc              O   sÈ   | st dƒ‚| ^}} t| ƒdkr0t dt| ƒ ƒ‚| r¦| d }t|tƒrbx^|D ]}|| ||< qLW nDt|dƒrŒx8|jƒ D ]}|| ||< qvW nx|D ]\}}|||< q’W x|jƒ D ]\}}|||< q°W dS )aK   D.update([E, ]**F) -> None.  Update D from mapping/iterable E and F.
            If E present and has a .keys() method, does:     for k in E: D[k] = E[k]
            If E present and lacks .keys() method, does:     for (k, v) in E: D[k] = v
            In either case, this is followed by: for k, v in F.items(): D[k] = v
        z@descriptor 'update' of 'MutableMapping' object needs an argumentr   z+update expected at most 1 arguments, got %dr   rŠ   N)Ú	TypeErrorrT   rS   r   ÚhasattrrŠ   r‹   )rP   rQ   r.   rU   r†   r:   r    r    r!   Úupdate8  s$    


zMutableMapping.updateNc             C   s*   y| | S  t k
r$   || |< Y nX |S )z@D.setdefault(k[,d]) -> D.get(k,d), also set D[k]=d if k not in D)r|   )r.   r†   rˆ   r    r    r!   Ú
setdefaultS  s
    zMutableMapping.setdefault)N)r2   r3   r4   r5   r   r–   r—   Úobjectr˜   r€   r™   r�   rœ   r�   r    r    r    r!   r   ÿ  s   c               @   sJ   e Zd ZdZf Zedd„ ƒZdd„ Zdd„ Zdd	„ Z	ddd„Z
dd„ ZdS )r   zŠAll the operations on a read-only sequence.

    Concrete subclasses must override __new__ or __init__,
    __getitem__, and __len__.
    c             C   s   t ‚d S )N)Ú
IndexError)r.   Úindexr    r    r!   r‡   k  s    zSequence.__getitem__c             c   s>   d}y x| | }|V  |d7 }qW W n t k
r8   d S X d S )Nr   r   )rŸ   )r.   Úir•   r    r    r!   rJ   o  s    zSequence.__iter__c             C   s&   x | D ]}||ks||krdS qW dS )NTFr    )r.   r:   r•   r    r    r!   rO   y  s    
zSequence.__contains__c             c   s(   x"t tt| ƒƒƒD ]}| | V  qW d S )N)ÚreversedÚrangerT   )r.   r¡   r    r    r!   rL     s    zSequence.__reversed__r   Nc             C   s    |dk	r"|dk r"t t| ƒ| dƒ}|dk	r>|dk r>|t| ƒ7 }|}xT|dksT||k r–y | | }||ksn||krr|S W n tk
rŠ   P Y nX |d7 }qDW t‚dS )zæS.index(value, [start, [stop]]) -> integer -- return first index of value.
           Raises ValueError if the value is not present.

           Supporting start and stop arguments is optional, but
           recommended.
        Nr   r   )ÚmaxrT   rŸ   Ú
ValueError)r.   r:   ÚstartÚstopr¡   r•   r    r    r!   r    ƒ  s    zSequence.indexc                s   t ‡ fdd„| D ƒƒS )zBS.count(value) -> integer -- return number of occurrences of valuec             3   s"   | ]}|ˆ ks|ˆ krd V  qdS )r   Nr    )r^   r•   )r:   r    r!   r_   œ  s    z!Sequence.count.<locals>.<genexpr>)Úsum)r.   r:   r    )r:   r!   Úcountš  s    zSequence.count)r   N)r2   r3   r4   ru   r5   r   r‡   rJ   rO   rL   r    r©   r    r    r    r!   r   a  s   

c               @   s   e Zd ZdZf ZdS )r   zMThis unifies bytes and bytearray.

    XXX Should add all their methods.
    N)r2   r3   r4   ru   r5   r    r    r    r!   r   ¤  s   c               @   sn   e Zd Zf Zedd„ ƒZedd„ ƒZedd„ ƒZdd„ Zd	d
„ Z	dd„ Z
dd„ Zddd„Zdd„ Zdd„ ZdS )r   c             C   s   t ‚d S )N)rŸ   )r.   r    r:   r    r    r!   r–   ¼  s    zMutableSequence.__setitem__c             C   s   t ‚d S )N)rŸ   )r.   r    r    r    r!   r—   À  s    zMutableSequence.__delitem__c             C   s   t ‚dS )z3S.insert(index, value) -- insert value before indexN)rŸ   )r.   r    r:   r    r    r!   ÚinsertÄ  s    zMutableSequence.insertc             C   s   | j t| ƒ|ƒ dS )z:S.append(value) -- append value to the end of the sequenceN)rª   rT   )r.   r:   r    r    r!   ÚappendÉ  s    zMutableSequence.appendc             C   s,   yx| j ƒ  qW W n tk
r&   Y nX dS )z,S.clear() -> None -- remove all items from SN)r€   rŸ   )r.   r    r    r!   r�   Í  s
    zMutableSequence.clearc             C   sL   t | ƒ}x>t|d ƒD ].}| || d  | |  | |< | || d < qW dS )z!S.reverse() -- reverse *IN PLACE*ri   r   N)rT   r£   )r.   rq   r¡   r    r    r!   ÚreverseÕ  s    zMutableSequence.reversec             C   s   x|D ]}| j |ƒ qW dS )zMS.extend(iterable) -- extend sequence by appending elements from the iterableN)r«   )r.   rŒ   r•   r    r    r!   ÚextendÛ  s    
zMutableSequence.extendr   c             C   s   | | }| |= |S )z™S.pop([index]) -> item -- remove and return item at index (default last).
           Raise IndexError if list is empty or index is out of range.
        r    )r.   r    r•   r    r    r!   r€   à  s    zMutableSequence.popc             C   s   | | j |ƒ= dS )zvS.remove(value) -- remove first occurrence of value.
           Raise ValueError if the value is not present.
        N)r    )r.   r:   r    r    r!   r}   è  s    zMutableSequence.removec             C   s   | j |ƒ | S )N)r­   )r.   rŒ   r    r    r!   Ú__iadd__î  s    
zMutableSequence.__iadd__Nrk   )rk   )r2   r3   r4   r5   r   r–   r—   rª   r«   r�   r¬   r­   r€   r}   r®   r    r    r    r!   r   ±  s   	
)Kru   Úabcr   r   rl   Ú__all__r2   Útyper~   Úbytes_iteratorÚ	bytearrayÚbytearray_iteratorrŠ   Údict_keyiteratorrŒ   Údict_valueiteratorr‹   Údict_itemiteratorÚlist_iteratorr¢   Úlist_reverseiteratorr£   Úrange_iteratorÚlongrange_iteratorr“   Úset_iteratorÚstr_iteratorÚtuple_iteratorÚzipÚzip_iteratorÚ	dict_keysÚdict_valuesÚ
dict_itemsr&   ÚmappingproxyÚ	generatorr#   Ú	coroutinerC   r$   Úasync_generatorr-   r	   r   r   Úregisterr   r   r   r
   r   r   r   r   r   r   r   r   Ú	frozensetr   r   r   r   r   r   r   r�   r   ÚtupleÚstrÚ
memoryviewr   Úbytesr   Úlistr    r    r    r!   Ú<module>   sÂ   
	
)
0













/

 

O
2



\
=



	

A
