Index
All Classes and Interfaces|All Packages
A
- addToCurrentSpellbooks(int) - Method in class Student
-
Adds a spellbook to the list of currently rented books.
- addToHistory(int) - Method in class SpellBook
-
Adds a student ID to the rental history of the spell book.
- addToHistory(int) - Method in class Student
-
Adds a spell book to the rental history.
- Archive - Class in Unnamed Package
-
Entry point for the spellbook archive system.
- Archive() - Constructor for class Archive
C
- checkEmptySpellbooks() - Method in class CommonErrorChecker
-
Checks if the spellbook map is empty.
- checkEmptyStudents() - Method in class CommonErrorChecker
-
Checks if the student map is empty.
- clearCurrentSpellbooks() - Method in class Student
- CommandHandler - Class in Unnamed Package
-
Handles user commands for managing students and spellbooks in the Hogwarts Archive system.
- CommandHandler() - Constructor for class CommandHandler
- CommonErrorChecker - Class in Unnamed Package
-
Class for validating common errors in system.
- CommonErrorChecker(Map<Integer, Student>, Map<Integer, SpellBook>) - Constructor for class CommonErrorChecker
-
Constructs a
CommonErrorCheckerwith the given student and spellbook maps.
G
- getCurrentSpellbooks() - Method in class Student
- getHistory() - Method in class SpellBook
-
Returns the rental history of the spell book.
- getHistory() - Method in class Student
- getInventor() - Method in class SpellBook
- getName() - Method in class Student
- getNumber() - Method in class Student
- getPrintableForm() - Method in class SpellBook
- getPrintableForm(boolean) - Method in class SpellBook
-
Returns a printable string representation of the spell book.
- getRentingStatus() - Method in class SpellBook
- getSerialNumber() - Method in class SpellBook
- getStudentRenting() - Method in class SpellBook
-
Returns the student ID currently renting the spell book.
- getTitle() - Method in class SpellBook
- getType() - Method in class SpellBook
H
- handleCommand(String) - Method in class CommandHandler
-
Parses and executes a user command.
I
- isMissingSpellbook(int) - Method in class CommonErrorChecker
-
Checks if a spellbook with the given serial number exists.
- isMissingStudent(int) - Method in class CommonErrorChecker
-
Checks if a student with the given ID exists.
M
- main(String[]) - Static method in class Archive
-
Starts the command-line interface for the Hogwarts Archive system.
R
- removeSpellbook(int) - Method in class Student
-
Removes a spell book from the list of currently rented books.
- resetStudentId() - Static method in class Student
-
Resets the student ID counter to its initial value between testcases.
S
- setInventor(String) - Method in class SpellBook
- setName(String) - Method in class Student
- setSerialNumber(int) - Method in class SpellBook
- setStudentRenting(int) - Method in class SpellBook
- setTitle(String) - Method in class SpellBook
- setType(String) - Method in class SpellBook
- SpellBook - Class in Unnamed Package
-
The
SpellBookclass represents a magical book in a library system. - SpellBook(int, String, String, String) - Constructor for class SpellBook
-
Constructs a new
SpellBookwith the specified details. - spellbookNotRentedByStudent(int, int) - Method in class CommonErrorChecker
-
Checks if the specified spellbook is currently rented by the given student.
- Student - Class in Unnamed Package
-
Represents a
studentwho can rent spell books. - Student(String) - Constructor for class Student
-
Constructs a new
Studentwith a unique student ID and the given name.
All Classes and Interfaces|All Packages