Enum Class AriaPopupType

java.lang.Object
java.lang.Enum<AriaPopupType>
com.oorian.html.aria.AriaPopupType
All Implemented Interfaces:
Serializable, Comparable<AriaPopupType>, Constable

public enum AriaPopupType extends Enum<AriaPopupType>
ARIA popup type values for the aria-haspopup attribute.

The aria-haspopup attribute indicates the availability and type of interactive popup element that can be triggered by an element. This helps assistive technologies inform users what to expect when they activate the element.

Usage:


 // Button that opens a menu
 menuButton.setAriaHasPopup(AriaPopupType.MENU);

 // Button that opens a dialog
 dialogButton.setAriaHasPopup(AriaPopupType.DIALOG);

 // Combobox with listbox popup
 combobox.setAriaHasPopup(AriaPopupType.LISTBOX);
 
Since:
2025
Version:
1.0
Author:
Marvin P. Warble Jr.
See Also:
  • Enum Constant Details

    • LISTBOX

      public static final AriaPopupType LISTBOX
      Indicates a listbox popup.
    • TREE

      public static final AriaPopupType TREE
      Indicates a tree popup.
    • GRID

      public static final AriaPopupType GRID
      Indicates a grid popup.
    • DIALOG

      public static final AriaPopupType DIALOG
      Indicates a dialog popup.
  • Method Details

    • values

      public static AriaPopupType[] values()
      Returns an array containing the constants of this enum class, in the order they are declared.
      Returns:
      an array containing the constants of this enum class, in the order they are declared
    • valueOf

      public static AriaPopupType valueOf(String name)
      Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)
      Parameters:
      name - the name of the enum constant to be returned.
      Returns:
      the enum constant with the specified name
      Throws:
      IllegalArgumentException - if this enum class has no constant with the specified name
      NullPointerException - if the argument is null
    • getValue

      public String getValue()
      Returns the aria-haspopup attribute value.
      Returns:
      The popup type value.
    • toString

      public String toString()
      Returns the aria-haspopup attribute value.
      Overrides:
      toString in class Enum<AriaPopupType>
      Returns:
      The popup type value.