Share this page

com.hp.lft.sdk.web

## Class MenuDescription

- java.lang.Object
- - com.hp.lft.sdk.internal.PropertiesDescriptionBase
  - - com.hp.lft.sdk.PropertiesDescription
    - - com.hp.lft.sdk.DescriptionBase
      - - com.hp.lft.sdk.web.WebBaseDescription
        - - com.hp.lft.sdk.web.WebElementDescription
          - - com.hp.lft.sdk.web.MenuDescription

- All Implemented Interfaces:
    CloneableObject, Description, com.hp.lft.sdk.internal.DescriptionWithVri, java.lang.Cloneable

      public class MenuDescription
      extends WebElementDescription

  The description of a Web Menu test object.

- - ### Nested Class Summary

    Modifier and Type | Class and Description
    --- | ---
    `static class` | `MenuDescription.Builder` This class can be used to construct an instance of the MenuDescription class using the builder pattern.
    `protected static class` | `MenuDescription.Init<T extends MenuDescription.Init<T>>` Helper class for MenuDescription.Builder.

  - ### Field Summary

    - ### Fields inherited from class com.hp.lft.sdk.internal.PropertiesDescriptionBase

      `properties`

  - ### Constructor Summary

    Modifier | Constructor and Description
    --- | ---
    `` | `MenuDescription()` Initializes a new instance of the MenuDescription class.
    `protected` | `MenuDescription(MenuDescription.Init<?> init)` Initializes a new instance of the MenuDescription class using the Builder pattern.

  - ### Method Summary

    Modifier and Type | Method and Description
    --- | ---
    `StringProperty` | `getFirstMenuItem()` Returns the first item in the list of items in this menu.
    `java.lang.String[]` | `getTopLevelMenuItems()` Returns a collection of all top level menu items in this menu, separated by semi-colons (;).
    `java.lang.Integer` | `getTopLevelMenuItemsCount()` Returns the number of top level menu items contained in this menu.
    `void` | `setFirstMenuItem(java.lang.String firstMenuItem)` Sets the first item in the list of items in this menu.
    `void` | `setFirstMenuItem(StringProperty firstMenuItem)` Sets the first item in the list of items in this menu.
    `void` | `setTopLevelMenuItems(java.lang.String[] topLevelMenuItems)` Sets the top level menu items in this object.
    `void` | `setTopLevelMenuItemsCount(java.lang.Integer topLevelMenuItemsCount)` Sets the number of top level menu items contained in this menu.

    - ### Methods inherited from class com.hp.lft.sdk.web.WebElementDescription

      `getAccessibilityName, getCSSSelector, getRole, getXPath, setAccessibilityName, setAccessibilityName, setCSSSelector, setCSSSelector, setRole, setRole, setXPath, setXPath`

    - ### Methods inherited from class com.hp.lft.sdk.web.WebBaseDescription

      `cloneTo, getAbsoluteLocation, getAttributes, getClassName, getId, getInnerHTML, getInnerText, getLocation, getName, getOuterHTML, getOuterText, getSize, getStyles, getTagName, getTitle, isVisible, setAbsoluteLocation, setAbsoluteLocation, setAbsoluteLocation, setAttributes, setClassName, setClassName, setId, setId, setInnerHTML, setInnerHTML, setInnerText, setInnerText, setLocation, setLocation, setLocation, setName, setName, setOuterHTML, setOuterHTML, setOuterText, setOuterText, setSize, setSize, setSize, setStyles, setTagName, setTagName, setTitle, setTitle, setVisible`

    - ### Methods inherited from class com.hp.lft.sdk.DescriptionBase

      `getIndex, getIndexType, getVRI, setIndex, setIndexType, setVRI, setVRI`

    - ### Methods inherited from class com.hp.lft.sdk.PropertiesDescription

      `clone`

    - ### Methods inherited from class com.hp.lft.sdk.internal.PropertiesDescriptionBase

      `getValueAs, getValueAsStringProperty, insertValue`

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

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

    - ### Methods inherited from interface com.hp.lft.sdk.CloneableObject

      `clone`

- - ### Constructor Detail

    - #### MenuDescription

          public MenuDescription()

      Initializes a new instance of the MenuDescription class.

    - #### MenuDescription

          protected MenuDescription(MenuDescription.Init<?> init)

      Initializes a new instance of the MenuDescription class using the Builder pattern.
      Parameters:
        `init` - the Builder pattern.

  - ### Method Detail

    - #### setTopLevelMenuItemsCount

          public void setTopLevelMenuItemsCount(java.lang.Integer topLevelMenuItemsCount)

      Sets the number of top level menu items contained in this menu.
      Parameters:
        `topLevelMenuItemsCount` - the number of top level menu items in this menu.

    - #### getTopLevelMenuItemsCount

          public java.lang.Integer getTopLevelMenuItemsCount()

      Returns the number of top level menu items contained in this menu.
      Returns:
        The number of top level menu items contained in this menu.

    - #### setTopLevelMenuItems

          public void setTopLevelMenuItems(java.lang.String[] topLevelMenuItems)

      Sets the top level menu items in this object.
      Parameters:
        `topLevelMenuItems` - the top level menu items in this menu.

    - #### getTopLevelMenuItems

          public java.lang.String[] getTopLevelMenuItems()

      Returns a collection of all top level menu items in this menu, separated by semi-colons (;).
      Returns:
        A collection of all top level menu items in this menu, separated by semi-colons (;).

    - #### setFirstMenuItem

          public void setFirstMenuItem(StringProperty firstMenuItem)

      Sets the first item in the list of items in this menu.
      Parameters:
        `firstMenuItem` - a StringProperty (or RegExpProperty) representing the first item in the list of items in this menu.

    - #### setFirstMenuItem

          public void setFirstMenuItem(java.lang.String firstMenuItem)

      Sets the first item in the list of items in this menu.
      Parameters:
        `firstMenuItem` - the first item in the list of items in this menu.

    - #### getFirstMenuItem

          public StringProperty getFirstMenuItem()

      Returns the first item in the list of items in this menu.
      Returns:
        the first item in the list of items in this menu.

Tips to improve your search results... UFT Developer Java SDK Reference Version 15.0-15.0.2 UFT Developer SDK Reference All View Local Help Center View Online Help Center back Go back in browser history forward Go forward in browser history Remove search highlights next topic Go to next topic previous topic Go to previous topic Print the current topic Version: