mirror of
https://github.com/tiennm99/zfoo.git
synced 2026-10-12 12:14:21 +00:00
perf[protocol]: 简化获取ProtocolRegistration,提高性能
This commit is contained in:
1 parent
df210f968d
commit
4a188eb565
1 file changed
+1
-3
@@ -70,9 +70,7 @@ public class ProtocolManager {
|
||||
}
|
||||
|
||||
public static IProtocolRegistration getProtocol(short protocolId) {
|
||||
var protocol = protocols[protocolId];
|
||||
AssertionUtils.notNull(protocol, "[protocolId:{}]协议不存在,可能没有注册该协议或者协议号错误", protocolId);
|
||||
return protocol;
|
||||
return protocols[protocolId];
|
||||
}
|
||||
|
||||
public static ProtocolModule moduleByProtocolId(short id) {
|
||||
|
||||
Reference in new issue
Block a user