• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

System.out and System.err differences?

 
Sheriff
Posts: 7023
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
In another thread, kelvin cheung just asked the following.

Originally posted by kelvin cheung:
hi,
may i ask you whats the difference between : system.out and system.err ?


[ May 06, 2004: Message edited by: Dirk Schreckmann ]
 
Dirk Schreckmann
Sheriff
Posts: 7023
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
You may want to take a look at the System class documentation to see what it has to say.
In a nutshell, they're just two different output streams. By default, in Windows, both streams direct text output to the system console.
Note that the "destination" of these output streams can be changed by calling System.setOut(PrintStream) and System.setErr(PrintStream). So, a programmer could decide to direct all normal output to the console, or to a text file, while directing all critical errors to a different location, like a special error log file.
Are you getting the idea?
[ May 06, 2004: Message edited by: Dirk Schreckmann ]
 
Ranch Hand
Posts: 120
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Dirk Schreckmann ,
i think i understand more now... ^^
thanks man ^^ ~~
 
Consider Paul's rocket mass heater.
reply
    Bookmark Topic Watch Topic
  • New Topic