|
Components |
|
| |||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
com.sas.servlet.util.ClientInfo
public class ClientInfo
Bean to access Client Information from within JSP tags and Servlets.
Field Summary | |
---|---|
static int |
HDML_BROWSER
Handheld Device Markup Language Browser |
static java.lang.String |
HDML_CONTENT_TYPE
Content types for HDML |
static int |
HTML_BROWSER
HTML Browser |
static java.lang.String |
HTML_CONTENT_TYPE
Content types for HTML |
static java.lang.String |
WML_CONTENT_TYPE
Content types for WML |
static int |
WML_OTHER_BROWSER
Wireless Markup Language Other Browser (i.e. |
static int |
WML_UP_BROWSER
Wireless Markup Language UP Browser |
Constructor Summary | |
---|---|
ClientInfo(javax.servlet.http.HttpServletRequest request)
Constructs a new ClientInfo object and calls the initialize method. |
Method Summary | |
---|---|
java.lang.String |
getAccept()
Gets the HTTP_ACCEPT header |
java.lang.String |
getBrowserType()
Gets the browser type. |
java.lang.String |
getBrowserVersion()
Gets the browser version |
java.lang.String |
getUserAgent()
Gets the browser type |
void |
initialize()
Initializes the client info object. |
boolean |
isChrome()
Determines if the browser is Chrome |
boolean |
isHDML()
Determines if the browser supports HDML |
boolean |
isInternetExplorer()
Determines if the browser is Internet Explorer |
boolean |
isMobile()
Returns true if the user-agent is thought to be a mobile device. |
boolean |
isNetscape()
Determines if the browser is Netscape |
boolean |
isPalmVII()
Determines if the browser is PalmVII |
boolean |
isSafari()
Determines if the browser is Safari |
boolean |
isUP()
Determines if the browser is UP |
boolean |
isWML()
Determines if the browser supports WML |
void |
setAccept(java.lang.String acceptHeader)
Sets the HTTP accept header |
void |
setApplicationSettings(java.util.Properties settings)
Sets the application's name value pair settings on this client info instance. |
void |
setBrowserType(java.lang.String browser)
Sets the browser type |
void |
setBrowserVersion(java.lang.String version)
Sets the browser version |
void |
setUserAgent(java.lang.String agent)
Sets the browser type |
Field Detail |
---|
public static final int WML_UP_BROWSER
public static final int WML_OTHER_BROWSER
public static final int HDML_BROWSER
public static final int HTML_BROWSER
public static final java.lang.String WML_CONTENT_TYPE
public static final java.lang.String HDML_CONTENT_TYPE
public static final java.lang.String HTML_CONTENT_TYPE
Constructor Detail |
---|
public ClientInfo(javax.servlet.http.HttpServletRequest request)
request
- The request object holds information about the clientMethod Detail |
---|
public void initialize()
public void setBrowserType(java.lang.String browser)
browser
- the browser typepublic void setBrowserVersion(java.lang.String version)
version
- the browser versionpublic void setUserAgent(java.lang.String agent)
agent
- the user agentpublic void setAccept(java.lang.String acceptHeader)
acceptHeader
- the HTTP accept headerpublic java.lang.String getBrowserType()
AOL AvantGo Blackberry Chrome Ericsson HotJava imode Lynx Mosaic MSIE MSPIE Netscape Nokia Opera Oracle PalmVII Prodigy Safari UP Webster Pro WebTV WebView WAPman ? (for unknown type)
public java.lang.String getBrowserVersion()
public java.lang.String getUserAgent()
public java.lang.String getAccept()
public boolean isInternetExplorer()
public boolean isNetscape()
public boolean isChrome()
public boolean isSafari()
public boolean isUP()
public boolean isPalmVII()
public boolean isWML()
public boolean isHDML()
public void setApplicationSettings(java.util.Properties settings)
settings
- Properties for a SAS application.public boolean isMobile()
|
Components |
|
| |||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |