Esempio n. 1
0
        public static void ManualInput(string id, string nameSurname, string departmanName, string undergraduateSchoolName, string undergraduateDepartmanName, params Temp[] lectures)
        {
            GraduateStudent graduateStudent = new GraduateStudent(undergraduateSchoolName, undergraduateDepartmanName);

            graduateStudent.Id            = id;
            graduateStudent.NameSurname   = nameSurname;
            graduateStudent.DepartmanName = departmanName;
            foreach (Temp lecture in lectures)
            {
                graduateStudent.LectureAdd(lecture.code, lecture.name, lecture.mark, lecture.akts);
            }
            students.Add(graduateStudent);
        }
Esempio n. 2
0
 static public void StudentAdd()
 {
     while (true)
     {
         int chooseP;
         Console.WriteLine("1-Add Undergraduate Student");
         Console.WriteLine("2-Add Graduate Student");
         Console.WriteLine("3-Add Phd Student");
         Console.WriteLine("Choose :");
         chooseP = Convert.ToInt32(Console.ReadLine());
         Console.Clear();
         if (chooseP == 1)
         {
             UndergraduateStudent undergraduateStudent = new UndergraduateStudent();
             AddDefaultInfo(undergraduateStudent);
         }
         else if (chooseP == 2)
         {
             Console.WriteLine("Student's Undergraduate School Name:");
             string undergraduateSchoolName = Console.ReadLine();
             Console.WriteLine("Student's Undergraduate Departman Name:");
             string          undergraduateDepartmanName = Console.ReadLine();
             GraduateStudent graduateStudent            = new GraduateStudent(undergraduateSchoolName, undergraduateDepartmanName);
             AddDefaultInfo(graduateStudent);
         }
         else if (chooseP == 3)
         {
             Console.WriteLine("Student's Undergraduate School Name:");
             string undergraduateSchoolName = Console.ReadLine();
             Console.WriteLine("Student's Undergraduate Departman Name:");
             string undergraduateDepartmanName = Console.ReadLine();
             Console.WriteLine("Student's Graduate School Name:");
             string graduateSchoolName = Console.ReadLine();
             Console.WriteLine("Student's Graduate Departman Name:");
             string     graduateDepartmanName = Console.ReadLine();
             PhdStudent graduateStudent       = new PhdStudent(undergraduateSchoolName, undergraduateDepartmanName, graduateDepartmanName, graduateSchoolName);
             AddDefaultInfo(graduateStudent);
         }
         else
         {
             Console.WriteLine("Wrong Choice!");
             Console.ReadKey();
             Console.Clear();
             continue;
         }
         Console.Clear();
     }
 }