org.richfaces.fragment.contextMenu

## Class AbstractPopupMenu.AdvancedPopupMenuInteractions

- java.lang.Object
- - org.richfaces.fragment.contextMenu.AbstractPopupMenu.AdvancedPopupMenuInteractions

- All Implemented Interfaces:
    VisibleComponentInteractions
  Direct Known Subclasses:
    RichFacesContextMenu.AdvancedContextMenuInteractions, RichFacesDropDownMenu.AdvancedDropDownMenuInteractions
  Enclosing class:
    AbstractPopupMenu

      public abstract class AbstractPopupMenu.AdvancedPopupMenuInteractions
      extends Object
      implements VisibleComponentInteractions

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `AdvancedPopupMenuInteractions()`

  - ### Method Summary

    All Methods Instance Methods Abstract Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `protected Event` | `getDefaultShowEvent()`
    `List<org.openqa.selenium.WebElement>` | `getItemsElements()` Returns menu items elements.
    `abstract List<org.openqa.selenium.WebElement>` | `getMenuItemElements()` Returns all elements of this menu
    `abstract org.openqa.selenium.WebElement` | `getMenuPopup()`
    `protected abstract org.openqa.selenium.WebElement` | `getScriptElement()`
    `protected int` | `getShowDelay()`
    `protected Event` | `getShowEvent()`
    `org.openqa.selenium.WebElement` | `getTargetElement()`
    `long` | `getTimeoutForPopupMenuToBeNotVisible()`
    `long` | `getTimeoutForPopupMenuToBeVisible()`
    `void` | `hide()` Dismisses currently displayed popup menu.
    `boolean` | `isVisible()`
    `void` | `setHideDelay()`
    `void` | `setHideDelay(int newHideDelayInMillis)` Delay (in ms) between losing focus and menu closing
    `void` | `setShowDelay()`
    `void` | `setShowDelay(int newShowDelayInMillis)` Sets the delay which is between showevent observing and the menu opening
    `void` | `setShowEvent()`
    `void` | `setShowEvent(Event newShowEvent)`
    `void` | `setShowEventFromWidget()`
    `void` | `setTarget()`
    `void` | `setTarget(org.openqa.selenium.WebElement target)`
    `void` | `setTargetFromWidget()`
    `void` | `setTimeoutForPopupMenuToBeNotVisible(long timeoutInMilliseconds)`
    `void` | `setTimeoutForPopupMenuToBeVisible(long timeoutInMilliseconds)`
    `void` | `show()` Invokes popup menu in the middle of the currently set target.
    `void` | `show(org.openqa.selenium.WebElement givenTarget)` Invokes popup menu in the middle of the given target.
    `void` | `show(org.openqa.selenium.WebElement givenTarget, org.openqa.selenium.Point location)` Invokes popup menu on a given point within the given target.
    `WaitingWrapper` | `waitUntilIsNotVisible()` Waits until the popup menu is visible.
    `WaitingWrapper` | `waitUntilIsVisible()`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### AdvancedPopupMenuInteractions

          public AdvancedPopupMenuInteractions()

  - ### Method Detail

    - #### hide

          public void hide()

      Dismisses currently displayed popup menu. If no popup menu is currently displayed an exception is thrown.
      Throws:
        `IllegalStateException` - when no popup menu is displayed in the time of invoking

    - #### getItemsElements

          public List<org.openqa.selenium.WebElement> getItemsElements()

      Returns menu items elements. One needs to invoke popup menu in order to work with them. Note that some of the elements may not become visible by just invoking the popup menu (e.g. popup menu items with sub items)
      Returns:
        the popup menu items

    - #### getMenuItemElements

          public abstract List<org.openqa.selenium.WebElement> getMenuItemElements()

      Returns all elements of this menu
      Returns:

    - #### getScriptElement

          protected abstract org.openqa.selenium.WebElement getScriptElement()

    - #### getMenuPopup

          public abstract org.openqa.selenium.WebElement getMenuPopup()

    - #### getShowDelay

          protected int getShowDelay()

    - #### getTargetElement

          public org.openqa.selenium.WebElement getTargetElement()

    - #### show

          public void show()

      Invokes popup menu in the middle of the currently set target. By default it is presumed that popup menu is invoked by right click. To change this behavior use `setInvoker()` method. You have to have a target set before invocation of this method.
      See Also:
        `#setInvoker(PopupMenuInvoker)`, `setTarget(WebElement)`

    - #### show

          public void show(org.openqa.selenium.WebElement givenTarget)

      Invokes popup menu in the middle of the given target. By default it is presumed that popup menu is invoked by right click. To change this behavior use `setInvoker()` method. It also works with the default value of `showDelay == 50ms`. Use `#setShowDelay` if this value is different for this menu.
      Parameters:
        `givenTarget` -
      See Also:
        `#setupInvoker(PopupMenuInvoker)`, `setShowDelay(int)`

    - #### show

          public void show(org.openqa.selenium.WebElement givenTarget,
                           org.openqa.selenium.Point location)

      Invokes popup menu on a given point within the given target. By default it is presumed that popup menu is invoked by right click. To change this behavior use `setInvoker()` method.
      Parameters:
        `givenTarget` -
        `location` -
      See Also:
        `#setupInvoker(PopupMenuInvoker)`

    - #### setHideDelay

          public void setHideDelay()

    - #### setHideDelay

          public void setHideDelay(int newHideDelayInMillis)

      Delay (in ms) between losing focus and menu closing
      Parameters:
        `newHideDelayInMillis` -

    - #### getDefaultShowEvent

          protected Event getDefaultShowEvent()

    - #### getShowEvent

          protected Event getShowEvent()

    - #### setShowEvent

          public void setShowEvent()

    - #### setShowEvent

          public void setShowEvent(Event newShowEvent)

    - #### setShowEventFromWidget

          public void setShowEventFromWidget()

    - #### setShowDelay

          public void setShowDelay()

    - #### setShowDelay

          public void setShowDelay(int newShowDelayInMillis)

      Sets the delay which is between showevent observing and the menu opening
      Parameters:
        `newShowDelayInMillis` -

    - #### setTarget

          public void setTarget()

    - #### setTarget

          public void setTarget(org.openqa.selenium.WebElement target)

    - #### setTargetFromWidget

          public void setTargetFromWidget()

    - #### setTimeoutForPopupMenuToBeNotVisible

          public void setTimeoutForPopupMenuToBeNotVisible(long timeoutInMilliseconds)

    - #### getTimeoutForPopupMenuToBeNotVisible

          public long getTimeoutForPopupMenuToBeNotVisible()

    - #### setTimeoutForPopupMenuToBeVisible

          public void setTimeoutForPopupMenuToBeVisible(long timeoutInMilliseconds)

    - #### getTimeoutForPopupMenuToBeVisible

          public long getTimeoutForPopupMenuToBeVisible()

    - #### waitUntilIsNotVisible

          public WaitingWrapper waitUntilIsNotVisible()

      Waits until the popup menu is visible. It takes into account the `showDelay` which has default value 50ms.
      See Also:
        `setShowDelay(int)`

    - #### waitUntilIsVisible

          public WaitingWrapper waitUntilIsVisible()

    - #### isVisible

          public boolean isVisible()

      Specified by:
        `isVisible` in interface `VisibleComponentInteractions`

Copyright © 2015 JBoss by Red Hat. All Rights Reserved.