Пример #1
0
        public static void aw()
        {
            DateTime time_start = new DateTime(DateTime.MinValue.Ticks);
            Writers  w          = new Writers();
            poisson  wpo        = new poisson();
            double   count      = 0;

            Console.WriteLine("writers call start()");
            while (true)
            {
                Thread.Sleep(17);
                if (wpo.is_new_product(DateTime.Now.ToOADate(), count))
                {
                    w.add();
                    count++;
                }
                w.start();
            }
        }
Пример #2
0
        public static void ar()
        {
            DateTime time_start = new DateTime(DateTime.MinValue.Ticks);
            Readers  r          = new Readers();
            poisson  rpo        = new poisson();
            double   count      = 0;

            Console.WriteLine("readers call start()");
            while (true)
            {
                Thread.Sleep(17);
                if (rpo.is_new_product(DateTime.Now.ToOADate(), count))
                {
                    r.add();
                    count++;
                }
                r.start();
            }
        }