ÿØÿàJFIFÿþ ÿÛC       ÿÛC ÿÀÿÄÿÄ"#QrÿÄÿÄ&1!A"2qQaáÿÚ ?Øy,æ/3JæÝ¹È߲؋5êXw²±ÉyˆR”¾I0ó2—PI¾IÌÚiMö¯–þrìN&"KgX:Šíµ•nTJnLK„…@!‰-ý ùúmë;ºgµŒ&ó±hw’¯Õ@”Ü— 9ñ-ë.²1<yà‚¹ïQÐU„ہ?.’¦èûbß±©Ö«Âw*VŒ) `$‰bØÔŸ’ëXÖ-ËTÜíGÚ3ð«g Ÿ§¯—Jx„–’U/ÂÅv_s(Hÿ@TñJÑãõçn­‚!ÈgfbÓc­:él[ðQe 9ÀPLbÃãCµm[5¿ç'ªjglå‡Ûí_§Úõl-;"PkÞÞÁQâ¼_Ñ^¢SŸx?"¸¦ùY騐ÒOÈ q’`~~ÚtËU¹CڒêV  I1Áß_ÿÙ 4]c@@s dZddlmZddlZddlmZddlmZddlmZdd lm Z e j e Z d Z d efd YZd efdYZdefdYZdZdZde jeefdYZdefdYZdefdYZdS(sBase implementation classes. The public-facing ``Events`` serves as the base class for an event interface; its public attributes represent different kinds of events. These attributes are mirrored onto a ``_Dispatch`` class, which serves as a container for collections of listener functions. These collections are represented both at the class level of a particular ``_Dispatch`` class as well as within instances of ``_Dispatch``. i(tabsolute_importNi(t_ClsLevelDispatch(t_EmptyListener(t_JoinedListeneri(tutilcC@s|jd o|dkS(Nt_tdispatch(t startswith(tname((sH/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/event/base.pyt_is_event_namest_UnpickleDispatchcB@seZdZdZRS(sSerializable callable that re-generates an instance of :class:`_Dispatch` given a particular :class:`.Events` subclass. cC@sJxC|jD],}d|jkr |jdjj|Sq WtddS(NRs*No class with a 'dispatch' member present.(t__mro__t__dict__Rt _for_classtAttributeError(tselft _instance_clstcls((sH/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/event/base.pyt__call__)s  (t__name__t __module__t__doc__R(((sH/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/event/base.pyR #st _DispatchcB@seZdZdZejZddZdZ e dZ e dZ d Z d Zd Zd Zed ZdZRS(s;Mirror the event listening definitions of an Events class with listener collections. Classes which define a "dispatch" member will return a non-instantiated :class:`._Dispatch` subclass when the member is accessed at the class level. When the "dispatch" member is accessed at the instance level of its owner, an instance of the :class:`._Dispatch` class is returned. A :class:`._Dispatch` class is generated for each :class:`.Events` class defined, by the :func:`._create_dispatcher_class` function. The original :class:`.Events` classes remain untouched. This decouples the construction of :class:`.Events` subclasses from the implementation used by the event internals, and allows inspecting tools like Sphinx to work in an unsurprising way against the public API. t_parentRR t_empty_listenersc@sw||_|_rjy|j|_Wqstk rffd|jD|_|jXs (RRt_empty_listener_regRtKeyErrort_event_descriptors(RtparentR((RsH/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/event/base.pyt__init__Ms    "cC@sLy|j|}Wntk r0t|nXt||j||SdS(N(RRRtsetattrR(RRR((sH/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/event/base.pyt __getattr__^s  cc@s&x|jD]}t||Vq WdS(N(t _event_namestgetattr(Rtk((sH/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/event/base.pyRiscC@s |jjS(N(t_eventst_listen(R((sH/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/event/base.pyR'pscC@s|j||S(N(t __class__(RR((sH/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/event/base.pyR tscC@s|j}|j|S(N(R(R (RtinstanceR((sH/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/event/base.pyt _for_instancews cC@sZd|jjkrJtd|jjtfi|jd6}||j_n|j||S(sCreate a 'join' of this :class:`._Dispatch` and another. This new dispatcher will dispatch events to both :class:`._Dispatch` objects. t_joined_dispatch_clssJoined%st __slots__(R(R ttypeRt_JoinedDispatcherR#R+(RtotherR((sH/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/event/base.pyt_join{s cC@st|jffS(N(R R(R((sH/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/event/base.pyt __reduce__scC@sUxN|jD]C}t|tr%q nt||jj|j|d|q WdS(sMPopulate from the listeners in another :class:`_Dispatch` object.tonly_propagateN(Rt isinstanceRR$Rt for_modifyt_update(RR/R2R((sH/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/event/base.pyR5s cC@s+x$|jD]}|j|jq WdS(N(RR4tclear(RR((sH/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/event/base.pyt_clears(RRR RN(RRRR,tweakreftWeakKeyDictionaryRtNoneR R"tpropertyRR'R R*R0R1tTrueR5R7(((sH/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/event/base.pyR3s        t _EventMetacB@seZdZdZRS(sKIntercept new Event subclasses and create associated _Dispatch classes.cC@s)t||||tj||||S(N(t_create_dispatcher_classR-R (Rt classnametbasestdict_((sH/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/event/base.pyR s(RRRR (((sH/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/event/base.pyR=sc C@sct|dr|jj}nt}g|D]}t|r+|^q+}td||fi|d6}||_|j||}x?|jD]4}t||t |||t |j |qWxo|j D]d} t | tr| tk rx@| jjjD],} t|| j| |jj | jqWqqWt|ddr_t||j_ndS(sRCreate a :class:`._Dispatch` class corresponding to an :class:`.Events` class.Rs %sDispatchR,t_dispatch_targetN(thasattrRR(RR R-R#t _set_dispatchR!Rt _registrarstappendt __bases__t issubclassR&RRR$R:t dispatcherRB( RR?R@RAt dispatch_baseR%t event_namest dispatch_clst dispatch_insttsuper_R((sH/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/event/base.pyR>s$% cC@s@x9|jjD]+}t|j|t|s t|=q q WdS(N(RR#REtremove(RR%((sH/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/event/base.pyt_remove_dispatchers tEventscB@sbeZdZedZedZeeeedZedZ edZ RS(s>Define event listening functions for a particular target type.cC@s|d|_||_|jS(N(R:RR&(RRL((sH/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/event/base.pyRDs c@s}fd}fd}tdry||jjsr|t|jjsr|try||jjrySndS(Nc@stfd|DS(Nc3@s!|]}tj|VqdS(N(R3R(Rtt(ttarget(sH/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/event/base.pys s(tall(ttypes(RS(sH/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/event/base.pyt dispatch_issc@stjj|S(N(R3RR(RR(RS(sH/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/event/base.pytdispatch_parent_issR(RCRR(R-R.(RRSRVRW((RSsH/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/event/base.pyt _accept_withs cC@s |jd|d|d|dS(Nt propagatetinserttnamed(t base_listen(Rt event_keyRYRZR[((sH/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/event/base.pyR'scC@s|jdS(N(RO(RR]((sH/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/event/base.pyt_removescC@s|jjdS(N(RR7(R((sH/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/event/base.pyR7s( RRRt staticmethodRDt classmethodRXtFalseR'R^R7(((sH/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/event/base.pyRQs R.cB@sDeZdZdZdZdZedZedZRS( s5Represent a connection between two _Dispatch objects.tlocalRRcC@s%||_||_|jj|_dS(N(RbRR(RRbR((sH/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/event/base.pyR s  cC@sAt|j|}t|j|j|}t||j||S(N(R$RbRRRR!(RRRtjl((sH/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/event/base.pyR" scC@s |jjS(N(RR'(R((sH/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/event/base.pyR'scC@s |jjS(N(RR&(R((sH/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/event/base.pyR&s(RbRR( RRRR,R R"R;R'R&(((sH/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/event/base.pyR.s   RIcB@s eZdZdZdZRS(sDescriptor used by target classes to deliver the _Dispatch class at the class level and produce new _Dispatch instances for target instances. cC@s|j|_||_dS(N(Rtevents(RRd((sH/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/event/base.pyR #s cC@s4|dkr|jS|jj||jd<}|S(NR(R:RR*R (RtobjRtdisp((sH/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/event/base.pyt__get__'s (RRRR Rg(((sH/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/event/base.pyRIs (Rt __future__RR8tattrRRRtRt defaultdicttlistRER tobjectR RR-R=R>RPtwith_metaclassRQR.RI(((sH/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/event/base.pyts   k " "0