ó
è¾bc           @   s”  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 g Z d „  Z d d% d „  ƒ  YZ d d& d „  ƒ  YZ e j	 e
 ƒ d e f d „  ƒ  YZ d d' d „  ƒ  YZ d d( d „  ƒ  YZ d	 d) d „  ƒ  YZ d
 e e e f d „  ƒ  YZ e j	 e ƒ d e f d „  ƒ  YZ e j	 e ƒ d e e e f d „  ƒ  YZ d e f d „  ƒ  YZ d e e f d „  ƒ  YZ e j	 e i  j ƒ  ƒ ƒ d e e f d  „  ƒ  YZ e j	 e i  j ƒ  ƒ ƒ d e f d! „  ƒ  YZ e j	 e i  j ƒ  ƒ ƒ d e f d" „  ƒ  YZ e j	 e ƒ d e e e f d# „  ƒ  YZ e j	 e ƒ e j	 e  ƒ e j	 e! ƒ e j	 e" ƒ d e f d$ „  ƒ  YZ# e# j	 e$ ƒ d S(*   s  Abstract Base Classes (ABCs) for collections, according to PEP 3119.

DON'T USE THIS MODULE DIRECTLY!  The classes here should be imported
via collections; they are defined here only to alleviate certain
bootstrapping issues.  Unit tests are in test_collections.
iÿÿÿÿ(   t   ABCMetat   abstractmethodNt   Hashablet   Iterablet   Iteratort   Sizedt	   Containert   Callablet   Sett
   MutableSett   Mappingt   MutableMappingt   MappingViewt   KeysViewt	   ItemsViewt
   ValuesViewt   Sequencet   MutableSequencec            sC   y! t  ‡  f d †  |  j Dƒ ƒ SWn t k
 r> t |  ˆ  ƒ SXd  S(   Nc         3   s   |  ] } ˆ  | j  k Vq d  S(   N(   t   __dict__(   t   .0t   B(   t   attr(    s   /usr/lib/python2.7/_abcoll.pys	   <genexpr>   s    (   t   anyt   __mro__t   AttributeErrort   hasattr(   t   CR   (    (   R   s   /usr/lib/python2.7/_abcoll.pyt   _hasattr   s    !c           B   s,   e  Z e Z e d  „  ƒ Z e d „  ƒ Z RS(   c         C   s   d S(   Ni    (    (   t   self(    (    s   /usr/lib/python2.7/_abcoll.pyt   __hash__#   s    c         C   sy   |  t  k ru y< x5 | j D]* } d | j k r | j d r? t SPq q WWqu t k
 rq t | d d  ƒ rr t Squ Xn  t S(   NR   (   R   R   R   t   TrueR   t   getattrt   Nonet   NotImplemented(   t   clsR   R   (    (    s   /usr/lib/python2.7/_abcoll.pyt   __subclasshook__'   s    (   t   __name__t
   __module__R    t   __metaclass__R   R   t   classmethodR#   (    (    (    s   /usr/lib/python2.7/_abcoll.pyR       s   c           B   s,   e  Z e Z e d  „  ƒ Z e d „  ƒ Z RS(   c         c   s   x t  r d  Vq Wd  S(   N(   t   FalseR    (   R   (    (    s   /usr/lib/python2.7/_abcoll.pyt   __iter__:   s    	c         C   s&   |  t  k r" t | d ƒ r" t Sn  t S(   NR)   (   R   R   R   R!   (   R"   R   (    (    s   /usr/lib/python2.7/_abcoll.pyR#   ?   s    (   R$   R%   R    R&   R   R)   R'   R#   (    (    (    s   /usr/lib/python2.7/_abcoll.pyR   7   s   c           B   s/   e  Z e d  „  ƒ Z d „  Z e d „  ƒ Z RS(   c         C   s
   t  ‚ d S(   sK   Return the next item from the iterator. When exhausted, raise StopIterationN(   t   StopIteration(   R   (    (    s   /usr/lib/python2.7/_abcoll.pyt   nextK   s    c         C   s   |  S(   N(    (   R   (    (    s   /usr/lib/python2.7/_abcoll.pyR)   P   s    c         C   s5   |  t  k r1 t | d ƒ r1 t | d ƒ r1 t Sn  t S(   NR+   R)   (   R   R   R   R!   (   R"   R   (    (    s   /usr/lib/python2.7/_abcoll.pyR#   S   s    (   R$   R%   R   R+   R)   R'   R#   (    (    (    s   /usr/lib/python2.7/_abcoll.pyR   I   s   	c           B   s,   e  Z e Z e d  „  ƒ Z e d „  ƒ Z RS(   c         C   s   d S(   Ni    (    (   R   (    (    s   /usr/lib/python2.7/_abcoll.pyt   __len__^   s    c         C   s&   |  t  k r" t | d ƒ r" t Sn  t S(   NR,   (   R   R   R   R!   (   R"   R   (    (    s   /usr/lib/python2.7/_abcoll.pyR#   b   s    (   R$   R%   R    R&   R   R,   R'   R#   (    (    (    s   /usr/lib/python2.7/_abcoll.pyR   [   s   c           B   s,   e  Z e Z e d  „  ƒ Z e d „  ƒ Z RS(   c         C   s   t  S(   N(   R(   (   R   t   x(    (    s   /usr/lib/python2.7/_abcoll.pyt   __contains__m   s    c         C   s&   |  t  k r" t | d ƒ r" t Sn  t S(   NR.   (   R   R   R   R!   (   R"   R   (    (    s   /usr/lib/python2.7/_abcoll.pyR#   q   s    (   R$   R%   R    R&   R   R.   R'   R#   (    (    (    s   /usr/lib/python2.7/_abcoll.pyR   j   s   c           B   s,   e  Z e Z e d  „  ƒ Z e d „  ƒ Z RS(   c         O   s   t  S(   N(   R(   (   R   t   argst   kwds(    (    s   /usr/lib/python2.7/_abcoll.pyt   __call__|   s    c         C   s&   |  t  k r" t | d ƒ r" t Sn  t S(   NR1   (   R   R   R   R!   (   R"   R   (    (    s   /usr/lib/python2.7/_abcoll.pyR#   €   s    (   R$   R%   R    R&   R   R1   R'   R#   (    (    (    s   /usr/lib/python2.7/_abcoll.pyR   y   s   c           B   sª   e  Z d  Z d „  Z d „  Z d „  Z d „  Z d „  Z d „  Z e	 d „  ƒ Z
 d „  Z e Z d	 „  Z d
 „  Z e Z d „  Z d „  Z d „  Z e Z d Z d „  Z RS(   sZ  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   sT   t  | t ƒ s t St |  ƒ t | ƒ k r/ t Sx |  D] } | | k r6 t Sq6 Wt S(   N(   t
   isinstanceR   R!   t   lenR(   R   (   R   t   othert   elem(    (    s   /usr/lib/python2.7/_abcoll.pyt   __le__–   s    c         C   s8   t  | t ƒ s t St |  ƒ t | ƒ k  o7 |  j | ƒ S(   N(   R2   R   R!   R3   R6   (   R   R4   (    (    s   /usr/lib/python2.7/_abcoll.pyt   __lt__    s    c         C   s8   t  | t ƒ s t St |  ƒ t | ƒ k o7 |  j | ƒ S(   N(   R2   R   R!   R3   t   __ge__(   R   R4   (    (    s   /usr/lib/python2.7/_abcoll.pyt   __gt__¥   s    c         C   sT   t  | t ƒ s t St |  ƒ t | ƒ k  r/ t Sx | D] } | |  k r6 t Sq6 Wt S(   N(   R2   R   R!   R3   R(   R   (   R   R4   R5   (    (    s   /usr/lib/python2.7/_abcoll.pyR8   ª   s    c         C   s8   t  | t ƒ s t St |  ƒ t | ƒ k o7 |  j | ƒ S(   N(   R2   R   R!   R3   R6   (   R   R4   (    (    s   /usr/lib/python2.7/_abcoll.pyt   __eq__´   s    c         C   s   |  | k S(   N(    (   R   R4   (    (    s   /usr/lib/python2.7/_abcoll.pyt   __ne__¹   s    c         C   s
   |  | ƒ S(   s¼   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"   t   it(    (    s   /usr/lib/python2.7/_abcoll.pyt   _from_iterable¼   s    c            s0   t  | t ƒ s t Sˆ  j ‡  f d †  | Dƒ ƒ S(   Nc         3   s!   |  ] } | ˆ  k r | Vq d  S(   N(    (   R   t   value(   R   (    s   /usr/lib/python2.7/_abcoll.pys	   <genexpr>È   s    (   R2   R   R!   R=   (   R   R4   (    (   R   s   /usr/lib/python2.7/_abcoll.pyt   __and__Å   s    c         C   s%   x | D] } | |  k r t  Sq Wt S(   s1   Return True if two sets have a null intersection.(   R(   R   (   R   R4   R>   (    (    s   /usr/lib/python2.7/_abcoll.pyt
   isdisjointÌ   s    c         C   s6   t  | t ƒ s t Sd „  |  | f Dƒ } |  j | ƒ S(   Nc         s   s"   |  ] } | D] } | Vq q d  S(   N(    (   R   t   st   e(    (    s   /usr/lib/python2.7/_abcoll.pys	   <genexpr>Ö   s    (   R2   R   R!   R=   (   R   R4   t   chain(    (    s   /usr/lib/python2.7/_abcoll.pyt   __or__Ó   s    c            sQ   t  ˆ  t ƒ s4 t  ˆ  t ƒ s" t S|  j ˆ  ƒ ‰  n  |  j ‡  f d †  |  Dƒ ƒ S(   Nc         3   s!   |  ] } | ˆ  k r | Vq d  S(   N(    (   R   R>   (   R4   (    s   /usr/lib/python2.7/_abcoll.pys	   <genexpr>à   s    (   R2   R   R   R!   R=   (   R   R4   (    (   R4   s   /usr/lib/python2.7/_abcoll.pyt   __sub__Û   s
    c            sQ   t  | t ƒ s4 t  | t ƒ s" t Sˆ  j | ƒ } n  ˆ  j ‡  f d †  | Dƒ ƒ S(   Nc         3   s!   |  ] } | ˆ  k r | Vq d  S(   N(    (   R   R>   (   R   (    s   /usr/lib/python2.7/_abcoll.pys	   <genexpr>è   s    (   R2   R   R   R!   R=   (   R   R4   (    (   R   s   /usr/lib/python2.7/_abcoll.pyt   __rsub__ã   s
    c         C   sD   t  | t ƒ s4 t  | t ƒ s" t S|  j | ƒ } n  |  | | |  BS(   N(   R2   R   R   R!   R=   (   R   R4   (    (    s   /usr/lib/python2.7/_abcoll.pyt   __xor__ë   s
    c         C   sÊ   t  j } d | d } t |  ƒ } d | d } | | M} x> |  D]6 } t | ƒ } | | | d >Ad Ad N} | | M} qB W| d d } | | M} | | k r± | | d 8} n  | d	 k rÆ d
 } n  | S(   s+  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.
        i   i   iMïèri   i³M[I×4?Ù    iÍ iãÃ6iÿÿÿÿiÁÇ8#(   t   syst   maxintR3   t   hash(   R   t   MAXt   MASKt   nt   hR-   t   hx(    (    s   /usr/lib/python2.7/_abcoll.pyt   _hash÷   s     	

	N(   R$   R%   t   __doc__R6   R7   R9   R8   R:   R;   R'   R=   R?   t   __rand__R@   RD   t   __ror__RE   RF   RG   t   __rxor__R    R   RP   (    (    (    s   /usr/lib/python2.7/_abcoll.pyR   ‹   s&   		
			
									c           B   sk   e  Z d  Z e d „  ƒ Z e d „  ƒ Z d „  Z d „  Z d „  Z d „  Z	 d „  Z
 d „  Z d	 „  Z RS(
   s‡  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(   s   Add an element.N(   t   NotImplementedError(   R   R>   (    (    s   /usr/lib/python2.7/_abcoll.pyt   add&  s    c         C   s
   t  ‚ d S(   s8   Remove an element.  Do not raise an exception if absent.N(   RU   (   R   R>   (    (    s   /usr/lib/python2.7/_abcoll.pyt   discard+  s    c         C   s,   | |  k r t  | ƒ ‚ n  |  j | ƒ d S(   s5   Remove an element. If not a member, raise a KeyError.N(   t   KeyErrorRW   (   R   R>   (    (    s   /usr/lib/python2.7/_abcoll.pyt   remove0  s    c         C   sG   t  |  ƒ } y t | ƒ } Wn t k
 r5 t ‚ n X|  j | ƒ | S(   s2   Return the popped value.  Raise KeyError if empty.(   t   iterR+   R*   RX   RW   (   R   R<   R>   (    (    s   /usr/lib/python2.7/_abcoll.pyt   pop6  s    
c         C   s3   y x t  r |  j ƒ  q WWn t k
 r. n Xd S(   s6   This is slow (creates N new iterators!) but effective.N(   R   R[   RX   (   R   (    (    s   /usr/lib/python2.7/_abcoll.pyt   clear@  s
    	c         C   s"   x | D] } |  j  | ƒ q W|  S(   N(   RV   (   R   R<   R>   (    (    s   /usr/lib/python2.7/_abcoll.pyt   __ior__H  s    c         C   s&   x |  | D] } |  j  | ƒ q W|  S(   N(   RW   (   R   R<   R>   (    (    s   /usr/lib/python2.7/_abcoll.pyt   __iand__M  s    c         C   sx   | |  k r |  j  ƒ  n[ t | t ƒ s: |  j | ƒ } n  x7 | D]/ } | |  k rc |  j | ƒ qA |  j | ƒ qA W|  S(   N(   R\   R2   R   R=   RW   RV   (   R   R<   R>   (    (    s   /usr/lib/python2.7/_abcoll.pyt   __ixor__R  s    c         C   s;   | |  k r |  j  ƒ  n x | D] } |  j | ƒ q  W|  S(   N(   R\   RW   (   R   R<   R>   (    (    s   /usr/lib/python2.7/_abcoll.pyt   __isub___  s
    (   R$   R%   RQ   R   RV   RW   RY   R[   R\   R]   R^   R_   R`   (    (    (    s   /usr/lib/python2.7/_abcoll.pyR	     s   
		
				c           B   s€   e  Z d  Z e d „  ƒ Z d d „ Z d „  Z d „  Z d „  Z	 d „  Z
 d „  Z d „  Z d	 „  Z d Z d
 „  Z d „  Z RS(   sÇ   A Mapping is a generic container for associating key/value
    pairs.

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

    c         C   s
   t  ‚ d  S(   N(   RX   (   R   t   key(    (    s   /usr/lib/python2.7/_abcoll.pyt   __getitem__w  s    c         C   s%   y |  | SWn t  k
 r  | SXd S(   s<   D.get(k[,d]) -> D[k] if k in D, else d.  d defaults to None.N(   RX   (   R   Ra   t   default(    (    s   /usr/lib/python2.7/_abcoll.pyt   get{  s    c         C   s)   y |  | Wn t  k
 r  t SXt Sd  S(   N(   RX   R(   R   (   R   Ra   (    (    s   /usr/lib/python2.7/_abcoll.pyR.   ‚  s
    c         C   s
   t  |  ƒ S(   s.   D.iterkeys() -> an iterator over the keys of D(   RZ   (   R   (    (    s   /usr/lib/python2.7/_abcoll.pyt   iterkeysŠ  s    c         c   s   x |  D] } |  | Vq Wd S(   s2   D.itervalues() -> an iterator over the values of DN(    (   R   Ra   (    (    s   /usr/lib/python2.7/_abcoll.pyt
   itervaluesŽ  s    c         c   s$   x |  D] } | |  | f Vq Wd S(   s=   D.iteritems() -> an iterator over the (key, value) items of DN(    (   R   Ra   (    (    s   /usr/lib/python2.7/_abcoll.pyt	   iteritems“  s    c         C   s
   t  |  ƒ S(   s   D.keys() -> list of D's keys(   t   list(   R   (    (    s   /usr/lib/python2.7/_abcoll.pyt   keys˜  s    c         C   s!   g  |  D] } | |  | f ^ q S(   s8   D.items() -> list of D's (key, value) pairs, as 2-tuples(    (   R   Ra   (    (    s   /usr/lib/python2.7/_abcoll.pyt   itemsœ  s    c         C   s   g  |  D] } |  | ^ q S(   s    D.values() -> list of D's values(    (   R   Ra   (    (    s   /usr/lib/python2.7/_abcoll.pyt   values   s    c         C   s5   t  | t ƒ s t St |  j ƒ  ƒ t | j ƒ  ƒ k S(   N(   R2   R
   R!   t   dictRj   (   R   R4   (    (    s   /usr/lib/python2.7/_abcoll.pyR:   §  s    c         C   s   |  | k S(   N(    (   R   R4   (    (    s   /usr/lib/python2.7/_abcoll.pyR;   ¬  s    N(   R$   R%   RQ   R   Rb   R    Rd   R.   Re   Rf   Rg   Ri   Rj   Rk   R   R:   R;   (    (    (    s   /usr/lib/python2.7/_abcoll.pyR
   m  s   								c           B   s#   e  Z d  „  Z d „  Z d „  Z RS(   c         C   s   | |  _  d  S(   N(   t   _mapping(   R   t   mapping(    (    s   /usr/lib/python2.7/_abcoll.pyt   __init__±  s    c         C   s   t  |  j ƒ S(   N(   R3   Rm   (   R   (    (    s   /usr/lib/python2.7/_abcoll.pyR,   ´  s    c         C   s   d j  |  ƒ S(   Ns&   {0.__class__.__name__}({0._mapping!r})(   t   format(   R   (    (    s   /usr/lib/python2.7/_abcoll.pyt   __repr__·  s    (   R$   R%   Ro   R,   Rq   (    (    (    s   /usr/lib/python2.7/_abcoll.pyR   ¯  s   		c           B   s)   e  Z e d  „  ƒ Z d „  Z d „  Z RS(   c         C   s
   t  | ƒ S(   N(   t   set(   R   R<   (    (    s   /usr/lib/python2.7/_abcoll.pyR=   ½  s    c         C   s   | |  j  k S(   N(   Rm   (   R   Ra   (    (    s   /usr/lib/python2.7/_abcoll.pyR.   Á  s    c         c   s   x |  j  D] } | Vq
 Wd  S(   N(   Rm   (   R   Ra   (    (    s   /usr/lib/python2.7/_abcoll.pyR)   Ä  s    (   R$   R%   R'   R=   R.   R)   (    (    (    s   /usr/lib/python2.7/_abcoll.pyR   »  s   	c           B   s)   e  Z e d  „  ƒ Z d „  Z d „  Z RS(   c         C   s
   t  | ƒ S(   N(   Rr   (   R   R<   (    (    s   /usr/lib/python2.7/_abcoll.pyR=   Ì  s    c         C   s@   | \ } } y |  j  | } Wn t k
 r1 t SX| | k Sd  S(   N(   Rm   RX   R(   (   R   t   itemRa   R>   t   v(    (    s   /usr/lib/python2.7/_abcoll.pyR.   Ð  s    c         c   s*   x# |  j  D] } | |  j  | f Vq
 Wd  S(   N(   Rm   (   R   Ra   (    (    s   /usr/lib/python2.7/_abcoll.pyR)   Ù  s    (   R$   R%   R'   R=   R.   R)   (    (    (    s   /usr/lib/python2.7/_abcoll.pyR   Ê  s   		c           B   s   e  Z d  „  Z d „  Z RS(   c         C   s/   x( |  j  D] } | |  j  | k r
 t Sq
 Wt S(   N(   Rm   R   R(   (   R   R>   Ra   (    (    s   /usr/lib/python2.7/_abcoll.pyR.   á  s    c         c   s$   x |  j  D] } |  j  | Vq
 Wd  S(   N(   Rm   (   R   Ra   (    (    s   /usr/lib/python2.7/_abcoll.pyR)   ç  s    (   R$   R%   R.   R)   (    (    (    s   /usr/lib/python2.7/_abcoll.pyR   ß  s   	c           B   sh   e  Z d  Z e d „  ƒ Z e d „  ƒ Z e ƒ  Z e d „ Z d „  Z	 d „  Z
 d „  Z d d „ Z RS(	   sì   A MutableMapping is a generic container for associating
    key/value pairs.

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

    c         C   s
   t  ‚ d  S(   N(   RX   (   R   Ra   R>   (    (    s   /usr/lib/python2.7/_abcoll.pyt   __setitem__ø  s    c         C   s
   t  ‚ d  S(   N(   RX   (   R   Ra   (    (    s   /usr/lib/python2.7/_abcoll.pyt   __delitem__ü  s    c         C   sG   y |  | } Wn' t  k
 r7 | |  j k r3 ‚  n  | SX|  | =| Sd S(   s©   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(   RX   t   _MutableMapping__marker(   R   Ra   Rc   R>   (    (    s   /usr/lib/python2.7/_abcoll.pyR[     s    c         C   sK   y t  t |  ƒ ƒ } Wn t k
 r/ t ‚ n X|  | } |  | =| | f S(   sƒ   D.popitem() -> (k, v), remove and return some (key, value) pair
           as a 2-tuple; but raise KeyError if D is empty.
        (   R+   RZ   R*   RX   (   R   Ra   R>   (    (    s   /usr/lib/python2.7/_abcoll.pyt   popitem  s    

c         C   s3   y x t  r |  j ƒ  q WWn t k
 r. n Xd S(   s,   D.clear() -> None.  Remove all items from D.N(   R   Rx   RX   (   R   (    (    s   /usr/lib/python2.7/_abcoll.pyR\     s
    	c          O   s  |  s t  d ƒ ‚ n  |  d } |  d }  t |  ƒ d k rT t  d t |  ƒ ƒ ‚ n  |  rð |  d } t | t ƒ r• xw | D] } | | | | <qz Wqð t | d ƒ rÌ xF | j ƒ  D] } | | | | <q± Wqð x! | D] \ } } | | | <qÓ Wn  x$ | j ƒ  D] \ } } | | | <qý Wd S(   sK   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
        s@   descriptor 'update' of 'MutableMapping' object needs an argumenti    i   s+   update expected at most 1 arguments, got %dRi   N(   t	   TypeErrorR3   R2   R
   R   Ri   Rj   (   R/   R0   R   R4   Ra   R>   (    (    s   /usr/lib/python2.7/_abcoll.pyt   update$  s&    


c         C   s.   y |  | SWn t  k
 r) | |  | <n X| S(   s@   D.setdefault(k[,d]) -> D.get(k,d), also set D[k]=d if k not in D(   RX   (   R   Ra   Rc   (    (    s   /usr/lib/python2.7/_abcoll.pyt
   setdefault@  s
    N(   R$   R%   RQ   R   Ru   Rv   t   objectRw   R[   Rx   R\   Rz   R    R{   (    (    (    s   /usr/lib/python2.7/_abcoll.pyR   í  s   					c           B   sJ   e  Z d  Z e d „  ƒ Z d „  Z d „  Z d „  Z d „  Z d „  Z	 RS(   sŠ   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(   t
   IndexError(   R   t   index(    (    s   /usr/lib/python2.7/_abcoll.pyRb   U  s    c         c   sI   d } y* x# t  r. |  | } | V| d 7} q WWn t k
 rD d  SXd  S(   Ni    i   (   R   R}   (   R   t   iRt   (    (    s   /usr/lib/python2.7/_abcoll.pyR)   Y  s    	
c         C   s%   x |  D] } | | k r t  Sq Wt S(   N(   R   R(   (   R   R>   Rt   (    (    s   /usr/lib/python2.7/_abcoll.pyR.   c  s    c         c   s0   x) t  t t |  ƒ ƒ ƒ D] } |  | Vq Wd  S(   N(   t   reversedt   rangeR3   (   R   R   (    (    s   /usr/lib/python2.7/_abcoll.pyt   __reversed__i  s    c         C   s7   x* t  |  ƒ D] \ } } | | k r | Sq Wt ‚ d S(   s|   S.index(value) -> integer -- return first index of value.
           Raises ValueError if the value is not present.
        N(   t	   enumeratet
   ValueError(   R   R>   R   Rt   (    (    s   /usr/lib/python2.7/_abcoll.pyR~   m  s    c            s   t  ‡  f d †  |  Dƒ ƒ S(   sB   S.count(value) -> integer -- return number of occurrences of valuec         3   s!   |  ] } | ˆ  k r d  Vq d S(   i   N(    (   R   Rt   (   R>   (    s   /usr/lib/python2.7/_abcoll.pys	   <genexpr>x  s    (   t   sum(   R   R>   (    (   R>   s   /usr/lib/python2.7/_abcoll.pyt   countv  s    (
   R$   R%   RQ   R   Rb   R)   R.   R‚   R~   R†   (    (    (    s   /usr/lib/python2.7/_abcoll.pyR   N  s   	
				c           B   st   e  Z d  Z e d „  ƒ Z e d „  ƒ Z e d „  ƒ Z d „  Z d „  Z d „  Z	 d d „ Z
 d	 „  Z d
 „  Z RS(   s®   All the operations on a read-only sequence.

    Concrete subclasses must provide __new__ or __init__,
    __getitem__, __setitem__, __delitem__, __len__, and insert().

    c         C   s
   t  ‚ d  S(   N(   R}   (   R   R~   R>   (    (    s   /usr/lib/python2.7/_abcoll.pyRu   ‰  s    c         C   s
   t  ‚ d  S(   N(   R}   (   R   R~   (    (    s   /usr/lib/python2.7/_abcoll.pyRv     s    c         C   s
   t  ‚ d S(   s5   S.insert(index, object) -- insert object before indexN(   R}   (   R   R~   R>   (    (    s   /usr/lib/python2.7/_abcoll.pyt   insert‘  s    c         C   s   |  j  t |  ƒ | ƒ d S(   s<   S.append(object) -- append object to the end of the sequenceN(   R‡   R3   (   R   R>   (    (    s   /usr/lib/python2.7/_abcoll.pyt   append–  s    c         C   sX   t  |  ƒ } xE t | d ƒ D]3 } |  | | d |  | |  | <|  | | d <q Wd S(   s!   S.reverse() -- reverse *IN PLACE*i   i   N(   R3   R   (   R   RM   R   (    (    s   /usr/lib/python2.7/_abcoll.pyt   reverseš  s    c         C   s"   x | D] } |  j  | ƒ q Wd S(   sM   S.extend(iterable) -- extend sequence by appending elements from the iterableN(   Rˆ   (   R   Rk   Rt   (    (    s   /usr/lib/python2.7/_abcoll.pyt   extend   s    iÿÿÿÿc         C   s   |  | } |  | =| S(   s™   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~   Rt   (    (    s   /usr/lib/python2.7/_abcoll.pyR[   ¥  s    
c         C   s   |  |  j  | ƒ =d S(   sv   S.remove(value) -- remove first occurrence of value.
           Raise ValueError if the value is not present.
        N(   R~   (   R   R>   (    (    s   /usr/lib/python2.7/_abcoll.pyRY   ­  s    c         C   s   |  j  | ƒ |  S(   N(   RŠ   (   R   Rk   (    (    s   /usr/lib/python2.7/_abcoll.pyt   __iadd__³  s    (   R$   R%   RQ   R   Ru   Rv   R‡   Rˆ   R‰   RŠ   R[   RY   R‹   (    (    (    s   /usr/lib/python2.7/_abcoll.pyR   €  s   				(    (    (    (    (    (%   RQ   t   abcR    R   RH   t   __all__R   R   R   t   registert   strR   R   R   R   R   t	   frozensetR	   Rr   R
   R   R   t   typet   viewkeysR   t	   viewitemsR   t
   viewvaluesR   Rl   R   t   tuplet
   basestringt   buffert   xrangeR   Rh   (    (    (    s   /usr/lib/python2.7/_abcoll.pyt   <module>	   sJ   			ŒMB[,7