/**
* Convert the {@link InternetProtocolFamily}. This MUST only be called on jdk version >= 7.
*/
public static ProtocolFamily convert(InternetProtocolFamily family) {
switch (family) {
case IPv4:
return StandardProtocolFamily.INET;
case IPv6:
return StandardProtocolFamily.INET6;
default:
throw new IllegalArgumentException();
}
}
ProtocolFamilyConverter.java 文件源码
java
阅读 19
收藏 0
点赞 0
评论 0
项目:netty4.0.27Learn
作者:
评论列表
文章目录