Re: [ROOT] redirection of output of Printf

From: Jiri Masik (masik@pc203b.fzu.cz)
Date: Tue Feb 25 2003 - 15:21:10 MET


Hajime Nanjyo <nanjyo@icepp.s.u-tokyo.ac.jp> writes:

> Dear Rooters,
>
> I used the ROOT static function Printf and wanted 
> to redirect the output of Printf from the stdout to
> a file(i.e. to a fstream). Could you tell me how?
>
> By the way,which source code the implimentaion
> of Printf is writen?
>

Hi Hajime,

see base/src/TString.cxx for the implementation of Printf. I think it
cannot be redirected in an interactive session. You can use iostream
operators in combination with Form {cout << Form("aa%d",1) << endl;}
or with stringstream. 
cheers

Jiri



This archive was generated by hypermail 2b29 : Thu Jan 01 2004 - 17:50:09 MET