简体   繁体   English

HttpSession invalidate()实际如何工作?

[英]How does HttpSession invalidate() actually work?

in documentation it says: 在文档中说:

public void invalidate() 公共无效invalidate()

Invalidates this session then unbinds any objects bound to it. 使该会话无效,然后取消绑定到该会话的任何对象。

Does that mean that just the references to the attribute objects are removed or the objects themselves are destroyed ? 这是否意味着仅删除对属性对象的引用,或者销毁对象本身?

Thanks 谢谢

invalidate方法使Web应用程序容器解除绑定(而不是销毁)Web应用程序对HttpSession Object的所有引用,然后销毁(从JVM中删除)HttpSession Object。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM