Class UserAgentInfo

java.lang.Object
org.jivesoftware.openfire.net.UserAgentInfo
All Implemented Interfaces:
Serializable, Cacheable

public class UserAgentInfo extends Object implements Cacheable
Represents user agent information provided by XMPP clients during authentication. This information includes an optional UUID v4 identifier, software description, and device description. This information is not exposed to other entities.
See Also:
  • Constructor Details

  • Method Details

    • extract

      public static UserAgentInfo extract(org.dom4j.Element userAgentElement)
      Extracts and validates user agent information from the authentication element.
      Parameters:
      userAgentElement - the authentication element containing potential user agent data
      Returns:
      UserAgentInfo containing the parsed data, or null if no user agent data present
    • getId

      public String getId()
    • getSoftware

      public String getSoftware()
    • getDevice

      public String getDevice()
    • getCachedSize

      public int getCachedSize() throws CannotCalculateSizeException
      Description copied from interface: Cacheable
      Returns the approximate size of the Object in bytes. The size should be considered to be a best estimate of how much memory the Object occupies and may be based on empirical trials or dynamic calculations.

      Specified by:
      getCachedSize in interface Cacheable
      Returns:
      the size of the Object in bytes.
      Throws:
      CannotCalculateSizeException - if the size cannot be calculated