Open topic with navigation

com.hp.lft.sdk.winforms

## Interface UiObjectBase

- All Superinterfaces:
    Clickable, DoubleClickable, LocationInfoProvider, SupportDragAndDrop, SupportSendKeys, SupportsNativeObject, UiObjectBase, VisibleProvider, WaitUntilVisibleProvider, WaitUntilEnabledProvider, EnabledProvider
  All Known Subinterfaces:
    Button, Calendar, CheckBox, ComboBox, EditField, Editor, Label, ListBox, ListView, PropertyGrid, RadioButton, ScrollBar, SpinBox, StatusBar, TabControl, Table, ToolBar, TreeView, UiObject, Window

      public interface UiObjectBase
      extends UiObjectBase, SupportsNativeObject

  Base for .NET Windows Forms test objects.

- - ### Method Summary

    Modifier and Type | Method and Description
    --- | ---
    `void` | `fireEvent(java.lang.String type, java.lang.Object... args)` Simulates an event on a .NET object.
    `java.lang.String` | `getFullNamePath()` Returns the full hierarchy of this object with all parent objects.
    `java.lang.String` | `getFullType()` Returns the full type name of this object.
    `java.lang.String` | `getObjectName()` The instance's name.
    `<TValue> TValue` | `getObjectProperty(java.lang.String propname, java.lang.Class<TValue> returnType)` Returns the value of a test object property.
    `java.lang.String` | `getText()` Returns the text associated with this object.
    `java.lang.String` | `getWindowClassRegExp()` Returns the permanent part of the MFC window class.
    `int` | `getWindowId()` Returns this object's window identifier.
    `boolean` | `isChildWindow()` Indicates whether this object's window is a child window.
    `boolean` | `isOwnedWindow()` Indicates whether the object's window has an owner window.

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

      `getHandle, getNativeClass, getWindowTitleRegExp, isEnabled, isFocused, isVisible, mouseMove`

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

      `click, click, click`

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

      `doubleClick, doubleClick, doubleClick`

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

      `getAbsoluteLocation, getLocation, getSize`

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

      `sendKeys, sendKeys`

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

      `dragAndDropOn, dragAndDropOn`

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

      `getNativeObject`

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

      `waitUntilEnabled, waitUntilEnabled`

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

      `isEnabled`

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

      `waitUntilVisible, waitUntilVisible`

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

      `isVisible`

- - ### Method Detail

    - #### fireEvent

          void fireEvent(java.lang.String type,
                         java.lang.Object... args)
                  throws GeneralLeanFtException

      Simulates an event on a .NET object.
      Parameters:
        `type` - the name of the event to simulate. The list of possible events depends on the object.
        `args` - the Args argument is passed to the constructor of the event's EventArgs object or the implementing class.
      Throws:
        `GeneralLeanFtException` - if an error occurs during execution.

    - #### isChildWindow

          boolean isChildWindow()
                         throws GeneralLeanFtException

      Indicates whether this object's window is a child window.
      Returns:
        true if a child window
      Throws:
        `GeneralLeanFtException` - if an error occurs during execution.

    - #### isOwnedWindow

          boolean isOwnedWindow()
                         throws GeneralLeanFtException

      Indicates whether the object's window has an owner window.
      Returns:
        true if has an owner window.
      Throws:
        `GeneralLeanFtException` - if an error occurs during execution.

    - #### getObjectName

          java.lang.String getObjectName()
                                  throws GeneralLeanFtException

      The instance's name.

      For example, for `myFoo = new fooBar`, the object name is myFoo.

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

    - #### getFullNamePath

          java.lang.String getFullNamePath()
                                    throws GeneralLeanFtException

      Returns the full hierarchy of this object with all parent objects.
      Returns:
        the hierarchy
      Throws:
        `GeneralLeanFtException` - if an error occurs during execution.

    - #### getFullType

          java.lang.String getFullType()
                                throws GeneralLeanFtException

      Returns the full type name of this object.
      Returns:
        the full type name
      Throws:
        `GeneralLeanFtException` - if an error occurs during execution.

    - #### getText

          java.lang.String getText()
                            throws GeneralLeanFtException

      Returns the text associated with this object.
      Returns:
        the text
      Throws:
        `GeneralLeanFtException` - if an error occurs during execution.

    - #### getWindowClassRegExp

          java.lang.String getWindowClassRegExp()
                                         throws GeneralLeanFtException

      Returns the permanent part of the MFC window class.
      Returns:
        the permanent part of the MFC window class.
      Throws:
        `GeneralLeanFtException` - if an error occurs during execution.

    - #### getWindowId

          int getWindowId()
                   throws GeneralLeanFtException

      Returns this object's window identifier.
      Returns:
        the window ID
      Throws:
        `GeneralLeanFtException` - if an error occurs during execution.

    - #### getObjectProperty

          <TValue> TValue getObjectProperty(java.lang.String propname,
                                            java.lang.Class<TValue> returnType)
                                     throws GeneralLeanFtException

      Returns the value of a test object property.

      This method can return any property of this control, including custom properties declared in a custom control.

      Type Parameters:
        `TValue` - the generic type of returnType.
      Parameters:
        `propname` - the name of the test object property.
        `returnType` - the type of the test object property.
      Returns:
        the property value
      Throws:
        `GeneralLeanFtException` - if an error occurs during execution.