Open topic with navigation

com.hp.lft.sdk.web

## Interface WebTestObject

- All Superinterfaces:
    LocationInfoProvider, SupportsNativeObject, TestObjectDescriber, VisibleProvider, WaitUntilVisibleProvider, WebTestObjectDescriber
  All Known Subinterfaces:
    Accordion, Area, AudioControl, Button, Button, Calendar, Carousel, CheckBox, CheckBox, DatePicker, DateTimeInput, Dialog, EditField, EditField, FacetFilter, FileField, Frame, Header, Image, Label, Link, ListBox, ListBox, Menu, Menu, Menubar, NavigationBar, NotificationBar, NumericField, Paginator, Password, RadioButton, RadioGroup, RadioGroup, RatingIndicator, RoadMap, RowRepeater, Slider, Table, Table, TabStrip, TabStrip, Tile, ToggleButton, ToolBar, TreeView, TreeView, VideoControl, WebElement

      public interface WebTestObject
      extends LocationInfoProvider, WebTestObjectDescriber, SupportsNativeObject

  A generic Web test object used only for implementation. Do not use to describe a concrete web test object.

- - ### Method Summary

    Modifier and Type | Method and Description
    --- | ---
    `java.lang.String` | `getAttribute(java.lang.String attributeName)` Returns the value of a single attribute.
    `java.util.Map<java.lang.String,java.lang.String>` | `getAttributes()` Returns a copy of the collection of attributes that is attached to the element, for example, "id","class",etc.
    `java.lang.String` | `getClassName()` Returns the element's CSS class.
    `java.lang.String` | `getComputedStyle(java.lang.String styleProperty)` Returns the value of a single style.
    `java.util.Map<java.lang.String,java.lang.String>` | `getComputedStyles()` Returns the element's computed styles as a dictionary with the name of the style as the key.
    `java.lang.String` | `getId()` Returns the element's HTML identifier.
    `java.lang.String` | `getInnerHTML()` Returns the element's HTML not including the current element.
    `java.lang.String` | `getInnerText()` Returns the text contained between the object's start and end tags.
    `java.lang.String` | `getName()` Returns the object's name.
    `java.lang.String` | `getOuterHTML()` Returns the element's HTML, including the current element.
    `java.lang.String` | `getOuterText()` Returns the object's text.
    `java.lang.String` | `getTagName()` Returns the element's tag name.
    `java.lang.String` | `getTitle()` Returns the element's title attribute.
    `boolean` | `isVisible()` Indicates whether the current element is visible.

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

      `getAbsoluteLocation, getLocation, getSize`

    - ### Methods inherited from interface com.hp.lft.sdk.web.WebTestObjectDescriber

      `describe, describe`

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

      `describe`

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

      `getNativeObject`

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

      `waitUntilVisible, waitUntilVisible`

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

      `isVisible`

- - ### Method Detail

    - #### getClassName

          java.lang.String getClassName()
                                 throws GeneralLeanFtException

      Returns the element's CSS class.
      Returns:
        the element's CSS class.
      Throws:
        `GeneralLeanFtException` - if an error occurs during execution.

    - #### getId

          java.lang.String getId()
                          throws GeneralLeanFtException

      Returns the element's HTML identifier.
      Returns:
        the element's HTML identifier.
      Throws:
        `GeneralLeanFtException` - if an error occurs during execution.

    - #### getTagName

          java.lang.String getTagName()
                               throws GeneralLeanFtException

      Returns the element's tag name.
      Returns:
        the element's tag name.
      Throws:
        `GeneralLeanFtException` - if an error occurs during execution.

    - #### getInnerHTML

          java.lang.String getInnerHTML()
                                 throws GeneralLeanFtException

      Returns the element's HTML not including the current element.
      Returns:
        the element's HTML not including the current element.
      Throws:
        `GeneralLeanFtException` - if an error occurs during execution.

    - #### getOuterHTML

          java.lang.String getOuterHTML()
                                 throws GeneralLeanFtException

      Returns the element's HTML, including the current element.
      Returns:
        the element's HTML, including the current element.
      Throws:
        `GeneralLeanFtException` - if an error occurs during execution.

    - #### getInnerText

          java.lang.String getInnerText()
                                 throws GeneralLeanFtException

      Returns the text contained between the object's start and end tags.
      Returns:
        the text contained between the object's start and end tags.
      Throws:
        `GeneralLeanFtException` - if an error occurs during execution.

    - #### getOuterText

          java.lang.String getOuterText()
                                 throws GeneralLeanFtException

      Returns the object's text.
      Note: Supported in Internet Explorer only.
      Returns:
        the object's text.
      Throws:
        `GeneralLeanFtException` - if an error occurs during execution.

    - #### getName

          java.lang.String getName()
                            throws GeneralLeanFtException

      Returns the object's name.
      Returns:
        the object's name.
      Throws:
        `GeneralLeanFtException` - if an error occurs during execution.

    - #### getTitle

          java.lang.String getTitle()
                             throws GeneralLeanFtException

      Returns the element's title attribute.
      Returns:
        the element's title attribute.
      Throws:
        `GeneralLeanFtException` - if an error occurs during execution.

    - #### isVisible

          boolean isVisible()
                     throws GeneralLeanFtException

      Indicates whether the current element is visible.
      Returns:
        true, if the current element is visible.
      Throws:
        `GeneralLeanFtException` - if an error occurs during execution.

    - #### getAttributes

          java.util.Map<java.lang.String,java.lang.String> getAttributes()
                                                                  throws GeneralLeanFtException

      Returns a copy of the collection of attributes that is attached to the element, for example, "id","class",etc.
      Returns:
        a copy of the collection of attributes that is attached to the element for example, "id","class",etc.
      Throws:
        `GeneralLeanFtException` - if an error occurs during execution.

    - #### getAttribute

          java.lang.String getAttribute(java.lang.String attributeName)
                                 throws GeneralLeanFtException

      Returns the value of a single attribute.
      Parameters:
        `attributeName` - the attribute name for the value to retrieve.
      Returns:
        the value of the specified attribute (null if the attribute does not exist).
      Throws:
        `GeneralLeanFtException` - if an error occurs during execution.

    - #### getComputedStyles

          java.util.Map<java.lang.String,java.lang.String> getComputedStyles()
                                                                      throws GeneralLeanFtException

      Returns the element's computed styles as a dictionary with the name of the style as the key.
      Returns:
        the element's computed styles as a dictionary with the name of the style as the key.
        Note: returns an empty collection when run against Internet Explorer 8 or when the document mode of another Internet Explorer version is set to Internet 8 or earlier.
      Throws:
        `GeneralLeanFtException` - if an error occurs during execution.

    - #### getComputedStyle

          java.lang.String getComputedStyle(java.lang.String styleProperty)
                                     throws GeneralLeanFtException

      Returns the value of a single style.
      Parameters:
        `styleProperty` - the style property for the value to retrieve.
      Returns:
        the value of the specified style (null if the style property does not exist).
      Throws:
        `GeneralLeanFtException` - if an error occurs during execution.