Package com.atlassian.jira.util
Class UnsupportedBrowserManager
java.lang.Object
com.atlassian.jira.util.UnsupportedBrowserManager
Contains a map of unsupported browsers and error message keys. It also provides helper methods to access and manipulate this map.
- Since:
- v4.2
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiongetBrowser(jakarta.servlet.http.HttpServletRequest request) getMessageKey(UserAgentUtil.Browser browser) getMessageKey(jakarta.servlet.http.HttpServletRequest request) booleanbooleanisHandledCookiePresent(jakarta.servlet.http.HttpServletRequest request) booleanbooleanisUnsupportedBrowser(jakarta.servlet.http.HttpServletRequest request)
-
Constructor Details
-
UnsupportedBrowserManager
-
-
Method Details
-
isUnsupportedBrowser
- Parameters:
browser- TheUserAgentUtil.Browserthat is to tested- Returns:
- Whether the browser is unsupported
-
isUnsupportedBrowser
public boolean isUnsupportedBrowser(jakarta.servlet.http.HttpServletRequest request) - Parameters:
request- The HttpServletRequest to extract the user agent from- Returns:
- whether the browser retrieved from the user agent in the current request is unsupported
-
getMessageKey
- Parameters:
browser- TheUserAgentUtil.Browser- Returns:
- the message key stored in the map for a specific unsupported browser, null if the browser is supported
-
getMessageKey
- Parameters:
request- The HttpServletRequest to extract the user agent from- Returns:
- the message key stored in the map for the browser retrieved from the user agent in the current request, null if the client browser is supported
-
isCheckEnabled
public boolean isCheckEnabled()- Returns:
- true if the jira.browser.unsupported.warnings.disabled property is false
-
isHandledCookiePresent
public boolean isHandledCookiePresent(jakarta.servlet.http.HttpServletRequest request) - Parameters:
request- The HttpServletRequest to extract the cookie from- Returns:
- whether the client has saved an UNSUPPORTED_BROWSER_WARNING cookie in the current request headers
-
getBrowser
- Parameters:
request- The HttpServletRequest to extract the user agent from- Returns:
- The
UserAgentUtil.Browserthat is deduced from the user agent header in the request
-