public static void Initialization(NSJSVirtualMachine machine) { if (machine == null) { throw new ArgumentNullException("machine"); } var extension = machine.GetExtension(); extension.Set("setTimeout", g_setTimeoutProc); extension.Set("setInterval", g_setIntervalProc); extension.Set("clearTimeout", g_clearTimeoutProc); extension.Set("clearInterval", g_clearIntervalProc); }
public static void Initialization(NSJSVirtualMachine machine) { if (machine == null) { throw new ArgumentNullException("machine"); } Timer.Initialization(machine); var extension = machine.GetExtension(); extension.Set("console", Console.ClassTemplate); extension.Set("alert", g_AlertProc); extension.Set("using", g_UsingProc); extension.Set("require", g_RequireProc); extension.Set("System", NSJSVirtualMachine.GetSystemTemplate()); }