如果想在后台访问struts框架的配置常量,比如struts.devMode,可以使用如下代码:
DefaultSettings d = new DefaultSettings();
System.out.println(d.get("struts.devMode"));