21 |
|
|
22 |
|
/** |
23 |
|
* An array of names of verbosity levels. |
24 |
< |
* Thus logging messages are now "classed" by the level" |
24 |
> |
* Thus logging messages are now "classed" by the level |
25 |
|
*/ |
26 |
|
private final static String[] VERBOSITY_NAMES = {"FATAL ", "ERROR ", "WARNING", "SYSMSG ", "SYSINIT", "DEBUG "}; |
27 |
|
|
64 |
|
* @return The string to be written to the log. |
65 |
|
*/ |
66 |
|
public static String formatLogLine(String source, int verbosity, String message){ |
67 |
< |
String date = DateFormat.getDateTimeInstance(DateFormat.SHORT, DateFormat.MEDIUM).format(new Date()); |
67 |
> |
String date = DateFormat.getDateTimeInstance(DateFormat.SHORT, DateFormat.MEDIUM, Locale.UK).format(new Date()); |
68 |
|
return "[" + date + "] [" + VERBOSITY_NAMES[verbosity] + "] " + source + ": " + message; |
69 |
|
} |
70 |
|
|