Example #1
0
    public ILocalCourse CreateLocalCourse(string name, ITeacher teacher, string lab)
    {
        //returns a localCourse object
        ILocalCourse newLocalCourse = new LocalCourse(name, teacher, lab);

        return newLocalCourse;
    }
        static void Main(string[] args)
        {
            Course c1 = new LocalCourse("OOP2", "1234");

            c1.AddTopic("Using Classes and Objects", "Defining Classes", "OOP Principles", "Property");

            Course c2 = new LocalCourse("OOAD", "5678");

            c2.AddTopic("Introduction to Modelling", "Introduction to UML", "Use Case Diagram", "Class Diagram");

            Course c3 = new OffsiteCourse("Cyber Security", "Sylhet");

            c3.AddTopic("Security", "Encryption", "Algorithm", "Cyber Ethics");

            Teacher t1 = new Teacher("Victor Stany Rozario", "15-34939-1");

            t1.AddCourse(c1, c2);
            Teacher t2 = new Teacher("SUPTA RICHARD PHILIP", "14-54463-2");

            t2.AddCourse(c3);

            Student s1 = new Student("Borno", "18-36449-1");

            s1.AddTeacher(t2);
            s1.AddTeacher(t1);


            TeacherDetails(t1);
            TeacherDetails(t2);
            StudentDetails(s1);
        }
        private static void Main()
        {
            LocalCourse localCourse = new LocalCourse("DateBase", "Petar Petrov", "OpenSource");
            Console.WriteLine(localCourse);

            localCourse.AddStudent("Peter");
            localCourse.AddStudent("Maria");
            Console.WriteLine(localCourse);

            localCourse.AddStudent("Milena");
            localCourse.AddStudent("Todor");
            Console.WriteLine(localCourse);

            OffsiteCourse offsiteCourse = new OffsiteCourse("PHP and WordPress Development", "Mario Peshev", "Plovdiv");
            offsiteCourse.AddStudent("Thomas");
            offsiteCourse.AddStudent("Ani");
            offsiteCourse.AddStudent("Steve");
            Console.WriteLine(offsiteCourse);
        }
        public static void Main()
        {
            LocalCourse localCourse = new LocalCourse("Databases");
            Console.WriteLine(localCourse);

            localCourse.Lab = "Enterprise";
            Console.WriteLine(localCourse);

            localCourse.Students = new List<string>() { "Peter", "Maria" };
            Console.WriteLine(localCourse);

            localCourse.TeacherName = "Svetlin Nakov";
            localCourse.Students.Add("Milena");
            localCourse.Students.Add("Todor");
            Console.WriteLine(localCourse);

            OffsiteCourse offsiteCourse = new OffsiteCourse("PHP and WordPress Development", "Mario Peshev", new List<string>() { "Thomas", "Ani", "Steve" });
            Console.WriteLine(offsiteCourse);
        }
Example #5
0
        /// <summary>
        /// Defines the entry point of the application.
        /// </summary>
        public static void Main()
        {
            ICourse localCourse = new LocalCourse("Databases", "Svetlin Nakov", "Enterprise");
            Console.WriteLine(localCourse);

            localCourse.Students.Add("Peter");
            localCourse.Students.Add("Maria");
            Console.WriteLine(localCourse);

            localCourse.Students.Add("Milena");
            localCourse.Students.Add("Todor");
            Console.WriteLine(localCourse);

            ICourse offsiteCourse = new OffsiteCourse("PHP and WordPress Development", "Mario Peshev");

            offsiteCourse.Students.Add("Thomas");
            offsiteCourse.Students.Add("Ani");
            offsiteCourse.Students.Add("Steve");
            Console.WriteLine(offsiteCourse);
        }
        private static void Main()
        {
            var localCourse = new LocalCourse("Databases");
            Console.WriteLine(localCourse);

            localCourse.Lab = "Enterprise";
            Console.WriteLine(localCourse);

            localCourse.AddStudents("Peter", "Maria");
            Console.WriteLine(localCourse);

            localCourse.Teacher = "Svetlin Nakov";
            localCourse.AddStudents("Milena");
            localCourse.AddStudents("Todor");
            Console.WriteLine(localCourse);

            var offsiteCourse = new OffsiteCourse(
                "PHP and WordPress Development",
                "Mario Peshev",
                new List<string> { "Thomas", "Ani", "Steve" });
            Console.WriteLine(offsiteCourse);
        }
Example #7
0
        static void Main(string[] args)
        {
            // part 1
            LocalCourse localCourse = new LocalCourse("Databases");

            Console.WriteLine(localCourse);

            localCourse.Lab = "Enterprise";
            Console.WriteLine(localCourse);

            localCourse.Students = new List <string>()
            {
                "Peter", "Maria"
            };
            Console.WriteLine(localCourse);

            localCourse.TeacherName = "Svetlin Nakov";
            localCourse.Students.Add("Milena");
            localCourse.Students.Add("Todor");
            Console.WriteLine(localCourse);

            // part 2
            OffsiteCourse offsiteCourse = new OffsiteCourse
                                          (
                "PHP and WordPress Development",
                "Mario Peshev",
                new List <string>()
            {
                "Thomas",
                "Ani",
                "Steve"
            }
                                          );

            Console.WriteLine(offsiteCourse);
        }
Example #8
0
 public ILocalCourse CreateLocalCourse(string name, ITeacher teacher, string lab)
 {
     ILocalCourse localCourse = new LocalCourse(name, lab);
     localCourse.Teacher = teacher;
     return localCourse;
 }
        public ILocalCourse CreateLocalCourse(string name, ITeacher teacher, string lab)
        {
            LocalCourse myLocalCourse = new LocalCourse(name, teacher, lab);

            return myLocalCourse;
        }