Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

iconnection建议增加一addclosecallback接口和removeclosecallback接口。 #253

Open
ayamzh opened this issue Jul 18, 2023 · 3 comments

Comments

@ayamzh
Copy link

ayamzh commented Jul 18, 2023

方便于关闭连接时做一些业务层后处理

@aceld
Copy link
Owner

aceld commented Jul 20, 2023

请问这个callback是加载 server 对 client的socket 执行Close()之后么 , client是否还需要添加对close()之后的callBack?

@aceld
Copy link
Owner

aceld commented Jul 20, 2023

方便于关闭连接时做一些业务层后处理

这是一个十分好的建议

@ayamzh
Copy link
Author

ayamzh commented Aug 28, 2023

请问这个callback是加载 server 对 client的socket 执行Close()之后么 , client是否还需要添加对close()之后的callBack?

对,server执行conn.close时,可以在ICONECTION里提供给业务层一个STOP方法来执行所有callback和conn的close。业务层不要直接操作 conn的close。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants