ÿØÿà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@sdZddlZddlmZddlmZddlmZddlmZddlmZdd lmZdd l m Z dd l m Z d Z ejd ZdejfdYZdefdYZdefdYZdefdYZde efdYZdefdYZdefdYZdefdYZejdZdefd YZd!efd"YZdS(#sContain the ``AssociationProxy`` class. The ``AssociationProxy`` is a Python property object which provides transparent proxied access to the endpoint of an association object. See the example ``examples/association/proxied_association.py``. iNi(texc(tinspect(torm(tutil(t collections(t interfaces(tor_(tColumnOperatorscKst|||S(sReturn a Python property implementing a view of a target attribute which references an attribute on members of the target. The returned value is an instance of :class:`.AssociationProxy`. Implements a Python property representing a relationship as a collection of simpler values, or a scalar value. The proxied property will mimic the collection type of the target (list, dict or set), or, in the case of a one to one relationship, a simple scalar value. :param target_collection: Name of the attribute we'll proxy to. This attribute is typically mapped by :func:`~sqlalchemy.orm.relationship` to link to a target collection, but can also be a many-to-one or non-scalar relationship. :param attr: Attribute on the associated instance or instances we'll proxy for. For example, given a target collection of [obj1, obj2], a list created by this proxy property would look like [getattr(obj1, *attr*), getattr(obj2, *attr*)] If the relationship is one-to-one or otherwise uselist=False, then simply: getattr(obj, *attr*) :param creator: optional. When new items are added to this proxied collection, new instances of the class collected by the target collection will be created. For list and set collections, the target class constructor will be called with the 'value' for the new instance. For dict types, two arguments are passed: key and value. If you want to construct instances differently, supply a *creator* function that takes arguments as above and returns instances. For scalar relationships, creator() will be called if the target is None. If the target is present, set operations are proxied to setattr() on the associated object. If you have an associated object with multiple attributes, you may set up multiple association proxies mapping to different attributes. See the unit tests for examples, and for examples of how creator() functions can be used to construct the scalar relationship on-demand in this situation. :param \*\*kw: Passes along any other keyword arguments to :class:`.AssociationProxy`. (tAssociationProxy(ttarget_collectiontattrtkw((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pytassociation_proxys4tASSOCIATION_PROXYRcBseZdZeZeZd d d d d edZ dZ dZ dZ d dZ dZdZdZd ZRS( sDA descriptor that presents a read/write view of an object attribute.c Csz||_||_||_||_||_||_||_dt|j|t |f|_ |rv||_ ndS(s Construct a new :class:`.AssociationProxy`. The :func:`.association_proxy` function is provided as the usual entrypoint here, though :class:`.AssociationProxy` can be instantiated and/or subclassed directly. :param target_collection: Name of the collection we'll proxy to, usually created with :func:`.relationship`. :param attr: Attribute on the collected instances we'll proxy for. For example, given a target collection of [obj1, obj2], a list created by this proxy property would look like [getattr(obj1, attr), getattr(obj2, attr)] :param creator: Optional. When new items are added to this proxied collection, new instances of the class collected by the target collection will be created. For list and set collections, the target class constructor will be called with the 'value' for the new instance. For dict types, two arguments are passed: key and value. If you want to construct instances differently, supply a 'creator' function that takes arguments as above and returns instances. :param cascade_scalar_deletes: when True, indicates that setting the proxied value to ``None``, or deleting it via ``del``, should also remove the source object. Only applies to scalar attributes. Normally, removing the proxied target will not remove the proxy source, as this object may have other state that is still to be kept. .. versionadded:: 1.3 .. seealso:: :ref:`cascade_scalar_deletes` - complete usage example :param getset_factory: Optional. Proxied attribute access is automatically handled by routines that get and set values based on the `attr` argument for this proxy. If you would like to customize this behavior, you may supply a `getset_factory` callable that produces a tuple of `getter` and `setter` functions. The factory is called with two arguments, the abstract type of the underlying collection and this proxy instance. :param proxy_factory: Optional. The type of collection to emulate is determined by sniffing the target collection. If your collection type can't be determined by duck typing or you'd like to use a different collection implementation, you may supply a factory function to produce those collections. Only applicable to non-scalar relationships. :param proxy_bulk_set: Optional, use with proxy_factory. See the _set() method for details. :param info: optional, will be assigned to :attr:`.AssociationProxy.info` if present. .. versionadded:: 1.0.9 s _%s_%s_%sN( R t value_attrtcreatortgetset_factoryt proxy_factorytproxy_bulk_settcascade_scalar_deletesttypet__name__tidtkeytinfo( tselfR R RRRRRR((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyt__init__csI        cCs9|dkr|S|j||}|r5|j|S|S(N(tNonet _as_instancetget(Rtobjtclass_tinst((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyt__get__s   cCs(t|}|j||j||S(N(RRtset(RRtvaluesR((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyt__set__s cCs%t|}|j||j|S(N(RRtdelete(RRR((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyt __delete__s cCs|j||S(sReturn the internal state local to a specific mapped class. E.g., given a class ``User``:: class User(Base): # ... keywords = association_proxy('kws', 'keyword') If we access this :class:`.AssociationProxy` from :attr:`.Mapper.all_orm_descriptors`, and we want to view the target class for this proxy as mapped by ``User``:: inspect(User).all_orm_descriptors["keywords"].for_class(User).target_class This returns an instance of :class:`.AssociationProxyInstance` that is specific to the ``User`` class. The :class:`.AssociationProxy` object remains agnostic of its parent class. :param class\_: the class that we are returning state for. :param obj: optional, an instance of the class that is required if the attribute refers to a polymorphic target, e.g. where we have to look at the type of the actual destination object to get the complete path. .. versionadded:: 1.3 - :class:`.AssociationProxy` no longer stores any state specific to a particular parent class; the state is now stored in per-class :class:`.AssociationProxyInstance` objects. (R(RRR((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyt for_classs!cCsy|j|jd}Wnatk r{|j|}|dk rrtj|||}t||jd|q|d}nX|dk r|j r|j |S|SdS(Nt_inst( t__dict__RtKeyErrort _calc_ownerRtAssociationProxyInstancet for_proxytsetattrt _is_canonicalt_non_canonical_get_for_object(RRRR towner((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyRs    cCs9yt|}Wntjk r'dSX|jjjSdS(N(RRtNoInspectionAvailableRtmappert class_managerR(Rt target_clstinsp((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyR+s cs^|jtjfd}|tkrEfd}nfd}||fS(Ncs|dk r|SdS(N(R(ttarget(t_getter(sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pytgetterscst||dS(N(R.(totktv(R (sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pytsetter scst||dS(N(R.(R:R<(R (sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyR=%s(Rtoperatort attrgettertdict(Rtcollection_classR9R=((R8R sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyt_default_getsets  cCsd|j|jfS(NsAssociationProxy(%r, %r)(R R(R((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyt__repr__*sN(Rt __module__t__doc__tTruet is_attributeR textension_typeRtFalseRR!R$R&R'RR+RBRC(((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyR]s" P   #   R,cBsXeZdZdZdZedZedZdZ e dZ edZ e jdZe dZe d Ze d Ze jd Ze jd Ze d ZdZdZe dZdZdZdZdZdZdZddZddZ ddZ!dZ"RS(sA per-class object that serves class- and object-specific results. This is used by :class:`.AssociationProxy` when it is invoked in terms of a specific class or instance of a class, i.e. when it is used as a regular Python descriptor. When referring to the :class:`.AssociationProxy` as a normal Python descriptor, the :class:`.AssociationProxyInstance` is the object that actually serves the information. Under normal circumstances, its presence is transparent:: >>> User.keywords.scalar False In the special case that the :class:`.AssociationProxy` object is being accessed directly, in order to get an explicit handle to the :class:`.AssociationProxyInstance`, use the :meth:`.AssociationProxy.for_class` method:: proxy_state = inspect(User).all_orm_descriptors["keywords"].for_class(User) # view if proxy object is scalar or not >>> proxy_state.scalar False .. versionadded:: 1.3 cCsI||_|j|_||_|j|_d|_||_||_dS(N(tparentRt owning_classR RRAt target_classR(RRJRKRLR((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyROs      c Cs|j}|j}tj|j|}t|tjsKtdn|jj }y|j ||}Wn!t k rt ||||SX|j |||||SdS(NsEassociation proxy to a non-relationship intermediary is not supported(R RRt class_mappert get_propertyt isinstancetRelationshipPropertytNotImplementedErrorR3Rt_cls_unwrap_target_assoc_proxytAttributeErrort!AmbiguousAssociationProxyInstancet_construct_for_assoc( tclsRJRKtparent_instanceR RtpropRLt target_assoc((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyR-as     cCs|dk rt||||St||}t|dsPt||||S|j}|rrt||||St||||SdS(Nt_is_internal_proxy(RtObjectAssociationProxyInstancetgetattrthasattrRTt_impl_uses_objectstColumnAssociationProxyInstance(RVRYRJRKRLRR t is_object((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyRUs  cCstj|jj|jS(N(RRMRKRNR (R((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyt _get_propertyscCs |jjS(N(Rat comparator(R((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyt _comparatorscCs,t||}t|ttfr(|SdS(N(R\RORR,R(RVRLRR ((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyRRscCs|j|j|jS(N(RRRLR(R((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyt_unwrap_target_assoc_proxyscCst|j|jS(sThe 'remote' class attribute referenced by this :class:`.AssociationProxyInstance`. .. seealso:: :attr:`.AssociationProxyInstance.attr` :attr:`.AssociationProxyInstance.local_attr` (R\RLR(R((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyt remote_attrs cCst|j|jS(sThe 'local' class attribute referenced by this :class:`.AssociationProxyInstance`. .. seealso:: :attr:`.AssociationProxyInstance.attr` :attr:`.AssociationProxyInstance.remote_attr` (R\RKR (R((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyt local_attrs cCs|j|jfS(szReturn a tuple of ``(local_attr, remote_attr)``. This attribute is convenient when specifying a join using :meth:`.Query.join` across two relationships:: sess.query(Parent).join(*Parent.proxied.attr) .. seealso:: :attr:`.AssociationProxyInstance.local_attr` :attr:`.AssociationProxyInstance.remote_attr` (RfRe(R((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyR scCs'|jj }|r#|jn|S(ssReturn ``True`` if this :class:`.AssociationProxyInstance` proxies a scalar relationship on the local side.(Ratuselistt_initialize_scalar_accessors(Rtscalar((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyRis cCs|jjj|jj S(N(RaR3RNRRg(R((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyt_value_is_scalarscCs tdS(N(RQ(R((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyt_target_is_objectscCsY|jjr*|jjd|\}}n|jjd\}}|||_|_dS(N(RJRRRBt _scalar_gett _scalar_set(RRtset_((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyRhs cs^|jtjfd}|tkrEfd}nfd}||fS(Ncs|dk r|SdS(N(R(R7(R8(sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyR9scst||S(N(R.(R:R;R<(R (sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyR=scst||S(N(R.(R:R<(R (sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyR=s(RR>R?R@(RRAR9R=((R8R sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyRBs  cCs |jjS(N(RJR(R((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyR scCs|dkr|S|jr8t||j}|j|Syt||j\}}}Wntk rjn>Xt||krt||kr|jdk st |S|j t ||j\|_}t ||jt|t||f|SdS(N( RRiR\R RlRRSRRAtAssertionErrort_newt_lazy_collectionR.(RRR7t creator_idtself_idtproxy((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyRs     $(cCs|jr|jjr!|jjn|j}t||j}|dkrt|dkrXdSt||j||q|j|||dkr|jj rt||jdqnC|j |}|j dk st ||k r|j ||ndS(N(RiRJRRLR\R RR.RmRRRARot _bulk_replace(RRR#RR7Rt((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyR")s     cCss|jdkr"|j|dn|jr_t||j}|dk r_t||jq_nt||jdS(N(RKRR+RiR\R tdelattrR(RRR7((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyR%?s  cCsA|jjr|jjn|j}tj|}|jjra||jj|||j|fS|jjr|jj||\}}n|jj|\}}|t kr|t |||||fS|t kr|t |||||fS|t kr|t|||||fStjd|jj|jfdS(Nscould not guess which interface to use for collection_class "%s" backing "%s"; specify a proxy_factory and proxy_bulk_set manually(RJRRLRtduck_type_collectionRRRRBtlistt_AssociationListR@t_AssociationDictR"t_AssociationSetRt ArgumentErrorRARR (Rtlazy_collectionRRAR9R=((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyRpIs0!      cCs|jjr"|jj||nl|jtkrA|j|nM|jtkr`|j|n.|jtkr|j|ntj ddS(NsEno proxy_bulk_set supplied for custom collection_class implementation( RJRRARxtextendR@tupdateR"RR|(RRtR#((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyt_setys cCs|jjr|jjp|j}|jjrN|jj|j|\}}n|jj|j\}}||_||_||_dS(N(RJRRLRRARBR9R=(RRtRR9R=((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyt_inflates!    cKs|jdd}|j}|dk rL|jd||}|jj|S|jrt|j|j}|j||}nB|rt j dn$|r|dk rt j dn|}|jj|S(Ntis_hast criterionsJCan't apply keyword arguments to column-targeted association proxy; use ==sINon-empty has() not allowed for column-targeted association proxy; use ==( tpopRRdt_criterion_existsRcRkR\RLRRR|(RRtkwargsRRYtinnerRXt value_expr((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyRs"       cKsV|jdkr=|jr=|j s+|jr=tjdn|jd|dt|S(s!Produce a proxied 'any' expression using EXISTS. This expression will be a composed product using the :meth:`.RelationshipProperty.Comparator.any` and/or :meth:`.RelationshipProperty.Comparator.has` operators of the underlying proxied attributes. s9'any()' not implemented for scalar attributes. Use has().RRN( RdRRiRkRjRtInvalidRequestErrorRRI(RRR((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pytanys    cKsW|jdkr>|j s,|jr>|j r>tjdn|jd|dt|S(s!Produce a proxied 'has' expression using EXISTS. This expression will be a composed product using the :meth:`.RelationshipProperty.Comparator.any` and/or :meth:`.RelationshipProperty.Comparator.has` operators of the underlying proxied attributes. s4'has()' not implemented for collections. Use any().RRN( RdRRiRkRjRRRRF(RRR((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pythass    cCsd|jj|jfS(Ns%s(%r)(t __class__RRJ(R((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyRCsN(#RRDRERRRLt classmethodR-RURatpropertyRcRRRtmemoized_propertyRdReRfR RiRjRkRhRBRRR"R%RpRRRRRRC(((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyR,1s8         0     RTcBsteZdZeZdZdZdZdZd dZ d dZ e j dZdZd ZRS( scan :class:`.AssociationProxyInstance` where we cannot determine the type of target object. cCs/td|jj|j|j|jfdS(NsAssociation proxy %s.%s refers to an attribute '%s' that is not directly mapped on class %s; therefore this operation cannot proceed since we don't know what type of object is referred towards(RSRKRR RRL(R((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyt _ambiguouss  cCs*|dkr|Stt|j|SdS(N(RtsuperRTR(RR((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyRs cCs|jdS(N(R(RR((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyt__eq__scCs|jdS(N(R(RR((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyt__ne__scKs|jdS(N(R(RRR((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyRscKs|jdS(N(R(RRR((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyRscCsiS(N((R((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyt _lookup_cachescCs|dk rt||j}|dk ryt|}Wntjk rPqX|j}|j}||jkr|j ||ny|j|SWqt k rqXqn|S(N( RR\R RRR2R3RRt_populate_cacheR*(RRWt actual_objR6R3tinstance_class((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyR0s       cCstj|jj|j}|j|jr|}y|j||j}Wnt k rbqX|j ||j |j||j|j |teqRRRc(Rtothertexpr((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyRs  cOs|j|jj|||S(N(RReR(RtopRR((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyRs( RRDRERIRkRFR/RR(((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyR_xs  RqcBs,eZdZdZdZdZRS(cCs||_||_dS(N(RJR7(RRR7((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyRs cCst|j|jS(N(R\RJR7(R((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyt__call__scCsi|jd6|jd6S(NRR7(RJR7(R((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyt __getstate__scCs|d|_|d|_dS(NRR7(RJR7(Rtstate((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyt __setstate__s (RRDRRRR(((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyRqs   t_AssociationCollectioncBsSeZdZedZdZdZeZdZdZ dZ RS(cCs1||_||_||_||_||_dS(sConstructs an _AssociationCollection. This will always be a subclass of either _AssociationList, _AssociationSet, or _AssociationDict. lazy_collection A callable returning a list-based collection of entities (usually an object attribute managed by a SQLAlchemy relationship()) creator A function that creates new target entities. Given one parameter: value. This assertion is assumed:: obj = creator(somevalue) assert getter(obj) == somevalue getter A function. Given an associated object, return the 'value'. setter A function. Given an associated object and a value, store that value on the object. N(R}RR9R=RJ(RR}RR9R=RJ((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyRs     cCs |jS(N(R}(R((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyttcCs t|jS(N(tlentcol(R((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyt__len__scCs t|jS(N(tboolR(R((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyt__bool__scCsi|jd6|jd6S(NRJR}(RJR}(R((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyRscCs.|d|_|d|_|jj|dS(NRJR}(RJR}R(RR((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyRs  cCs|j|j||dS(N(tclearR(Rt assoc_proxyR#((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyRus ( RRDRRRRRt __nonzero__RRRu(((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyRs     RycBseZdZdZdZdZdZdZdZdZ dZ d Z d Z d Z d Zd ZdZdZddZdZdZdZdZdZdZdZdZdZdZdZdZdZdZ e Z!d Z"d!Z#d"Z$d#Z%d$Z&d%Z'xre(e)j*D][\Z+Z,e-j.e,roe,je+kroe,j roe/e(e+roe0e(e+je,_qoqoW[+[,RS(&s(Generic, converting, list-to-list proxy.cCs |j|S(N(R(Rtvalue((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyt_createscCs |j|S(N(R9(Rtobject_((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyt_getscCs|j||S(N(R=(RRR((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyRscCsNt|ts#|j|j|Sg|j|D]}|j|^q1SdS(N(ROtsliceRR(Rtindextmember((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyt __getitem__sc Cst|ts)|j|j||nW|jdkrGt|}n.|jdkrlt||j}n |j}|jpd}|jpd}t t |jpd||}|dkr x|D] }||=qW|}x|D] }|j |||d7}qWntt|t|krIt dt|t|fnx4t ||D]#\}}|j|j||qYWdS(NiisBattempt to assign sequence of size %s to extended slice of size %s(RORRRtstopRRtsteptstartRxtrangetinsertt ValueErrortzip( RRRRRRtrngtititem((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyt __setitem__s. !    cCs|j|=dS(N(R(RR((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyt __delitem__ scCs1x*|jD]}|j||kr tSq WtS(N(RRRFRI(RRR((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyt __contains__ scCs*g|j||!D]}|j|^qS(N(RR(RRtendR((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyt __getslice__scCs6g|D]}|j|^q}||j||+dS(N(RR(RRRR#R<tmembers((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyt __setslice__s"cCs|j||5dS(N(R(RRR((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyt __delslice__sccs&x|jD]}|j|Vq WdS(sIterate over proxied values. For the actual domain objects, iterate over .col instead or just use the underlying collection directly from its property on the parent. N(RR(RR((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyt__iter__scCs)|j}|j|}|j|dS(N(RRtappend(RRRR((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyR)s cs8tgtjfdt|D] }d^q%S(Ncs |kS(N((R<(R(sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyR3Ri(tsumRtitertools_filtertiter(RRt_((RsR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pytcount.scCs"x|D]}|j|qWdS(N(R(RR#R<((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyR~8s cCs |j|g|j||+dS(N(RR(RRR((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyR<sicCs|j|jj|S(N(R9RR(RR((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyR?scCsGx4t|D]&\}}||kr |j|=dSq WtddS(Nsvalue not in list(t enumerateRR(RRRtval((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pytremoveBs   cCs tdS(s#Not supported, use reversed(mylist)N(RQ(R((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pytreverseIscCs tdS(s!Not supported, use sorted(mylist)N(RQ(R((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pytsortNscCs|jdt|j5dS(Ni(RR(R((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyRSscCst||kS(N(Rx(RR((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyRVscCst||kS(N(Rx(RR((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyRYscCst||kS(N(Rx(RR((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyt__lt__\scCst||kS(N(Rx(RR((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyt__le___scCst||kS(N(Rx(RR((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyt__gt__bscCst||kS(N(Rx(RR((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyt__ge__escCstjt||S(N(RtcmpRx(RR((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyt__cmp__hscCs3yt|}Wntk r$tSXt||S(N(Rxt TypeErrortNotImplemented(RtiterableR((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyt__add__ks  cCs3yt|}Wntk r$tSX|t|S(N(RxRR(RRR((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyt__radd__rs  cCs!t|tstSt||S(N(ROtintRRx(Rtn((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyt__mul__yscCs|j||S(N(R~(RR((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyt__iadd__s cCsZt|tstS|dkr,|jn*|dkrV|jt||dn|S(Nii(RORRRR~Rx(RR((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyt__imul__s   cGst|j||S(N(RxR(RRtargs((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyRscCs t|S(N(Rx(R((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pytcopyscCstt|S(N(treprRx(R((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyRCscCstdt|jdS(Ns%s objects are unhashable(RRR(R((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyt__hash__s(1RRDRERRRRRRRRRRRRRR~RRRRRRRRRRRRRRRRt__rmul__RRRRRCRRxtlocalstitemst func_nametfuncRtcallableR]R\(((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyRysZ                                 " t _NotProvidedRzcBseZdZdZdZdZdZdZdZdZ dZ d Z d Z d Z d Zd ZdZdZdZdZdZd#dZd#dZdZejrdZdZdZdZdZndZdZe dZ!dZ"dZ#d Z$d!Z%d"Z&xre'e(jD][\Z)Z*ej+e*rie*je)krie*j rie,e-e)rie.e-e)je*_qiqiW[)[*RS($s(Generic, converting, dict-to-dict proxy.cCs|j||S(N(R(RRR((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyRscCs |j|S(N(R9(RR((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyRscCs|j|||S(N(R=(RRRR((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyRscCs|j|j|S(N(RR(RR((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyRscCsI||jkr,|j|j|||n|j|||j|s(R(R((RsR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyt iteritemsscsfdjDS(Nc3s%|]}jj|VqdS(N(RR(RR(R(sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pys s(R(R((RsR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyt itervaluesscCs |jjS(N(Rtiterkeys(R((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyRscCs)g|jjD]}|j|^qS(N(RR#R(RR((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyR#scCs-g|D]"}||j|j|f^qS(N(RR(RR;((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyRscsfdjDS(Nc3s+|]!}|jj|fVqdS(N(RR(RR(R(sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pys s(R(R((RsR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyR scsfdjDS(Nc3s%|]}jj|VqdS(N(RR(RR(R(sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pys s(R(R((RsR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyR#scCsC|tkr!|jj|}n|jj||}|j|S(N(RRRR(RRRR((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyRs cCs*|jj}|d|j|dfS(Nii(RtpopitemR(RR((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyRsc Ost|dkr+tdt|nt|dkr|d}t|drxxd|D]}||||\}}||kr|||RRRRRRRtsqlRt sql.operatorsRR tsymbolR tInspectionAttrInfoRtobjectR,RTR[R_RqRRyRRzR{(((sR/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/ext/associationproxy.pyts0  7 \;7