Ticket #4853: non-blocking-consumer-write.patch

File non-blocking-consumer-write.patch, 969 bytes (added by Jean-Paul Calderone, 11 years ago)
  • twisted/internet/interfaces.py

     
    11141114        @return: C{None}
    11151115        """
    11161116
     1117
    11171118    def unregisterProducer():
    11181119        """
    11191120        Stop consuming data from a producer, without disconnecting.
    11201121        """
    11211122
     1123
    11221124    def write(data):
    11231125        """
    11241126        The producer will write data by calling this method.
     1127
     1128        The implementation must be non-blocking and perform whatever
     1129        buffering is necessary.  If the producer has provided enough data
     1130        for now and it is a L{IPushProducer}, the consumer may call its
     1131        C{pauseProducing} method.
    11251132        """
    11261133
     1134
     1135
    11271136class IFinishableConsumer(IConsumer):
    11281137    """
    11291138    A Consumer for producers that finish.