Class UserAgentInfo


  • public class UserAgentInfo
    extends Object
    Create a User Agent Information reporting class.
    • Field Detail

      • DEVICE_TYPE_DIGITAL_MEDIA_RECEIVER

        public static final String DEVICE_TYPE_DIGITAL_MEDIA_RECEIVER
        The device type "Digital Media Rec."
        See Also:
        Constant Field Values
      • DEVICE_TYPE_GAME_CONSOLE

        public static final String DEVICE_TYPE_GAME_CONSOLE
        The device type "Game Console"
        See Also:
        Constant Field Values
      • DEVICE_TYPES

        public static final String[] DEVICE_TYPES
        The list of device types
    • Constructor Detail

      • UserAgentInfo

        public UserAgentInfo​(String userAgentValue)
        Create a User Agent Information reporting class from the given HTTP user-agent header value.
        Parameters:
        userAgentValue - the HTTP user-agent header value.
    • Method Detail

      • isInternetExplorer6

        public boolean isInternetExplorer6()
        Returns:
        true if the browser type is Internet Explorer 6
      • isInternetExplorer7

        public boolean isInternetExplorer7()
        Returns:
        true if the browser type is Internet Explorer 7
      • isAppleiOS

        public boolean isAppleiOS()
        Returns:
        true if Apple iOS type device
      • getBrowserType

        public String getBrowserType()
        Returns:
        the browserType
      • getBrowserVersion

        public String getBrowserVersion()
        Returns:
        the browserVersion
      • getDeviceType

        public String getDeviceType()
        Returns:
        the deviceType
      • getOsType

        public String getOsType()
        Returns:
        the osType
      • getOsVersion

        public String getOsVersion()
        Returns:
        the osVersion
      • isWindows8MetroMode

        public boolean isWindows8MetroMode()
        Returns:
        true if the browser is running in Windows 8 Metro UI mode
      • isWindowsRTOS

        public boolean isWindowsRTOS()
        Returns:
        true if the browser is running in Windows 8 RT OS
      • isAndroidOS

        public boolean isAndroidOS()
        Returns:
        true if the browser is running in Android OS
      • isXFASupportedOS

        public boolean isXFASupportedOS()
        Returns:
        true if XFA Reader supported on OS
      • isFileUploadSupported

        public boolean isFileUploadSupported()
        Checks if is file upload supported.
        Returns:
        true, if is file upload supported
      • toString

        public String toString()
        Return the string representation of this object.
        Overrides:
        toString in class Object
        Returns:
        the string representation of the user agent record