Class LocationProperty

java.lang.Object
com.hp.lft.sdk.LocationProperty
All Implemented Interfaces:
CloneableObject, com.hp.lft.sdk.internal.GroupedProperty, Cloneable

public class LocationProperty extends Object implements com.hp.lft.sdk.internal.GroupedProperty, CloneableObject
Class for defining a test object's location property.
  • Field Details

    • x

      public Integer x
      The x-coordinate (in pixels) of the test object location.
    • y

      public Integer y
      The y-coordinate (in pixels) of the test object location.
  • Constructor Details

    • LocationProperty

      public LocationProperty()
      Initializes a new instance of the LocationProperty class.
    • LocationProperty

      public LocationProperty(Point location)
      Initializes a new instance of the LocationProperty class with the specified location values.
      Parameters:
      location - the Location to use to initialize the LocationProperty.
    • LocationProperty

      public LocationProperty(Integer x, Integer y)
      Initializes a new instance of the LocationProperty class with the specified x and y values.
      Parameters:
      x - the x-coordinate (in pixels) of the test object location.
      y - the y-coordinate (in pixels) of the test object location.
    • LocationProperty

      public LocationProperty(LocationProperty locationToCopy)
      Initializes a new instance of the LocationProperty class by copying values from the provided LocationProperty object.
      Parameters:
      locationToCopy - the LocationProperty object whose values will be copied to the new instance.
  • Method Details

    • clone

      public Object clone() throws CloneNotSupportedException
      Description copied from interface: CloneableObject
      Returns a clone of this instance.
      Specified by:
      clone in interface CloneableObject
      Overrides:
      clone in class Object
      Returns:
      a clone of this instance.
      Throws:
      CloneNotSupportedException - if the instance cannot be cloned.
    • getProperties

      public Map<String,Object> getProperties()
      Specified by:
      getProperties in interface com.hp.lft.sdk.internal.GroupedProperty
    • getX

      public Integer getX()
      Returns the x-coordinate (in pixels) of the test object location.
      Returns:
      the x-coordinate (in pixels) of the test object location.
    • setX

      public LocationProperty setX(Integer x)
      Sets the x-coordinate (in pixels) of the test object location.
      Parameters:
      x - the x-coordinate (in pixels) of the test object location.
      Returns:
      the LocationProperty instance with the updated state (builder pattern).
    • getY

      public Integer getY()
      Returns the y-coordinate (in pixels) of the test object location.
      Returns:
      the y-coordinate (in pixels) of the test object location.
    • setY

      public LocationProperty setY(Integer y)
      Sets the y-coordinate (in pixels) of the test object location.
      Parameters:
      y - the y-coordinate (in pixels) of the test object location.
      Returns:
      the LocationProperty instance with the updated state (builder pattern).
    • toString

      public String toString()
      Overrides:
      toString in class Object