2022-07-04 22:17:38 +08:00
|
|
|
|
/*
|
|
|
|
|
* <EFBFBD>ɼ<EFBFBD><EFBFBD><EFBFBD>DAO
|
|
|
|
|
*/
|
2022-07-06 15:40:27 +08:00
|
|
|
|
#ifndef GRADE_H
|
|
|
|
|
#define GRADE_H
|
2022-07-03 18:22:02 +08:00
|
|
|
|
|
|
|
|
|
#include<string>
|
|
|
|
|
using std::string;
|
|
|
|
|
|
|
|
|
|
class Grade {
|
|
|
|
|
public:
|
|
|
|
|
Grade() { ; }
|
|
|
|
|
Grade(string stuId, string courseId, string grade) {
|
|
|
|
|
this->stuId = stuId;
|
|
|
|
|
this->courseId = courseId;
|
|
|
|
|
this->grade = grade;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
string getStuId() { return stuId; }
|
|
|
|
|
void setStuId(string stuId) { this->stuId = stuId; }
|
|
|
|
|
string getCourseId() { return courseId; }
|
|
|
|
|
void setCourseId(string courseId) { this->courseId = courseId; }
|
|
|
|
|
double getGrade() { return atof(grade.c_str()); }
|
|
|
|
|
string getGradeStr() { return grade; }
|
|
|
|
|
void setGrade(string grade) { this->grade = grade; }
|
|
|
|
|
|
|
|
|
|
string toString() {
|
2022-07-04 15:59:30 +08:00
|
|
|
|
return stuId + "\t" + courseId + "\t" + grade;
|
2022-07-03 18:22:02 +08:00
|
|
|
|
}
|
|
|
|
|
private:
|
2022-07-04 22:17:38 +08:00
|
|
|
|
string stuId;//ѧ<><D1A7>
|
|
|
|
|
string courseId;//<2F>γ̺<CEB3>
|
|
|
|
|
string grade;//<2F>ɼ<EFBFBD>
|
2022-07-03 18:22:02 +08:00
|
|
|
|
};
|
|
|
|
|
|
2022-07-06 15:40:27 +08:00
|
|
|
|
#endif // !GRADE_H
|