ó
    Ñ]jÿ.  ã                  ó   • S r SSKJr  SSKJr  SSKJr  SSKrSSKrSSKJ	r	  SSKJ
r
  SSKJr  SSKJr  SS	KJr  SS
KJr  SSKJr  SSKJr  SSKJr  SSKJr  SSKJr  SSKJr  SSKJr  SSKJr  SSKJr  SSKJr  SSKJr  SSKJr  \(       d  \(       d  SSKJr  OSSK Jr  \(       a  SSK!J"r"  SSK!J#r#  SSK!J$r$  \" S\	S9r%\" S\\	S 4   S9r& " S! S"\\\	   \\&   5      r'\r(\'r) " S# S$\5      r* " S% S&\*\RV                  S'   \RX                  \	   5      r- " S( S)\*\R\                  S'\	4   5      r/ " S* S+\\R                  S'\	4   5      r0g),z.Define row constructs including :class:`.Row`.é    )Úannotations)ÚABCN)ÚAny)ÚCallable)ÚDict)ÚGeneric)ÚIterator)ÚList)ÚMapping)ÚNoReturn)ÚOptional)Úoverload)ÚSequence)ÚTuple)ÚTYPE_CHECKING)ÚTypeVar)ÚUnioné   )Úutil)Ú
deprecated)ÚHAS_CYEXTENSIONé   )ÚBaseRow)Ú_KeyType)Ú_ProcessorsType)Ú	RMKeyViewÚ_T)ÚboundÚ_TP.c                  óÊ  • \ rS rSrSrSrS!S jrS"S jrS#S jr\	" SS5      S#S	 j5       r
\S#S
 j5       r\\	" SS5      S#S j5       5       r\S$S j5       r    S%S jr\(       d  S&S jr\" S5      r\" S5      rS'S jrS(S jr\R.                  r\(       a  \S)S j5       r\S*S j5       rS+S jrS,S jrS,S jrS,S jrS,S jrS,S jrS,S jrS-S jr \S.S j5       r!S/S jr"Sr#g )0ÚRowé2   aÓ  Represent a single result row.

The :class:`.Row` object represents a row of a database result.  It is
typically associated in the 1.x series of SQLAlchemy with the
:class:`_engine.CursorResult` object, however is also used by the ORM for
tuple-like results as of SQLAlchemy 1.4.

The :class:`.Row` object seeks to act as much like a Python named
tuple as possible.   For mapping (i.e. dictionary) behavior on a row,
such as testing for containment of keys, refer to the :attr:`.Row._mapping`
attribute.

.. seealso::

    :ref:`tutorial_selecting_data` - includes examples of selecting
    rows from SELECT statements.

.. versionchanged:: 1.4

    Renamed ``RowProxy`` to :class:`.Row`. :class:`.Row` is no longer a
    "proxy" object in that it contains the final form of data within it,
    and now acts mostly like a named tuple. Mapping-like functionality is
    moved to the :attr:`.Row._mapping` attribute. See
    :ref:`change_4710_core` for background on this change.

© c                ó   • [        S5      e)Nzcan't set attribute©ÚAttributeError)ÚselfÚnameÚvalues      ÚR/home/mande/repo/quber/.venv/lib/python3.13/site-packages/sqlalchemy/engine/row.pyÚ__setattr__ÚRow.__setattr__P   s   € ÜÐ2Ó3Ð3ó    c                ó   • [        S5      e)Nzcan't delete attributer%   )r'   r(   s     r*   Ú__delattr__ÚRow.__delattr__S   s   € ÜÐ5Ó6Ð6r-   c                ó   • U $ )aÍ  Return a 'tuple' form of this :class:`.Row`.

At runtime, this method returns "self"; the :class:`.Row` object is
already a named tuple. However, at the typing level, if this
:class:`.Row` is typed, the "tuple" return type will be a :pep:`484`
``Tuple`` datatype that contains typing information about individual
elements, supporting typed unpacking and attribute access.

.. versionadded:: 2.0.19 - The :meth:`.Row._tuple` method supersedes
   the previous :meth:`.Row.tuple` method, which is now underscored
   to avoid name conflicts with column names in the same way as other
   named-tuple methods on :class:`.Row`.

