本文整理匯總了Java中io.netty.channel.ChannelHandlerContext.executor方法的典型用法代碼示例。如果您正苦於以下問題:Java ChannelHandlerContext.executor方法的具體用法?Java ChannelHandlerContext.executor怎麽用?Java ChannelHandlerContext.executor使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類io.netty.channel.ChannelHandlerContext
的用法示例。
在下文中一共展示了ChannelHandlerContext.executor方法的1個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。
示例1: channelActive
import io.netty.channel.ChannelHandlerContext; //導入方法依賴的package包/類
@Override
public void channelActive ( final ChannelHandlerContext ctx ) throws Exception
{
logger.debug ( "Channel active - {}", ctx );
// we may and must remember the channel context, to know were to send notifications to
this.ctx = ctx;
this.source = new DataModuleMessageSource ( this.options, ctx.executor (), new ContextChannelWriter ( ctx ), this.dataModel, this.backgroundScanPeriod );
this.messageChannel.addSource ( this.source );
this.spontHandler = new DataListenerImpl ( this.source, new CauseOfTransmission ( StandardCause.SPONTANEOUS ) );
super.channelActive ( ctx );
}