I have a method which runs asynchronously after start, using OutputStream or Writer as parameter.
It acts as a recording adapter for an OutputStream or Writer (it’s a third party API I can’t change).
How could I pass Log4J’s internal OutputStream or Writer to that method?
…because Log4J swallows System.out and System.err, I was using before.
My suggestion is, why dont you write your OutputStream then?! I was about to write one for you, but I found this good example on the net, check it out!
LogOutputStream.java