.. seealso::

    :attr:`.Row._t` - shorthand attribute notation

    :meth:`.Result.tuples`


r#   ©r'   s    r*   Ú_tupleÚ
Row._tupleV   s	   € ð, ˆr-   z2.0.19zÛThe :meth:`.Row.tuple` method is deprecated in favor of :meth:`.Row._tuple`; all :class:`.Row` methods and library-level attributes are intended to be underscored to avoid name conflicts.  Please use :meth:`Row._tuple`.c                ó"   • U R                  5       $ )zEReturn a 'tuple' form of this :class:`.Row`.

.. versionadded:: 2.0

)r3   r2   s    r*   ÚtupleÚ	Row.tuplen   s   € ð �{‰{‹}Ðr-   c                ó   • U $ )a?  A synonym for :meth:`.Row._tuple`.

.. versionadded:: 2.0.19 - The :attr:`.Row._t` attribute supersedes
   the previous :attr:`.Row.t` attribute, which is now underscored
   to avoid name conflicts with column names in the same way as other
   named-tuple methods on :class:`.Row`.

.. seealso::

    :attr:`.Result.t`
r#   r2   s    r*   Ú_tÚRow._t}   s	   € ð ˆr-   zÒThe :attr:`.Row.t` attribute is deprecated in favor of :attr:`.Row._t`; all :class:`.Row` methods and library-level attributes are intended to be underscored to avoid name conflicts.  Please use :attr:`Row._t`.c                ó   • U R                   $ )z;A synonym for :meth:`.Row._tuple`.

.. versionadded:: 2.0

)r9   r2   s    r*   ÚtÚRow.tŒ   s   € ð �w‰wˆr-   c                óZ   • [        U R                  SU R                  U R                  5      $ )a%  Return a :class:`.RowMapping` for this :class:`.Row`.

This object provides a consistent Python mapping (i.e. dictionary)
interface for the data contained within the row.   The :class:`.Row`
by itself behaves like a named tuple.

.. seealso::

    :attr:`.Row._fields`

.. versionadded:: 1.4

N)Ú
RowMappingÚ_parentÚ_key_to_indexÚ_datar2   s    r*   Ú_mappingÚRow._mappingœ   s#   € ô ˜$Ÿ,™,¨¨d×.@Ñ.@À$Ç*Á*ÓMÐMr-   c                óX   • [        U R                  XR                  U R                  5      $ ©N)r!   r@   rA   rB   )r'   Ú	processors     r*   Ú_filter_on_valuesÚRow._filter_on_values­   s!   € ô �4—<‘< ×,>Ñ,>ÀÇ
Á
ÓKÐKr-   c                ó*   ^ • [         SU 4S jj5       nU$ )z3Handle ambiguous names such as "count" and "index" c                ó~   >^ • T R                   R                  T5      (       a  T R                  T5      $ SUU 4S jjnU$ )Nc                 óL   >• [        [        R                  T5      " T/U Q70 UD6$ rF   )ÚgetattrÚcollections_abcr   )ÚargÚkwr(   r'   s     €€r*   ÚmethÚ4Row._special_name_accessor.<locals>.go.<locals>.meth½   s0   ø€ Ü&¤×'?Ñ'?ÀÔFØ ð Ø#&ò Ø*,ñ ð r-   )rO   r   rP   r   Úreturnr   )r@   Ú_has_keyÚ__getattr__)r'   rQ   r(   s   ` €r*   ÚgoÚ&Row._special_name_accessor.<locals>.go·   s:   ù€ à—<‘<×(Ñ(¨×.Ñ.Ø×+Ñ+¨DÓ1Ð1÷ð ð
  �Kr-   )r'   r!   rS   r   )Úproperty)r(   rV   s   ` r*   Ú_special_name_accessorÚRow._special_name_accessor´   s   ø€ ô ö
 ó ð
 ð ˆIr-   ÚcountÚindexc                ó   • XR                   ;   $ rF   )rB   ©r'   Úkeys     r*   Ú__contains__ÚRow.__contains__É   s   € Ø—j‘jÑ Ð r-   c                ó¤   • [        U[        5      (       a%  U" U R                  5       UR                  5       5      $ U" U R                  5       U5      $ rF   )Ú
