<div dir="ltr">Check out <a href="https://code.google.com/p/anodyzed/">https://code.google.com/p/anodyzed/</a> It does pretty much exactly what you're looking for.<div style> (*Chris*)</div></div><div class="gmail_extra">
<br><br><div class="gmail_quote">On Mon, May 27, 2013 at 9:49 AM, Heitor Machado <span dir="ltr"><<a href="mailto:heitor.m@gmail.com" target="_blank">heitor.m@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div dir="ltr">Is it possible to use MessageFormat in logback ?<br><br>I saw that it uses slf4j MessageFormat*ter*, because its faster as said here: <a href="http://stackoverflow.com/questions/8635769/out-of-curiosity-why-dont-logging-apis-implement-printf-like-logging-metho" target="_blank">http://stackoverflow.com/questions/8635769/out-of-curiosity-why-dont-logging-apis-implement-printf-like-logging-metho</a><br>
<br> SLF4J uses its own message formatting implementation which differs from that of the Java platform. This is justified by the fact that SLF4J's implementation performs about 10 times faster but at the cost of being non-standard and less flexible.<br>
<br>The ideia is to use the full stack feature of MessageFormat like that:<br><br> Object[] arguments = {<br> new Integer(7),<br> new Date(System.currentTimeMillis()),<br> "a disturbance in the Force"<br>
};<br><br> String result = MessageFormat.format(<br> "At {1,time} on {1,date}, there was {2} on planet {0,number,integer}.",<br> arguments);<br><br> output: At 12:30 PM on Jul 3, 2053, there was a disturbance<br>
in the Force on planet 7.<br><br>anyone ?<br></div>
<br>_______________________________________________<br>
Logback-user mailing list<br>
<a href="mailto:Logback-user@qos.ch">Logback-user@qos.ch</a><br>
<a href="http://mailman.qos.ch/mailman/listinfo/logback-user" target="_blank">http://mailman.qos.ch/mailman/listinfo/logback-user</a><br></blockquote></div><br></div>