## com.cyscape.browserhawk
Interface BrowserInfo

All Superinterfaces:
  java.lang.Cloneable, java.io.Serializable

    public interface BrowserInfo

extends java.io.Serializable, java.lang.Cloneable

Interface for accessing the various properties and capabilities of the visiting browser. Implements `Serializable` so a servlet/JSP can place an instance of this class in an HttpSession and have the server persist it to disk.

All these properties are available with BrowserHawk Standard Edition except WinInstallerMinVer which requires BrowserHawk Enterprise Edition.

Method Summary
`java.lang.String` | `applyRules(java.lang.String ruleset)` Applies the given set of rules and returns a String determined by the rules, or the empty string if no rule matches.
`java.lang.Object` | `clone()` Support BrowserInfo cloning
`java.lang.Object` | `get(java.lang.String propertyName)` Returns the value of the property whose name is specified as a String.
`boolean` | `getActiveXControls()` Returns whether the browser supports ActiveX controls
`boolean` | `getAOL()` Returns whether the visitor is accessing your site through an America Online branded browser (on the AOL network)
`double` | `getAOLVersion()` Returns the AOL version number being used.
`int` | `getAuthenticodeUpdate()` Returns the version of Authenticode which the browser supports.
`boolean` | `getBackgroundSounds()` Returns whether the browser supports playing background sounds.
`java.lang.String` | `getBDDDate()` Returns the date (as a String) for when the BDD data file was built, for example "5/1/2002 5:46:11 PM".
`java.lang.String` | `getBDDVersion()` Returns the version of the BDD data file, for example "5.03a".
`boolean` | `getBeta()` Returns whether the browser is a beta version.
`java.lang.String` | `getBrowser()` Returns the common name associated with the browser such as "Netscape" and "IE"
`boolean` | `getCDF()` Returns whether the browser supports Channel Definition Format for "subscribing" to web content with optional auto-updates.
`int` | `getCharHeightAvail()` Returns the number of characters you can fit down the screen of wireless devices without breaks.
`int` | `getCharWidthAvail()` Provides the amount of characters you can fit across the screen of wireless devices without breaks.
`boolean` | `getCompressGZip()` Returns whether the browser accepts compressed content in GZip format.
`java.lang.String` | `getContainerBrowser()` Returns the browser, if any, that surrounds the browsing environment.
`java.lang.String` | `getContainerFullversion()` Returns the full version of the browser, if any, that surrounds the browsing environment.
`double` | `getContainerVersion()` Returns the version of the browser, if any, that surrounds the browsing environment.
`boolean` | `getCookies()` Returns whether the browser supports the ability to accept cookies
`java.lang.String` | `getCountry()` Returns the 2-letter country code for the client.
`boolean` | `getCrawler()` Returns whether the browser is actually a crawler, spider, or other agent used to index a site for searchable content
`java.lang.String` | `getDeviceName()` Returns for clients that are devices their specific device name (like iPhone, Blackberry, iPad, etc).
`boolean` | `getDHTML()` Returns whether the browser supports DHTML script.
`boolean` | `getEmailCrawler()` Returns whether the visiting agent is a crawler designed to scan your site for the purpose of collecting email addresses listed on your site's pages.
`java.lang.String` | `getFileUpload()` Returns "Yes", "Maybe", or "No" to indicate whether the browser supports the ability to have a user upload a file to your server from their browser (whether the browser supports RFC 1867)
`boolean` | `getFontColor()` Returns whether the browser supports the display of different colored text.
`boolean` | `getFontSize()` Returns whether the browser supports the ability to display varying font sizes.
`boolean` | `getFrames()` Returns whether the browser supports frames.
`java.lang.String` | `getFullversion()` Returns the entire version of the browser, including all major and minor numbers and letters, if any.
`boolean` | `getGecko()` Returns whether the client uses the Gecko rendering engine (developed by Mozilla.org).
`java.lang.String` | `getGeckoBuildDate()` Returns the build date of the Gecko rendering engine in the client, or null if none.
`boolean` | `getGold()` Returns whether the browser is a Gold version of the Netscape browsers.
`boolean` | `getHDML()` Returns true if the client device supports HDML (WAP's predecessor).
`boolean` | `getIFrames()` Returns whether the browser supports the IFRAME tag.
`java.lang.String` | `getIPAddr()` Returns the IP address of the visitor.
`boolean` | `getJavaApplets()` Returns whether the browser supports Java applets.
`boolean` | `getJavaScript()` Returns whether the browser supports JavaScript.
`double` | `getJavaScriptVer()` Returns the version of JavaScript that the browser supports.
`java.lang.String` | `getLanguage()` Returns the most likely preference for the visitor's spoken language.
`int` | `getMajorver()` Returns the major version of the browser.
`double` | `getMinorver()` Returns the minor version of the browser.
`java.lang.String` | `getMinorverlet()` Returns the minor version letter of the browser, if any.
`boolean` | `getMobileDevice()` Returns whether this client is a mobile device (like a phone).
`boolean` | `getMouseOver()` Returns whether the browser supports the ability to use JavaScript mouse-over effects.
`boolean` | `getMSN()` Returns whether the user is on the MSN network.
`boolean` | `getNETCLRInstalled()` Returns whether the .NET CLR is installed on the client.
`java.lang.String` | `getNETCLRVersion()` Returns the version of the .NET CLR installed on the client, or null if none or information not available.
`java.lang.String` | `getOSDetails()` Returns details on operating system the visitor is using.
`boolean` | `getPDA()` Returns true if the client is a PDA device such as a Palm Pilot
`java.lang.String` | `getPlatform()` Returns more general information (as compared to getOSDetails()) about the user's platform.
`boolean` | `getPNG()` Returns whether the browser supports the Portable Network Graphic (PNG) image file format.
`boolean` | `getProxy()` Returns whether the user is connecting through a proxy server.
`java.lang.String` | `getProxyString()` Returns the name of the proxy or proxies that acted on this request when that information is available, or the empty string if none.
`java.lang.String` | `getResolveIP()` Returns the hostname of the client making the web request, as a String, or null if it cannot be determined for any reason.
`boolean` | `getSSL()` Returns whether the browser supports the Secure Sockets Layer (SSL) protocol
`boolean` | `getSSLActive()` Returns whether the user is connected through an active SSL connection.
`java.lang.String` | `getSSLCipherSuite()` Returns the SSL cipher suite used for this SSL session; only available if the user is connected through an active SSL connection.
`int` | `getSSLKeySize()` Returns the SSL key size that the browser supports; only available if the user is connected through an active SSL connection.
`boolean` | `getStyleSheets()` Returns whether the browser supports cascading style sheets (CSS).
`boolean` | `getTableBGColor()` Returns whether the browser supports the ability to control the color of individual HTML table cells.
`boolean` | `getTableBGImage()` Returns whether the browser supports the ability to display an image in the background of individual HTML table cells.
`boolean` | `getTables()` Returns whether the browser supports the ability display HTML tables.
`boolean` | `getVBScript()` Returns whether the browser supports VBScript.
`double` | `getVersion()` Returns the version of the browser.
`boolean` | `getWAP()` Returns true for devices that support WML and WAP (Wireless Application Protocol), such as wireless phones.
`java.lang.String` | `getWAPDeviceModel()` Contains the model of the WAP device if known, or "Unknown" if not.
`java.lang.String` | `getWAPGateway()` Shows details of the UP.Link gateway if being used.
`int` | `getWAPMaxDeckSize()` Contains the approximate maximum number of bytes that the wireless device will support in a deck.
`java.lang.String` | `getWAPSubscriberID()` Automatically set to the unqiue subscriber ID of the WAP visitor when available.
`boolean` | `getWin16()` Returns whether the browser is running on a 16 bit Windows operating system, such as Windows 3.1.
`double` | `getWinInstallerMinVer()` Returns the minimum version of the Windows Installer that is installed on the client.
`boolean` | `getXML()` Returns whether the browser supports direct XML display.
`boolean` | `getXMLHttpRequest()` Returns whether this client supports the XMLHttpRequest object used for AJAX interactions.
`java.lang.String` | `toXML()` Returns an XML representation of all the BrowserInfo properties and their associated values.
`java.lang.String` | `toXML(java.util.Properties props)` Returns an XML representation of all the BrowserInfo properties and their associated values.

Method Detail

### clone

    java.lang.Object clone()

  Support BrowserInfo cloning

### getActiveXControls

    boolean getActiveXControls()

  Returns whether the browser supports ActiveX controls

### getAOL

    boolean getAOL()

  Returns whether the visitor is accessing your site through an America Online branded browser (on the AOL network)

### getAOLVersion

    double getAOLVersion()

  Returns the AOL version number being used. Otherwise it returns 0.

### getAuthenticodeUpdate

    int getAuthenticodeUpdate()

  Returns the version of Authenticode which the browser supports. Authenticode is a Microsoft technology for digitally signing code.

### getBackgroundSounds

    boolean getBackgroundSounds()

  Returns whether the browser supports playing background sounds.

### getBeta

    boolean getBeta()

  Returns whether the browser is a beta version.

### getBrowser

    java.lang.String getBrowser()

  Returns the common name associated with the browser such as "Netscape" and "IE"

### getCDF

    boolean getCDF()

  Returns whether the browser supports Channel Definition Format for "subscribing" to web content with optional auto-updates.

### getCharHeightAvail

    int getCharHeightAvail()

  Returns the number of characters you can fit down the screen of wireless devices without breaks. Note that this number is based on Western character sets which take up only half that of other character sets. If displaying data in Japanese, for example, you can display twice as many characters as reported. Currently this property is set only for DoCoMo i-mode devices and support for other devices will be added shortly.

### getCharWidthAvail

    int getCharWidthAvail()

  Provides the amount of characters you can fit across the screen of wireless devices without breaks. Note that this number is based on Western character sets which take up only half that of other character sets. If displaying data in Japanese, for example, you can display twice as many characters as reported. Currently this property is set only for DoCoMo i-mode devices and support for other devices will be added shortly.

### getCookies

    boolean getCookies()

  Returns whether the browser supports the ability to accept cookies

### getCompressGZip

    boolean getCompressGZip()

  Returns whether the browser accepts compressed content in GZip format. If so your pages can be compressed on the fly to optimize download times.

### getCrawler

    boolean getCrawler()

  Returns whether the browser is actually a crawler, spider, or other agent used to index a site for searchable content

### getDHTML

    boolean getDHTML()

  Returns whether the browser supports DHTML script. Typically used in conjunction with getBrowser() and getMajorver().

### getFileUpload

    java.lang.String getFileUpload()

  Returns "Yes", "Maybe", or "No" to indicate whether the browser supports the ability to have a user upload a file to your server from their browser (whether the browser supports RFC 1867)

### getFontColor

    boolean getFontColor()

  Returns whether the browser supports the display of different colored text.

### getFontSize

    boolean getFontSize()

  Returns whether the browser supports the ability to display varying font sizes.

### getFrames

    boolean getFrames()

  Returns whether the browser supports frames.

### getFullversion

    java.lang.String getFullversion()

  Returns the entire version of the browser, including all major and minor numbers and letters, if any. Example: 4.01.03a. Also see getMajorver(), getMinorver(), and getVersion().

### getGold

    boolean getGold()

  Returns whether the browser is a Gold version of the Netscape browsers.

### getHDML

    boolean getHDML()

  Returns true if the client device supports HDML (WAP's predecessor).

### getIPAddr

    java.lang.String getIPAddr()

  Returns the IP address of the visitor.

### getJavaApplets

    boolean getJavaApplets()

  Returns whether the browser supports Java applets.

### getJavaScript

    boolean getJavaScript()

  Returns whether the browser supports JavaScript.

### getJavaScriptVer

    double getJavaScriptVer()

  Returns the version of JavaScript that the browser supports.

### getLanguage

    java.lang.String getLanguage()

  Returns the most likely preference for the visitor's spoken language.

### getMajorver

    int getMajorver()

  Returns the major version of the browser. Example: For Netscape 4.05 getMajorver() returns 4. Also see getMinorver(), getVersion(), and getFullversion().

### getMinorver

    double getMinorver()

  Returns the minor version of the browser. Example: For Netscape 4.05 getMinorver() returns 0.05. Also see getMajorver(), getVersion(), and getFullversion().

### getMinorverlet

    java.lang.String getMinorverlet()

  Returns the minor version letter of the browser, if any. Returns the empty string if none. Example: For Netscape 4.05C getMinorverlet() returns "C". Also see getMajorver(), getMinorver(), getVersion(), and getFullversion().

### getMouseOver

    boolean getMouseOver()

  Returns whether the browser supports the ability to use JavaScript mouse-over effects.

### getMSN

    boolean getMSN()

  Returns whether the user is on the MSN network.

### getOSDetails

    java.lang.String getOSDetails()

  Returns details on operating system the visitor is using. For example Sun, Microsoft, Linux, BSD.

### getPlatform

    java.lang.String getPlatform()

  Returns more general information (as compared to getOSDetails()) about the user's platform. For example UNIX, Win98, MacPPC, WinNT

### getPDA

    boolean getPDA()

  Returns true if the client is a PDA device such as a Palm Pilot

### getPNG

    boolean getPNG()

  Returns whether the browser supports the Portable Network Graphic (PNG) image file format.

### getProxy

    boolean getProxy()

  Returns whether the user is connecting through a proxy server. Note: Not all connections through a proxy can be detected as such.

### getSSL

    boolean getSSL()

  Returns whether the browser supports the Secure Sockets Layer (SSL) protocol

### getSSLActive

    boolean getSSLActive()

  Returns whether the user is connected through an active SSL connection. Note: Detection of this capability is not available on all web servers.

### getSSLCipherSuite

    java.lang.String getSSLCipherSuite()

  Returns the SSL cipher suite used for this SSL session; only available if the user is connected through an active SSL connection. For example, SSL_RSA_WITH_RC4_128_MD5. Note: Detection of this capability is not available on all web servers. Returns "Unknown" if not determinable.

### getSSLKeySize

    int getSSLKeySize()

  Returns the SSL key size that the browser supports; only available if the user is connected through an active SSL connection. For example, 40 or 128. Note: Detection of this capability is not available on all web servers. It's required for servers that support Servlet API 2.3 and up, but not all are conformant. Returns -1 if the cipher suite is unrecognized. Returns 0 if no SSL information can be found. The ExtendedBrowserInfo.getSSLKeySize() property provides another mechanism to test this value when the servlet engine doesn't support SSL reporting.

### getStyleSheets

    boolean getStyleSheets()

  Returns whether the browser supports cascading style sheets (CSS).

### getTableBGColor

    boolean getTableBGColor()

  Returns whether the browser supports the ability to control the color of individual HTML table cells.

### getTableBGImage

    boolean getTableBGImage()

  Returns whether the browser supports the ability to display an image in the background of individual HTML table cells.

### getTables

    boolean getTables()

  Returns whether the browser supports the ability display HTML tables.

### getVBScript

    boolean getVBScript()

  Returns whether the browser supports VBScript.

### getVersion

    double getVersion()

  Returns the version of the browser. Example: For Netscape 4.05 getVersion() returns 4.05. Also see getMajorver(), getMinorver(), and getFullversion().

### getWAP

    boolean getWAP()

  Returns true for devices that support WML and WAP (Wireless Application Protocol), such as wireless phones. For example most modern wireless Internet phones use WML instead of HTML.

### getWAPDeviceModel

    java.lang.String getWAPDeviceModel()

  Contains the model of the WAP device if known, or "Unknown" if not. For example, the Ericsson R380 would be set to "R380".

### getWAPGateway

    java.lang.String getWAPGateway()

  Shows details of the UP.Link gateway if being used. For example "up1.upl.sprintpcs.com". Returns the empty string if none.

### getWAPMaxDeckSize

    int getWAPMaxDeckSize()

  Contains the approximate maximum number of bytes that the wireless device will support in a deck.

### getWAPSubscriberID

    java.lang.String getWAPSubscriberID()

  Automatically set to the unqiue subscriber ID of the WAP visitor when available. Currently requires visitor to be using UP.Link gateway.

### getWin16

    boolean getWin16()

  Returns whether the browser is running on a 16 bit Windows operating system, such as Windows 3.1.

### getXML

    boolean getXML()

  Returns whether the browser supports direct XML display.

### getEmailCrawler

    boolean getEmailCrawler()

  Returns whether the visiting agent is a crawler designed to scan your site for the purpose of collecting email addresses listed on your site's pages.

### getIFrames

    boolean getIFrames()

  Returns whether the browser supports the IFRAME tag.

### applyRules

    java.lang.String applyRules(java.lang.String ruleset)

  Applies the given set of rules and returns a String determined by the rules, or the empty string if no rule matches. This feature is only supported in the Enterprise version of the software. Other versions always return null.

### getResolveIP

    java.lang.String getResolveIP()

  Returns the hostname of the client making the web request, as a String, or null if it cannot be determined for any reason. For example, "daedalus.client.com". Attempts are made to use cached results whenever possible.

### getBDDVersion

    java.lang.String getBDDVersion()

  Returns the version of the BDD data file, for example "5.03a". The value is null if version information is not available.

### getBDDDate

    java.lang.String getBDDDate()

  Returns the date (as a String) for when the BDD data file was built, for example "5/1/2002 5:46:11 PM". The date and time are displayed as appropriate for the locale in which the BDD data file was built, which for official data files is always the US (mm/dd/yyyy). With user-built BDD data files the locale and date string may be different. The value is null if date information is not available.

### getNETCLRInstalled

    boolean getNETCLRInstalled()

  Returns whether the .NET CLR is installed on the client.

### getNETCLRVersion

    java.lang.String getNETCLRVersion()

  Returns the version of the .NET CLR installed on the client, or null if none or information not available. Currently requires IE 6 and up..

### getGecko

    boolean getGecko()

  Returns whether the client uses the Gecko rendering engine (developed by Mozilla.org).

### getGeckoBuildDate

    java.lang.String getGeckoBuildDate()

  Returns the build date of the Gecko rendering engine in the client, or null if none.

### getProxyString

    java.lang.String getProxyString()

  Returns the name of the proxy or proxies that acted on this request when that information is available, or the empty string if none.

### getWinInstallerMinVer

    double getWinInstallerMinVer()

  Returns the minimum version of the Windows Installer that is installed on the client. While it is not possible to determine if they have a later version, it is possible to deduce what the minimum version they must have installed is.

  Requires BrowserHawk Enterprise Edition.

### getCountry

    java.lang.String getCountry()

  Returns the 2-letter country code for the client. This is a convenience method that in order to work requires CountryHawk be installed and available on the system. If CountryHawk is not installed, this method will throw a BrowserHawkException. If CountryHawk is misconfigured, this method will throw a CountryException.

### getContainerBrowser

    java.lang.String getContainerBrowser()

  Returns the browser, if any, that surrounds the browsing environment. For example, Netscape 8 can "wrap" the Internet Explorer rendering engine. BrowserHawk will in this case return IE-related values for getBrowser(), getVersion(), and getFullversion() because those values matter most in choosing how to interact with the client. The getContainerBrowser() method allow the fetching of the container or "wrapper" browser, such as "Netscape" in the above example. Returns null if there's no container browser.

  This property on BrowserInfo can detect container browsers when identifying tokens are placed in the User-Agent sent from the client, such as when Netscape 8 or the AOL Browser wrap IE 6. The property by the same name on ExtendedBrowserInfo can detect these and additionally detect browser wrappings that require client-side JavaScript execution for detection such as when the Windows Media Player wraps IE 6.

### getContainerVersion

    double getContainerVersion()

  Returns the version of the browser, if any, that surrounds the browsing environment. For example, Netscape 8 can "wrap" the Internet Explorer rendering engine. BrowserHawk will in this case return IE-related values for getBrowser(), getVersion(), and getFullversion() because those values matter most in choosing how to interact with the client. The getContainerVersion() method allow the fetching of the container or "wrapper" browser version, such as "8.0" in the above example. Returns 0.0 if there's no container browser.

  This property on BrowserInfo can detect container browsers when identifying tokens are placed in the User-Agent sent from the client, such as when Netscape 8 or the AOL Browser wrap IE 6. The property by the same name on ExtendedBrowserInfo can detect these and additionally detect browser wrappings that require client-side JavaScript execution for detection such as when the Windows Media Player wraps IE 6.

### getContainerFullversion

    java.lang.String getContainerFullversion()

  Returns the full version of the browser, if any, that surrounds the browsing environment. For example, Netscape 8 can "wrap" the Internet Explorer rendering engine. BrowserHawk will in this case return IE-related values for getBrowser(), getVersion(), and getFullversion() because those values matter most in choosing how to interact with the client. The getContainerVersion() method allow the fetching of the container or "wrapper" browser version, such as "8.0.1" in the above example. Returns null if there's no container browser.

  This property on BrowserInfo can detect container browsers when identifying tokens are placed in the User-Agent sent from the client, such as when Netscape 8 or the AOL Browser wrap IE 6. The property by the same name on ExtendedBrowserInfo can detect these and additionally detect browser wrappings that require client-side JavaScript execution for detection such as when the Windows Media Player wraps IE 6.

### getXMLHttpRequest

    boolean getXMLHttpRequest()

  Returns whether this client supports the XMLHttpRequest object used for AJAX interactions.

### getMobileDevice

    boolean getMobileDevice()

  Returns whether this client is a mobile device (like a phone).

### getDeviceName

    java.lang.String getDeviceName()

  Returns for clients that are devices their specific device name (like iPhone, Blackberry, iPad, etc). Returns null or "" if the client is not a mobile device.

### toXML

    java.lang.String toXML()

  Returns an XML representation of all the BrowserInfo properties and their associated values. The root element includes metadata about the capture including the BrowserHawk version, license level installed, edition, BDD version, and timestamp in the ISO 8601 format. See also `ExtendedBrowserInfo.toXML()` and `BrowserHawk.toXML(BrowserInfo, ExtendedBrowserInfo)`.

### toXML

    java.lang.String toXML(java.util.Properties props)

  Returns an XML representation of all the BrowserInfo properties and their associated values. The root element includes metadata about the capture including the BrowserHawk version, license level installed, edition, BDD version, and timestamp in the ISO 8601 format. By passing a Properties object you can add additional attributes on the root, for example a user's login ID or department. It's left to the caller to ensure each key is a valid XML attribute name. See also `ExtendedBrowserInfo.toXML()` and `BrowserHawk.toXML(BrowserInfo, ExtendedBrowserInfo)`.

### get

    java.lang.Object get(java.lang.String propertyName)

  Returns the value of the property whose name is specified as a String. The name is case sensitive. The value returned may be of type String, Integer, Double, or Boolean. For example, to retrieve the ContainerVersion, you call

      Double d = (Double) info.get("ContainerVersion")

  .