ó
    Æàh]  ã                   ó(   • S r SSKJr   " S S5      rg)z°
Experimental optimization

This module provides a single mixin class which allows protocols to
collapse numerous small writes into a single larger one.

@author: Jp Calderone
é    )Úreactorc                   ó<   • \ rS rSrSrSrSrSrS rS r	S r
S rS	rg)
ÚBufferingMixiné   z#
Mixin which adds write buffering.
Ng        c                 óX   • [         R                  " U R                  U R                  5      $ ©N)r   Ú	callLaterÚDELAYÚflush©Úselfs    ÚZ/root/1688_scrapy/alibaba-scraper/venv/lib/python3.13/site-packages/twisted/conch/mixin.pyÚscheduleÚBufferingMixin.schedule   s   € Ü× Ò  §¡¨T¯Z©ZÓ8Ð8ó    c                 ó:   • UR                  U R                  5        g r   )Úresetr
   )r   Útokens     r   Ú
rescheduleÚBufferingMixin.reschedule   s   € Ø‰D—J‘JÕr   c                 óÄ   • U R                   c  / U l        U R                  5       U l         OU R                  U R                   5        U R                  R	                  U5        g)zì
Buffer some bytes to be written soon.

Every call to this function delays the real write by C{self.DELAY}
seconds.  When the delay expires, all collected bytes are written
to the underlying transport using L{ITransport.writeSequence}.
N)Ú_delayedWriteCallÚdatar   r   Úappend)r   r   s     r   ÚwriteÚBufferingMixin.write!   sI   € ð ×!Ñ!Ñ)ØˆDŒIØ%)§]¡]£_ˆDÕ"àO‰O˜D×2Ñ2Ô3Ø	‰	×Ñ˜Õr   c                 ój   • SU l         U R                  R                  U R                  5        SU l        g)z
Flush the buffer immediately.
N)r   Ú	transportÚwriteSequencer   r   s    r   r   ÚBufferingMixin.flush0   s)   € ð "&ˆÔØ‰×$Ñ$ T§Y¡YÔ/Øˆ	r   )r   r   )Ú__name__Ú
__module__Ú__qualname__Ú__firstlineno__Ú__doc__r   r   r
   r   r   r   r   Ú__static_attributes__© r   r   r   r      s-   † ñð ÐØ€Dà€Eò9ò òõr   r   N)r%   Útwisted.internetr   r   r'   r   r   Ú<module>r)      s   ðñ
õ %÷%ò %r   