Enum Class ScreenOrientation

java.lang.Object
java.lang.Enum<ScreenOrientation>
com.iizix.gyro.ScreenOrientation
All Implemented Interfaces:
Serializable, Comparable<ScreenOrientation>, Constable

public enum ScreenOrientation extends Enum<ScreenOrientation>
Enumeration for values used for screen orientation.
Author:
Christopher Mindus
  • Enum Constant Details

    • portrait

      public static final ScreenOrientation portrait
      The orientation is either portrait-primary or portrait-secondary (sensor).
    • landscape

      public static final ScreenOrientation landscape
      The orientation is either landscape-primary or landscape-secondary (sensor).
    • portrait_primary

      public static final ScreenOrientation portrait_primary
      The orientation is in the primary portrait mode.
    • portrait_secondary

      public static final ScreenOrientation portrait_secondary
      The orientation is in the secondary portrait mode.
    • landscape_primary

      public static final ScreenOrientation landscape_primary
      The orientation is in the primary landscape mode.
    • landscape_secondary

      public static final ScreenOrientation landscape_secondary
      The orientation is in the secondary landscape mode.
    • unknown

      public static final ScreenOrientation unknown
      Unknown orientation.
  • Field Details

    • clientOrientation

      public final String clientOrientation
      The string in window.screen.orientation on the client side.
    • isPortrait

      public final boolean isPortrait
      Flag for portrait orientation (false for "unknown").
    • isLandscape

      public final boolean isLandscape
      Flag for landscape orientation (false for "unknown").
  • Method Details

    • values

      public static ScreenOrientation[] 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 ScreenOrientation 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