ice.util
Class Emulation

java.lang.Object
  extended byice.util.Emulation

public class Emulation
extends Object

Emulation class is used to provide current IB emulation mode information from a single source.

Since:
v6.0

Constructor Summary
Emulation()
           
 
Method Summary
static String getEmulatedAppCodeName()
          Gets the current browser emulation mode appName.
static String getEmulatedAppName()
          Gets the current browser emulation appName.
static String getEmulatedAppVersion()
          Gets the current browser emulation appVersion.
static String getEmulatedPlatform()
          Gets the current emulated browser platform description.
static String getEmulatedUserAgent()
          Gets the current emulated user-agent string.
static String getEmulationMode()
          Gets the current browser emulation mode, as defined by the current value of the "ice.browser.emulation" system property.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Emulation

public Emulation()
Method Detail

getEmulationMode

public static String getEmulationMode()
Gets the current browser emulation mode, as defined by the current value of the "ice.browser.emulation" system property.

This method returns one of the following values:

Note: If a value other than those specified above is returned, ICEbrowser native mode is enabled (no emulation).

Returns:
String the current emulation mode (i.e. "ie", "ns", "ns6", "")

getEmulatedAppCodeName

public static String getEmulatedAppCodeName()
Gets the current browser emulation mode appName.

This is always "Mozilla".

Returns:
String the emulation appName ("Mozilla")

getEmulatedAppName

public static String getEmulatedAppName()
Gets the current browser emulation appName.

If the "ice.browser.appName" system property is defined its value is returned, otherwise a value associated with the current emulation mode is returned.

Returns:
String the emulation mode appName(i.e. "Microsoft Internet Explorer", "Netscape", "ICEbrowser", etc.)

getEmulatedAppVersion

public static String getEmulatedAppVersion()
Gets the current browser emulation appVersion.

If the "ice.browser.appVersion" system property is defined, that is returned otherwise a value associated with the current emulation mode is returned.

Returns:
String the emulation mode appVersion (e.g. "4.0 (compatible; MSIE 6.0; Windows NT 5.0; ICEbrowser)")

getEmulatedPlatform

public static String getEmulatedPlatform()
Gets the current emulated browser platform description.

A value associated with the current emulation mode and hardware/software platform is returned.

Returns:
String the emulated platform description (e.g. "Windows XP 5.1 x86")

getEmulatedUserAgent

public static String getEmulatedUserAgent()
Gets the current emulated user-agent string.

If the "ice.browser.http.agent" system property is defined its value is returned, otherwise a value associated with the current emulation mode is returned.

Returns:
String the emulation mode user-agent (e.g. "Mozilla/5.0 (Java 1.4.2_02; Windows XP 5.1 x86; en) ICEbrowser/v6_0")