Categories:
.NET (961)
C (387)
C++ (185)
CSS (84)
DBA (8)
General (31)
HTML (48)
Java (641)
JavaScript (220)
JSP (109)
JUnit (31)
MySQL (297)
Networking (10)
Oracle (562)
Perl (48)
Perl (9)
PHP (259)
PL/SQL (140)
RSS (51)
Software QA (28)
SQL Server (5)
Struts (20)
Unix (2)
Windows (3)
XHTML (199)
XML (59)
Other Resources:
How could Java classes direct program messages to the system console, but error messages, say to a file?
How could Java classes direct program messages to the system console, but error messages, say to a file?
✍: Guest
The class System has a variable out that represents the standard output, and the variable err that represents the standard error device. By default, they both point at the system console. This how the standard output could be re-directed:
Stream st = new Stream(new FileOutputStream("output.txt")); System.setErr(st); System.setOut(st);
2012-05-18, 2230👍, 0💬
Popular Posts:
What is a fish bone diagram ? Dr. Kaoru Ishikawa, invented the fishbone diagram. Therefore, it can b...
How To Write a Query with a Right Outer Join? - Oracle DBA FAQ - Understanding SQL SELECT Query Stat...
How to create a thread in a program? You have two ways to do so. First, making your class "extends" ...
How To Merge Values of Two Arrays into a Single Array? - PHP Script Tips - PHP Built-in Functions fo...
How To Retrieve the Count of Updated Rows? - Oracle DBA FAQ - Working with Database Objects in PL/SQ...