`
- 浏览:
49584 次
- 性别:
- 来自:
北京
-
-
<?
xml
version
=
"1.0"
encoding
=
"UTF-8"
?>
-
<!DOCTYPE struts PUBLIC
-
"-//Apache Software Foundation//DTD Struts Configuration 2.0//EN"
-
"http://struts.apache.org/dtds/struts-2.0.dtd"
>
-
-
<
struts
>
-
-
-
<
constant
name
=
"struts.devMode"
value
=
"true"
/>
-
-
<
constant
name
=
"struts.i18n.reload"
value
=
"true"
/>
-
-
<
constant
name
=
"struts.configuration.xml.reload"
value
=
"true"
/>
-
-
<
constant
name
=
"struts.convention.classes.reload"
value
=
"true"
/>
-
-
-
<
constant
name
=
"struts.ui.theme"
value
=
"simple"
/>
-
-
<
constant
name
=
"struts.locale"
value
=
"zh_CN"
/>
-
-
<
constant
name
=
"struts.i18n.encoding"
value
=
"UTF-8"
/>
-
-
<
constant
name
=
"struts.action.extension"
value
=
"action,do,jsp"
/>
-
-
<
constant
name
=
"struts.enable.DynamicMethodInvocation"
value
=
"true"
/>
-
-
<
constant
name
=
"struts.enable.SlashesInActionNames"
value
=
"false"
/>
-
-
<
constant
name
=
"struts.convention.result.path"
value
=
"/"
/>
-
-
<
constant
name
=
"struts.convention.action.suffix"
value
=
"Action"
/>
-
-
<
constant
name
=
"struts.convention.action.name.lowercase"
value
=
"true"
/>
-
-
<
constant
name
=
"struts.convention.action.name.separator"
value
=
"_"
/>
-
-
<
constant
name
=
"struts.convention.action.disableScanning"
value
=
"false"
/>
-
-
<
constant
name
=
"struts.convention.default.parent.package"
value
=
"default"
/>
-
-
<
constant
name
=
"struts.convention.package.locators"
value
=
"actions"
/>
-
-
<
constant
name
=
"struts.convention.package.locators.disable"
value
=
"false"
/>
-
-
<
constant
name
=
"struts.convention.package.locators.basePackage"
value
=
"com.sunflower.actions"
/>
-
-
<
constant
name
=
"struts.convention.exclude.packages"
value
=
"org.apache.struts.*,org.apache.struts2.*,org.springframework.web.struts.*,org.springframework.web.struts2.*,org.hibernate.*"
/>
-
-
-
<
constant
name
=
"struts.convention.action.includeJars"
value
=
""
/>
-
-
<
constant
name
=
"struts.convention.relative.result.types"
value
=
"dispatcher,freemarker"
/>
-
<!--
-
如果此值设为true,如果一个action的命名空间为/login,名称为HelloWorldAction。result返回值是success,默认会找到/WEB-INF/pages/login/hello_world.jsp(如果有hello_world_success.jsp就找这个文件,连接符“_”是在
<
constant
name
=
"struts.convention.action.name.separator"
value
=
"_"
/>
中配置的)。如果有一个action的result返回值是“error”,就会找/WEB-INF/pages /login/hello_world_error.jsp。
-
-
如果此值设为false,如果一个action的命名空间为/login,名称为HelloWorldAction。result返回值是success,默认会找到/WEB- INF/pages/login/hello_world/index.jsp(如果有success.jsp就找这个文件)。如果有一个action的result返回值是“error”,就会找/WEB-INF/pages /login/hello_world/error.jsp。
-
--
>
-
<
constant
name
=
"struts.convention.result.flatLayout"
value
=
"true"
/>
-
<
constant
name
=
"struts.convention.action.mapAllMatches"
value
=
"false"
/>
-
-
<
constant
name
=
"struts.convention.action.checkImplementsAction"
value
=
"true"
/>
-
<
constant
name
=
"struts.mapper.alwaysSelectFullNamespace"
value
=
"false"
/>
-
<
constant
name
=
"struts.convention.redirect.to.slash"
value
=
"true"
/>
-
<
package
name
=
"default"
extends
=
"struts-default"
>
-
<
interceptors
>
-
<
interceptor-stack
name
=
"defaultStack"
>
-
<
interceptor-ref
name
=
"exception"
/>
-
<
interceptor-ref
name
=
"servletConfig"
/>
-
<
interceptor-ref
name
=
"actionMappingParams"
/>
-
<
interceptor-ref
name
=
"staticParams"
/>
-
<
interceptor-ref
name
=
"params"
/>
-
</
interceptor-stack
>
-
</
interceptors
>
-
</
package
>
-
</
struts
>
分享到:
Global site tag (gtag.js) - Google Analytics
相关推荐
从struts2.1开始,struts2不再推荐使用Codebehind作为零配置插件,而是改为使用Convention插件来支持零配置,和Codebehind相比,Convention插件更彻底,该插件完全抛弃配置信息,不仅不需要是使用struts.xml文件进行...
struts2的convention配置详解 很全
无需配置Convention即可使用Convention,Convention的某些约束习惯可以通过配置属性来控制,您也可以在类中覆写其中的方法来达到扩展目地。
简述STRUTS2_Convention零配置
从struts2.1开始,struts2不再推荐使用Codebehind作为零配置插件,而是改为使用Convention插件来支持零配置,和Codebehind相比,Convention插件更彻底,该插件完全抛弃配置信息,不仅不需要是使用struts.xml文件进行...
从struts2.1版本开始,Convention Plugin作为替换替换Codebehind Plugin来实现Struts2的零配置。 • 包命名习惯来指定Action位置 • 命名习惯制定结果(支持JSP,FreeMarker等)路径 • 类名到URL的约定转换 • 包名...
struts2采用convention-plugin实现零配置,讲述如何不通过配置文件搭建struts2
你可以通过设置struts.convention.package.locators属性来修改这个配置。如: <constant name="struts.convention.package.locators" value="web,action" /> 则定义了在项目中,包路径包含web和action的将被视为...
Struts-Convention实现零配置,可直接部署运行,主要针对于新手,很简单的一个项目,内有说明:explanation.txt
struts-convention实现零配置
struts2-convention-plugin-2.3.15.3.jar struts2配置Action注解要用到的包,真正实现零配置
Struts开始使用convention-plugin代替codebehind-plugin来实现struts的零配置,使用Convention插件,你需要此JAR文件
Struts2 的第三方插件 使用注解的方式配置struts.xml文件
Struts采用convention-plugin实现零配置
struts2-convention-plugin-2.3.1.jar,使用注解的方式代替xml配置action,必须要引用这个包。
如何使用插件convention来实现struts2框架的零配置以及整合ssh架构
配置struts2 - 风轻云淡 配置struts2 - 风轻云淡