Class HttpSessionRequiredException

All Implemented Interfaces:
Serializable

public class HttpSessionRequiredException extends ServletException
Exception thrown when an HTTP request handler requires a pre-existing session.
Since:
2.0
Author:
Juergen Hoeller
See Also:
  • Constructor Details

    • HttpSessionRequiredException

      public HttpSessionRequiredException(String msg)
      Create a new HttpSessionRequiredException.
      Parameters:
      msg - the detail message
    • HttpSessionRequiredException

      public HttpSessionRequiredException(String msg, String expectedAttribute)
      Create a new HttpSessionRequiredException.
      Parameters:
      msg - the detail message
      expectedAttribute - the name of the expected session attribute
      Since:
      4.3
  • Method Details

    • getExpectedAttribute

      @Nullable public String getExpectedAttribute()
      Return the name of the expected session attribute, if any.
      Since:
      4.3