OwlCyberSecurity - MANAGER
Edit File: _funcs.pyc
� Q��ac @` s� d d l m Z m Z m Z d d l Z d d l m Z d d l m Z m Z m Z d d l m Z e d e e d d � Z d � Z e d e e d � Z d � Z d � Z d � Z d d d d � Z d S( i ( t absolute_importt divisiont print_functionNi ( t iteritems( t NOTHINGt _obj_setattrt fields( t AttrsAttributeNotFoundErrorc ` s� t | j � } | � } x�| D]�} t | | j � } � d k rY � | | � rY q n � d k rz � | | | � } n | t k r�t | j � r� t | d t d � d | d � d � �| | j <q�t | t t t t f � rL� t k r� | j n t } | g | D]0 } t | d t d � d | d � d � �^ q � | | j <q�t | t � r�| � � � � � � f d � t | � D� � | | j <q�| | | j <q | | | j <q W| S( sf Return the ``attrs`` attribute values of *inst* as a dict. Optionally recurse into other ``attrs``-decorated classes. :param inst: Instance of an ``attrs``-decorated class. :param bool recurse: Recurse into classes that are also ``attrs``-decorated. :param callable filter: A callable whose return code determines whether an attribute or element is included (``True``) or dropped (``False``). Is called with the `attrs.Attribute` as the first argument and the value as the second argument. :param callable dict_factory: A callable to produce dictionaries from. For example, to produce ordered dictionaries instead of normal Python dictionaries, pass in ``collections.OrderedDict``. :param bool retain_collection_types: Do not convert to ``list`` when encountering an attribute whose type is ``tuple`` or ``set``. Only meaningful if ``recurse`` is ``True``. :param Optional[callable] value_serializer: A hook that is called for every attribute or dict key/value. It receives the current instance, field and value and must return the (updated) value. The hook is run *after* the optional *filter* has been applied. :rtype: return type of *dict_factory* :raise attr.exceptions.NotAnAttrsClassError: If *cls* is not an ``attrs`` class. .. versionadded:: 16.0.0 *dict_factory* .. versionadded:: 16.1.0 *retain_collection_types* .. versionadded:: 20.3.0 *value_serializer* .. versionadded:: 21.3.0 If a dict has a collection for a key, it is serialized as a tuple. t recurset filtert dict_factoryt retain_collection_typest value_serializert is_keyc 3` si | ]_ \ } } t | d t d � d � d � d � �t | d t d � d � d � d � �f Vq d S( R R R R R N( t _asdict_anythingt Truet False( t .0t kkt vv( t dfR R R ( sN /opt/cpanel-ccs/.develop/virtualenv/lib/python2.7/site-packages/attr/_funcs.pys <genexpr>\ s N( R t __class__t getattrt namet NoneR t hast asdictt isinstancet tuplet listt sett frozensetR R t dictR ( t instR R R R R t attrst rvt at vt cft i( ( R R R R sN /opt/cpanel-ccs/.develop/virtualenv/lib/python2.7/site-packages/attr/_funcs.pyR s<