public class ContextBoundUnmarshallerProvider extends DefaultUnmarshallerProvider
UnmarshallerProvider ,其存储到一个参考Unmarshaller在ChannelHandlerContext经由ChannelHandlerContext.attr(AttributeKey)方法。
所以同样Unmarshaller会期间的生活时使用Channel为ChannelHandler的ChannelHandlerContext 。
| Constructor and Description |
|---|
ContextBoundUnmarshallerProvider(org.jboss.marshalling.MarshallerFactory factory, org.jboss.marshalling.MarshallingConfiguration config) |
| Modifier and Type | Method and Description |
|---|---|
org.jboss.marshalling.Unmarshaller |
getUnmarshaller(ChannelHandlerContext ctx)
获取 Unmarshaller对于给定ChannelHandlerContext
|
public ContextBoundUnmarshallerProvider(org.jboss.marshalling.MarshallerFactory factory,
org.jboss.marshalling.MarshallingConfiguration config) public org.jboss.marshalling.Unmarshaller getUnmarshaller(ChannelHandlerContext ctx) throws java.lang.Exception
UnmarshallerProvider
Unmarshaller对于给定ChannelHandlerContext
getUnmarshaller在界面
UnmarshallerProvider
getUnmarshaller在课堂上
DefaultUnmarshallerProvider
java.lang.Exception
Copyright © 2008–2018 The Netty Project. All rights reserved.