1

Possible Duplicate:
Log4J print empty line to logfile

In java, I can use System.out.println() to print a blank line.

And now I want to know how to log a blank line in log4j.

Is there any method named logger.appendEmptyLine() or any method that can do this?

Community
  • 1
  • 1
Jason
  • 11
  • 3
  • duplicate: http://stackoverflow.com/q/11843941/1515052 – Simulant Aug 07 '12 at 11:57
  • This question was asked on May 10, the "duplicate" linked by @Simulant was asked on August 7. So the duplicate was asked after this question. Now which one is the duplicate really? So much for `as earlier questions on this topic`. – Simon Forsberg Nov 11 '12 at 18:47
  • this one was erlier, but I found it later. I didn't want to answer the same text on both questions. An the other User who asked the Question is more active. – Simulant Nov 11 '12 at 20:50

1 Answers1

0
logger.debug("\n");

or maybe

logger.debug("");
BigMike
  • 6,683
  • 1
  • 23
  • 24
  • That will break the message. I'm assuming he wants the date/time stamp to be immediately before the message, but have a blank line or two before the that log message. – Meower68 Apr 29 '13 at 18:16