示例#1
0
 private void RunScript(string script)
 {
     _asyncronousEngine = new AsyncronousEngine();
     _asyncronousEngine.EmbedScriptAssemblies.Add(Assembly.GetExecutingAssembly());
     _asyncronousEngine.Engine.SetValue("storage", new Storage(_asyncronousEngine));
     _asyncronousEngine.RequestFileExecution(script, block: true);
 }
示例#2
0
        static void SetIntervalDemo()
        {
            Console.WriteLine("Jint setInterval() demo");

            var ae = new AsyncronousEngine();

            ae.EmbedScriptAssemblies.Add(Assembly.GetExecutingAssembly());
            ae.RequestFileExecution("setIntervalSetTimeoutNested.js");

            Console.WriteLine("Hit a key to stop");
            Console.ReadKey();
            ae.RequestClearQueue();

            Console.WriteLine("*** Done ***");
            Console.ReadKey();
        }
示例#3
0
 private void butSynchronousExecution_Click(object sender, EventArgs e)
 {
     _asyncronousEngine.RequestFileExecution("SynchronousExecution.js");
 }
 private void RunScript(string script)
 {
     Init();
     _asyncronousEngine.RequestFileExecution(script, block: true);
 }
示例#5
0
 public void SynchronousExecution()
 {
     _asyncronousEngine.RequestFileExecution("SynchronousExecution.js");
 }