ó
    OÎh¾  ã                  óª   • S r SSKJr  SSKJrJr  SSKJr  SSKJ	r	J
r
Jr  SSKJr  / SQr " S S	\S
9r " S S\5      r " S S\5      r\SS j5       rg)z
Abstraction of CLI Input.
é    )Úannotations)ÚABCMetaÚabstractmethod)Úcontextmanager)ÚCallableÚContextManagerÚ	Generator)ÚKeyPress)ÚInputÚ	PipeInputÚ
DummyInputc                  óà   • \ rS rSrSr\SS j5       r\SS j5       r\SS j5       rSS jr	SS jr
\\SS j5       5       r\SS	 j5       r\SS
 j5       r\SS j5       r\SS j5       rSS jrSrg)r   é   zß
Abstraction for any input.

An instance of this class can be given to the constructor of a
:class:`~prompt_toolkit.application.Application` and will also be
passed to the :class:`~prompt_toolkit.eventloop.base.EventLoop`.
c                ó   • g)z+
Fileno for putting this in an event loop.
N© ©Úselfs    ÚV/home/mande/repo/quber/.venv/lib/python3.13/site-packages/prompt_toolkit/input/base.pyÚfilenoÚInput.fileno   ó   � ó    c                ó   • g)z0
Identifier for storing type ahead key presses.
Nr   r   s    r   Útypeahead_hashÚInput.typeahead_hash#   r   r   c                ó   • g)zD
Return a list of Key objects which are read/parsed from the input.
Nr   r   s    r   Ú	read_keysÚInput.read_keys)   r   r   c                ó   • / $ )zS
Flush the underlying parser. and return the pending keys.
(Used for vt100 input.)
r   r   s    r   Ú
flush_keysÚInput.flush_keys/   s	   € ð
 ˆ	r   c                ó   • g)z>The event loop can call this when the input has to be flushed.Nr   r   s    r   ÚflushÚInput.flush6   ó   € àr   c                ó   • g)z/Should be true when the input stream is closed.Fr   r   s    r   ÚclosedÚInput.closed:   s   € ð r   c                ó   • g)z5
Context manager that turns the input into raw mode.
Nr   r   s    r   Úraw_modeÚInput.raw_mode@   r   r   c                ó   • g)z8
Context manager that turns the input into cooked mode.
Nr   r   s    r   Úcooked_modeÚInput.cooked_modeF   r   r   c                ó   • g)zR
Return a context manager that makes this input active in the current
event loop.
Nr   ©r   Úinput_ready_callbacks     r   ÚattachÚInput.attachL   r   r   c                ó   • g)zc
Return a context manager that makes sure that this input is not active
in the current event loop.
Nr   r   s    r   ÚdetachÚInput.detachS   r   r   c                ó   • g)zClose input.Nr   r   s    r   ÚcloseÚInput.closeZ   r%   r   r   N©ÚreturnÚint©r;   Ústr©r;   zlist[KeyPress])r;   ÚNone©r;   Úbool©r;   úContextManager[None]©r1   zCallable[[], None]r;   rD   )Ú__name__Ú
__module__Ú__qualname__Ú__firstlineno__Ú__doc__r   r   r   r   r    r#   Úpropertyr'   r*   r-   r2   r5   r8   Ú__static_attributes__r   r   r   r   r      s¾   † ñð óó ðð
 óó ðð
 óó ðô
ôð Øóó ó ðð óó ðð
 óó ðð
 óó ðð óó ð÷r   r   )Ú	metaclassc                  ó@   • \ rS rSrSr\SS j5       r\SS j5       rSrg)	r   é_   z
Abstraction for pipe input.
c                ó   • g)zFeed byte string into the pipeNr   ©r   Údatas     r   Ú
send_bytesÚPipeInput.send_bytesd   r   r   c                ó   • g)z Feed a text string into the pipeNr   rQ   s     r   Ú	send_textÚPipeInput.send_texth   r   r   r   N)rR   Úbytesr;   r@   )rR   r>   r;   r@   )	rF   rG   rH   rI   rJ   r   rS   rV   rL   r   r   r   r   r   _   s/   † ñð ó-ó ð-ð ó/ó ó/r   r   c                  ór   • \ rS rSrSrSS jrSS jrSS jr\SS j5       r	SS jr
SS jrSS	 jrSS
 jrSrg)r   ém   z¦
Input for use in a `DummyApplication`

If used in an actual application, it will make the application render
itself once and exit immediately, due to an `EOFError`.
c                ó   • [         e©N)ÚNotImplementedErrorr   s    r   r   ÚDummyInput.filenou   s   € Ü!Ð!r   c                ó   • S[        U 5       3$ )Nzdummy-)Úidr   s    r   r   ÚDummyInput.typeahead_hashx   s   € Øœ˜4›�zÐ"Ð"r   c                ó   • / $ r\   r   r   s    r   r   ÚDummyInput.read_keys{   s   € Øˆ	r   c                ó   • g)NTr   r   s    r   r'   ÚDummyInput.closed~   s   € ð r   c                ó   • [        5       $ r\   ©Ú_dummy_context_managerr   s    r   r*   ÚDummyInput.raw_mode„   ó   € Ü%Ó'Ð'r   c                ó   • [        5       $ r\   rg   r   s    r   r-   ÚDummyInput.cooked_mode‡   rj   r   c                ó$   • U" 5         [        5       $ r\   rg   r0   s     r   r2   ÚDummyInput.attachŠ   s   € ñ 	Ôä%Ó'Ð'r   c                ó   • [        5       $ r\   rg   r   s    r   r5   ÚDummyInput.detach”   rj   r   r   Nr:   r=   r?   rA   rC   rE   )rF   rG   rH   rI   rJ   r   r   r   rK   r'   r*   r-   r2   r5   rL   r   r   r   r   r   m   s>   † ñô"ô#ôð óó ðô
(ô(ô(÷(r   r   c               #  ó   #   • S v •  g 7fr\   r   r   r   r   rh   rh   ˜   s   é € ä	ùs   ‚N)r;   zGenerator[None, None, None])rJ   Ú
__future__r   Úabcr   r   Ú
contextlibr   Útypingr   r   r	   Úprompt_toolkit.key_bindingr
   Ú__all__r   r   r   rh   r   r   r   Ú<module>rx      sa   ðñõ #ç 'Ý %ß 6Ñ 6å /ò€ôH�gò HôV/�ô /ô((�ô ((ðV ó
ó ñ
r   