com.gargoylesoftware.htmlunit.javascript.configuration
Class JavaScriptConfiguration

java.lang.Object
  extended by com.gargoylesoftware.htmlunit.javascript.configuration.JavaScriptConfiguration

public final class JavaScriptConfiguration
extends Object

A container for all the JavaScript configuration information.

Version:
$Revision: 8606 $
Author:
Mike Bowler, Chris Erskine, Ahmed Ashour

Method Summary
 Iterable<ClassConfiguration> getAll()
          Gets all the configurations.
 ClassConfiguration getClassConfiguration(String hostClassName)
          Gets the class configuration for the supplied JavaScript class name.
 Map<Class<?>,Class<? extends SimpleScriptable>> getDomJavaScriptMapping()
          Returns an immutable map containing the DOM to JavaScript mappings.
static JavaScriptConfiguration getInstance(BrowserVersion browserVersion)
          Returns the instance that represents the configuration for the specified BrowserVersion.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

getInstance

public static JavaScriptConfiguration getInstance(BrowserVersion browserVersion)
Returns the instance that represents the configuration for the specified BrowserVersion. This method is synchronized to allow multi-threaded access to the JavaScript configuration.

Parameters:
browserVersion - the BrowserVersion
Returns:
the instance for the specified BrowserVersion

getAll

public Iterable<ClassConfiguration> getAll()
Gets all the configurations.

Returns:
the class configurations

getClassConfiguration

public ClassConfiguration getClassConfiguration(String hostClassName)
Gets the class configuration for the supplied JavaScript class name.

Parameters:
hostClassName - the js class name
Returns:
the class configuration for the supplied JavaScript class name

getDomJavaScriptMapping

public Map<Class<?>,Class<? extends SimpleScriptable>> getDomJavaScriptMapping()
Returns an immutable map containing the DOM to JavaScript mappings. Keys are java classes for the various DOM classes (e.g. HtmlInput.class) and the values are the JavaScript class names (e.g. "HTMLAnchorElement").

Returns:
the mappings


Copyright © 2002–2013 Gargoyle Software Inc.. All rights reserved.