use of com.gargoylesoftware.htmlunit.javascript.RecursiveFunctionObject in project htmlunit by HtmlUnit.
the class Intl method define.
private void define(final Class<? extends HtmlUnitScriptable> c, final BrowserVersion browserVersion) {
try {
final ClassConfiguration config = AbstractJavaScriptConfiguration.getClassConfiguration(c, browserVersion);
final HtmlUnitScriptable prototype = JavaScriptEngine.configureClass(config, this, browserVersion);
final FunctionObject functionObject = new RecursiveFunctionObject(c.getSimpleName(), config.getJsConstructor(), this);
if (c == V8BreakIterator.class) {
prototype.setClassName("v8BreakIterator");
}
functionObject.addAsConstructor(this, prototype);
} catch (final Exception e) {
throw Context.throwAsScriptRuntimeEx(e);
}
}
Aggregations