Newbie needs "interface"

Roberto Bonato rbonato at irisa.fr
Thu Nov 22 11:17:58 EST 2001


Hi all


        I'm writing a function that implements an algorithm and that
prints intermediate results all along the (usually very long)
computation. Sometimes I want the results to be written on the stdout,
sometimes on a Tkinter Text widget, sometimes to a file. I feel the need
of something like a Java Interface with a method "write" to wrap all
such devices into.
Since I'm a newbie at programming and at Python in particular I still
cannot find a simple and elegant way to do that. Thanks for any help.

--
Roberto Bonato
IRISA-INRIA, Campus de Beaulieu -  Rennes cedex, France




More information about the Python-list mailing list