Tomcat源码分析(六)--日志记录器和国际化
日志记录器挺简单的,没有很多东西,最主要的就是一个Logger接口:
public String getString(String key) { if (key == null) { String msg = "key is null"; throw new NullPointerException(msg); } String str = null; try { str = bundle.getString(key); } catch (MissingResourceException mre) { str = "Cannot find message associated with key '" + key + "'"; } return str; }