With System.out, you have:
System.out.print
System.out.println
Occasionally I don't want a newline (like when I'm printing "About to commit transaction...done"). With System.out I would do this:
System.out.print("About to commit transaction...");
System.out.println("done.");
I can't figure out how to do this in log4j. My log4j properties file has this:
log4j.rootLogger=DEBUG, CA
log4j.appender.CA=org.apache.log4j.ConsoleAppender
log4j.appender.CA.layout=org.apache.log4j.PatternLayout
log4j.appender.CA.layout.ConversionPattern=%-30c{1} %x %-30M - %m%n
I don't want to simply remove the "%n" and have to specify it in every single logging statement.
Is this possible in Log4j?