Module org.htmlunit

Class NativeFunctionToStringFunction

java.lang.Object
org.htmlunit.javascript.NativeFunctionToStringFunction

public final class NativeFunctionToStringFunction extends Object
Replacement (in fact a wrapper) for Rhino's native toString function on Function prototype allowing to produce the desired formatting.
Author:
Marc Guillemot, Ronald Brill, Ahmed Ashour
  • Method Details

    • installFix

      public static void installFix(org.htmlunit.corejs.javascript.VarScope scope, BrowserVersion browserVersion)
      Install the wrapper in place of the native toString function on Function's prototype.
      Parameters:
      scope - the scope
      browserVersion - the simulated browser