Author: rjung Date: Sun Mar 29 09:23:45 2015 New Revision: 1669876 URL: http://svn.apache.org/r1669876 Log: No functional change: - move enum to top (more enum coming soon) - rename var "header" to "name", because the concept is more general
Modified: tomcat/trunk/java/org/apache/catalina/valves/AbstractAccessLogValve.java Modified: tomcat/trunk/java/org/apache/catalina/valves/AbstractAccessLogValve.java URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/catalina/valves/AbstractAccessLogValve.java?rev=1669876&r1=1669875&r2=1669876&view=diff ============================================================================== --- tomcat/trunk/java/org/apache/catalina/valves/AbstractAccessLogValve.java (original) +++ tomcat/trunk/java/org/apache/catalina/valves/AbstractAccessLogValve.java Sun Mar 29 09:23:45 2015 @@ -135,6 +135,13 @@ public abstract class AbstractAccessLogV private static final Log log = LogFactory.getLog(AbstractAccessLogValve.class); + /** + * The list of our time format types. + */ + private static enum FormatType { + CLF, SEC, MSEC, MSEC_FRAC, SDF + } + //------------------------------------------------------ Constructor public AbstractAccessLogValve() { super(true); @@ -394,13 +401,6 @@ public abstract class AbstractAccessLogV }; /** - * The list of our format types. - */ - private static enum FormatType { - CLF, SEC, MSEC, MSEC_FRAC, SDF - } - - /** * Are we doing conditional logging. default null. * It is the value of <code>conditionUnless</code> property. */ @@ -1488,22 +1488,22 @@ public abstract class AbstractAccessLogV } /** - * create an AccessLogElement implementation which needs header string + * create an AccessLogElement implementation which needs an element name */ - protected AccessLogElement createAccessLogElement(String header, char pattern) { + protected AccessLogElement createAccessLogElement(String name, char pattern) { switch (pattern) { case 'i': - return new HeaderElement(header); + return new HeaderElement(name); case 'c': - return new CookieElement(header); + return new CookieElement(name); case 'o': - return new ResponseHeaderElement(header); + return new ResponseHeaderElement(name); case 'r': - return new RequestAttributeElement(header); + return new RequestAttributeElement(name); case 's': - return new SessionAttributeElement(header); + return new SessionAttributeElement(name); case 't': - return new DateAndTimeElement(header); + return new DateAndTimeElement(name); default: return new StringElement("???"); } --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org