MCPcopy Create free account
hub / github.com/e2wugui/zeze / OnSocketClose

Method OnSocketClose

ZezeJava/ZezeJava/src/main/java/Zeze/Net/Service.java:334–342  ·  view source on GitHub ↗

ASocket 关闭的时候总是回调。 @param so closing socket @param e caught exception, null for none.

(@NotNull AsyncSocket so, @Nullable Throwable e)

Source from the content-addressed store, hash-verified

332 * @param e caught exception, null for none.
333 */
334 public void OnSocketClose(@NotNull AsyncSocket so, @Nullable Throwable e) throws Exception {
335 if (socketMap.remove(so.getSessionId(), so)) {
336 closedRecvCountHandle.getAndAdd(this, so.getRecvCount());
337 closedRecvSizeHandle.getAndAdd(this, so.getRecvSize());
338 closedSendCountHandle.getAndAdd(this, so.getSendCount());
339 closedSendSizeHandle.getAndAdd(this, so.getSendSize());
340 closedSendRawSizeHandle.getAndAdd(this, so.getSendRawSize());
341 }
342 }
343
344 /**
345 * 可靠rpc调用:一般用于重新发送没有返回结果的rpc。

Callers 3

closeMethod · 0.45
closeMethod · 0.45
closeMethod · 0.45

Calls 7

removeMethod · 0.65
getSessionIdMethod · 0.65
getRecvCountMethod · 0.45
getRecvSizeMethod · 0.45
getSendCountMethod · 0.45
getSendSizeMethod · 0.45
getSendRawSizeMethod · 0.45

Tested by

no test coverage detected