Пример #1
0
        public static void Append(this Bulk bulk, ISelector filter, PipeLine pipeline)
        {
            var statement = new Statement()
            {
                Selector = filter, PipeLine = pipeline
            };

            bulk.Append(statement);
        }
Пример #2
0
 public static IWork InterpretDocument(string text, Context context)
 {
     Bulk bulk = new Bulk();
     StringReader reader = new StringReader(text);
     bool ok; 
     do
     {
         string statement = reader.ReadLine();
         bool skip = (string.IsNullOrWhiteSpace(statement)) || (statement.StartsWith("//"));
         ok = (statement != null);
         if (skip) continue;
         
         if (ok)
         {
             IWork work = InterpretStatement(context, statement);
             bulk.Append(work);
         }
     }
     while (ok);
     return bulk;
 }
Пример #3
0
        public static IWork InterpretDocument(string text, Context context)
        {
            Bulk         bulk   = new Bulk();
            StringReader reader = new StringReader(text);
            bool         ok;

            do
            {
                string statement = reader.ReadLine();
                bool   skip      = (string.IsNullOrWhiteSpace(statement)) || (statement.StartsWith("//"));
                ok = (statement != null);
                if (skip)
                {
                    continue;
                }

                if (ok)
                {
                    IWork work = InterpretStatement(context, statement);
                    bulk.Append(work);
                }
            }while (ok);
            return(bulk);
        }