最新文章列表

Spring和mima结合配置IoAccept中的sessionConfig中的属性

是不是想在使用spring配置mina的时候,配置IoAccept中的sessionConfig中的属性?比如readBufferSize和 IdleTime 如果你用java代码你会这样写: IoAcceptor acceptor=new NioSocketAcceptor(); acceptor.getSessionConfig().setReadBufferSize(2048); ac ...
maosz1982 评论(1) 有6979人浏览 2012-08-15 15:12

mina中多个filter中decoder出现的问题

Mina中使用多个filter,解码的时候总是出现问题,解码顺序似乎一直有问题。看了源码终于找到问题所在。 ProtocolCodecFilter中有一些AttributeKey,会放在IoSession中的attribute里。 private final AttributeKey ENCODER = new AttributeKey(ProtocolCodecFilter.class, &qu ...
maosz1982 评论(1) 有1284人浏览 2012-08-15 14:59

LongSentenceFilter Joshua SMT [2]

Note that the first version of LongSentenceFilter is not complete, because even after filtering there still may be French sentences of more than 100 words. Now this version tackles this problem. Note a ...
sanjewel 评论(0) 有927人浏览 2012-02-11 05:52

Mina1.1.7 Decoder逻辑

CumulativeProtocolDecoder.decode() 拿到IoSession中的ByteBuffer,如果有则设置usingSessionBuffer=true并且读取这个ByteBuffer;否则设置usingSessionBuffer=false,并且从网络流中读取ByteBuffer。 循环调用doDecode()方法进行解码,直到解码失败(doDecode返回false) ...
blueswind8306 评论(0) 有1593人浏览 2011-10-13 12:00

CumulativeProtocolDecoder 流与事件模型

  ByteBuffer 的 flip 方法,许多人都知道是写操作后,即将要开始读操作,需要flip一把。但是,compact方法,知道的人似乎比较少,它用在什么场景呢?本文就是回答这个问题的。   import java.nio.ByteBuffer; public class T { public static void main(String[] args) { ...
eyesmore 评论(0) 有3311人浏览 2011-08-01 18:31

最近博客热门TAG

Java(141747) C(73651) C++(68608) SQL(64571) C#(59609) XML(59133) HTML(59043) JavaScript(54918) .net(54785) Web(54513) 工作(54116) Linux(50906) Oracle(49876) 应用服务器(43288) Spring(40812) 编程(39454) Windows(39381) JSP(37542) MySQL(37268) 数据结构(36423)

博客人气排行榜

    博客电子书下载排行

      >>浏览更多下载

      相关资讯

      相关讨论

      Global site tag (gtag.js) - Google Analytics