六狼论坛

 找回密码
 立即注册

QQ登录

只需一步,快速开始

新浪微博账号登陆

只需一步,快速开始

搜索
查看: 40|回复: 0

DWR的三种Reverse Ajax Mode配置详解

[复制链接]

升级  36%

30

主题

30

主题

30

主题

秀才

Rank: 2

积分
104
 楼主| 发表于 2013-1-23 02:54:10 | 显示全部楼层 |阅读模式
Dwr的Reverse Ajax可分为两中基本的mode.一种是Active,另一种是Passive,在Active中又分为三种.
Full Streaming Mode
Early Closing Mode
Polling Mode
在DWR应用中.默认启用的是Full Streaming Mode .它是三种modes中最快的一种.它每60秒检查一次浏览器是否是活跃的.配置很简单:

<div style="border-right: #cccccc 1px solid; padding-right: 5px; padding-left: 4px; font-size: 13px; border-top: #cccccc 1px solid; padding-bottom: 4px; border-left: #cccccc 1px solid; width: 98%; padding-top: 4px; border-bottom: #cccccc 1px solid; background-color: #eeeeee;"><servlet>
  
<servlet-name>dwr-invoker</servlet-name>
  
<servlet-class>org.directwebremoting.servlet.DwrServlet</servlet-class>
  
<init-param>
   
<param-name>activeReverseAjaxEnabled</param-name>
   
<param-value>true</param-value>
  
</init-param>
</servlet>
您需要登录后才可以回帖 登录 | 立即注册 新浪微博账号登陆

本版积分规则

快速回复 返回顶部 返回列表