如何在执行特定方法后在日志文件中添加空格,我使用的是LOG4j

时间:2015-11-26 10:42:00

标签: java

在日志文件中的特定方法的每个事务之后我想要一个空行。

Ex-
 2015-11-26 15:59:04:[INFO]:MOrder:afterSave:
** Order No :800716 afterSave Started
:2015-11-26 15:59:04:[INFO]:MOrder:beforeSave:
** Order No :800716 Before Save Started
:2015-11-26 15:59:04:[INFO]:MOrder:afterSave:
** Order No :800716 afterSave Started
:2015-11-26 15:59:04:[INFO]:MOrder:processIt:
** Order No :800716 ProcessIt Started
:2015-11-26 15:59:04:[INFO]:MOrder:completeIt:
** Order No :800716 CompleteIt Started

"空白行"

:2015-11-26 15:59:04:[INFO]:MOrder:beforeSave:** Order No :800716 BeforeS ave Started
:2015-11-26 15:59:04:[INFO]:MOrder:afterSave:
** Order No :800716 afterSave Started

在上面的示例中,我想在完成方法后使用一个空白行,我正在使用log4j。

0 个答案:

没有答案