[Twisted-Python] POP3 improvements

Abe Fettig abe at fettig.net
Tue Dec 31 09:28:01 EST 2002


On Tue, 2002-12-31 at 07:53, Tommi Virtanen wrote:
> On Tue, Dec 31, 2002 at 06:08:22PM +1100, screwtape at froup.com wrote:
> > I think it would be nice if Twisted had a DownloadingFile interface or
> > something - make a new DownloadingFile instance, then pass it to FTP's
> > RETR, HTTP's GET, an IRC DCC transfer, a twisted.conch scp session, or
> > whatever. Then you can get the DownloadingFile instance to trigger
> > deferreds when it's complete, when it's progress is updated, that sort
> > of thing. It would make it easy to generate stats like download speed,
> > estimated time, and so forth.
> 
> 	How does that differ from the normal file interface?
> 
> 	f.write(somestuff)
> 	f.write(somestuff)
> 	f.write(somestuff)
> 	f.close()
> 

This would be my question too.  Is there really a need to use a new
interface, or can I just stick with file-like objects?

Abe





More information about the Twisted-Python mailing list