struts-plugin resulttype 参数
来源:互联网 发布:java语言入门书 编辑:程序博客网 时间:2024/05/19 13:28
来源 https://cwiki.apache.org/confluence/display/WW/JSON%20Plugin
Excluding properties
A comma-delimited list of regular expressions can be passed to the JSON Result and Interceptor, properties matching any of these regular expressions will be ignored on the serialization process:
<!-- Interceptor fragment -->
<interceptor-ref name="json">
<param name="enableSMD">true</param>
<param name="excludeProperties">
login.password,
studentList.*\.sin
</param>
</interceptor-ref>
Including properties
A comma-delimited list of regular expressions can be passed to the JSON Result to restrict which properties will be serialized. ONLY properties matching any of these regular expressions will be included in the serialized output.
Note
Exclude property expressions take precedence over include property expressions. That is, if you use include and exclude property expressions on the same result, include property expressions will not be applied if an exclude exclude property expression matches a property first.
<!-- Result fragment -->
<result type="json">
<param name="includeProperties">
^entries\[\d+\]\.clientNumber,
^entries\[\d+\]\.scheduleNumber,
^entries\[\d+\]\.createUserId
</param>
</result>
Root Object
Use the "root" attribute(OGNL expression) to specify the root object to be serialized.
<result type="json">
<param name="root">
person.job
</param>
</result>
The "root" attribute(OGNL expression) can also be used on the interceptor to specify the object that must be populated, make sure this object is not null.
<interceptor-ref name="json">
<param name="root">bean1.bean2</param>
</interceptor-ref>
- struts-plugin resulttype 参数
- Struts 2 plugin architecture
- struts-annotations-plugin 介绍
- struts-plugin.xml
- struts-plugin.xml
- struts convention-plugin
- struts convension plugin
- struts plugIn的作用
- 不错的struts插件:Struts Spring Plugin
- 不错的struts插件:Struts Spring Plugin
- 不错的struts插件:Struts Spring Plugin
- 扩展Struts的Plugin接口
- Struts框架 Plugin初始化数据
- 一个Struts 2 Eclipse Plugin
- struts convention-plugin的使用
- struts 零配置 convention-plugin
- was plugin参数
- Struts2-ResultType-4-带参数的结果集
- eclipse如何显示代码行
- mediastreamsegmenter用法
- 在perl中简单的正则匹配
- hadoop 集群大版本切换之保存数据和日志的方法
- 先要到网上下载Snoopy.class.php
- struts-plugin resulttype 参数
- AP Confusion: Problems with ‘partitiontolerance
- mysql5.5.22 源码编译
- android/NDK开发assets资源中文名打包问题
- shell判断数字
- java.lang包 详解
- HTTP响应状态码详解
- Xcode各个版本下载地址
- SQL存储过程返回格式化过的字符串