package utils.logging;

import java.util.logging.Formatter;
import java.util.logging.LogRecord;

public class L1Formatter extends Formatter{

	@Override
	public String format(LogRecord rec) {
		StringBuffer buf = new StringBuffer(1000);

		buf.append(formatMessage(rec));
		buf.append("\n\t\t\t\t\t (");
		buf.append(rec.getLevel());
		buf.append(" - ");
		buf.append(rec.getSourceClassName() + "#");
		buf.append(rec.getSourceMethodName());
		buf.append(")");
		buf.append("\n");

		return buf.toString();
	}
}

@@ -53,16 +53,48 @@
 matter;%0A
+import java.util.logging.Level;%0A
 import j
@@ -170,138 +170,488 @@
 er%7B%0A
-%0A%09@Override%0A%09public String format(LogRecord rec) %7B%0A%09%09StringBuffer buf = new StringBuffer(1000);%0A%0A%09%09buf.append(formatMessage(rec));
+%09// TODO: ansi colors are just a demo hack, here%0Apublic static final String ANSI_RESET = %22%5Cu001B%5B0m%22;%0Apublic static final String ANSI_BLACK = %22%5Cu001B%5B30m%22;%0Apublic static final String ANSI_RED = %22%5Cu001B%5B31m%22;%0A%09@Override%0A%09public String format(LogRecord rec) %7B%0A%09%09StringBuffer buf = new StringBuffer(1000);%0A%0A%09%09if ( rec.getLevel() == Level.SEVERE) %7B%0A%09%09%09buf.append(ANSI_RED);%0A%09%09%7D%0A%0A%09%09buf.append(formatMessage(rec));%0A%09%09if ( rec.getLevel() == Level.SEVERE) %7B%0A%09%09%09buf.append(ANSI_RESET);%0A%09%09%7D
 %0A%09%09b

Add color output for type errors