
π Student Projects (College Reports) Β· Class UML
Classes for results and attendance, with a grading policy that can change.
Drawing diagramβ¦
Class diagram for a student result management system: Student has Enrolments; Enrolment links a Subject and holds Marks and AttendanceRecords and can compute attendance percentage; GradingPolicy is an interface with AbsoluteGrading and RelativeGrading; ResultCalculator uses a grading policy to produce a SemesterResult; ReportCard is built from semester results.
classDiagram
class Student {
+String rollNo
+String name
+enrolments() List~Enrolment~
}
class Subject {
+String code
+String title
+int credits
}
class Enrolment {
+String semester
+attendancePercent() decimal
+totalMarks() decimal
}
class Mark {
+String assessment
+decimal marks
+decimal maxMarks
}
class AttendanceRecord {
+Date classDate
+bool present
}
class GradingPolicy {
<<interface>>
+gradeFor(decimal percent) String
}
class AbsoluteGrading {
+gradeFor(decimal percent) String
}
class RelativeGrading {
+gradeFor(decimal percent) String
}
class ResultCalculator {
+calculate(Student, String semester) SemesterResult
}
class SemesterResult {
+decimal sgpa
+decimal cgpa
}
class ReportCard {
+generatePdf() void
}
Student "1" --> "many" Enrolment
Enrolment --> Subject
Enrolment "1" *-- "many" Mark
Enrolment "1" *-- "many" AttendanceRecord
GradingPolicy <|.. AbsoluteGrading
GradingPolicy <|.. RelativeGrading
ResultCalculator --> GradingPolicy
ResultCalculator ..> SemesterResult : creates
ReportCard o-- SemesterResultWho uses a college library system and what each of them can do: members, the librarian and the system administrator.
The database of a library system: books and their copies, authors, members, loans, reservations and fines, with keys and cardinality.
How data moves through a library system: members and the librarian, the main processes, and the data stores they read and write.
The main classes of a library system with attributes, methods and UML relationships.
The steps when a member borrows a book: checks, loan record and the copy status update.
What students, examiners and the administrator do in an online examination system.