isinstancer!   Ú_to_tuple_instance)r'   ÚotherÚops      r*   Ú_opÚRow._opÌ   sN   € ô ˜%¤×%Ñ%ñ ˆt×&Ñ&Ó(¨%×*BÑ*BÓ*DÓEð	
ñ �D×+Ñ+Ó-¨uÓ5ð	
r-   c                ó   • g rF   r#   ©r'   r\   s     r*   Ú__getitem__ÚRow.__getitem__×   s   € Ø25r-   c                ó   • g rF   r#   rj   s     r*   rk   rl   Ú   s   € Ø>Ar-   c                ó   • g rF   r#   rj   s     r*   rk   rl   Ý   s   € Àr-   c                óB   • U R                  U[        R                  5      $ rF   )rg   ÚoperatorÚlt©r'   re   s     r*   Ú__lt__Ú
Row.__lt__ß   ó   € Ø�x‰x˜œxŸ{™{Ó+Ð+r-   c                óB   • U R                  U[        R                  5      $ rF   )rg   rp   Úlerr   s     r*   Ú__le__Ú
Row.__le__â   ru   r-   c                óB   • U R                  U[        R                  5      $ rF   )rg   rp   Úgerr   s     r*   Ú__ge__Ú
Row.__ge__å   ru   r-   c                óB   • U R                  U[        R                  5      $ rF   )rg   rp   Úgtrr   s     r*   Ú__gt__Ú
Row.__gt__è   ru   r-   c                óB   • U R                  U[        R                  5      $ rF   )rg   rp   Úeqrr   s     r*   Ú__eq__Ú
Row.__eq__ë   ru   r-   c                óB   • U R                  U[        R                  5      $ rF   )rg   rp   Únerr   s     r*   Ú__ne__Ú
Row.__ne__î   ru   r-   c                ó@   • [        [        R                  " U 5      5      $ rF   )ÚreprÚsql_utilÚ	_repr_rowr2   s    r*   Ú__repr__ÚRow.__repr__ñ   s   € Ü”H×&Ò& tÓ,Ó-Ð-r-   c                ót   • [        U R                  R                   Vs/ s H	  oc  M  UPM     sn5      $ s  snf )aa  Return a tuple of string keys as represented by this
:class:`.Row`.

The keys can represent the labels of the columns returned by a core
statement or the names of the orm classes returned by an orm
execution.

This attribute is analogous to the Python named tuple ``._fields``
attribute.

.. versionadded:: 1.4

.. seealso::

    :attr:`.Row._mapping`

)r6   r@   Úkeys)r'   Úks     r*   Ú_fieldsÚRow._fieldsô   s-   € ô&  §¡×!2Ò!2ÓDÒ!2˜A—aÑ!2ÑDÓEÐEùÒDs   ž5¨5c                ó,   • [        U R                  5      $ )a-  Return a new dict which maps field names to their corresponding
values.

This method is analogous to the Python named tuple ``._asdict()``
method, and works by applying the ``dict()`` constructor to the
:attr:`.Row._mapping` attribute.

.. versionadded:: 1.4

.. seealso::

    :attr:`.Row._mapping`

)ÚdictrC   r2   s    r*   Ú_asdictÚRow._asdict	  s   € ô �D—M‘MÓ"Ð"r-   N)r(   Ústrr)   r   rS   r   )r(   r™   rS   r   )rS   r   )rS   r?   )rG   zOptional[_ProcessorsType]rS   zRow[Any])r(   r™   rS   r   )r_   r   rS   Úbool)re   r   rf   zCallable[[Any, Any], bool]rS   rš   )r\   ÚintrS   r   )r\   ÚslicerS   úSequence[Any])r\   zUnion[int, slice]rS   r   ©re   r   rS   rš   ©rS   r™   )rS   zTuple[str, ...])rS   zDict[str, Any])$Ú__name__Ú
__module__Ú__qualname__Ú__firstlineno__Ú__doc__Ú	__slots__r+   r/   r3   r   r6   rX   r9   r<   rC   rH   r   rY   r[   r\   r`   rg   r   Ú__hash__r   rk   rs   rx   r|   r€   r„   rˆ   rŽ   r“   r—   Ú__static_attributes__r#   r-   r*   r!   r!   2   sA  † ñð6 €Iô4ô7ôñ0 Øð	Cóóóðð óó ðð ÙØð	?óóóó ðð óNó ðNð LØ2ðLà	ôLö
 ô	ñ$ ' wÓ/ˆÙ& wÓ/ˆô!ô
ð ×Ñ€Hæà	Û5ó 
Ø5à	ÛAó 
ØAäCô,ô,ô,ô,ô,ô,ô.ð óFó ðF÷(#r-   r!   c                  ó|   • \ rS rSr% SrS\S'   S\S'       SS jrSS jrSS	 jrSS
 jr	SS jr
SS jrSS jrSrg)ÚROMappingViewi  r#   r�   Ú_itemsúMapping['_KeyType', Any]rC   c                ó   • Xl         X l        g rF   )rC   rª   )r'   ÚmappingÚitemss      r*   Ú__init__ÚROMappingView.__init__%  s   € ð  ŒØ�r-   c                ó,   • [        U R                  5      $ rF   )Úlenrª   r2   s    r*   Ú__len__ÚROMappingView.__len__+  s   € Ü�4—;‘;ÓÐr-   c                ó$   • SR                  U 5      $ )Nz&{0.__class__.__name__}({0._mapping!r}))Úformatr2   s    r*   rŽ   ÚROMappingView.__repr__.  s   € Ø7×>Ñ>¸tÓDÐDr-   c                ó,   • [        U R                  5      $ rF   )Úiterrª   r2   s    r*   Ú__iter__ÚROMappingView.__iter__1  s   € Ü�D—K‘KÓ Ð r-   c                ó   • XR                   ;   $ rF   ©rª   )r'   Úitems     r*   r`   ÚROMappingView.__contains__4  s   € Ø—{‘{Ñ"Ð"r-   c                ó0   • [        U5      [        U 5      :H  $ rF   ©Úlistrr   s     r*   r„   ÚROMappingView.__eq__7  ó   € Ü�E‹{œd 4›jÑ(Ð(r-   c                ó0   • [        U5      [        U 5      :g  $ rF   rÁ   rr   s     r*   rˆ   ÚROMappingView.__ne__:  rÄ   r-   )rª   rC   N)r­   r«   r®   r�   ©rS   r›   rŸ   )rS   zIterator[Any])r¾   r   rS   rš   rž   )r    r¡   r¢   r£   r¥   Ú__annotations__r¯   r³   rŽ   rº   r`   r„   rˆ   r§   r#   r-   r*   r©   r©     sG   ‡ Ø€IàÓØ&Ó&ðØ/ðØ8Eôô ôEô!ô#ô)÷)r-   r©   c                  ó   • \ rS rSrSrSrg)ÚROMappingKeysValuesViewi>  r½   r#   N©r    r¡   r¢   r£   r¥   r§   r#   r-   r*   rÊ   rÊ   >  s	   † ð ƒIr-   rÊ   r   c                  ó   • \ rS rSrSrSrg)ÚROMappingItemsViewiD  r½   r#   NrË   r#   r-   r*   rÍ   rÍ   D  s   † ØƒIr-   rÍ   c                  óž   • \ rS rSrSrSr\(       a  SS jrO\R                  rSS jr
SS jrSS jrSS jrSS	 jrSS
 jrSS jrSS jrSrg)r?   iH  a¤  A ``Mapping`` that maps column names and objects to :class:`.Row`
values.

The :class:`.RowMapping` is available from a :class:`.Row` via the
:attr:`.Row._mapping` attribute, as well as from the iterable interface
provided by the :class:`.MappingResult` object returned by the
:meth:`_engine.Result.mappings` method.

:class:`.RowMapping` supplies Python mapping (i.e. dictionary) access to
the  contents of the row.   This includes support for testing of
containment of specific keys (string column names or objects), as well
as iteration of keys, values, and items::

    for row in result:
        if "a" in row._mapping:
            print("Column 'a': %s" % row._mapping["a"])

        print("Column b: %s" % row._mapping[table.c.b])

.. versionadded:: 1.4 The :class:`.RowMapping` object replaces the
   mapping-like access previously provided by a database result row,
   which now seeks to behave mostly like a named tuple.

r#   c                ó   • g rF   r#   r^   s     r*   rk   ÚRowMapping.__getitem__f  s   € °Sr-   c                ó,   • [        U R                  5      $ rF   )rÂ   rB   r2   s    r*   Ú_values_implÚRowMapping._values_implk  s   € Ü�D—J‘JÓÐr-   c                ó<   • S U R                   R                   5       $ )Nc              3  ó.   #   • U  H  oc  M  Uv •  M     g 7frF   r#   )Ú.0r’   s     r*   Ú	<genexpr>Ú&RowMapping.__iter__.<locals>.<genexpr>o  s   é € Ð>Ò,�a—‘Ò,ùs   ‚Œ	©r@   r‘   r2   s    r*   rº   ÚRowMapping.__iter__n  s   € Ù>˜4Ÿ<™<×,Ò,Ó>Ð>r-   c                ó,   • [        U R                  5      $ rF   )r²   rB   r2   s    r*   r³   ÚRowMapping.__len__q  s   € Ü�4—:‘:‹Ðr-   c                ó8   • U R                   R                  U5      $ rF   )r@   rT   r^   s     r*   r`   ÚRowMapping.__contains__t  s   € Ø�|‰|×$Ñ$ SÓ)Ð)r-   c                ó*   • [        [        U 5      5      $ rF   )r‹   r–   r2   s    r*   rŽ   ÚRowMapping.__repr__w  s   € Ü”D˜“JÓÐr-   c           	     óf   • [        X R                  5        Vs/ s H  oX   4PM
     sn5      $ s  snf )zUReturn a view of key/value tuples for the elements in the
underlying :class:`.Row`.

)rÍ   r‘   r^   s     r*   r®   ÚRowMapping.itemsz  s1   € ô
 "Ø¯y©y¬{Ó;ª{¨˜™Ó#©{Ñ;ó
ð 	
ùÚ;s   ˜.
c                ó.   • U R                   R                  $ )z^Return a view of 'keys' for string column names represented
by the underlying :class:`.Row`.

rÙ   r2   s    r*   r‘   ÚRowMapping.keysƒ  s   € ð �|‰|× Ñ Ð r-   c                ó4   • [        X R                  5       5      $ )zUReturn a view of values for the values represented in the
underlying :class:`.Row`.

)rÊ   rÒ   r2   s    r*   ÚvaluesÚRowMapping.values‹  s   € ô
 ' t×->Ñ->Ó-@ÓAÐAr-   N)r_   r   rS   r   )rS   z	List[Any])rS   zIterator[str]rÇ   )r_   ÚobjectrS   rš   rŸ   )rS   rÍ   )rS   r   )rS   rÊ   )r    r¡   r¢   r£   r¤   r¥   r   rk   r   Ú_get_by_key_impl_mappingrÒ   rº   r³   r`   rŽ   r®   r‘   ræ   r§   r#   r-   r*   r?   r?   H  sJ   † ñð2 €Iæå8ð ×6Ñ6ˆô ô?ôô*ô ô
ô!÷Br-   r?   )1r¤   Ú
__future__r   Úabcr   Úcollections.abcrN   rp   Útypingr   r   r   r   r	   r
   r   r   r   r   r   r   r   r   r   Úsqlr   rŒ   r   Úutil._has_cyr   Ú_py_rowr   Ú"sqlalchemy.cyextension.resultproxyÚresultr   r   r   r   r   r!   ÚBaseRowProxyÚRowProxyr©   ÚKeysViewÚ
ValuesViewrÊ   Ú	ItemsViewrÍ   r?   r#   r-   r*   Ú<module>rø      s  ðñ 5å "å Ý )Û Û Ý Ý Ý Ý Ý Ý Ý Ý Ý Ý Ý Ý Ý  Ý Ý å "Ý Ý *æžÞ+åEæÝ Ý'Ý!áˆT˜Ñ€Ùˆe˜5  c ™?Ñ+€ôf#ˆ'�8˜C‘= '¨#¡,ô f#ðR €Ø€ô)�Cô )ô>Ø�6—?‘? :Ñ.°×0AÑ0AÀ#Ñ0Fôô˜¨×(8Ñ(8¸ÀS¸Ñ(Iô ôHB�˜&Ÿ.™.¨°S¨Ñ9õ HBr-   