接口 WebSessionAttributeListener

所有超级接口:
EventListener
所有已知实现类:
SessionScope.DestructionCallback

public interface WebSessionAttributeListener extends EventListener
This listener interface can be implemented in order to get notifications of changes to the attribute lists of sessions within this web application.
从以下版本开始:
4.0 2022/10/30 14:37
作者:
Harry Yang
  • 方法详细资料

    • attributeAdded

      default void attributeAdded(WebSession session, String attributeName, Object value)
      Notification that an attribute has been added to a session. Called after the attribute is added. The default implementation is a NO-OP.
      参数:
      session - web session to hold this attribute
      attributeName - name of attribute
      value - attribute value
    • attributeRemoved

      default void attributeRemoved(WebSession session, String attributeName, @Nullable Object value)
      Notification that an attribute has been removed from a session. Called after the attribute is removed. The default implementation is a NO-OP.
      参数:
      session - web session to hold this attribute
      attributeName - name of attribute
      value - attribute value
    • attributeReplaced

      default void attributeReplaced(WebSession session, String attributeName, Object oldValue, Object newValue)
      Notification that an attribute has been replaced in a session. Called after the attribute is replaced. The default implementation is a NO-OP.
      参数:
      session - web session to hold this attribute
      attributeName - name of attribute
      oldValue - old attribute value
      newValue - new attribute value