/****************************************************************************** * CS1CStudent() * This constructor will receive the student's name and id and create a * student object with that info *****************************************************************************/ CS1CStudent::CS1CStudent(string studentName, //The Student's Name int studentId) //The Student's ID : Student(studentName, studentId) { setTotalScore(0); setPythonKnowledge(false); }
/****************************************************************************** * CS1CStudent() * This constructor will receive the student's name, id, phone number, age, * class standing, gpa and create a student object with that info *****************************************************************************/ CS1CStudent::CS1CStudent(string studentName, //Student's Name int studentId, //Student's ID long long studentPhoneNum, //Student's Phone Number int studentAge, //Student's Age char studentGender, //Student's Gender string studentClass, //Student's Class Standing double studentGPA, //Student's GPA double studentTotalScore, //Student's Total Scores bool studentPythonKnow, //Student's Python Knowledge int studentGradMonth, //Student's Grad Month int studentGradDay, //Student's Grad Day int studentGradYear) //Student's Grad Year : Student(studentName, studentId, studentPhoneNum, studentAge, studentGender, studentClass, studentGPA) { setTotalScore(studentTotalScore); setPythonKnowledge(studentPythonKnow); setGradDate(studentGradMonth, studentGradDay, studentGradYear); }
/****************************************************************************** * CS1CStudent() * This default constructor will create a Student object *****************************************************************************/ CS1CStudent::CS1CStudent() : Student() { setTotalScore(0); setPythonKnowledge(false); }
/* 加累积分数 */ void ScoreControl::addTotalScore(int nScore) { setTotalScore(m_nTotalScore+nScore); }