/// <summary>
        /// Constructor for the class Lecturer without giving a lecturerID.
        /// ID will be generated autmatically.
        /// Should be used when creating a truly new object that is not yet stored.
        /// </summary>
        /// <param name="titleAndName">cannot be null</param>
        /// <param name="university">cannot be null</param>
        /// <param name="major">cannot be null</param>
        public Lecturer(string titleAndName, University university, Major major)
        {
            DataSearch ds = new DataSearch();

            Init(Guid.NewGuid(), titleAndName, university, major);
        }
예제 #2
0
 /// <summary>
 /// Construtor for the class Course without giving a courseID.
 /// Averages and amounts of rating categories will be set to 0.
 /// ID will be generated automatically.
 /// Should be used when creating a truly new object that is not yet stored.
 /// </summary>
 /// <param name="courseName">cannot be null</param>
 /// <param name="university">cannot be null</param>
 /// <param name="lecturer">cannot be null</param>
 /// <param name="since">cannot be null</param>
 /// <param name="major">cannot be null</param>
 public Course(string name, University university, Lecturer lecturer, Semester since, Major major)
 {
     Init(Guid.NewGuid(), name, university, lecturer, since, major);
 }
예제 #3
0
 /// <summary>
 /// Constructor for class Student with manually assigning a studentID.
 /// Should be used when recreating an object from the datafile
 /// </summary>
 /// <param name="studentID">cannot be null</param>
 /// <param name="studentName">cannot be null</param>
 /// <param name="university">cannot be null</param>
 /// <param name="userName">cannot be null</param>
 /// <param name="password">cannot be null</param>
 /// <param name="areaOfStudies">can be null</param>
 public Student(string userName, string password, University university,
                string areaOfStudies)
 {
     Init(Guid.NewGuid(), userName, password, university, areaOfStudies);
 }
예제 #4
0
        /// <summary>
        /// Constructor for the class Major without giving a majorID.
        /// ID will be generated automatically.
        /// Should be used when creating a truly new object that is not yet stored.
        /// </summary>
        /// <param name="name"></param>
        /// <param name="university"></param>
        public Major(string name, University university)
        {
            DataSearch ds = new DataSearch();

            Init(Guid.NewGuid(), name, university);
        }