Is there a way to log System.out and System.err to a text file w/o redirecting, i.e. the console and the file would match?
Thanks in advance
Logging ?
Started by Victor, Jul 20 2008 09:31 PM
5 replies to this topic
#1
Posted 20 July 2008 - 09:31 PM
|
|
|
#2
Posted 22 July 2008 - 02:42 AM
It might be some trick you can use that I'm not aware about....
I would write my own function for e.g. System.out which use System.out like normal, but also logs the information like you want it.
That's just my way :D
I would write my own function for e.g. System.out which use System.out like normal, but also logs the information like you want it.
That's just my way :D
Hey! Check out my new Toyota keyboaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
#3
Posted 22 July 2008 - 11:40 AM
I thought about something like that, but it's a complex program with several classes that use System.out alot. I'd hate to do something time consuming when a simple function could be used. I'm able to log to a file the System.out and System.err, but it redirects the traffic
#4
Posted 22 July 2008 - 11:43 AM
I mean a function like:
Declaring func "OutEx" (params)
System.out (params)
[log here] (params)
And then just replace everywhere you use System.Out.
If this doesn't work for you, I'm not sure..... Maybe ask someone else :D
Declaring func "OutEx" (params)
System.out (params)
[log here] (params)
And then just replace everywhere you use System.Out.
If this doesn't work for you, I'm not sure..... Maybe ask someone else :D
Hey! Check out my new Toyota keyboaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
#5
Posted 22 July 2008 - 11:45 AM
I understood what you were talking about, and if nothing better is suggested I will just have to do that.
#6
Posted 22 July 2008 - 12:30 PM
Patience, son, patience :D
Hey! Check out my new Toyota keyboaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa


Sign In
Create Account


Back to top









