Class HTMLLabelElement

All Implemented Interfaces:
Serializable, Cloneable, org.htmlunit.corejs.javascript.ConstProperties, org.htmlunit.corejs.javascript.debug.DebuggableObject, org.htmlunit.corejs.javascript.Scriptable, org.htmlunit.corejs.javascript.SymbolScriptable

public class HTMLLabelElement extends HTMLElement
A JavaScript object for HTMLLabelElement.
See Also:
  • Constructor Details

    • HTMLLabelElement

      public HTMLLabelElement()
      Creates an instance.
  • Method Details

    • jsConstructor

      public void jsConstructor()
      JavaScript constructor.
      Overrides:
      jsConstructor in class HTMLElement
    • getHtmlFor

      public String getHtmlFor()
      Retrieves the object to which the given label object is assigned.
      Returns:
      the identifier of the element to which the label element is assigned
    • setHtmlFor

      public void setHtmlFor(String id)
      Sets or retrieves the object to which the given label object is assigned.
      Parameters:
      id - Specifies the identifier of the element to which the label element is assigned
      See Also:
    • getControl

      public HTMLElement getControl()
      Returns:
      the HTMLElement labeled by the given label object
    • getForm

      public HTMLFormElement getForm()
      Returns the value of the JavaScript form attribute.
      Overrides:
      getForm in class HTMLElement
      Returns:
      the value of the JavaScript form attribute