Write() public method

public Write ( string text ) : void
text string
return void
Exemplo n.º 1
0
 protected void OnConsoleWrite(EvaluationContext context, string text)
 {
     if (ConsoleWrite != null)
     {
         ConsoleWriteEventArgs args = new ConsoleWriteEventArgs(text);
         ConsoleWrite(this, args);
     }
     context.Write(text);
 }
Exemplo n.º 2
0
        private void EvaluateParsedScript()
        {
            var iRoot = GetAstInterface();

            if (iRoot == null)
            {
                return;
            }
            EvaluationContext.ClearLastResult();
            var start = Environment.TickCount;

            iRoot.Evaluate(EvaluationContext, AstMode.Read);
            EvaluationContext.EvaluationTime = Environment.TickCount - start;
            if (EvaluationContext.HasLastResult)
            {
                EvaluationContext.Write(EvaluationContext.LastResult + Environment.NewLine);
            }
        }