Enum Class SensorType

java.lang.Object
java.lang.Enum<SensorType>
org.openqa.selenium.devtools.v141.emulation.model.SensorType
All Implemented Interfaces:
Serializable, Comparable<SensorType>, Constable

@Beta public enum SensorType extends Enum<SensorType>
Used to specify sensor types to emulate. See https://w3c.github.io/sensors/#automation for more information.
  • Enum Constant Details

    • ABSOLUTE_ORIENTATION

      public static final SensorType ABSOLUTE_ORIENTATION
    • ACCELEROMETER

      public static final SensorType ACCELEROMETER
    • AMBIENT_LIGHT

      public static final SensorType AMBIENT_LIGHT
    • GRAVITY

      public static final SensorType GRAVITY
    • GYROSCOPE

      public static final SensorType GYROSCOPE
    • LINEAR_ACCELERATION

      public static final SensorType LINEAR_ACCELERATION
    • MAGNETOMETER

      public static final SensorType MAGNETOMETER
    • RELATIVE_ORIENTATION

      public static final SensorType RELATIVE_ORIENTATION
  • Method Details

    • values

      public static SensorType[] values()
      Returns an array containing the constants of this enum class, in the order they are declared.
      Returns:
      an array containing the constants of this enum class, in the order they are declared
    • valueOf

      public static SensorType valueOf(String name)
      Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)
      Parameters:
      name - the name of the enum constant to be returned.
      Returns:
      the enum constant with the specified name
      Throws:
      IllegalArgumentException - if this enum class has no constant with the specified name
      NullPointerException - if the argument is null
    • fromString

      public static SensorType fromString(String s)
    • toString

      public String toString()
      Overrides:
      toString in class Enum<SensorType>
    • toJson

      public String toJson()