本文整理汇总了Java中org.sdnplatform.sync.internal.rpc.SyncMessageDecoder类的典型用法代码示例。如果您正苦于以下问题:Java SyncMessageDecoder类的具体用法?Java SyncMessageDecoder怎么用?Java SyncMessageDecoder使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
SyncMessageDecoder类属于org.sdnplatform.sync.internal.rpc包,在下文中一共展示了SyncMessageDecoder类的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: initChannel
import org.sdnplatform.sync.internal.rpc.SyncMessageDecoder; //导入依赖的package包/类
@Override
protected void initChannel(Channel ch) throws Exception {
BootstrapChannelHandler handler =
new BootstrapChannelHandler(bootstrap);
ChannelPipeline pipeline = ch.pipeline();
pipeline.addLast("syncMessageDecoder", new SyncMessageDecoder(maxFrameSize));
pipeline.addLast("syncMessageEncoder", new SyncMessageEncoder());
pipeline.addLast("timeout", new BootstrapTimeoutHandler(timer, 10));
pipeline.addLast("handler", handler);
}
示例2: initChannel
import org.sdnplatform.sync.internal.rpc.SyncMessageDecoder; //导入依赖的package包/类
@Override
protected void initChannel(Channel ch) throws Exception {
RemoteSyncChannelHandler channelHandler =
new RemoteSyncChannelHandler(syncManager);
ChannelPipeline pipeline = ch.pipeline();
pipeline.addLast("syncMessageDecoder", new SyncMessageDecoder(maxFrameSize));
pipeline.addLast("syncMessageEncoder", new SyncMessageEncoder());
pipeline.addLast("timeout", new RSHandshakeTimeoutHandler(channelHandler, timer, 3));
pipeline.addLast("handler", channelHandler);
}