public class BrowserSnifferImpl
extends Object
implements com.liferay.portal.kernel.servlet.BrowserSniffer
Modifier and Type | Field and Description |
---|---|
protected static String[] |
revisionLeadings |
protected static char[] |
revisionSeparators |
protected static String[] |
versionLeadings |
protected static char[] |
versionSeparators |
Constructor and Description |
---|
BrowserSnifferImpl() |
Modifier and Type | Method and Description |
---|---|
boolean |
acceptsGzip(javax.servlet.http.HttpServletRequest request) |
protected String |
getAccept(javax.servlet.http.HttpServletRequest request) |
String |
getBrowserId(javax.servlet.http.HttpServletRequest request) |
com.liferay.portal.kernel.servlet.BrowserMetadata |
getBrowserMetadata(javax.servlet.http.HttpServletRequest request) |
float |
getMajorVersion(javax.servlet.http.HttpServletRequest request) |
String |
getRevision(javax.servlet.http.HttpServletRequest request) |
protected String |
getUserAgent(javax.servlet.http.HttpServletRequest request) |
String |
getVersion(javax.servlet.http.HttpServletRequest request) |
boolean |
isAir(javax.servlet.http.HttpServletRequest request) |
boolean |
isAndroid(javax.servlet.http.HttpServletRequest request) |
boolean |
isChrome(javax.servlet.http.HttpServletRequest request) |
boolean |
isEdge(javax.servlet.http.HttpServletRequest request) |
boolean |
isFirefox(javax.servlet.http.HttpServletRequest request) |
boolean |
isGecko(javax.servlet.http.HttpServletRequest request) |
boolean |
isIe(javax.servlet.http.HttpServletRequest request) |
protected boolean |
isIe(String userAgent)
Deprecated.
As of Judson (7.1.x), replaced by
BrowserMetadata.isIe() |
boolean |
isIeOnWin32(javax.servlet.http.HttpServletRequest request) |
boolean |
isIeOnWin64(javax.servlet.http.HttpServletRequest request) |
boolean |
isIphone(javax.servlet.http.HttpServletRequest request) |
boolean |
isLinux(javax.servlet.http.HttpServletRequest request) |
boolean |
isMac(javax.servlet.http.HttpServletRequest request) |
boolean |
isMobile(javax.servlet.http.HttpServletRequest request) |
boolean |
isMozilla(javax.servlet.http.HttpServletRequest request) |
boolean |
isOpera(javax.servlet.http.HttpServletRequest request) |
boolean |
isRtf(javax.servlet.http.HttpServletRequest request) |
boolean |
isSafari(javax.servlet.http.HttpServletRequest request) |
boolean |
isSun(javax.servlet.http.HttpServletRequest request) |
boolean |
isWebKit(javax.servlet.http.HttpServletRequest request) |
boolean |
isWindows(javax.servlet.http.HttpServletRequest request) |
protected static String |
parseVersion(String userAgent,
String[] leadings,
char[] separators) |
protected static String[] revisionLeadings
protected static char[] revisionSeparators
protected static String[] versionLeadings
protected static char[] versionSeparators
public boolean acceptsGzip(javax.servlet.http.HttpServletRequest request)
acceptsGzip
in interface com.liferay.portal.kernel.servlet.BrowserSniffer
public String getBrowserId(javax.servlet.http.HttpServletRequest request)
getBrowserId
in interface com.liferay.portal.kernel.servlet.BrowserSniffer
public com.liferay.portal.kernel.servlet.BrowserMetadata getBrowserMetadata(javax.servlet.http.HttpServletRequest request)
getBrowserMetadata
in interface com.liferay.portal.kernel.servlet.BrowserSniffer
public float getMajorVersion(javax.servlet.http.HttpServletRequest request)
getMajorVersion
in interface com.liferay.portal.kernel.servlet.BrowserSniffer
public String getRevision(javax.servlet.http.HttpServletRequest request)
getRevision
in interface com.liferay.portal.kernel.servlet.BrowserSniffer
public String getVersion(javax.servlet.http.HttpServletRequest request)
getVersion
in interface com.liferay.portal.kernel.servlet.BrowserSniffer
public boolean isAir(javax.servlet.http.HttpServletRequest request)
isAir
in interface com.liferay.portal.kernel.servlet.BrowserSniffer
public boolean isAndroid(javax.servlet.http.HttpServletRequest request)
isAndroid
in interface com.liferay.portal.kernel.servlet.BrowserSniffer
public boolean isChrome(javax.servlet.http.HttpServletRequest request)
isChrome
in interface com.liferay.portal.kernel.servlet.BrowserSniffer
public boolean isEdge(javax.servlet.http.HttpServletRequest request)
isEdge
in interface com.liferay.portal.kernel.servlet.BrowserSniffer
public boolean isFirefox(javax.servlet.http.HttpServletRequest request)
isFirefox
in interface com.liferay.portal.kernel.servlet.BrowserSniffer
public boolean isGecko(javax.servlet.http.HttpServletRequest request)
isGecko
in interface com.liferay.portal.kernel.servlet.BrowserSniffer
public boolean isIe(javax.servlet.http.HttpServletRequest request)
isIe
in interface com.liferay.portal.kernel.servlet.BrowserSniffer
public boolean isIeOnWin32(javax.servlet.http.HttpServletRequest request)
isIeOnWin32
in interface com.liferay.portal.kernel.servlet.BrowserSniffer
public boolean isIeOnWin64(javax.servlet.http.HttpServletRequest request)
isIeOnWin64
in interface com.liferay.portal.kernel.servlet.BrowserSniffer
public boolean isIphone(javax.servlet.http.HttpServletRequest request)
isIphone
in interface com.liferay.portal.kernel.servlet.BrowserSniffer
public boolean isLinux(javax.servlet.http.HttpServletRequest request)
isLinux
in interface com.liferay.portal.kernel.servlet.BrowserSniffer
public boolean isMac(javax.servlet.http.HttpServletRequest request)
isMac
in interface com.liferay.portal.kernel.servlet.BrowserSniffer
public boolean isMobile(javax.servlet.http.HttpServletRequest request)
isMobile
in interface com.liferay.portal.kernel.servlet.BrowserSniffer
public boolean isMozilla(javax.servlet.http.HttpServletRequest request)
isMozilla
in interface com.liferay.portal.kernel.servlet.BrowserSniffer
public boolean isOpera(javax.servlet.http.HttpServletRequest request)
isOpera
in interface com.liferay.portal.kernel.servlet.BrowserSniffer
public boolean isRtf(javax.servlet.http.HttpServletRequest request)
isRtf
in interface com.liferay.portal.kernel.servlet.BrowserSniffer
public boolean isSafari(javax.servlet.http.HttpServletRequest request)
isSafari
in interface com.liferay.portal.kernel.servlet.BrowserSniffer
public boolean isSun(javax.servlet.http.HttpServletRequest request)
isSun
in interface com.liferay.portal.kernel.servlet.BrowserSniffer
public boolean isWebKit(javax.servlet.http.HttpServletRequest request)
isWebKit
in interface com.liferay.portal.kernel.servlet.BrowserSniffer
public boolean isWindows(javax.servlet.http.HttpServletRequest request)
isWindows
in interface com.liferay.portal.kernel.servlet.BrowserSniffer
protected static String parseVersion(String userAgent, String[] leadings, char[] separators)
protected String getAccept(javax.servlet.http.HttpServletRequest request)
protected String getUserAgent(javax.servlet.http.HttpServletRequest request)
@Deprecated protected boolean isIe(String userAgent)
BrowserMetadata.isIe()