Module org.htmlunit
Package org.htmlunit

Interface ConfirmHandler

All Superinterfaces:
Serializable
Functional Interface:
This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.

@FunctionalInterface public interface ConfirmHandler extends Serializable
A handler for the JavaScript function window.confirm(). Confirms are triggered when the JavaScript function window.confirm() is invoked.
Author:
Mike Bowler, Ronald Brill
  • Method Summary

    Modifier and Type
    Method
    Description
    boolean
    handleConfirm(Page page, String message)
    Handles a confirm for the specified page.
  • Method Details

    • handleConfirm

      boolean handleConfirm(Page page, String message)
      Handles a confirm for the specified page.
      Parameters:
      page - the page on which the confirm occurred
      message - the message in the confirm
      Returns:
      true if we are simulating clicking the OK button, false if we are simulating clicking the Cancel button