Class BootstrapSwitch


  • public class BootstrapSwitch
    extends Object
    Wrap a bootstrap switch widget (http://bootstrapswitch.com/).
    Since:
    9.7RC1
    Version:
    $Id: a7eeda215888545e645600a42faac1f37ebbdbc4 $
    • Constructor Detail

      • BootstrapSwitch

        public BootstrapSwitch​(org.openqa.selenium.WebElement webElement,
                               XWikiWebDriver driver)
        Construct a bootstrap switch.
        Parameters:
        webElement - the element the the wrapper will handle
        driver - the xwiki web driver
    • Method Detail

      • click

        public void click()
        Click on the switch.
      • setState

        public void setState​(BootstrapSwitch.State wantedState)
                      throws Exception
        Set the state of the switch with the given value.
        Parameters:
        wantedState - the expected state
        Throws:
        Exception - if the expected state cannot be set
      • isEnabled

        public boolean isEnabled()
        Returns:
        either or not the input is enabled (meaning we can click on it)
        Since:
        10.8RC1, 9.11.8