Package org.htmlunit

Interface AlertHandler

  • All Superinterfaces:
    java.io.Serializable
    All Known Implementing Classes:
    CollectingAlertHandler

    public interface AlertHandler
    extends java.io.Serializable
    A handler for JavaScript alerts. Alerts are triggered when the JavaScript method Window.alert() is called.
    • Method Detail

      • handleAlert

        void handleAlert​(Page page,
                         java.lang.String message)
        Handle an alert for the given page.
        Parameters:
        page - the page on which the alert occurred
        message - the message in the alert