Beispiel #1
0
        public void AddWorkers()
        {
            bool AddWorker = true;

              while (AddWorker)
              {

              string name;
              DateTime birthDate;
              float baseSalary;
              string profile;
              name = GetData.Name();
              birthDate = GetData.Date();
              baseSalary = GetData.Salary();
              profile = GetData.Profile();
              Worker CreateNew = new Worker(name, birthDate, baseSalary, profile);

              Workers.Add(CreateNew);

              //quit or continue option
              Console.WriteLine("Do u want to add user? Y/N:");
              ConsoleKeyInfo choise = Console.ReadKey();
              AddWorker = Decision.AddOrQuit(AddWorker, choise);
              }
        }
Beispiel #2
0
        static void Main(string[] args)
        {
            Worker Ravshan = new Worker();
            Worker Djumschut = new Worker();
            TeamLeader Naschalnika = new TeamLeader();

            Naschalnika.Report();

            while (!Home.done)
            {
                Thread.Sleep(200);

                Ravshan.build(ref Home.parts);
                Djumschut.build(ref Home.parts);

                Naschalnika.Report();
            }

            Naschalnika.Report();
        }