All Implemented Interfaces:
TagBase, GlobalAttributable, Serializable, Cloneable

public class Role extends AbstractAttribute implements GlobalAttributable
The role value can be any Role.*, for eg Role.BUTTON. Refer http://w3c.github.io/html/dom.html#global-aria--attributes for more info
Since:
2.0.1
See Also:
  • Field Details

    • ANY

      public static final String ANY
      ARIA global states and properties can be used on any HTML element.
      See Also:
    • ALERT

      public static final String ALERT
      A message with important, and usually time-sensitive, information.
      See Also:
    • ALERTDIALOG

      public static final String ALERTDIALOG
      A type of dialog that contains an alert message, where initial focus goes to an element within the dialog.
      See Also:
    • APPLICATION

      public static final String APPLICATION
      A region declared as a web application, as opposed to a web document.
      See Also:
    • ARTICLE

      public static final String ARTICLE
      A section of a page that consists of a composition that forms an independent part of a document, page, or site.
      See Also:
    • BUTTON

      public static final String BUTTON
      An input that allows for user-triggered actions when clicked or pressed.
      See Also:
    • CHECKBOX

      public static final String CHECKBOX
      A checkable input that has three possible values: true, false, or mixed.
      See Also:
    • COLUMNHEADER

      public static final String COLUMNHEADER
      A cell containing header information for a column.
      See Also:
    • COMBOBOX

      public static final String COMBOBOX
      A presentation of a select; usually similar to a textbox where users can type ahead to select an option, or type to enter arbitrary text as a new item in the list. See related listbox.
      See Also:
    • COMPLEMENTARY

      public static final String COMPLEMENTARY
      A supporting section of the document, designed to be complementary to the main content at a similar level in the DOM hierarchy, but remains meaningful when separated from the main content.
      See Also:
    • CONTENTINFO

      public static final String CONTENTINFO
      A large perceivable region that contains information about the parent document.
      See Also:
    • DEFINITION

      public static final String DEFINITION
      A definition of a term or concept.
      See Also:
    • DIALOG

      public static final String DIALOG
      A dialog is an application window that is designed to interrupt the current processing of an application in order to prompt the user to enter information or require a response.
      See Also:
    • DIRECTORY

      public static final String DIRECTORY
      A list of references to members of a group, such as a static table of contents.
      See Also:
    • DOCUMENT

      public static final String DOCUMENT
      A region containing related information that is declared as document content, as opposed to a web application.
      See Also:
    • FORM

      public static final String FORM
      A landmark region that contains a collection of items and objects that, as a whole, combine to create a form.
      See Also:
    • GRID

      public static final String GRID
      A grid is an interactive control which contains cells of tabular data arranged in rows and columns, like a table.
      See Also:
    • GRIDCELL

      public static final String GRIDCELL
      A cell in a grid or treegrid.
      See Also:
    • GROUP

      public static final String GROUP
      A set of user interface objects which are not intended to be included in a page summary or table of contents by assistive technologies.
      See Also:
    • HEADING

      public static final String HEADING
      A heading for a section of the page.
      See Also:
    • IMG

      public static final String IMG
      A container for a collection of elements that form an image.
      See Also:
    • LIST

      public static final String LIST
      A group of non-interactive list items.
      See Also:
    • LISTBOX

      public static final String LISTBOX
      A widget that allows the user to select one or more items from a list of choices.
      See Also:
    • LISTITEM

      public static final String LISTITEM
      A single item in a list or directory.
      See Also:
    • LOG

      public static final String LOG
      A type of live region where new information is added in meaningful order and old information may disappear.
      See Also:
    • MAIN

      public static final String MAIN
      The main content of a document.
      See Also:
    • MARQUEE

      public static final String MARQUEE
      A type of live region where non-essential information changes frequently.
      See Also:
    • MATH

      public static final String MATH
      Content that represents a mathematical expression.
      See Also:
    • NOTE

      public static final String NOTE
      A section whose content is parenthetic or ancillary to the main content of the resource.
      See Also:
    • OPTION

      public static final String OPTION
      A selectable item in a select list.
      See Also:
    • PRESENTATION

      public static final String PRESENTATION
      An element whose implicit native role semantics will not be mapped to the accessibility API.
      See Also:
    • PROGRESSBAR

      public static final String PROGRESSBAR
      An element that displays the progress status for tasks that take a long time.
      See Also:
    • RADIO

      public static final String RADIO
      A checkable input in a group of radio roles, only one of which can be checked at a time.
      See Also:
    • RADIOGROUP

      public static final String RADIOGROUP
      A group of radio buttons.
      See Also:
    • REGION

      public static final String REGION
      A large perceivable section of a web page or document, that the author feels is important enough to be included in a page summary or table of contents, for example, an area of the page containing live sporting event statistics.
      See Also:
    • ROW

      public static final String ROW
      A row of cells in a grid.
      See Also:
    • ROWGROUP

      public static final String ROWGROUP
      A group containing one or more row elements in a grid.
      See Also:
    • ROWHEADER

      public static final String ROWHEADER
      A cell containing header information for a row in a grid.
      See Also:
    • SCROLLBAR

      public static final String SCROLLBAR
      A graphical object that controls the scrolling of content within a viewing area, regardless of whether the content is fully displayed within the viewing area.
      See Also:
    • SEPARATOR

      public static final String SEPARATOR
      A divider that separates and distinguishes sections of content or groups of menuitems.
      See Also:
    • SLIDER

      public static final String SLIDER
      A user input where the user selects a value from within a given range.
      See Also:
    • SPINBUTTON

      public static final String SPINBUTTON
      A form of range that expects the user to select from among discrete choices.
      See Also:
    • STATUS

      public static final String STATUS
      A container whose content is advisory information for the user but is not important enough to justify an alert, often but not necessarily presented as a status bar.
      See Also:
    • TAB

      public static final String TAB
      A grouping label providing a mechanism for selecting the tab content that is to be rendered to the user.
      See Also:
    • TABLIST

      public static final String TABLIST
      A list of tab elements, which are references to tabpanel elements.
      See Also:
    • TABPANEL

      public static final String TABPANEL
      A container for the resources associated with a tab, where each tab is contained in a tablist.
      See Also:
    • TEXTBOX

      public static final String TEXTBOX
      Input that allows free-form text as its value.
      See Also:
    • TIMER

      public static final String TIMER
      A type of live region containing a numerical counter which indicates an amount of elapsed time from a start point, or the time remaining until an end point.
      See Also:
    • TOOLBAR

      public static final String TOOLBAR
      A collection of commonly used function buttons represented in compact visual form.
      See Also:
    • TOOLTIP

      public static final String TOOLTIP
      A contextual popup that displays a description for an element.
      See Also:
    • TREE

      public static final String TREE
      A type of list that may contain sub-level nested groups that can be collapsed and expanded.
      See Also:
    • TREEGRID

      public static final String TREEGRID
      A grid whose rows can be expanded and collapsed in the same manner as for a tree.
      See Also:
    • TREEITEM

      public static final String TREEITEM
      An option item of a tree. This is an element within a tree that may be expanded or collapsed if it contains a sub-level group of treeitems.
      See Also:
  • Constructor Details

    • Role

      public Role(String value)
      Parameters:
      value - the value for the attribute
      Since:
      2.0.1
  • Method Details

    • setValue

      public void setValue(String value)
      sets the value for this attribute
      Parameters:
      value - the value for the attribute.
      Since:
      2.0.1
    • setValue

      public void setValue(boolean updateClient, String value)
      sets the value for this attribute
      Parameters:
      updateClient - true to update client browser page if it is available. The default value is true but it will be ignored if there is no client browser page.
      value - the value for the attribute.
      Since:
      2.1.15
    • getValue

      public String getValue()
      gets the value of this attribute
      Returns:
      the value of the attribute
      Since:
      2.0.1
    • init

      protected void init()
      invokes only once per object
      Since:
      2.0.1