in src/main/java/org/apache/commons/logging/impl/SimpleLog.java [159:191]
static {
// Add props from the resource simplelog.properties
final InputStream in = getResourceAsStream("simplelog.properties");
if (null != in) {
try {
simpleLogProps.load(in);
} catch (final IOException e) {
// ignored
} finally {
try {
in.close();
} catch (final IOException e) {
// ignored
}
}
}
showLogName = getBooleanProperty(systemPrefix + "showlogname", showLogName);
showShortName = getBooleanProperty(systemPrefix + "showShortLogname", showShortName);
showDateTime = getBooleanProperty(systemPrefix + "showdatetime", showDateTime);
if(showDateTime) {
dateTimeFormat = getStringProperty(systemPrefix + "dateTimeFormat",
dateTimeFormat);
try {
dateFormatter = new SimpleDateFormat(dateTimeFormat);
} catch (final IllegalArgumentException e) {
// If the format pattern is invalid - use the default format
dateTimeFormat = DEFAULT_DATE_TIME_FORMAT;
dateFormatter = new SimpleDateFormat(dateTimeFormat);
}
}
}