Class InstanceEvent

  • All Implemented Interfaces:
    Serializable

    public final class InstanceEvent
    extends EventObject
    General event for notifying listeners of significant events related to a specific instance of a Servlet, or a specific instance of a Filter, as opposed to the Wrapper component that manages it.
    Version:
    $Revision: 1.2 $ $Date: 2005/12/08 01:27:17 $
    Author:
    Craig R. McClanahan
    See Also:
    Serialized Form
    • Constructor Detail

      • InstanceEvent

        public InstanceEvent​(Wrapper wrapper,
                             jakarta.servlet.Filter filter,
                             InstanceEvent.EventType type)
        Construct a new InstanceEvent with the specified parameters. This constructor is used for filter lifecycle events.
        Parameters:
        wrapper - Wrapper managing this servlet instance
        filter - Filter instance for which this event occurred
        type - Event type (required)
      • InstanceEvent

        public InstanceEvent​(Wrapper wrapper,
                             jakarta.servlet.Filter filter,
                             InstanceEvent.EventType type,
                             Throwable exception)
        Construct a new InstanceEvent with the specified parameters. This constructor is used for filter lifecycle events.
        Parameters:
        wrapper - Wrapper managing this servlet instance
        filter - Filter instance for which this event occurred
        type - Event type (required)
        exception - Exception that occurred
      • InstanceEvent

        public InstanceEvent​(Wrapper wrapper,
                             jakarta.servlet.Filter filter,
                             InstanceEvent.EventType type,
                             jakarta.servlet.ServletRequest request,
                             jakarta.servlet.ServletResponse response)
        Construct a new InstanceEvent with the specified parameters. This constructor is used for filter processing events.
        Parameters:
        wrapper - Wrapper managing this servlet instance
        filter - Filter instance for which this event occurred
        type - Event type (required)
        request - Servlet request we are processing
        response - Servlet response we are processing
      • InstanceEvent

        public InstanceEvent​(Wrapper wrapper,
                             jakarta.servlet.Filter filter,
                             InstanceEvent.EventType type,
                             jakarta.servlet.ServletRequest request,
                             jakarta.servlet.ServletResponse response,
                             Throwable exception)
        Construct a new InstanceEvent with the specified parameters. This constructor is used for filter processing events.
        Parameters:
        wrapper - Wrapper managing this servlet instance
        filter - Filter instance for which this event occurred
        type - Event type (required)
        request - Servlet request we are processing
        response - Servlet response we are processing
        exception - Exception that occurred
      • InstanceEvent

        public InstanceEvent​(Wrapper wrapper,
                             jakarta.servlet.Servlet servlet,
                             InstanceEvent.EventType type)
        Construct a new InstanceEvent with the specified parameters. This constructor is used for processing servlet lifecycle events.
        Parameters:
        wrapper - Wrapper managing this servlet instance
        servlet - Servlet instance for which this event occurred
        type - Event type (required)
      • InstanceEvent

        public InstanceEvent​(Wrapper wrapper,
                             jakarta.servlet.Servlet servlet,
                             InstanceEvent.EventType type,
                             Throwable exception)
        Construct a new InstanceEvent with the specified parameters. This constructor is used for processing servlet lifecycle events.
        Parameters:
        wrapper - Wrapper managing this servlet instance
        servlet - Servlet instance for which this event occurred
        type - Event type (required)
        exception - Exception that occurred
      • InstanceEvent

        public InstanceEvent​(Wrapper wrapper,
                             jakarta.servlet.Servlet servlet,
                             InstanceEvent.EventType type,
                             jakarta.servlet.ServletRequest request,
                             jakarta.servlet.ServletResponse response)
        Construct a new InstanceEvent with the specified parameters. This constructor is used for processing servlet processing events.
        Parameters:
        wrapper - Wrapper managing this servlet instance
        servlet - Servlet instance for which this event occurred
        type - Event type (required)
        request - Servlet request we are processing
        response - Servlet response we are processing
      • InstanceEvent

        public InstanceEvent​(Wrapper wrapper,
                             jakarta.servlet.Servlet servlet,
                             InstanceEvent.EventType type,
                             jakarta.servlet.ServletRequest request,
                             jakarta.servlet.ServletResponse response,
                             Throwable exception)
        Construct a new InstanceEvent with the specified parameters. This constructor is used for processing servlet processing events.
        Parameters:
        wrapper - Wrapper managing this servlet instance
        servlet - Servlet instance for which this event occurred
        type - Event type (required)
        request - Servlet request we are processing
        response - Servlet response we are processing
        exception - Exception that occurred
    • Method Detail

      • getException

        public Throwable getException()
        Return the exception that occurred during the processing that was reported by this event.
      • getFilter

        public jakarta.servlet.Filter getFilter()
        Return the filter instance for which this event occurred.
      • getRequest

        public jakarta.servlet.ServletRequest getRequest()
        Return the servlet request for which this event occurred.
      • getResponse

        public jakarta.servlet.ServletResponse getResponse()
        Return the servlet response for which this event occurred.
      • getServlet

        public jakarta.servlet.Servlet getServlet()
        Return the servlet instance for which this event occurred.
      • getWrapper

        public Wrapper getWrapper()
        Return the Wrapper managing the servlet instance for which this event occurred.