"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "logback-core/src/main/java/ch/qos/logback/core/rolling/helper/FileNamePattern.java" between
logback-1.2.3.tar.gz and logback-v_1.2.7.tar.gz

About: Logback is a generic Logging Framework (intended as a log4j successor).

FileNamePattern.java  (logback-1.2.3):FileNamePattern.java  (logback-v_1.2.7)
skipping to change at line 199 skipping to change at line 199
* Used to compute sub-regex when the pattern has both %d and %i, and the * Used to compute sub-regex when the pattern has both %d and %i, and the
* date is known. * date is known.
*/ */
public String toRegexForFixedDate(Date date) { public String toRegexForFixedDate(Date date) {
StringBuilder buf = new StringBuilder(); StringBuilder buf = new StringBuilder();
Converter<Object> p = headTokenConverter; Converter<Object> p = headTokenConverter;
while (p != null) { while (p != null) {
if (p instanceof LiteralConverter) { if (p instanceof LiteralConverter) {
buf.append(p.convert(null)); buf.append(p.convert(null));
} else if (p instanceof IntegerTokenConverter) { } else if (p instanceof IntegerTokenConverter) {
buf.append("(\\d{1,3})"); buf.append("(\\d{1,5})");
} else if (p instanceof DateTokenConverter) { } else if (p instanceof DateTokenConverter) {
buf.append(p.convert(date)); buf.append(p.convert(date));
} }
p = p.getNext(); p = p.getNext();
} }
return buf.toString(); return buf.toString();
} }
/** /**
* Given date, convert this instance to a regular expression * Given date, convert this instance to a regular expression
 End of changes. 1 change blocks. 
1 lines changed or deleted 1 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)