com.hp.lft.sdk.mobile

Class DeviceDescription

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


    public class DeviceDescription
    extends PropertiesDescription
    implements com.hp.lft.sdk.internal.MapHolder
    The description of a mobile Device test object.
    • Field Summary

      • Fields inherited from class com.hp.lft.sdk.internal.PropertiesDescriptionBase

        properties
    • Constructor Summary

      Constructor and Description
      DeviceDescription()
      Initializes a new instance of the DeviceDescription class.
    • Method Summary

      Modifier and TypeMethod and Description
      static DeviceDescriptionfromMap(java.util.Map<java.lang.String,java.lang.Object> props)
      This method creates a new instance of DeviceDescription and initializes it with the given props map.
      java.lang.Objectget(java.lang.String capability)
      Returns the current value of a DeviceDescription capability.
      java.lang.StringgetFleetType()
      Returns the fleetType of the device, as defined in Digital Lab (UFT Mobile).

      Supported in UFT Developer version 24.2 and later

      java.lang.StringgetId()
      Returns the device ID used by Digital Lab (UFT Mobile).
      java.lang.StringgetLocation()
      Returns the geographical location of the public device, as defined in Digital Lab (UFT Mobile).

      Supported in UFT Developer version 24.2 and later

      java.lang.StringgetManufacturer()
      Returns the manufacturer name that Digital Lab (UFT Mobile) uses to identify the device.
      java.util.Map<java.lang.String,java.lang.Object>getMap()
      For internal use only.
      java.lang.StringgetModel()
      Returns the device model that Digital Lab (UFT Mobile) uses to identify the device.
      java.lang.StringgetName()
      Returns the logical name that Digital Lab (UFT Mobile) uses to identify the device.
      java.lang.StringgetOsType()
      Returns the OS type of the emulated device.
      java.lang.StringgetOsVersion()
      Returns the OS version of the emulated device.
      voidset(java.lang.String capability, java.lang.Object value)
      Sets a DeviceDescription capability to the given value.
      voidsetFleetType(java.lang.String id)
      Sets the fleetType of the device that Digital Lab (UFT Mobile) uses to identify the device.

      Supported in UFT Developer version 24.2 and later

      voidsetId(java.lang.String id)
      Sets the device ID used by Digital Lab (UFT Mobile).
      voidsetLocation(java.lang.String id)
      Sets the geographical location that Digital Lab (UFT Mobile) uses to identify the public device.

      The location is relevant only when the DeviceSource is HOSTED and the fleetType is PUBLIC.

      Possible values: ANY (default) or a string representing the geographic location.

      Supported in UFT Developer version 24.2 and later

      voidsetManufacturer(java.lang.String manufacturer)
      Sets the manufacturer name that Digital Lab (UFT Mobile) uses to identify the device.
      voidsetModel(java.lang.String model)
      Sets the device model that Digital Lab (UFT Mobile) uses to identify the device.
      voidsetName(java.lang.String name)
      Sets the logical name that Digital Lab (UFT Mobile) uses to identify the device.
      voidsetOsType(java.lang.String osType)
      Sets the OS type of the emulated device.
      voidsetOsVersion(java.lang.String version)
      Sets the OS version of the emulated device.
      • Methods inherited from class com.hp.lft.sdk.internal.PropertiesDescriptionBase

        cloneTo, getValueAs, getValueAsStringProperty, insertValue
      • Methods inherited from class java.lang.Object

        equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • DeviceDescription

        public DeviceDescription()
        Initializes a new instance of the DeviceDescription class.
    • Method Detail

      • setFleetType

        Supported in UFT Developer version 24.2 and later

        public void setFleetType(java.lang.String fleetType)
        Sets the fleetType that Digital Lab (UFT Mobile) uses to identify the device.
        The fleetType is relevant only when the device is hosted by OpenText or stored on an AWS farm. (DeviceSource=HOSTED or AMAZON_DEVICE_FARM)
        Parameters:
        fleetType - the fleetType of the device.
        Possible values: ANY (default), PUBLIC, or PRIVATE.
      • getFleetType

        Supported in UFT Developer version 24.2 and later

        public java.lang.String getFleetType()
        Returns the fleetType of the device, as defined in Digital Lab (UFT Mobile).
        The fleetType is relevant only when the device is hosted by OpenText or stored on an AWS farm. (DeviceSource=HOSTED or AMAZON_DEVICE_FARM)
        Returns:
        the fleetType of the device.
        Possible values: ANY (default), PUBLIC, or PRIVATE.
      • setId

        public void setId(java.lang.String id)
        Sets the device ID used by Digital Lab (UFT Mobile).
        Parameters:
        id - the device ID used by Digital Lab (UFT Mobile).
      • getId

        public java.lang.String getId()
        Returns the device ID used by Digital Lab (UFT Mobile).
        Returns:
        the device ID used by Digital Lab (UFT Mobile).
      • setLocation

        Supported in UFT Developer version 24.2 and later

        public void setLocation(java.lang.String location)
        Sets the geographic location that Digital Lab (UFT Mobile) uses to identify the public device.
        The location is relevant only when the DeviceSource is HOSTED and the fleetType is PUBLIC.
        Parameters:
        location - the geographic location of the public device.
        Possible values: ANY (default) or a string representing the geographic location.
      • getLocation

        Supported in UFT Developer version 24.2 and later

        public java.lang.String getLocation()
        Returns the geographic location of the device, as defined in Digital Lab (UFT Mobile).
        The location is relevant only when the DeviceSource is HOSTED and the fleetType is PUBLIC.
        Returns:
        the geographic location of the device.
        Possible values: ANY (default) or a string representing the geographic location.
      • setName

        public void setName(java.lang.String name)
        Sets the logical name that Digital Lab (UFT Mobile) uses to identify the device.
        Parameters:
        name - logical name that Digital Lab (UFT Mobile) uses to identify the device.
      • getName

        public java.lang.String getName()
        Returns the logical name that Digital Lab (UFT Mobile) uses to identify the device.
        Returns:
        the logical name that Digital Lab (UFT Mobile) uses to identify the device.
      • setOsType

        public void setOsType(java.lang.String osType)
        Sets the OS type of the emulated device.
        Parameters:
        osType - the OS type of the emulated device.
      • getOsType

        public java.lang.String getOsType()
        Returns the OS type of the emulated device.
        Returns:
        the OS type of the emulated device.
      • setOsVersion

        public void setOsVersion(java.lang.String version)
        Sets the OS version of the emulated device. The following symbols are supported:

        >, >=, <, <=

        For example:

        setOsVersion(">4.0")

        setOsVersion(">=4.1")

        Parameters:
        version - the OS version of the emulated device.
      • getOsVersion

        public java.lang.String getOsVersion()
        Returns the OS version of the emulated device.
        Returns:
        the OS version of the emulated device.
      • setManufacturer

        public void setManufacturer(java.lang.String manufacturer)
        Sets the manufacturer name that Digital Lab (UFT Mobile) uses to identify the device.
        Parameters:
        manufacturer - the manufacturer name of the device.
      • getManufacturer

        public java.lang.String getManufacturer()
        Returns the manufacturer name that Digital Lab (UFT Mobile) uses to identify the device.
        Returns:
        the manufacturer name that Digital Lab (UFT Mobile) uses to identify the device.
      • setModel

        public void setModel(java.lang.String model)
        Sets the device model that Digital Lab (UFT Mobile) uses to identify the device.
        Parameters:
        model - the device model of the device.
      • getModel

        public java.lang.String getModel()
        Returns the device model that Digital Lab (UFT Mobile) uses to identify the device.
        Returns:
        the device model that Digital Lab (UFT Mobile) uses to identify the device.
      • set

        public void set(java.lang.String capability,
                        java.lang.Object value)
                 throws GeneralLeanFtException
        Sets a DeviceDescription capability to the given value.
        Parameters:
        capability - the name of the capability to set value for.
        value - the new value of the capability.
        Throws:
        GeneralLeanFtException - if the set operation fails.
      • getMap

        public java.util.Map<java.lang.String,java.lang.Object> getMap()
        For internal use only.
        Specified by:
        getMap in interface com.hp.lft.sdk.internal.MapHolder
        Returns:
        for internal use only.